A Brief Overview of Code World Models
Most modern world models represent environment dynamics using neural networks, including recurrent models, Transformers, and diffusion models. An alternative research direction is to represent world models as executable programs.
Such models, referred to as code world models (CWMs), are constructed through LLM-based program synthesis. In this paradigm, the LLM does not directly act as the world simulator. Instead, it synthesizes executable code that implements the simulator, including the environment's state transitions, observations, rewards, and other relevant dynamics.
We will discuss three representative CWM works:
- WorldCoder (2024)
- DeepMind CWM (2025)
- PoE-World (2025)
We focus primarily on WorldCoder, while the latter two are used to complement the discussion with more advanced formulations and design choices and we don't talk about the details of them.