PreprintCited by 31Explainable Artificial Intelligence (XAI)Adversarial Robustness in Machine LearningTopic Modeling

Eliciting Latent Predictions from Transformers with the Tuned Lens

Open access
Belrose, Nora, Ostrovsky, Igor, McKinney, Lev, Furman, Zach, Smith, Logan, Halawi, Danny, Biderman, Stella, Steinhardt, Jacob·2023·arXiv

Abstract

We analyze transformers from the perspective of iterative inference, seeking to understand how model predictions are refined layer by layer. To do so, we train an affine probe for each block in a frozen pretrained model, making it possible to decode every hidden state into a distribution over the vocabulary. Our method, the tuned lens, is a refinement of the earlier "logit lens" technique, which yielded useful insights but is often brittle. We test our method on various autoregressive language models with up to 20B parameters, showing it to be more predictive, reliable and unbiased than the logit lens. With causal experiments, we show the tuned lens uses similar features to the model itself. We also find the trajectory of latent predictions can be used to detect malicious inputs with high accuracy. All code needed to reproduce our results can be found at https://github.com/AlignmentResearch/tuned-lens.

The claims and statistics of this paper haven’t been checked yet.

Run the check — free, no account needed. It reads the open-access text and checks the sources it cites.

A few free checks a day · papers already verified open instantly · results are public

Integrity signals

Registry

DataCite · 10.48550/arxiv.2303.08112

Cites

53 of 60 references verified0 citation errors · 0 not checkable

Statistics

Claims the paper makes

The claims and statistics of this paper haven’t been checked yet.

Run the check — free, no account needed. It reads the open-access text and checks the sources it cites.

A few free checks a day · papers already verified open instantly · results are public

Claims other papers make about this one

Each is checked against this paper’s own text: does it say what the citing paper says it does?

  • OthelloGPT exhibits iterative inference, or iterative refinement of features.

    “Multiple evidence of iterative refinements are provided in the Appendix.”

    From Emergent Linear Representations in World Models of Self-Supervised Sequence Models (2023) · cites this paper as Belrose et al., 2023

    The Introduction (page unavailable) describes iterative inference as incremental updates to a transformer language model’s latent next-token prediction, and points to Appendix C for evidence. This supports the general idea of layer-by-layer refinement, but our copy does not identify OthelloGPT or show that its features are iteratively refined. (LLM, conf=0.84)

    Experimental — accuracy not yet measured

Self-check

Percentages, sums and reported differences re-computed from the paper’s own numbers.

The self-check needs the paper’s full text.

Cites

Flagged first, then by citations

17 of the 77 references couldn’t be matched to a known paper.

Research works printed but not linked: 5

  1. Ian Hacking. Slightly more realistic personal probability. Philosophy of Science, 34(4):311-325, 1967.
  2. Edward J Hu, Yelong Shen, Phillip Wallis, Zeyuan Allen- Zhu, Yuanzhi Li, Shean Wang, Lu Wang, Weizhu Chen, et al. Lora: Low-rank adaptation of large language mod- els. ICLR, 1(2):3, 2022.
  3. Karel Lenc and Andrea Vedaldi. Understanding image rep- resentations by measuring their equivariance and equiv- alence. In Proceedings of the IEEE conference on com- puter vision and pattern recognition, pages 991-999, 2015.
  4. PC Mahalanobis. On the generalized distances in statistics: Mahalanobis distance. Journal Soc. Bengal, 26:541-588, 1936.
  5. Andreas Veit, Michael J Wilber, and Serge Belongie. Resid- ual networks behave like ensembles of relatively shallow networks. Advances in neural information processing systems, 29, 2016.

Cited by

Sorted by citations

Authors
Belrose, N., Ostrovsky, I., McKinney, L., Furman, Z., Smith, L., Halawi, D., Biderman, S., & Steinhardt, J.
Venue
arXiv
Publisher
arXiv
Published
2023
ISSN
2331-8422 (ISSN-L)
OpenAlex
W4327526719
Cited by
27
References
77
Citations by year
2026: 2 · 2025: 5 · 2024: 5 · 2023: 15
Type
posted content
Language
en
Open access
Locations
  • arXiv (Cornell University) (submittedVersion, cc-by)
  • arXiv (Cornell University) (cc-by)
Topics
  • Physical Sciences › Computer Science › Artificial Intelligence › Explainable Artificial Intelligence (XAI)
  • Physical Sciences › Computer Science › Artificial Intelligence › Adversarial Robustness in Machine Learning
  • Physical Sciences › Computer Science › Artificial Intelligence › Topic Modeling
Keywords
logit lens, transformer interpretability, iterative inference, autoregressive language models, model interpretability

About these checks

Registry, retraction, Cites and statistics results are computed, not judged, with one exception: a printed reference that no index lists is read once by a model before it counts as a citation error. Claims are extracted by a model and kept only when their quote appears verbatim in the text; each cited source is then checked, with a model’s help, for whether it says what the claim relies on. Those verdicts can be wrong — read the claim’s quote and the cited source before relying on one.

Statistics and arithmetic are recomputed, not judged.

Confidence bands are shown only for fields calibrated on our annotated test set. None is calibrated yet, so no band is shown.

What counts as a claim ›How we measure confidence ›How we check this ›

Are you an author, or do you see a problem with this page? Request a review