TL;DR
Video generators can make stunningly realistic clips, yet they often fail at basic logic, physics, and multi-step planning because they lack training data and dedicated memory spaces for step-by-step deduction. OpenCoF tackles this by introducing a diverse 17K-video reasoning dataset and equipping video diffusion transformers with learnable "scratchpad" tokens—teaching models not just to render pixels, but to visually think frame by frame.
What Problem Does This Paper Address?
When language models tackle hard problems, they use Chain-of-Thought (CoT)—writing out intermediate steps before landing on an answer. What is the visual equivalent for dynamic, physical, or spatial problems? Enter Chain-of-Frame (CoF) reasoning: letting a model work through a problem via the temporal evolution of video frames (like folding a 2D net into a 3D cube or sliding a block down a friction-filled ramp).
While modern video generators look cinematic, visual realism doesn't equal logical consistency. Trained mostly on general internet video, existing models struggle with physical rules and multi-step consequences. Furthermore, Diffusion Transformer (DiT) architectures have no dedicated place to hold an intermediate "plan"—forcing any reasoning to hide implicitly inside noisy pixel latents. Prior attempts to improve video reasoning have mostly stuck to narrow tasks (like maze-solving) without testing out-of-distribution generalization or modifying internal model mechanics.
Methods
The authors separate the effect of better data from better architecture using an open-source image-to-video backbone (Wan2.2-I2V-A14B):
- Data-Only Fine-Tuning (
Wan-CoF): First, they fine-tune the baseline model using standard LoRA on their new reasoning dataset without changing the architecture. This establishes how much reasoning emerges purely from diverse temporal supervision. - Reasoning Tokens (
vtandtt): Next, to give the DiT an explicit "working memory," they introduce two separate, architecture-agnostic token mechanisms: - Visual Reasoning Tokens (
vt): Learnable tokens prepended directly to the flattened 1D sequence of compressed video latents. Inside every DiT block,vttokens interact bidirectionally with video patches via self-attention—aggregating global visual context and broadcasting updates back—before being discarded at the end. - Textual Reasoning Tokens (
tt): Learnable tokens prepended to the text-encoder prompt sequence. They enter via cross-attention as static, unidirectional key/value context, acting as a learned, prompt-independent high-level rule prior shared across all frames.
Datasets
To train the models, the authors introduce OpenCoF-17K, containing 17,312 standardized videos (480p, 15 fps, 81 frames) paired with an initial image and text prompt across 11 task families. Unlike prior datasets relying solely on procedural generation, OpenCoF-17K blends four pipelines:
- Instance-based rendering: Chess (mate-in-one) and $4\times4$ Sudoku.
- Expert-guided rendering: 2D geometry auxiliary lines (human-annotated from Geo170K) and dot-to-dot animations (LLM + text-to-image + CV).
- Procedural scene synthesis: Tangram puzzles, 3D cube folding, 3D polycube rotation, and physics motion (tracks with varying friction).
- External video repurposing: Curated subsets from VR-Bench (mazes), BridgeData V2 (robotic manipulation), and VBVR (30 cognitive subtasks).
Crucially, evaluation is performed strictly out-of-distribution on four independent, externally curated benchmarks: MME-CoF, Gen-ViRe, VIPER, and RULER-Bench.
Key Insights and Ideas
- Supervision transfers across domains: Training on OpenCoF-17K doesn't just memorize puzzle formats; skills transfer to unseen external benchmarks (e.g., training on simulated ramps boosts VIPER Physics; grid games boost Gen-ViRe Algorithmic & Logical scores).
- Visual vs. Textual tokens divide and conquer: Attention maps reveal a fascinating division of labor.
vtacts like a spatial-temporal planner—firing strongly at the start (anchoring initial states) and end (resolving final consequences) of videos, with sparse, localized spatial focus (e.g., right on a robot gripper). Conversely,ttacts like a steady semantic rulebook—attending diffusely across the whole workspace and staying evenly active once motion begins. - Early denoising is "planning time": Both token types receive their heaviest attention during early, high-noise diffusion steps—confirming that the model leans on reasoning tokens while global structure and motion trajectories are still being decided, before tapering off during late-stage pixel refinement.
Key Results
Fine-tuning on OpenCoF-17K (Wan-CoF) substantially lifts the Wan2.2 baseline across all four external benchmarks, and adding reasoning tokens pushes performance even further:
- MME-CoF (0–4 scale): Baseline
1.00$\rightarrow$Wan-CoF1.30(+30%) $\rightarrow$Wan-CoF_tt1.35(+35%), surpassing open-source HunyuanVideo-I2V (0.98) and nearing closed-source Seedance-1.0-Pro (1.48). - Gen-ViRe (0–1 scale): Baseline
0.304$\rightarrow$Wan-CoF0.391(+29%) $\rightarrow$Wan-CoF_vt0.441(+45%). - VIPER (0–100 POC): Baseline
3.3$\rightarrow$Wan-CoF7.5(+127%) $\rightarrow$Wan-CoF_tt8.8(+167%), matching open-source Hunyuan-1.5 (8.1). - RULER-Bench (0–100 I2V): Baseline
55.8$\rightarrow$Wan-CoF56.8$\rightarrow$Wan-CoF_vt59.6(+6.8%).
In sub-category breakdowns, vt excels at maintaining persistent visual plans (VIPER Planning jumps from 5.3 to 15.8), while tt shines on structural rules and prompt adherence.
Limitations and Future Work
The primary limitation acknowledged by the authors is that Visual Reasoning Tokens (vt) and Textual Reasoning Tokens (tt) were only trained and studied in isolation. Because empirical results and attention analyses show they play highly complementary roles—low-level spatial boundary tracking versus steady high-level semantic constraints—figuring out how to unify both token mechanisms effectively into a single model is the most promising next step.
Summary updated