Discovering Interpretable Algorithms by Decompiling Transformers to RASP
Not on the map. Why?
Abstract (arXiv)
Recent work has shown that the computations of Transformers can be simulated in the RASP family of programming languages. These findings have enabled improved understanding of the expressive capacity and generalization abilities of Transformers. In particular, Transformers have been suggested to length-generalize exactly on problems that have simple RASP programs. However, it remains open whether trained models actually implement simple interpretable programs. In this paper, we present a general method to extract such programs from trained Transformers. The idea is to faithfully re-parameterize a Transformer as a RASP program and then apply causal interventions to discover a small sufficient sub-program. In experiments on small Transformers trained on algorithmic and formal language tasks, we show that our method often recovers simple and interpretable RASP programs from length-generalizing transformers. Our results provide the most direct evidence so far that Transformers internally implement simple RASP programs.
Key facts. Cited by 4 papers in the map (data through 7 Oct 2026). First posted on arXiv 9 Feb 2026.
Builds on
0 of 0 references.
No references here yet.
Built on by
Citing papers per year: 2026: 4.
4 papers.
- 2026Invariant Learning Dynamics of Transformers in Inductive Reasoning Taskscited by 1
- 2026Symmetry Reveals Layerwise Dynamics: How Transformers Perform In-Context Classificationcited by 0
- 2026Can Graph Learning Learn Circuits?cited by 0
- 2026Length Generalization for Transformers via Compressioncited by 0
- 2026Length Generalization for Transformers via Compression8 Sep 2026
- 2026Can Graph Learning Learn Circuits?9 Aug 2026
- 2026Invariant Learning Dynamics of Transformers in Inductive Reasoning Tasks13 Jul 2026
- 2026Symmetry Reveals Layerwise Dynamics: How Transformers Perform In-Context Classification13 Apr 2026