Structured World Representations in Maze-Solving Transformers
Not on the map. Why?
Abstract (arXiv)
Transformer models underpin many recent advances in practical machine learning applications, yet understanding their internal behavior continues to elude researchers. Given the size and complexity of these models, forming a comprehensive picture of their inner workings remains a significant challenge. To this end, we set out to understand small transformer models in a more tractable setting: that of solving mazes. In this work, we focus on the abstractions formed by these models and find evidence for the consistent emergence of structured internal representations of maze topology and valid paths. We demonstrate this by showing that the residual stream of only a single token can be linearly decoded to faithfully reconstruct the entire maze. We also find that the learned embeddings of individual tokens have spatial structure. Furthermore, we take steps towards deciphering the circuity of path-following by identifying attention heads (dubbed textitadjacency heads), which are implicated in finding valid subsequent tokens.
Key facts. Cited by 16 papers in the map (data through 14 Oct 2026). Builds on 16 of its 20 references that are in the map. First posted on arXiv 5 Dec 2023.
Builds on
16 of 20 references.
References · 16
- 2022Interpretability in the Wild: a Circuit for Indirect Object Identification in GPT-2 smallcited by 1,165
- 2023Progress measures for grokking via mechanistic interpretabilitycited by 839
- 2023Towards Automated Circuit Discovery for Mechanistic Interpretabilitycited by 724
- 2022What learning algorithm is in-context learning? Investigations with linear modelscited by 684
- 2023Eliciting Latent Predictions from Transformers with the Tuned Lenscited by 623
- 2022Emergent World Representations: Exploring a Sequence Model Trained on a Synthetic Taskcited by 431
- 2023Finding Neurons in a Haystack: Case Studies with Sparse Probingcited by 334
- 2022Towards Understanding Grokking: An Effective Theory of Representation Learningcited by 230
- 2023Does Circuit Analysis Interpretability Scale? Evidence from Multiple Choice Capabilities in Chinchillacited by 149
- 2022Toward Transparent AI: A Survey on Interpreting the Inner Structures of Deep Neural Networkscited by 129
- 2023Uncovering mesa-optimization algorithms in Transformerscited by 100
- 2023Evaluating Cognitive Maps and Planning in Large Language Models with CogEvalcited by 77
4 more
- 2023Evaluating Large Language Models on Graphs: Performance Insights and Comparative Analysiscited by 35
- 2023A Configurable Library for Generating and Manipulating Maze Datasetscited by 31
- 2023Understanding and Controlling a Maze-Solving Policy Networkcited by 22
- 2023Can Transformers Learn to Solve Problems Recursively?cited by 17
Built on by
Citing papers per year: 2024: 3; 2025: 7; 2026: 6.
16 papers.
Sort:
By area:
- 2024Mechanistic Interpretability for AI Safety -- A Reviewcited by 422
- 2024A Mechanistic Analysis of a Transformer Trained on a Symbolic Multi-Step Reasoning Taskcited by 49
- 2024Transformers Can Navigate Mazes With Multi-Step Predictioncited by 11
- 2025Revisiting the Othello World Model Hypothesiscited by 11
- 2025Linear Spatial World Models Emerge in Large Language Modelscited by 6
- 2025Enhancing Conversational Agents with Theory of Mind: Aligning Beliefs, Desires, and Intentions for Human-Like Interactioncited by 3
- 2025Is This Just Fantasy? Language Model Representations Reflect Human Judgments of Event Plausibilitycited by 3
- 2026Do LLMs Build Spatial World Models? Evidence from Grid-World Maze Taskscited by 2
- 2026Probing Visual Planning in Image Editing Modelscited by 2
- 2026Correcting Influence: Unboxing LLM Outputs with Orthogonal Latent Spacescited by 1
- 2026Interaction Locality in Hierarchical Recursive Reasoningcited by 1
- 2025Geometric Reasoning in the Embedding Spacecited by 0
4 more
- 2025Understanding the learned look-ahead behavior of chess neural networkscited by 0
- 2025Causal Masking on Spatial Data: An Information-Theoretic Case for Learning Spatial Datasets with Unimodal Language Modelscited by 0
- 2026A Close Look At World Model Recovery In Supervised Fine-Tuned LLM Plannerscited by 0
- 2026World Modeling in Transformerscited by 0
- 2026World Modeling in Transformers18 Sep 2026
- 2026A Close Look At World Model Recovery In Supervised Fine-Tuned LLM Planners2 Jun 2026
- 2026Interaction Locality in Hierarchical Recursive Reasoning20 May 2026
- 2026Correcting Influence: Unboxing LLM Outputs with Orthogonal Latent Spaces12 May 2026
- 2026Probing Visual Planning in Image Editing Models23 Apr 2026
- 2026Do LLMs Build Spatial World Models? Evidence from Grid-World Maze Tasks12 Apr 2026
- 2025Causal Masking on Spatial Data: An Information-Theoretic Case for Learning Spatial Datasets with Unimodal Language Models30 Oct 2025
- 2025Is This Just Fantasy? Language Model Representations Reflect Human Judgments of Event Plausibility16 Jul 2025
- 2025Linear Spatial World Models Emerge in Large Language Models3 Jun 2025
- 2025Understanding the learned look-ahead behavior of chess neural networks26 May 2025
- 2025Geometric Reasoning in the Embedding Space2 Apr 2025
- 2025Revisiting the Othello World Model Hypothesis6 Mar 2025
4 more
- 2025Enhancing Conversational Agents with Theory of Mind: Aligning Beliefs, Desires, and Intentions for Human-Like Interaction20 Feb 2025
- 2024Transformers Can Navigate Mazes With Multi-Step Prediction6 Dec 2024
- 2024Mechanistic Interpretability for AI Safety -- A Review22 Apr 2024
- 2024A Mechanistic Analysis of a Transformer Trained on a Symbolic Multi-Step Reasoning Task19 Feb 2024
- 2025Revisiting the Othello World Model Hypothesiscited by 11
- 2025Linear Spatial World Models Emerge in Large Language Modelscited by 6
- 2026Do LLMs Build Spatial World Models? Evidence from Grid-World Maze Taskscited by 2
- 2026A Close Look At World Model Recovery In Supervised Fine-Tuned LLM Plannerscited by 0
- 2026World Modeling in Transformerscited by 0
- 2026World Modeling in Transformers18 Sep 2026
- 2026A Close Look At World Model Recovery In Supervised Fine-Tuned LLM Planners2 Jun 2026
- 2026Do LLMs Build Spatial World Models? Evidence from Grid-World Maze Tasks12 Apr 2026
- 2025Linear Spatial World Models Emerge in Large Language Models3 Jun 2025
- 2025Revisiting the Othello World Model Hypothesis6 Mar 2025
- 2026Probing Visual Planning in Image Editing Modelscited by 2
- 2026Interaction Locality in Hierarchical Recursive Reasoningcited by 1
- 2025Geometric Reasoning in the Embedding Spacecited by 0
- 2026Interaction Locality in Hierarchical Recursive Reasoning20 May 2026
- 2026Probing Visual Planning in Image Editing Models23 Apr 2026
- 2025Geometric Reasoning in the Embedding Space2 Apr 2025
- 2024Mechanistic Interpretability for AI Safety -- A Reviewcited by 422
- 2024Mechanistic Interpretability for AI Safety -- A Review22 Apr 2024
- 2024A Mechanistic Analysis of a Transformer Trained on a Symbolic Multi-Step Reasoning Taskcited by 49
- 2024Transformers Can Navigate Mazes With Multi-Step Predictioncited by 11
- 2025Is This Just Fantasy? Language Model Representations Reflect Human Judgments of Event Plausibilitycited by 3
- 2026Correcting Influence: Unboxing LLM Outputs with Orthogonal Latent Spacescited by 1
- 2025Understanding the learned look-ahead behavior of chess neural networkscited by 0
- 2025Causal Masking on Spatial Data: An Information-Theoretic Case for Learning Spatial Datasets with Unimodal Language Modelscited by 0
- 2026Correcting Influence: Unboxing LLM Outputs with Orthogonal Latent Spaces12 May 2026
- 2025Causal Masking on Spatial Data: An Information-Theoretic Case for Learning Spatial Datasets with Unimodal Language Models30 Oct 2025
- 2025Is This Just Fantasy? Language Model Representations Reflect Human Judgments of Event Plausibility16 Jul 2025
- 2025Understanding the learned look-ahead behavior of chess neural networks26 May 2025
- 2024Transformers Can Navigate Mazes With Multi-Step Prediction6 Dec 2024
- 2024A Mechanistic Analysis of a Transformer Trained on a Symbolic Multi-Step Reasoning Task19 Feb 2024