World Models
- Ha & Schmidhuber (2018) World Models paper formalized the idea of a learned internal model of the environment
- Tesla FSD and Google DeepMind systems use world models for autonomous driving and robotics planning
- GPT-4 exhibits implicit world modeling: it can simulate physical and social scenarios described in text
A world model is a neural network that learns to predict what will happen next in an environment (images, physics, outcomes of actions). It enables planning without executing real actions, allowing agents to explore hypothetical futures in imagination rather than in reality.
- Connects directly to model-based reinforcement learning - the agent plans using the world model
- Video prediction models (Sora, DALL-E video) are world models specialized for visual environments
- Connects to memory-augmented neural networks and cognitive science theories of mental simulation
- Define what makes a model a "world model" and distinguish it from a generative model or a policy.
- Explain the Recurrent State Space Model (RSSM) in DreamerV3 and why planning in latent space beats pixel-space planning.
- Describe how video generation models like GAIA-1 and Genie serve as implicit world models.
- Identify the key open problems: partial observability, physical plausibility, and long-horizon consistency.
- Connect world models to the broader goal of autonomous machine intelligence as framed by LeCun (2022).
A world model is a learned internal simulator: given the current state and an action, it predicts the next state (and reward). Ha and Schmidhuber [1] showed that an agent could train entirely inside its own dream. DreamerV3 [2] scales this to diverse domains via a compact latent space. Video generation models — GAIA-1, Genie [3] — extend the idea to controllable video, where the generated frames are the “world” that an agent can interact with.
Intuition
A chess engine does not play moves on a real board and wait for consequences; it imagines future positions and evaluates them. A world model gives a neural agent the same capability: instead of collecting every training example by interacting with the real environment (which is slow, expensive, or dangerous), the agent rolls out imagined trajectories inside a learned model of the environment.
The key insight from Ha and Schmidhuber 2018 is that if the world model is accurate enough, an agent can train its policy entirely on imagined data (“in the dream”) and then transfer zero-shot to the real environment. Even imperfect world models provide a sample-efficiency boost because imagined rollouts are cheap.
The idea predates deep learning: Schmidhuber proposed self-modeling networks in 1990, and Sutton’s “Dyna” architecture (1991) interleaved real and imagined rollouts in tabular RL [6]. What modern deep world models add is the ability to model rich, high-dimensional observations (pixels, language) using neural representations.
What makes a model a “world model”?
A model is a world model if it predicts future states from current state and action :
A pure generative model (e.g., an unconditional video diffusion model) generates plausible-looking sequences but does not have an explicit action-conditioning mechanism. A world model is action-conditioned: different actions lead to different predicted futures, and the model’s internal dynamics encode the causal structure of the environment.
A world model supports:
- Planning: roll out multiple action sequences, pick the one leading to the highest estimated return.
- Policy training: generate imagined experience to train a policy without real environment interaction.
- Counterfactual reasoning: ask “what would have happened if I had taken action ?”
| Property | Generative model | World model | Policy / RL agent |
|---|---|---|---|
| Primary output | Plausible future observations | State predictions conditioned on actions | Actions to take in environment |
| Action-conditioned? | No (or weakly) | Yes (core design requirement) | Yes (outputs actions) |
| Supports planning? | Not directly | Yes — roll out imagined action sequences | Indirectly (model-free RL does not plan) |
| Used for counterfactuals? | With caution | Yes | No |
| Examples | Stable Diffusion, VideoPoet | DreamerV3, MuZero, GAIA-1 | PPO, SAC, AlphaGo policy net |
Ha and Schmidhuber (2018): Dream to learn
The Ha and Schmidhuber “World Models” paper [1] introduced the V-M-C (Vision-Memory-Controller) architecture:
- V (VAE): a convolutional variational autoencoder that compresses each frame to a low-dimensional latent vector .
- M (MDN-RNN): a mixture-density RNN that models the distribution over future latent states , where is the hidden state of the RNN. The mixture-density output allows the model to capture multi-modal next-state distributions.
- C (linear controller): a small linear layer that maps to actions. Because C is linear, it can be optimised cheaply with CMA-ES (a black-box evolution strategy).
The key experiment: the controller C can be trained entirely on rollouts generated inside the M model (the “dream”), then deployed in the real environment. On CarRacing-v0, the policy trained in the dream matched or exceeded policies trained in the real environment, demonstrating that world-model planning can serve as a training environment.
Dreamer and DreamerV3
Dreamer [4] and its successor DreamerV3 [2] replace the V-M-C decomposition with an end-to-end differentiable world model called the Recurrent State Space Model (RSSM), trained jointly with the policy.
The Recurrent State Space Model (RSSM)
The RSSM represents state as a pair where is a deterministic recurrent state and is a stochastic latent variable:
Sequence model (transition prior):
Encoder (posterior, conditioned on the actual observation):
Decoder:
Training minimises the ELBO-style world-model loss:
Why latent-space planning beats pixel-space planning: planning over raw pixels requires the world model to hallucinate photorealistic future frames, which is expensive and prone to compounding perceptual errors. Planning over is computationally trivial, and the latent space is learned to be predictable — by training pressure from the KL term, only captures what can be predicted from the transition model. Noise and irrelevant texture are discarded.
Policy learning via imagined rollouts: once the RSSM is trained, a policy and a value function are trained on rollouts generated entirely by the RSSM, with gradients flowing through the imagined trajectory via the reparametrisation trick.
DreamerV3 [2] extends the architecture with:
- Symlog predictions (predict the symlog-transformed reward to handle varying reward scales across domains).
- KL balancing (separately scale the KL towards the prior vs the posterior to prevent posterior collapse).
- Free bits (a minimum KL per dimension to prevent degenerate solutions).
With these changes, DreamerV3 trains a single set of hyperparameters that works across Atari, continuous control, Minecraft, and BSuite — the first model-based RL agent to achieve human-level performance in Minecraft (collecting diamonds) from scratch.
MuZero: planning without a reconstruction decoder
MuZero [5] takes a different architectural stance: it learns a world model without an observation decoder. Instead of reconstructing , the latent state is learned end-to-end to be useful for value and policy prediction. Three learned functions:
- Representation : (encode observations to latent).
- Dynamics : (transition + reward).
- Prediction : (policy logits + value estimate).
Planning uses MCTS over the latent state space. Because the dynamics function is learned, MuZero can plan in games (Go, chess, shogi, Atari) without access to a simulator, achieving superhuman performance on all of them.
Video generation as world modeling
A video generation model that accepts action tokens as conditioning implicitly learns a world model: given frame and action , generate . Two exemplars:
GAIA-1 (Wayve, 2023): a 9 billion parameter autoregressive video model trained on driving data. Given a driving video and a sequence of actions (steering, throttle), GAIA-1 generates photorealistic future frames consistent with the vehicle dynamics. The generated video can be used to train downstream driving policies, providing a simulation engine that generalises to novel scenarios.
Genie (Google DeepMind, 2024) [3]: a 11 billion parameter foundation world model trained on 2D platformer gameplay video, without any action labels. Genie learns to infer latent actions from video transitions via a spatiotemporal video tokenizer, a latent action model, and a dynamics model. Given a single image, it can generate an interactive environment: pressing left/right/jump produces consistent future frames obeying the inferred game physics. The model generalises to novel hand-drawn scene images never seen in training, demonstrating that world model knowledge can transfer across visual domains.
OpenAI Sora (2024) and similar video diffusion models are sometimes described as world models because they generate physically consistent video sequences. Strictly, they are conditional generative models, not world models: they do not have an explicit action interface, and “planning” over them requires treating prompts as approximate action descriptions. Whether implicit physical consistency is sufficient for planning is an active research question.
Open problems
Partial observability: real environments are partially observable — the agent never sees the full state. DreamerV3 handles this via the stochastic latent , but long-horizon memory (remembering which doors were locked three rooms ago) remains challenging.
Physical plausibility: video generation models can produce visually coherent but physically implausible sequences (objects passing through walls, incorrect rigid-body dynamics). Training on physics-engine-simulated data or incorporating physics priors is an active area.
Long-horizon consistency: world models tend to drift over many steps. A 10-step imagined rollout is plausible; a 1000-step rollout diverges from the true environment dynamics. Hierarchical world models (planning at multiple time scales) and uncertainty-aware planning (pulling back to real experience when the model is uncertain) are current research directions.
Scaling world models: LeCun (2022) [7] argues that world models are the central missing ingredient for human-level autonomous intelligence, proposing a Joint Embedding Predictive Architecture (JEPA) that learns self-supervised world models in abstract feature space rather than pixel space. Whether scaling video-generation-style world models eventually solves this is an open question.
- 1. What distinguishes a world model from a generative model?
- 2. Why does DreamerV3 plan in latent space rather than pixel space?
- 3. In DreamerV3's RSSM, what is the role of the deterministic component h_t?
- 4. What makes Genie (2024) unusual as a world model?
- 5. What is the "dream training" paradigm introduced by Ha and Schmidhuber (2018)?
What makes a model a 'world model' vs a generative model, and why does this distinction matter for planning?onsite
A generative model produces plausible-looking observations from a noise distribution or a conditioning signal, but does not have an explicit interface for action conditioning. A world model specifically maps : it is causal in the action, meaning different actions lead to different predicted futures in a controlled, plausible way.
This distinction matters for planning because planning requires evaluating the consequences of hypothetical actions. A generative model cannot answer “what would happen if I steer left?” unless it has learned the action-state causal structure. A world model by definition supports this query. The practical consequence is that world models enable agents to improve their policies from imagined experience, substantially reducing the number of real environment interactions needed — critical for settings where real-environment samples are expensive (robotics, drug discovery, autonomous driving).
Explain how DreamerV3's RSSM works and why latent-space planning is preferable to pixel-space planning.staff
The RSSM represents state as a pair . The deterministic component is computed via a GRU-style recurrent function , providing a running summary of history. The stochastic component is a random variable drawn from a posterior during training (when observations are available) and a prior during imagination (when the model rolls forward without new observations). The training objective includes a reconstruction loss (predicting and ) and a KL term that pushes the posterior toward the prior, training the prior to capture the predictable structure of transitions.
Policy training runs entirely in imagination: from a starting state , the model imagines steps by sampling actions from the policy, advancing via the transition model, and receiving rewards from the reward head. The policy and value function are updated via backpropagation through the entire imagined trajectory using the reparametrization trick on .
Why latent over pixels: generating photorealistic next frames requires the dynamics model to reproduce all visual detail — lighting, texture, non-relevant background objects. This is hard and causes compounding perceptual error over long rollouts. A 32-dimensional only needs to capture the predictable aspects of transitions (object positions, velocities, relevant game state). The reconstruction pressure from the decoder trains to be sufficient for observation prediction, but the dynamics model operates entirely in the compact latent space, making imagination fast and accurate over long horizons.
References
- Ha, D. and Schmidhuber, J. (2018). World Models. arXiv preprint. arXiv:1803.10122
- Hafner, D., Lillicrap, T. P., Norouzi, M., and Ba, J. (2023). Mastering Diverse Domains through World Models. arXiv preprint. arXiv:2301.04104
- Bruce, J., Dennis, M., Edwards, A., Parker-Holder, J., Shi, Y., Hughes, E., Lai, M., Mavalankar, A., Steigerwald, R., Apps, C., Aytar, Y., Bechtle, S., Bhatt, U., Blundell, C., Carifio, J., Catoia, V., Chakrabarti, S., Chan, H., Crespo, G., and others (2024). Genie: Generative Interactive Environments. arXiv preprint. arXiv:2402.15391
- Hafner, D., Lillicrap, T. P., Fischer, I., Villegas, R., Ha, D., Lee, H., and Davidson, J. (2019). Learning Latent Dynamics for Planning from Pixels. ICML 2019. arXiv:1811.04551
- Schrittwieser, J., Antonoglou, I., Hubert, T., Simonyan, K., Sifre, L., Schmitt, S., Guez, A., Lockhart, E., Hassabis, D., Graepel, T., Lillicrap, T., and Silver, D. (2020). Mastering Atari, Go, Chess and Shogi by Planning with a Learned Model. Nature 588, 604-609. arXiv:1911.08265
- Sutton, R. S. and Barto, A. G. (2018). Reinforcement Learning: An Introduction. MIT Press, 2nd edition. http://incompleteideas.net/book/the-book-2nd.html
- LeCun, Y. (2022). A Path Towards Autonomous Machine Intelligence. OpenReview preprint. https://openreview.net/forum?id=BZ5a1r-kVsf