Lune

NeurIPS2024Top-tier venue

Transformers Represent Belief State Geometry in their Residual Stream

Adam S. Shai, Lucas Teixeira, Alexander Gietelink Oldenziel, Sarah Marzen, Paul M. Riechers

Abstract

What computational structure are we building into large language models when we train them on next-token prediction? Here, we present evidence that this structure is given by the meta-dynamics of belief updating over hidden states of the data-generating process. Leveraging the theory of optimal prediction, we anticipate and then find that belief states are linearly represented in the residual stream of transformers, even in cases where the predicted belief state geometry has highly nontrivial fractal structure. We investigate cases where the belief state geometry is represented in the final residual stream or distributed across the residual streams of multiple layers, providing a framework to explain these observations. Furthermore we demonstrate that the inferred belief states contain information about the entire future, beyond the local next-token prediction that the transformers are explicitly trained on. Our work provides a general framework connecting the structure of training data to the geometric structure of activations inside transformers.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

16 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Transformers learn factored representations cites Not All Language Model Features Are One-Dimensionally Linear
  • Transformers learn factored representations cites Transformers Learn Shortcuts to Automata
  • Better & Faster Large Language Models via Multi-token Prediction cites The Pitfalls of Next-Token Prediction
  • Not All Language Model Features Are One-Dimensionally Linear cites Emergent World Representations: Exploring a Sequence Model Trained on a Synthetic Task
  • The Pitfalls of Next-Token Prediction cites Transformers Learn Shortcuts to Automata
  • Symmetries in language statistics shape the geometry of model representations cites Transformers learn factored representations
  • Symmetries in language statistics shape the geometry of model representations cites Not All Language Model Features Are One-Dimensionally Linear
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers16

  1. Symmetries in language statistics shape the geometry of model representationsDhruva Karkada, Daniel Korchinski, Andres Nava, Matthieu Wyart et al.ICML 2026 · 15 citations
  2. Not All Language Model Features Are One-Dimensionally LinearJoshua Engels, Eric J. Michaud, Isaac Liao, Wes Gurnee et al.ICLR 2025 · 3 citations
  3. Spectral Filters, Dark Signals, and Attention SinksNicola CanceddaACL 2024 · 3 citations
  4. Transformers learn factored representationsAdam Shai, Loren Amdahl-Culleton, Casper Christensen, Henry R Bigelow et al.ICML 2026 · 2 citations
  5. Transformers Learn Latent Mixture Models In-Context via Mirror DescentFrancesco D'Angelo, Nicolas FlammarionICLR 2026 · 2 citations

Builds on4

  1. Better & Faster Large Language Models via Multi-token PredictionFabian Gloeckle, Badr Youbi Idrissi, Baptiste Rozière, David Lopez-Paz et al.ICML 2024 · 286 citations
  2. The Pitfalls of Next-Token PredictionGregor Bachmann, Vaishnavh NagarajanICML 2024 · 163 citations
  3. Emergent World Representations: Exploring a Sequence Model Trained on a Synthetic TaskKenneth Li, Aspen K. Hopkins, David Bau, Fernanda B. Viégas et al.ICLR 2023 · 60 citations
  4. Transformers Learn Shortcuts to AutomataBingbin Liu, Jordan T. Ash, Surbhi Goel, Akshay Krishnamurthy et al.ICLR 2023 · 11 citations

Related papers

  1. Constrained Belief Updates Explain Geometric Structures in Transformer RepresentationsMateusz Piotrowski, Paul M. Riechers, Daniel Filan, Adam S. ShaiICML 2025
  2. How Transformers Represent Hierarchies: A Local-to-Global MechanismZhiling Zhou, Tianhao Wang, Zhuoran YangICML 2026
  3. Provable Long-Range Benefits of Next-Token PredictionXinyuan Cao, Santosh S. VempalaSTOC 2026
  4. A Meta-Learning Perspective on Transformers for Causal Language ModelingXinbo Wu, Lav R. VarshneyACL Findings 2024 · 3 citations
  5. Residual Stream Analysis with Multi-Layer SAEsTim Lawson, Lucy Farnik, Conor J. Houghton, Laurence AitchisonICLR 2025
Dusk over the sea between two cliffs drawn in fine vertical lines