Skip to content

FastCWM: Streaming Code World Models That Learn from Their Own Renders

Hao Wu, Fan Zhang, Yuqi Li, Yizhou Zhao, Yingli Tian, Linsey Pang, Prakhar Mehrotra, Qingsong Wen, Ming-Hsuan Yang

cs.CV

Abstract

Code world models combine executable scene programs with video diffusion for physically structured simulation, yet existing pipelines compile full scripts before offline rendering. Consequently, mid-stream user edits take minutes and force full prefix recomputation, while open-loop execution prevents the code policy from learning from rendered frames. We introduce FastCWM, a chunk-synchronized code world model that allows users to steer a simulation in seconds without re-rendering prefix history and learns from its own rendered feedback. At each 1717-frame causal chunk, a code agent emits compact state-transition patches ΔctΔc_t over explicit 33D proxies, while a 44-step streaming renderer synthesizes matching video frames over a sliding key-value cache so edits branch immediately from cached memory. One-to-one chunk alignment further enables render-in-the-loop learning during offline training, where physical and visual verifiers localize errors to individual patches and resample suffixes from cached states before distilling repairs into single-pass inference. Evaluated on our FastCWM-Bench suite across five rigid-body and articulated domains plus a held-out split, FastCWM runs at 0.38×0.38\times real-time playback pacing (1.851.85 s per 0.710.71 s chunk on five H100100 GPUs) while keeping interactive edit latency to 3.733.73 s (4.34.3 s warm start) and reaching 83.1%83.1\% task success. We plan to release the model weights and source code.

Create a lesson

Metadata

Categories
cs.CV, cs.AI
Comments
18 pages, including supplementary material