TL;DR
Current video generation models excel at creating visually realistic scenes but frequently violate basic laws of physics when encountering unfamiliar scenarios. To bridge this gap, researchers have introduced Phys-AR, a framework that transforms video frames into language-like, recursive "Diffusion Timestep Tokens" that allow Large Language Models (LLMs) to symbolically reason about motion. By optimizing this setup with physics-informed reinforcement learning, the model successfully extrapolates to unseen physical conditions, generating videos that strictly adhere to principles like gravity, velocity, and mass conservation.
What Problem Does This Paper Address?
While state-of-the-art video diffusion models (like Sora or CogVideoX) generate stunning visuals, they don't actually "understand" physics. Instead, they rely on data-driven approximations, statistically interpolating patterns from their training data. Consequently, when forced to extrapolate to out-of-distribution (OOD) scenarios—such as an object moving at an unprecedented velocity—they break down, producing trajectories that defy first-principle equations.
A major roadblock to fixing this is how we tokenize visual data. Standard visual tokenizers (like VQGAN) slice images into spatial patches arranged in a grid. This spatial arrangement lacks the hierarchical, sequential dependencies inherent to natural language, making it highly incompatible with the symbolic reasoning mechanisms of LLMs.
Methods
To enable LLMs to reason about physics within videos, the authors developed a two-part framework consisting of a novel tokenizer and a two-stage training pipeline:
- Diffusion Timestep Tokenizer (DDT): Instead of spatial patches, DDT learns discrete, recursive visual tokens by leveraging the diffusion process itself. As Gaussian noise is incrementally added to an image, visual attributes are gradually erased. The DDT encoder constructs a 1D sequence of tokens that recursively expands to compensate for these lost attributes at each timestep. This results in a language-like structure where specific tokens decouple and represent distinct visual features (e.g., position vs. object radius).
- Phys-AR Framework: With video frames successfully converted into a symbolic string of DDT tokens, the model undergoes a two-stage training process:
- Stage 1: Supervised Fine-Tuning (SFT): The LLM's vocabulary is expanded to include the DDT tokens, and it is trained on standard next-token prediction to master the "grammar" of the visual symbols.
- Stage 2: Post-Training via Reinforcement Learning (RL): To move past simple pattern memorization, the authors apply Group Relative Policy Optimization (GRPO). The model is guided by a rule-based physical reward function that penalizes errors in velocity trajectories and object mass (radius).
Datasets
The framework was evaluated using synthetic physical motion videos from PhyWorld. The dataset includes 2D simulations across three distinct scenarios:
- Uniform Motion
- Parabolic Motion (Gravity)
- Elastic Collisions
To rigorously test the model's ability to generalize, the dataset was split strictly by physical parameters. The model was pre-trained on mid-range ball radii ($r \in [0.8, 1.4]$) and velocities ($v \in [1.5, 3.5]$), and evaluated on extreme, out-of-distribution (OOD) ranges ($r \in [0.3, 0.6] \cup [1.5, 2.0]$ and $v \in [0, 0.8] \cup [4.5, 6.0]$).
Key Insights and Ideas
- Spatial Tokens Introduce "Semantic Antonyms": The authors discovered that spatial tokenizers create a form of spatial symmetry when an image is modified. This introduces a negative cosine similarity (effectively a semantic "antonym") that does not exist in natural language, disrupting an LLM's ability to perform logical reasoning. DDT tokens avoid this entirely.
- DDT Tokens Behave Like Language: Through counterfactual interpolation (swapping subsets of tokens between different images), the authors proved that DDT tokens cleanly disentangle attributes. Swapping a "position token" changes only the position of the ball, whereas spatial tokenizers result in messy, patch-based blending (similar to CutMix).
- RL Acts as the Physics Teacher: Much like how memorizing numbers doesn't make a human good at calculus, next-token prediction isn't enough for an LLM to master physics. The reinforcement learning stage forces the model to iteratively self-correct its inference path based on verifiable physical laws.
Key Results
When tested on out-of-distribution data, standard Diffusion Transformers (DiT) and spatial-token autoregressive models failed significantly, showing high trajectory deviations. In contrast, Phys-AR (AR+DDT) maintained physical consistency:
- Velocity Error Reduction: On OOD data, Phys-AR achieved a velocity error magnitude of $10^{-2}$, outperforming DiT and spatial AR models which sat at a much higher error magnitude of $10^{-1}$.
- Model Scaling Effects: For traditional diffusion models, simply adding more parameters (scaling from DiT-S to DiT-L) did not fix physical errors. However, for the autoregressive Phys-AR setup, scaling the underlying LLM architecture (e.g., from Qwen-1.5B to Llama-3.1-8B) dramatically improved physical reasoning capacity and lowered OOD errors.
Limitations and Future Work
While promising, the current iteration of Phys-AR is limited to simple, simulated 2D environments with clear, easily parameterized physics (balls moving in a grid). Real-world videos feature complex, multi-object interactions, occlusions, and chaotic dynamics that make designing explicit rule-based reward functions incredibly challenging.
Moving forward, the authors plan to scale the training of the DDT-tokenizer and the multimodal LLM to a massive dataset of roughly 500 million images, aiming to extend this symbolic physical reasoning approach to more generalized video understanding and text-to-image generation tasks.
Summary updated