Video-Coder:强化视频生成的智能体编码

·

研究论文 · 2026/11/09

本文提出Video-Coder,首个通过编写和执行代码构建动态3D场景(草稿视频)以指导下游视频生成的智能体。为支持该范式,作者设计了数据管道并构建了Video-Coder-SFT-6k和Video-Coder-RL-2k数据集,开发了集成代码执行、3D渲染和反馈的Video-Coder Harness环境。采用SFT后接基于双奖励(执行奖励和视频奖励)的强化学习训练,并引入退火策略逐步减少执行奖励。实验表明,Video-Coder将Minimax-H3在PhyGenBench上提升约7分,在VBench-2.0上提升24分。

该工作开创了代码驱动视频生成的新范式,通过智能体编写代码构建3D场景来增强生成视频的结构与运动控制,实验提升显著,且完全开源,对视频生成和智能体交叉领域有重要参考价值。

Recent years have witnessed remarkable progress in video generation in terms of visual quality and temporal consistency. However, generating videos with precise spatial structure, coherent motion dynamics, and controllable scene composition remains challenging. In this paper, we introduce Video-Coder, the first attempt to train a code-driven video generation agent, which autonomously writes and executes code to construct a dynamic 3D scene (Draft Video) that provides structure and motion signals to downstream video generators. To support this paradigm, we design a dedicated data pipeline and curate two high-quality datasets, Video-Coder-SFT-6k and Video-Coder-RL-2k, which contain diverse prompts and ground-truth reference videos. We further develop the Video- Coder Harness, a unified interactive environment integrating code execution, 3D scene rendering, and execution feedback for agent training and inference. We then train Video-Coder with SFT fol- lowed by harness-native agentic reinforcement learning with dual reward feedback, which combines execution-based and video-based rewards. Additionally, we design an annealing training strategy that gradually reduces the execution reward over time, allowing the model to rely more on the video reward in the later training stages. Experiments show that Video-Coder achieves significant gains, improving Minimax-H3 by approximately 7 points on PhyGenBench and 24 points on VBench-2.0. We hope this work can serve as an open foundation for coding agents in video generation, and we fully open-source our data, models, and code

阅读原文

参与讨论