Introduction
A central debate in artificial intelligence is whether Large Language Models (LLMs) are merely "stochastic parrots"—engines of superficial statistical correlations—or if they develop a coherent "world model" to process information. For instance, if a model knows that "Paris" is in "France," does it merely recognize that these words frequently co-occur, or does it possess an internal coordinate system where Paris sits at a specific physical location?
Recent research investigates whether LLMs internalize the fundamental dimensions of our reality: space and time. By analyzing the Llama-2 family of models, researchers discovered that these systems don't just predict the next word; they build sophisticated, linear internal representations of the physical world and historical time.
Probing for Space and Time
To uncover these internal maps, the authors employed a technique called linear probing. They analyzed the internal activations—the "hidden thoughts"—of Llama-2 and Pythia models as they processed the names of places or historical events.
The methodology involved several key steps:
- Extraction: For a given entity (e.g., "The Great Pyramid"), researchers recorded the model's activation state across every layer.
- Regression: They trained simple linear ridge regression models to determine if those activations could accurately predict real-world coordinates (latitude/longitude) or historical timestamps.
- Linearity Test: To prove the representations are truly linear, they compared these simple probes against complex, non-linear Multi-Layer Perceptron (MLP) probes. Comparable performance suggests the model inherently stores the data linearly.
- Neuron Identification: The team searched for individual neurons whose activation levels highly correlated with specific spatial or temporal dimensions.
The researchers tested this across six diverse datasets to evaluate different scales. Spatial datasets included global places (~40k), US-specific locations (~30k), and New York City points of interest (~20k). Temporal datasets covered the death years of historical figures (~37k), release dates of art and entertainment (~31k), and publication dates of news headlines (~28k).
Key Insights: The Linear Map
The most striking finding is that spatial and temporal information is stored linearly. Concepts like "North-South" or "Past-Future" are represented as specific, measurable directions within the model's high-dimensional space.
- Multi-Scale Competence: The models maintain distinct, accurate representations across different scales. Llama-2 can effectively "zoom in" from a global map down to the specific grid of Manhattan.
- Space and Time Neurons: The researchers identified literal "space" and "time" neurons. Certain neurons activate specifically based on how far North an entity is located, or how recently a news event occurred.
- Unified Representations: The model uses the same spatial direction for different types of entities. A city and a natural landmark at the same latitude trigger the same spatial activation, suggesting a unified concept of location rather than memorized trivia.
- Emergence via Compression: These internal maps were not explicitly programmed. They emerged naturally as the model attempted to compress and predict massive amounts of text. To predict the next token accurately, the model effectively "realized" it was more efficient to build an internal map than to memorize every individual distance.
Performance and Model Dynamics
The linear probes demonstrated remarkable accuracy. In the Llama-2-70B model, linear probes achieved an $R^2$ score of over 0.8 for both the World Map and Historical Figures datasets.
Interestingly, these representations are not present in the very first layers of the model. They build up gradually through the early layers and plateau around the halfway point (e.g., layers 40-50 for an 80-layer model). Furthermore, model size and training data play a crucial role: larger models (70B) significantly outperformed smaller ones (7B), and Llama-2 outperformed Pythia, likely due to its vastly larger training corpus (2 trillion tokens vs. 300 billion). These representations also proved robust, remaining largely unaffected by variations in how the model was prompted.
Limitations and Future Directions
While these findings strongly support the existence of internal world models, there are limitations. The datasets were derived primarily from English Wikipedia and US-centric sources, leaving it an open question how "global" these maps are in non-English contexts.
Additionally, while the models excel at relative positioning (e.g., knowing Canada is North of the US), they sometimes struggle with absolute coordinates when certain data blocks are held out, hinting at some reliance on memorized human coordinate systems. Finally, this study focuses on "static" facts. A true, comprehensive world model would need to be dynamic and causal—understanding how entities move and interact over time, not just where they sit on a map.
Future work will likely explore the "mesh" hypothesis, investigating whether LLMs use a hierarchical mesh of basis points to represent space, potentially utilizing sparse autoencoders to further decode these fascinating internal structures.
Summary updated