Transformers Linearly Represent Constrained-based World Models in Sudoku
Roman Kniazev, Nathanaël Fijalkow
NeurIPS 2026
TL;DR. We analyze a transformer trained to solve Sudoku and find that it builds an internal world model organized around the puzzle's constraint structure, with a sparse and interpretable circuit for the most common forced placement.
Abstract. Do transformers, when trained on sequential reasoning traces, build internal models of the underlying task? And if so, does the structure of those internal representations mirror the structure of the domain?
We train an 8-layer transformer on Sudoku solving traces and perform a mechanistic analysis of its internal computation. We find a linearly represented substructure world model: it does not represent the board state cell by cell, as a human analyst would expect, but organizes information around the rows, columns, and boxes that Sudoku's constraints act on. We see that mid-layer attention heads organize around Sudoku's substructures, suppressing placement logits for digits already present and promoting those for absent digits. We identify a naked-single circuit: a small set of dedicated neurons in the final MLP layer, each individually detecting when exactly one digit remains possible for a specific cell, and reliably promoting that digit.
These findings suggest that transformers trained on solving traces may encode constraint-relevant information more cleanly than individual surface facts. For interpretability, probing only the obvious surface decomposition of a task may therefore underestimate what the model has learned.
Are you an author? Claim this paper to see who's reading it, with views and other statistics, and to write about it here.
Claim this paperedit · history
NeurIPS 2026
Accept (poster) · 3 reviews · OpenReview
Updated 25 Nov 2026, 03:43 UTC.
- Decision
- Accept (poster)
Read decision
Meta-review
This is a well-conducted paper trying to unveil mechanisms underlying the abilities of a Transformer trained on reasoning traces that showcase how to solve Sudoku problems. The authors demonstrate a the Transformer learns a structured world model that reflects the constraints of the domain (i.e., Sudoku) and a sparse circuit is involved in prediction over this world model. The toolkit used to arrive at these claims is bread-and-butter interpretability infrastructure: probes, patching, and behavioral validation. Overall, the results are cleanly derived, as noted by the reviewers as well.
Having said the above, I currently lean towards a reject stance on this paper. Such toy scenarios have been studied several times over in the interpretability community to understand whether Transformers learn to represent the world they operate in [1,2], and interpretability of decision-making models in such toy models has also been explored [3]. There is nothing wrong with using toy systems to better understand how Transformers reason, but I am currently unclear what novel insights I am able to derive from this paper that were not already available (or at least easily inferable) from existing literature. As the reviewers suggested, including other domains and showing a non-trivial mechanism transfer (e.g., the constraint world model being a general preference of the Transformer architecture) would be great. I am open to revising my opinion based on rebuttals, but currently I believe this paper meets the bar for a very good workshop paper and needs more scope expansion to warrant a full paper accept.
[1] https://arxiv.org/abs/2210.13382
[2] https://aclanthology.org/2023.blackboxnlp-1.2/
[3] https://github.com/jbloomAus/DecisionTransformerInterpretability
Final justification
Despite an originally reject-leaning view, I concur with the reviewers that the results of this paper can be meaningfully appealing to a NeurIPS audience. I hence recommend the paper for accept.
Read meta-review
Meta-review
This is a well-conducted paper trying to unveil mechanisms underlying the abilities of a Transformer trained on reasoning traces that showcase how to solve Sudoku problems. The authors demonstrate a the Transformer learns a structured world model that reflects the constraints of the domain (i.e., Sudoku) and a sparse circuit is involved in prediction over this world model. The toolkit used to arrive at these claims is bread-and-butter interpretability infrastructure: probes, patching, and behavioral validation. Overall, the results are cleanly derived, as noted by the reviewers as well.
Having said the above, I currently lean towards a reject stance on this paper. Such toy scenarios have been studied several times over in the interpretability community to understand whether Transformers learn to represent the world they operate in [1,2], and interpretability of decision-making models in such toy models has also been explored [3]. There is nothing wrong with using toy systems to better understand how Transformers reason, but I am currently unclear what novel insights I am able to derive from this paper that were not already available (or at least easily inferable) from existing literature. As the reviewers suggested, including other domains and showing a non-trivial mechanism transfer (e.g., the constraint world model being a general preference of the Transformer architecture) would be great. I am open to revising my opinion based on rebuttals, but currently I believe this paper meets the bar for a very good workshop paper and needs more scope expansion to warrant a full paper accept.
[1] https://arxiv.org/abs/2210.13382
[2] https://aclanthology.org/2023.blackboxnlp-1.2/
[3] https://github.com/jbloomAus/DecisionTransformerInterpretability
Final justification
Despite an originally reject-leaning view, I concur with the reviewers that the results of this paper can be meaningfully appealing to a NeurIPS audience. I hence recommend the paper for accept.
1 comment
- Rating
- 4/6
- Confidence
- 4/5
- Quality
- 3/4
- Clarity
- 3/4
- Significance
- 3/4
- Originality
- 2/4
- Contribution type
- general
- Ethical concerns
- NO or VERY MINOR ethics concerns only
Read review
Summary
This submission performs a mechanistic interpretability case study of a small transformer reasoning model trained to solve Sudoku puzzles. It tries to specifically answer the question how the model represents the state of a Sudoku puzzle (what the authors refer to as the "world model"). Through a series of task-informed analyses using standard mechanistic intepretability methods such as probing, patching and general model inspection, it finds that the model uses a particular data structure that directly reflects the constraint structure of Sudoku puzzles and allows to linearly decode candidates for blank cells.
Strengths and weaknesses
Strengths
The analyses performed in the submission are well exectued and clearly communicated. I found the manuscript easy to follow and the presented results convincing within their scope.
Weaknesses
The contribution of this submission is relatively narrowly scoped: Prior work has performed a similar analysis for a different game [1, 2], prior work has trained small reasoning transformers to solve Sudoku tasks [3, 4] and the analysis methods used are all standard tools -- although their use is of course informed by the particular task. The manuscript clearly communicates these points but it is nevertheless difficult to decide whether collectively they cross the threshold to justify a full paper. The manuscript did specifically restrict itself to analysing how the sudoku state is represented but did for example not investigate how the model reasons through each task, e.g. how it decides to backtrack etc.
[1] Li et al. (2023): Emergent world representations: Exploring a sequence model trained on a synthetic task.
[2] Nanda et al. (2023): Emergent linear representations in world models of self-supervised sequence models.
[3] Giannoulis et al. (2026): Teaching transformers to solve combinatorial problems through efficient trial & error.
[4] Shah et al. (2024): Causal language modeling can elicit search and reasoning capabilities on logic puzzles.
Questions
As shown in Fig. 1 (right), the target logit drops across all layers, peaking at layer 4 with a mean drop of approximately 25 logits
- It's hard to tell whether a 25 logits difference is large or not without reference to other logits. It would be useful to report the fraction of times where the prediction flips as a result of the logit drop.
The patched top-1 is itself a valid placement on the original board in 73–76% of cases at L3–L4, suggesting that the patched state remains coherent.
- What is the reference value for the validity of the unpatched top-1 prediction (given that backtracking is possible it's not 1 I guess)?
However, this drop is an artefact of the probes’ decision threshold, not the underlying representation.
-
I think this is an interesting finding and deserves a bit more space in the main text, it took me a few attempts reading this section to understand what is going on, especially given that the figure dedicated to it shows the "artifact".
-
Is my understanding correct that the final MLP layer selects the cell to be filled in but not the specific digit to place. The latter had at that point already been computed by the prior layers? If this understanding is correct, I think it would help to clarify in the manuscript that this is what the "final decision" entails.
-
Figure 3 gives the impression that all attention patterns are highly aligned with the substructures. It would maybe be more representative to include also a non aligned example from the corresponding appendix figure.
The coverage is complete: 71 cell have a single associated neuron and 10 cells have two
- For the cells sharing a neuron, how does the network delineate them? Does it make characteristic errors specifically with respect to these cells?
Finally, our causal evidence for the world-model directions relies on a single patching protocol; alternative interventions could probe the robustness of these findings.
I found this point in the limitations section confusing. What kind of alternative patching protocols or interventions do you have in mind here? What assumptions does your patching protocol make that might be unjustified or in what way might it lead to incorrect conclusions?
Limitations
I find that the title "Transformers Linearly Represent Highly Structured World Models" is overly general and not well supported by the presented results. In my opinion, it would be more accurate to title it more descriptively, e.g., "Mechanistic analysis of state representations in a Sudoku-solving transformer" or something along those lines.
Final justification
While the submission is relatively narrow in terms of novelty, focusing on world models in sudoku-solving transformers, it is well executed and the finding that the internal world model only encodes task-relevant information is interesting.
Formatting concerns
None
4 comments
Rebuttal
We thank the reviewer for the close reading and the specific, actionable questions. We address each point below.
Q1. On the title. We agree with the reviewer that our experiments being restricted to Sudoku, it would be more accurate to include them in the title. Following Reviewer tmTr’s suggestion we propose “Transformers Linearly Represent Constraint-based World Models in Sudoku”.
Q2. Fraction of flipped predictions under patching. We report on this question in Table 4 (Appendix B.4), under "Changed top-1": the patched top-1 differs from the clean top-1 in 95.3–99.7% of cases across layers, peaking above 99% from layer 2 onward. We agree this number belongs in the main text next to Figure 1 (right) rather than only in the appendix, since a 25-logit drop is hard to interpret in isolation but a near-total flip rate is immediately legible. We will move this figure into Section 3.3.
Q3. Reference value for unpatched top-1 validity. The reviewer is correct that this isn't 1, since backtracking traces mean the "correct" next move is not unique at every state. We did not report the clean baseline directly; we will add it in the revision. Given the model's 98.4% per-cell accuracy on held-out puzzles, we expect the unpatched, clean top-1 prediction to be a valid placement well over 90% of the time. Against that baseline, the 73–76% figure represents a real drop in coherence caused by the intervention, rather than a number close to baseline that would suggest the patch had little effect. We will compute and report the exact clean baseline on the same 300-state sample used for Table 4, so the comparison is clean.
Q4. The probe-threshold artefact. We agree this section is under-explained. To restate plainly: as the puzzle fills in, a digit becomes present in almost every substructure simply because there are fewer empty cells left, not because the model's internal encoding of "is d present in S" has degraded. The probes' decision thresholds were fixed at training time on an early, sparse distribution, so they misfire late in the trace even though the underlying direction is still perfectly linearly separable, which is exactly what the ROC-AUC analysis in Appendix B.3 (Figure 8) shows: AUC stays at approximately 1.0 across the whole trace for mid-layers, only exact-match accuracy degrades. We will expand this passage in Section 3.4 and forward-reference Figure 8 directly, rather than leaving the resolution to the appendix.
Q5. Does the final MLP select the cell or the digit? The reviewer's understanding is exactly right, and we agree the manuscript should say so explicitly rather than leaving it implicit. Section 5.1 shows the correct digit is already ranked first in 98.77% of unique-NS states before the final MLP acts. Section 5.2 shows the final MLP's contribution is a boost that is essentially digit-uniform (standard error 0.10 across the 9 target digits, versus a mean boost of +3.00), meaning it amplifies all placement logits for a cell equally rather than discriminating between digits. So the digit identity is resolved by the mid-layers; the final MLP's role is to detect "this cell is now a naked single" and commit to filling it, not to decide which digit. We will add a sentence stating this reading directly in Section 5.2.
Q6. Figure 3 and representativeness of attention alignment. Appendix Figure 10 already contains the full 8-layer-by-8-head grid of attention patterns, and several heads there are not substructure-aligned (for instance, some heads at layers 2–4 spread attention broadly with no concentrated pattern, and some concentrate weakly at under 5% mass on any single region). We will pull one such non-aligned example into Figure 3 alongside the aligned example already there, so the figure doesn't overstate uniformity.
Q7. Cells sharing a neuron. This is a genuinely open question we had not investigated. To clarify the setting first: 10 of the 91 cells are each covered by two dedicated neurons rather than one, so there is redundancy for individual cells. We will check whether the two neurons associated with a cell are redundant copies or whether they partition the cell’s naked single cases in two different scenarios, like partitioning on digits.
Q8. "Alternative patching protocols" in the limitations. This sentence was too vague and we will either cut it or make it concrete. What we had in mind: our current protocol transplants probe directions between paired (G1, G2) states that differ by exactly one placement, which assumes the probe direction itself is the correct causal handle and that the intervention's effect is well approximated by a linear addition to the residual stream. A resample-ablation protocol, patching in the corresponding activation from an unrelated puzzle state rather than a paired next-step state, would test whether the effect depends on the paired-state construction. Path patching, isolating the contribution of specific attention heads or MLP sublayers rather than patching the full residual stream at a layer, would test whether the effect is concentrated in the components we identified in Section 4 or is more diffuse than our single-protocol result suggests.
Thank you for answering my questions. I think the new suggested title,"Transformers Linearly Represent Constraint-based World Models in Sudoku", reflects the paper's contributions much better.
My main concern remains the relatively incremental nature of the contribution (see weaknesses). Could you try to summarize, what you believe are the main novel insights your submission contributes over existing work and contextualize their significance? What can we learn (maybe beyond specifically Sudoku playing transformers) that wasn't previously known?
Thank you for the follow-up. Prior work on Othello and chess found world models with units that represent the surface state (i.e. one feature per cell or square). Our contribution is evidence for a different regime, when the goal and valid actions are defined by a different, more compact constraint structure. In this regime, a transformer represents and uses this structure instead. Broadly, the conclusion is that while we know that transformers have emergent world models, they don’t need to reconstruct the world at its presented granularity, but may encode the task-sufficient variables that determine valid actions.
Thank you for the additional clarification. You have addressed most of my concerns with your answers and the corresponding changes promised to be made to the manuscript.
Broadly, the conclusion is that while we know that transformers have emergent world models, they don’t need to reconstruct the world at its presented granularity, but may encode the task-sufficient variables that determine valid actions.
I still find it difficult to judge whether the specific scope of the paper in the context of the existing prior work meets the "novelty" bar but I do think that this is an important conclusion that can be drawn from this work. Conditioned on the title being changed to "Transformers Linearly Represent Constraint-based World Models in Sudoku", I am raising my score to a borderline accept.
- Rating
- 4/6
- Confidence
- 4/5
- Quality
- 3/4
- Clarity
- 3/4
- Significance
- 3/4
- Originality
- 3/4
- Contribution type
- general
- Ethical concerns
- NO or VERY MINOR ethics concerns only
Read review
Summary
Using linear probes, the paper studies latent representations of decoder-only transformer trained on solving traces of Sudoku instances. By comparing accuracies of different probes, authors argue that unlike in previously studied problems (Othello, chess), the model tends to represent substructures rather than individual cells. The identified representations are verified via ablations and their computational contribution is studied on mid-layer attention heads and the MLP decision layer, resulting, e.g., in discovery of naked-single circuit.
Strengths and weaknesses
Strengths:
Quality
The work is generally based on a methodologically sound progression of probing experiments (with the exception of the unaligned probing setting, see W1): starting with cell-content probes, continuing with cell-candidate probes, finding dependence of individual probes within Sudoku’s substructures, and thus finishing off with substructure probes. The supporting ablation, transfer, and pattern experiments are also robust.
Clarity
The presentation of the experimental setup and results is generally clear, with appropriate visualizations (although interpretations of the results are rather generous, see W2).
Significance and Originality
The manuscript builds upon prior work on (a) training sequential models on reasoning traces of Sudoku and (b) probing internal representations of sequential models for internal models; the combination of both topics with its (perhaps niche) specifics is original.
Weaknesses:
W1. The comparison of accuracy between 9-class cell-state and binary substructure-state classifiers is not fair, as the former task is harder to learn in many settings (see, e.g., [1]). Further, substructures include multiple cells, leading to a higher base probability of positive occurrence, which also benefits the substructure-state classifiers. The issue is only partially resolved by the cell-candidate probes (also binary, but showing near-perfect accuracy), since the explanation via asymmetric relations between probes suggests that the results are highly dependent on the domain.
W2. The interpretation results are likely tightly coupled with the chosen puzzle/domain, which reduces the significance of the work.
- In Sudoku, the algebraic structures are natural and lossless representations of states. This is not true in Othello, chess, other non-trivial games, or real-world settings, where complete algebraic structures are too complex or unknown. The “algebraic world model” may be a byproduct of the Sudoku domain, rather than an inherent emergent feature of sequential models trained on reasoning problems. To lift the findings beyond “model found the natural decomposition of Sudoku”, more complex domains should have been studied in the setting.
- A significant part of the cited prior work on interpreting state representations has used game transcripts rather than solving traces (with backtracking). How this influences the geometry of learned representations is not discussed.
W3. The work does not provide details or further reasoning for trimming the 0.9% overlength traces, why they weren’t excluded, or whether the truncated traces could negatively impact the training process.
[1] Dembczyński, Krzysztof, et al. "On label dependence and loss minimization in multi-label classification." Machine Learning 88.1 (2012): 5-45.
Questions
Q1. Can you compare the 9-class cell-state and binary substructure probes in a fairer setting (e.g., with chance-corrected metrics or per-class AUC)?
Q2. Have you performed (at least preliminary) experiments on domains with other algebraic structures (and in domains without explicit algebraic structure)? If such results were provided, I would consider raising my significance score.
Q3. How are the overlength traces trimmed and how are the special tokens handled in that case? Why weren’t such traces simply discarded from the dataset?
Criterion for Rating Improvement
I would consider increasing my rating based on a convincing argument (e.g., preliminary experiments in another domain) for why the algebraic world model representation isn’t just an artifact of the Sudoku domain (see W2 and Q2).
Limitations
While authors admit the limitation of using a single puzzle type, the potential coupling of the world model hypothesis to the Sudoku’s specific algebraic structure should be further disclaimed and discussed.
Final justification
The reassessed conclusion of the authors, on the one hand, more faithfully reflects the experimental results; on the other hand, it limits the scope and significance of the work.
I believe the paper presents solid research with potentially limited impact, and thus I keep my rating at 4, borderline accept.
Formatting concerns
No issues.
4 comments
Rebuttal
We thank the reviewer for their constructive feedback and thorough reading of our submission. We address the three raised concerns below.
Q1. On comparing cell-state probes with substructure probes. We agree that comparing nine-class cell probes with binary substructure probes was not fully fair. We trained 729 binary cell probes, one for each (cell,digit) pair. For each filled cell, we count a prediction as correct only if all nine probes correctly identify its digit. These probes reach 0.57 exact-match accuracy and AUC 0.972, while the substructure probes reach AUC of approximately 1.0. Thus, the gap even widens in the changed setting.
Q2. Experiments in other domains. As we outlined in response to the reviewer tmTr, this concern pushed us to reassess the main conclusion. We think that the phenomena we observe are specific to a class of tasks in which there is a compact constraint state that determines which next actions are valid, but does not uniquely determine the full surface state. Sudoku differs from Othello and chess precisely because these two descriptions differ: row, column, and box occupancy determines which digits are legal in an empty cell, without specifying the contents of every cell. Our result is that the model represents this constraint-relevant state more cleanly than the surface state.
To test whether this extends beyond Sudoku, we have conducted preliminary experiments in two additional constraint-satisfaction domains, work allocation and graph coloring. These experiments confirm that there are other domains with similar phenomena. In the work-allocation task, there are 45 jobs, 45 workers, and 45 machines. Each job is compatible with three workers and three machines, yielding nine allowed (worker, machine) pairs per job. These choices overlap across jobs, giving 405 allowed (job, worker, machine) triples in total. The vocabulary consists of these triples, and solving traces are sequences of assignments with possible backtracking. A solution assigns every job while using every worker and every machine exactly once.
As in the article, we train linear probes on the residual-stream activation at the [SEP] position following a trace prefix. To decode the surface assignment state, we train nine binary probes for each job, one for each compatible worker-machine pair. These probes predict whether a particular pair is currently assigned to that job. They achieve a mean accuracy of 0.94. However, the groups of nine probes per job jointly achieve the average exact match of only 0.504 . This is similar to the cell probes in the Sudoku case. We then train constraint-level probes. For each worker, a binary probe predicts whether that worker has already been assigned to any job. These probes achieve 0.999 mean binary accuracy and 0.977 exact-match accuracy over the entire 45-bit worker-coverage state. That is, despite requiring all 45 worker indicators to be correct simultaneously, the complete constraint state is recovered almost perfectly. This is similar to the substructure-level case in Sudoku.
This shows the transfer of the qualitative separation observed in Sudoku using binary probes at both levels. In both domains, the model linearly represents the constraint-relevant information nearly perfectly. State-level assignments remain partially predictable because they are constrained, but the relations binding them into a particular board or assignment are not comparably accessible.
In graph coloring, the model receives a graph and generates a sequence of (vertex, color) assignments, with backtracking, so that adjacent vertices have different colors. We do not find a linearly decodable representation of individual vertex states. However, several attention heads focus on vertices in the same clique. This mirrors our second Sudoku result: attention is organized around groups of variables linked by a shared constraint.
Q3. Truncated traces. We follow the training protocol of Giannoulis et al. Traces longer than the 250-token context window are cut at a token boundary; this affects only 0.9% of traces, typically unusually hard puzzles with extensive backtracking. The retained prefix is still valid next-token training data. Since truncation is rare and only reflects the context-window limit, we do not expect it to affect performance significantly. We will clarify this, although studying training protocol effects on performance is outside the main scope of the paper.
Clarifications and further questions
I have a few further questions/notes:
W2:
While my first bullet point is addressed in response to Q2 (see below), the second point on prior work using game transcripts hasn't been addressed at all. Could you elaborate on how the difference between game-transcript- and solve-trace-training influences the geometry of learned representations?
Q2:
I appreciate your adjustment of the conclusion; it makes sense, especially for the Sudoku setting. Regarding the preliminary experiments, could you elaborate on the exact format and encoding of both the actions and the constraints? While you mentioned the binary setup for work allocation, what exact classifiers and metrics were used for Graph Coloring? I am asking this in the context of Q1 "fairness discussion" on the inherent complexity of state vs. constraint probes.
Q3:
While I understand that this issue is not related to the paper's main claims, could you please explicitly address the second part of my Q3 regarding why such traces weren't discarded? Also, what exactly do you mean by valid truncated trace? Does it have to end with a [success] token, or can the branch stay "open" (e.g., cutting off after a [push] token)?
W2. Indeed, prior work used two-player game transcripts. In Othello, player turns create a parity-based symmetry and Nanda et al. found representations based on the current player (mine-yours) rather than absolute colors (black-white). Sudoku traces have no such symmetry: the meaning of a placement does not depend on token position. These traces instead have, [push] and [pop] tokens that encode the control flow (i.e. branching and rollback). We agree that this mechanism may favor explicit representation of the constraint state since the model is given examples of constraint violation in failed branches. We did not inspect the representations of a model trained on solution-only traces since it achieved only approximately 60% grid accuracy, so we leave a controlled comparison of representation geometry across training formats to future work.
Q2. In the work-allocation experiment, an assignment action is represented by one atomic token , denoting the assignment of job (j) to worker (w) and machine (m), and there are 45 of each. Each job admits three workers and three machines, with the triples defined as follows: with , so there are 405 assignments in total. Incompatible triples have no assignment token. The initial part of the trace contains several preassignments (17 on average). As in the Sudoku case, traces additionally use [push], [pop], and [success] to encode backtracking. The constraint is that every job, worker and machine should be used exactly once. There’s no explicit encoding of the constraint on the level of traces. We then train 9 binary logistic regression probes per job, each predicting if one of the 9 assignments was used for this job. This is similar to the cell-level probes in Sudoku. We also train a binary logistic regression probe per worker and a probe per machine that predict if that worker or machine is assigned. This is similar to the substructure-level probes in Sudoku. From this experiment we get that the model represents the set of used workers and machines linearly in the residual stream, but does not represent the set of used assignments.
In graph coloring, we consider a fixed graph consisting of 48 vertices, forming 12 4-vertex cliques, with some edges between the cliques so that every vertex has degree 6. The goal is to color the graph in four colors. Every (vertex,color) assignment is a token, so there are 192 assignments in total. The rest is similar. The probes we consider are as follows. For every vertex we train a binary probe that predicts if the vertex is colored with color c. So there are 4 probes per vertex, 192 in total. For the constraint-level probes, we consider 4 probes per edge, one per color, each predicting if there is a vertex of that color on the edge. Both of the probes give ~0.5 exact-match accuracy.
Q3. The truncated traces are valid in the sense that they are simply a prefix of a full trace. Since they are truncated, they don’t end with a [success] token, and a branch can stay open (i.e. [push] without a [pop]). During early experimentation, we found that including these truncated traces did not affect the performance substantially, so we didn’t exclude them from the dataset.
Thank you for rebuttal, keeping the score
I thank the authors for their engagement and for describing additional details. The reassessed conclusion seems much more grounded in the experimental results, particularly regarding the narrower scope of the constraint-based world model claim. With that, however, the significance of the paper's contribution became a bit more questionable.
For these reasons, while I still believe the paper presents solid research (and wouldn't object to an overall acceptance of the paper), I have to keep my rating at 4, borderline accept.
- Rating
- 5/6
- Confidence
- 4/5
- Quality
- 4/4
- Clarity
- 4/4
- Significance
- 3/4
- Originality
- 2/4
- Contribution type
- general
- Ethical concerns
- NO or VERY MINOR ethics concerns only
Read review
Summary
This work trains a casual transformer to solve sudoku puzzles, and then applies mechanistic interpretability tools to investigate what it has learned. They show that it instantiates a coherent constraint-based world model.
Strengths and weaknesses
Thank you for an extremely clear and well structured paper! I like this a lot and have no concerns regarding implementation. The only thing I would really like to see is some more discussion of the implications of these findings, which would increase my rating.
Strengths: really excellent, clear, methodical application of interpretability tools to understand a small transformer.
Weaknesses: it's a small model in a small domain, and the wider implications of this work are not discussed. Originality contribution is limited – they apply known interp tools to a model trained on an existing dataset. But, it's very competently done.
I also think the title is a bit overstated - should be “Transformers Linearly Represent Constraint-based World Models in Sudoku” or similar?
Questions
“Linear probes for “is 56 digit d present in substructure S?” achieve perfect exact match accuracy across all 243 57 (substructure, digit) pairs in mid-layers, while per-cell probes plateau at 80% accuracy.” — why do you think this happens in mid-layers only? Also, binary is easier than 10 classes – do you account for that?
How much is this constraint-based world model a property of the task vs the architecture vs training protocol?
The decision circuit you found is sparse and monosemantic – do you expect all other decision circuits in the model to be so as well?
How do you reconcile this with work that demonstrates typical monosemanticity – is it a product of the task?
How do you expect these findings to inform our general understanding of transformer models and how they process and represent data?
What are the implications of these results? <-- a convincing argument for important implications would increase my rating.
Limitations
yes
Final justification
I've increased my significance rating in response to the author's explanation of the broader applicability of this work, and the addition of similar constraint-based findings in other tasks.
Formatting concerns
none
3 comments
Rebuttal
We thank the reviewer for the positive assessment and for pushing us on implications, which, we agree, was under-argued in the submission. We address each question below and have used this rebuttal to sharpen the paper's central claim.
Q1. On the title. We agree and thank you for your suggestion for a more accurate title: “Transformers Linearly Represent Constraint-based World Models in Sudoku”.
Q2. Task vs architecture vs training protocol. This question, together with the meta-review, pushed us to realize we had under-argued the paper's actual contribution. Prior interpretability work on toy environments (Othello, chess, mazes) has consistently found that models represent the state at the same granularity as the natural, surface-level encoding of the task, one feature per cell or square. The reason prior toy models did not uncover this phenomenon is not that they looked in the wrong place, but that in Othello, chess, and mazes the surface unit (a cell or square) already coincides with the unit that determines legal moves, so there was no gap between natural representation and task-relevant representation for a model to bridge; Sudoku is, to our knowledge, the first toy domain studied in this way where the two diverge, which is precisely what lets us observe the model choosing the algebra over the surface form. Our finding is that this choice is not universal in the trivial sense, that is, it is not automatic or guaranteed, but when a task has an explicit constraint algebra that differs from its surface presentation, the model discovers and represents the algebra instead, because the algebra is what actually determines legal moves. This is not simply a property of Sudoku's geometry. To test whether this is specific to Sudoku, we ran preliminary analyses on work allocation and graph coloring. Work allocation shows the same gap between a near-perfect representation of constraint state and a weaker representation of surface assignments, while graph-coloring heads attend to cliques, mirroring Sudoku’s constraint-aligned attention. We describe the tasks, probes, and results in our response to Reviewer bEYY, Q2. We believe this cross-domain replication is the right way to answer the "is this just architecture, or just this task" question empirically rather than by argument. Overall, these results suggest that the effect extends to a class of tasks where the surface state differs from the state governing the constraints. We have preliminary indications that this does not depend on transformer hyperparameters, but separating architecture and training protocol individual roles remains future work.
Q3. On mid-layer-only accuracy. We cannot yet determine why the transition occurs specifically at layer 4, but several results suggest a shift from building the constraint state to using it. Cross-layer transfer shows that layers 1-3 use a different geometry, while probes transfer almost perfectly across layers 4-7. Constraint-aligned attention heads also appear in these middle layers, and patching has its strongest effect there. We interpret the early layers as aggregating placement information and the middle layers as forming and using the stable substructure representation.
Q4. On the binary vs 10-class comparison. We clarify that the original cell probe is a 9-class problem because we train and evaluate only filled cells. We agree that comparing a multiclass probe with binary probes is not fully fair. We therefore trained 729 binary cell probes, one for every (cell, digit) pair. Requiring all nine probes for a filled cell to be correct gives 0.57 average exact-match accuracy, compared with approximately 1.0 for the binary substructure probes. The gap therefore remains with binary probes and the same exact-match metric.
Q5. Sparsity and monosemanticity of other decision circuits. We do not expect all decision circuits to be as clean as the naked-single circuit. NS is a local condition (one cell has exactly one candidate) and can be detected by a cell-specific neuron. Hidden singles require comparing the possible locations of a digit across an entire substructure, while backtracking requires comparing cells and deciding whether no forced placement is available. Our preliminary results support this difference. For hidden singles, we find no monosemantic (substructure, digit) detectors. The final-MLP amplification is instead spread across several types of neurons, although the pre-MLP residual already ranks the forced cell first in 97.57% of cases. Backtracking uses a mixed mechanism: the layer-7 MLP provides most of the [push] promotion, while three final-MLP neurons also write directly to the [push] logit. These results are still preliminary, but they suggest that decision circuits range from sparse and local to distributed and relational. We will add this distinction to the discussion.
Q6. Reconciling with typical monosemanticity findings. Superposition is generally understood as a consequence of representing more features than available dimensions, which incentivizes polysemantic, distributed encoding. Naked singles are a case where the relevant feature space is small and the same computation repeats identically across 81 cells and 9 digits, which plausibly makes a dedicated, monosemantic circuit the more efficient solution. We see this as consistent with, rather than contradicting, existing superposition results, and will make that connection explicit.
Q7. General implications. We think the main implication is that transformers trained on sequential reasoning traces do not necessarily encode the trace in the format in which it was presented, but instead, they build a constraint-sufficient state, that is, a representation of the information needed to determine which actions remain possible. These constraints can be represented more clearly than the individual surface facts, while the surface state remains only partially decodable from the constraints. This matters for interpretability: probing (or simply measuring against) only the obvious state-level decomposition may underestimate what the model has learned, and researchers should also look for representations organized around the task’s constraints.
Thank you for your considered response.
"We think the main implication is that transformers trained on sequential reasoning traces do not necessarily encode the trace in the format in which it was presented, but instead, they build a constraint-sufficient state, that is, a representation of the information needed to determine which actions remain possible. These constraints can be represented more clearly than the individual surface facts, while the surface state remains only partially decodable from the constraints. This matters for interpretability: probing (or simply measuring against) only the obvious state-level decomposition may underestimate what the model has learned, and researchers should also look for representations organized around the task’s constraints."
I think this is very compelling and would love to see this point made explicitly alongside the results from work allocation and graph colouring, to demonstrate broader applicability. Nice work.
We will be happy to include this to the discussion of the results together with the results on work allocation and graph coloring, with a full description of the additional domains in the appendix.
From OpenReview, CC BY 4.0. Authors as signed there; shown unedited.
Loading the discussion…
Summary of contribution and planned revisions
Dear Area Chair,
As the discussion phase closes, we would like to summarize what we believe the paper contributes in light of the discussion, and list the concrete revisions we commit to for the final version.
A new phenomenon, not previously observable in earlier toy domains. We do not dispute that toy settings have been studied extensively to understand emergent world models; that literature is our starting point. Our claim is that the phenomenon we report is new within it. In Othello, chess, and mazes, the unit that determines legal moves coincides with the surface unit of the input (a cell or a square), so the world models found in prior work were necessarily at surface granularity: there was no gap between the natural representation and the task-relevant one for a model to bridge. Sudoku is, to our knowledge, the first domain studied in this way where the two diverge: a compact constraint state (digit-per-substructure occupancy) determines which actions are legal without determining the full surface state. We find that the model represents this constraint state linearly and nearly perfectly, uses it causally, and represents the surface state only partially. The general insight, which Reviewer tmTr described as very compelling, is that transformers trained on reasoning traces need not reconstruct the world at its presented granularity; they can instead build a constraint-sufficient state. For interpretability practice, this means that probing only the obvious surface decomposition of a task can systematically underestimate what a model has learned.
Replication in two additional domains. Following the suggestion in the meta-review and by Reviewers bEYY and tmTr, we ran the same pipeline on two further constraint-satisfaction domains during the discussion period. In work allocation (405 job-worker-machine assignment tokens, exactly-once constraints on jobs, workers, and machines), the representational dissociation replicates with binary probes at both levels: per-job assignment probes reach 0.94 mean accuracy but only 0.504 joint exact match, while the full 45 worker coverage constraint state is recovered at 0.977 exact match. In graph coloring, the attention-organization finding replicates: attention heads organize around cliques, the groups of variables linked by a shared constraint, mirroring Sudoku's substructure-aligned heads. Together with Sudoku, these results support the regime-level claim the meta-review asked for: when a task has a compact constraint state that diverges from its surface state, the transformer preferentially represents the constraint state. Disentangling the individual roles of architecture and training protocol remains future work, though preliminary indications suggest the effect is not sensitive to transformer hyperparameters.
Planned revisions. Consolidating the commitments made across the individual responses:
We believe these changes directly address the significance concern: the paper reports a phenomenon that earlier toy domains could not have revealed, now replicated beyond Sudoku, with claims scoped accordingly. We thank the Area Chair and the reviewers for a discussion that materially improved the paper.