In this post I try to explain a whole host of logit lens variants. If you have a specific lens you'd like to understand, this post's best read in order according to the graph of contents. Otherwise, you can read this top-to-bottom; I've arranged the sections such that a lens' prerequisites precede it. You may or may not find the prerequisites helpful, but I'd recommend reading the transformer architecture recap at a minimum before you continue if you're not already familiar with transformers.
If you just want to know which lens to choose for your interpretability project, the MATS Which lens should I use? decision table might be a good place to start.
WorkspaceBench is a benchmark for global workspace lenses. It's worth reading the LW post (especially the section Desiderata of a workspace reader) to understand the kind of tasks that we'd like our lenses to do well on.
If you're reading this on LW, I'd recommend looking at the version on my website! It has interactive figures.
what is a lens?
Loosely, a lens is anything that takes model activations and produces a potentially workspace-like[1], somewhat human-interpretable, maybe causally relevant output. This output is usually a distribution over tokens, or sometimes multi-token trajectories. Tools like labelled SAE features, labelled MLP neurons, and NLAs probably also count as lenses, but they don't have "lens" in the name so I won't discuss them here.
A transformer takes a sequence of tokens as input.
Each token is a one-hot vector of shape , i.e. the token that we assign index is represented by the vector where ,
First, we apply the "embedding matrix" which "down-projects" the token to a residual-stream vector
Transformer blocks (layers), at a high level, read from and write to the residual stream based on the earlier tokens in the sequence and the residual stream as seen at their input.
You can think of attention heads as responsible for looking back at earlier tokens, and writing relevant information from those tokens into the residual stream, and the MLPs as responsible for doing various computations and transformations with the information in the residual stream.
Finally, the residual-stream vector is "up-projected" from to by the unembedding matrix.
For simplicity, we'll mostly ignore normalisation and softmax-ing.
notation
— "vocabulary size" of model, number of tokens it can represent.
— column vector with -th component 1 and all other components 0. The token with index is represented before embedding / after sampling by .
— "hidden dimension", "model dimension"
— residual stream content after transformer blocks, an arbitrary intermediate position.
shape .
— residual stream content after all transformer blocks, the final position in the residual stream before the unembedding matrix.
shape .
— unembedding matrix.
yields the logits.
— embedding matrix.
— composition of transformer layers (i.e. inclusive of layers a and b) as a function.
The logit lens is simple to implement; we apply the unembedding matrix at an intermediate point in the residual stream. An equivalent way of thinking about this is that we "cut out" further transformer blocks past some point in the residual stream. Mathematically, the logit lens on replaces with the identity function.
Why does this work at all?
If a layer "wants" to push the next-token prediction towards a specific token , the best way for it to transmit this information is by writing the vector to the residual stream, where .
On the other hand, if a layer has information that it intends for a later layer to read as part of a circuit, there's no reason that the way it writes this information to the residual stream should have any relation to the unembedding matrix, since the later layer(s) can easily transform these directions arbitrarily.
So, we might think that the interpretable part of the logit lens output is the model's "best guess" at what the next token is, since information that is supposed to be further processed before affecting the prediction is unlikely to "line up" with directions that strongly push the output distribution towards a specific token.
As you'd expect, the output of the logit lens is not very interpretable when applied on the lower layers, since much of the residual stream content is written to transmit information to later layers for further computation. Despite this, it's still likely that a model represents concepts that correspond well to certain tokens even in earlier layers. We'll call the tendency for average token-concept representations at intermediate layers to drift from the "inverse-unembedding" "basis"[2], representational drift.
Another important limitation of the logit lens is that it doesn't target the model's global workspace well.
The global workspace is (handwavingly) the space of concepts which a model has "conscious" access to, i.e. that it can accurately report on and manipulate at will. For instance, when answering a dastardly difficult multi-step reasoning problem like "What colour are the buses in the city containing Buckingham Palace?", we might expect to observe concepts relating to the words "bus", "city", "Buckingham Palace", "London", and "red" in the workspace.
As explained earlier, the logit lens can be thought of as a best-guess, given an intermediate residual stream vector, at the final logits. For the multi-step reasoning problem stated above, it's quite clear that "London" is an unlikely final answer, so a model might avoid pushing the next-token prediction towards "London", even though it's likely the model represents a concept for "London" internally as part of an intermediate reasoning step.
We saw earlier that the logit lens fails to account for representational drift, that is, the same token-concepts being represented differently at different points in the residual stream. To account for this, the tuned lens on trains an affine[3]"translator" to approximate .
As long as the representational drift is well approximated by an affine transformation, the tuned lens should correct for this and provide a more interpretable readout, especially at earlier layers where the drift is worse.
As long as the computation done by the transformer layers after some point is not well approximated by an affine transformation, the translator that replaces them should be incapable of learning to "shortcut" intermediate activations to last-layer activations. If our translator copies the computation done by the transformer layers it replaces too well, it becomes useless, since we lose access to the intermediate steps we're interested in.
Of course, neither of these assumptions are entirely true. Tuned lenses do tend to produce more coherent outputs at earlier layers compared to logit lenses, but in practice they sometimes have the capacity to approximate the remaining transformer layers fairly well, skipping over intermediate token-concept representations that other lenses can recover.
Unfortunately, like its younger sibling, the tuned lens still doesn't target the model's workspace well.
The aim of a tuned lens is to Elicit Latent Predictions, and therefore it shouldn't be surprising that tuned lens output distribution at later layers roughly monotonically converges towards the model's actual output distribution. We trained our "translators" to minimise prediction error, and it's intuitive that at later layers the output is easier to predict from the hidden state.
However, we might expect the workspace token distributions to occasionally diverge from the final next-token prediction when the model does multi-step reasoning. This suggests that the tuned lens, too, doesn't reliably target the model's workspace.
Concretely, it computes, for each layer, the average linearized effect of an activation on the model's likelihood of producing a particular token (now or in the future), averaging over a large corpus of contexts...
This means that how a direction in the residual stream tends to change the token distribution, averaged over many contexts, tells us its meaning.
Mathematically, the logit shift that we want to assign to is
is called the Jacobian. Calculating the average Jacobian over all contexts exactly is intractable for the models we care about, so instead we estimate it by evaluating the model over many contexts, backpropagating from at the current token position and subsequent token positions to , and taking an average.
For intuition though, it's helpful to think about the effect of small perturbations of . Over a large number of contexts we could perturb by some small amount , then take the mean of differences
as the "average linearised effect of an activation on the model's likelihood of producing a particular token". Repeating this for all basis vectors through yields an estimate for which we can use to transform arbitrary .
We'll call the space with "basis" given by the rows of the J-space. Actually, the rows of form an overcomplete set, but if we say that the J-space is the set of sparse, non negative combinations of those rows, then we get something that looks like a high-dimensional space.
Empirically, the J-space acts like a workspace. Intervening on by adding/subtracting J-lens vectors to it affects the model's output the way we'd expect it to if the J-space were a global workspace, and the model can "introspect" on the concepts in its J-space, and manipulate them on command.
Why would we expect the J-lens to access the model's global workspace?
J-space vectors can represent intermediate steps without steering towards the intermediate step's token. We already saw this is a desideratum that logit and tuned lenses lack.
The J-space vector for a token-concept still ends up steering the final prediction to that token in the average context, so it probably represents a concept related to that token to the model itself.
The future lens is quite different from the lenses we've seen up to this point. We take advantage of the model's latent capability to understand its own activations to produce multiple tokens from a hidden state.
Suppose we measure from a model prompted with context that produces output and "patch" into the model at the same layer under another context , forcing .
You might naively hope that the output after this intervention, , will be much closer to than the output without this intervention is. This is plausible, since remaining layers, , are able to understand the contents of and output differently based on this. However, is also dependent on . The conflicting context prevents the patched activation from steering well.
The future lens optimises the same "soft prompt" over many interventions so that
The idea here is that will be optimised to only contain information which helps generalised prediction capability like "output grammatically correct text" or "output more common words instead of rarer ones" and therefore the output on the soft prompt + unseen activation is only a function of the unseen activation.
The future lens also nicely generalises to multi-token readouts. On decoding further tokens we give the soft prompt concatenated with the earlier decoded tokens and perform the same hidden state intervention:
training for multiple token continuation
doesn't necessarily have the same nice properties as that allow it to elicit accurate predictions based on the injected hidden state. In the Future Lens paper they train with one continuation token already appended, as produced by the model with original context , and find that it works best. 🤷
As far as I am aware, the future lens was the first lens to produce a multi-token readout. We'll see some other examples later.
The future lens is in principle not a workspace lens. might contain circuits that the injected residual-stream vector happens to contain the global workspace inputs for. The output then "skips over" these intermediate inputs we'd like our lens to access and instead computes the next-token prediction.
The output of the J-lens is restricted to single tokens. This is quite a severe limitation, because many of the concepts we care about can't be represented in a human-interpretable way by a single token. The template lens is a J-lens-esque technique for these multi-token concepts.
We start with a list of D multi-token words/phrases . For each , we prompt our model to write a large number of diverse passages where is the natural completion, but doesn't appear anywhere in the passage. We run the model over our passages for and collect at the last token of the passage, taking the mean as 𝛍. We'll call the mean over all passages and words 𝛍.
The template lens is then defined as follows:
𝛍𝛍
Essentially, we compare how similar is to the difference-in-mean-activations for a given concept 𝛍𝛍𝛍. We whiten[4] and 𝛍 to account for the fact that some directions have lower variance than others, so in those directions a larger or 𝛍 is more significant.
The R-lens is a modification to the J-lens which uses Layerwise Relevance Propagation instead of backpropagation. I'll focus on intuition & differences in modelling assumptions between the J-lens and R-lens, because the implementation is not very illuminating in my opinion. Importantly, the R-lens has improved empirical performance in early layers compared to the J-lens. It's since been outperformed by the J++, which also uses relevance propagation.
I have two basic intuitions for why LRP might be better to use than good-old-fashioned backprop.
1. denoising gradients
LRP can be thought of as a modification of backpropagation. It might stop / downweight gradient terms where we'd have a systematically wrong approximation of finite differences in given alone. This reduces their effect on the estimate of . Therefore our estimate of using LRP should work better to approximate finite differences.
2. sensitivity vs contribution
Contribution is defined fairly intuitively: if , contributes , and contributes . and both contribute .
On the other hand, the sensitivity of to tells us how a change in affects . 's sensitivity to is entirely described by , etc. In general, the sensitivity of an output to an input is described by the (potentially infinite) sequence of -th derivatives, and might be dependent on other inputs (consider ).
It turns out that if we replace backprop with LRP in our J-lens estimation process, instead of a matrix () telling us the average first order sensitivity of to , we get a matrix () telling us the average contribution of to .
In principle, can model the average contributions entirely, whereas can only ever model the average first-order sensitivity. It could be that for our purposes, a complete model of average contributions is better than an incomplete model of average sensitivity, even though our intuition from the J-lens was that the concept of sensitivity better captures what we want a good lens to read:
...how a direction in the residual stream tends to change the token distribution, averaged over many contexts, tells us its meaning.
The chain lens is a straightforward improvement on the J-lens which uses multi-token prediction heads[5]with contrastive decoding[6]to elicit multi-token predictions from the J-lens.
The J++ lens is another J-lens variant, incorporating LRP as introduced by the R-lens. Importantly, the J++ lens does Jacobian Filtering. Also, the J++-lens restricts its readouts to tokens with semantic meaning ("readout filtering" in the jargon of the paper).
The core idea for Jacobian filtering is quite simple. We first partition the activation space into subsets through . We then fit Jacobians for each , by using the same procedure as the R-lens but restricted to average for . These Jacobians are referred to as "expert" Jacobians, by analogy to the mixture of experts architecture in transformers[7]. We create a benchmark of latent-variable extraction problems (like the example in the penultimate paragraph of the logit lens section) to test how well the lens accesses the model's workspace, and then optimise weights for each so that has good performance on this benchmark.
The authors show empirically that Jacobian filtering is responsible for most of the J++ lens' uplift over the J and R lenses[8].
This makes sense, because we chose weights that perform well on our benchmark. If we assume that some noisy components are responsible for making the J-lens perform poorly, then downweighting or zeroing the noisy components should make the lens perform better. The authors find some evidence for this; removing the worst-performing experts from the R-lens improves performance[9], and the single best expert recovers most of the uplift of the J++-lens[10]. However, it's not so clear to me what mechanism explains the rest of the uplift.
You could argue there is potential for overfitting . Empirically, this doesn't seem to be the case[11]. In this case, if the activation space partition is sufficiently coarse, it is unlikely that the weights have enough capacity to overfit to the training benchmark.
The authors also explore some hypotheses as to why some expert Jacobians are worse than others. They find some evidence that the poorly performing experts were more often fit on non-semantic tokens[12], although this doesn't exclusively explain the bad experts.
The oracle lens is another lens from Anthropic's Global Workspace paper, but it's quite a bit more elaborate than the J-lens and template lens, using a pipeline of self-supervised models to recover arbitrary multi-token phrases from a residual-stream vector.
First, we train a reconstructor. This is a copy of our base model fine-tuned to map a short[13]phrase of text to , an activation vector which is ideally equal to . We sample at the token position immediately before the phrase.
Like in the template lens, our s and s are whitened so that errors in directions which typically vary less are up-weighted and vice-versa. I won't keep mentioning whitening explicitly since it's not that consequential to understanding how the lens works, but it's used consistently throughout the process.
Next, we build a list of multi-token phrases sampled from model-generated text (you can read the Anthropic paper for more detail on how exactly this is done). We'll then pass our phrases through the reconstructor model to produce a dictionary mapping phrases to phrase vectors.
The dictionary of phrase vectors is used to label unseen activations from the model while it is generating text in the <|assistant|> turn. We ‘decompose’ these activations into an ordered list of (at most) phrase vectors from our dictionary which hopefully explain the variance of .
how does the decomposition work?
The algorithm for decomposing an activation vector into phrase vectors looks like this:
Finally, we train an oracle: yet another fine-tuned copy of our base model, which will reproduce our phrase-vector lists given an injected , and a prompt including , the desired phrase length, and , the desired number of phrases in the phrase-vector list. The oracle's training target is the first phrase-vectors corresponding to phrases of length generated by our "teacher", the decomposition algorithm. The rank-ordering produced by the oracle ideally matches the teacher's order.
This might seem pointless, since at best the oracle will match the performance of the decomposition algorithm. However, after this self-supervised fine-tuning step, we further RL-train our oracle model on new assistant-turn activations to maximise the fraction of activation variance its reconstructions explain. There are also slight penalties for high phrase count and deviating from the target phrase count and phrase length given in the prompt.
At inference-time we:
Sample of interest from the base model.
Inject into our oracle and sample phrases from the oracle's phrase list.
Map each oracle-generated phrase to an activation direction using the reconstructor.
Choose non-negative coefficients so that is as close as possible to .
This is a simple lens, conceptually similar to the logit lens, for looped models with architecture similar to Inkling 2 Mini.
Inkling 2 Mini's architecture consists of a 6-transformer-layer "prelude", followed by a 12-layer "core" and then a 6-layer "coda". The core is looped 3 times, which means after the first forward pass through the core we take the output and pass it through the core 2 times subsequently.
The coda lens simply cuts out some number of passes through the core (much in the same manner as the last few transformer blocks are cut out for the logit lens), and applies the coda to read out the inter-pass state. Note that the coda can attend to prior tokens and is therefore not exclusively a function of the inter-pass hidden state at the current token position.
This method is useful as a starting point to interpret what computation is being done in subsequent passes, but is quite limited as a workspace lens. Each pass of the core can do significant computation, which would obscure the intermediate states we wish to recover. Inkling 2 Mini's coda has 6 transformer blocks and is therefore capable of significant computation, which is not desirable for a workspace lens.
The K-lens is a natural extension of the J-lens. Instead of finding the Jacobian , we find the transpose of the Jacobian, :
what does the Jacobian transpose mean? What does mean?
The -th element of tells us the dot product between the -th column of and . So is basically telling us how similar is to
In a similar vein tells us how similar is to the embedding of the -th token,
We estimate in the same manner as . We can interpret the output of as telling us which input tokens would push the state at layer in the direction of on average.
. Suppose there exists some "inverse-unembedding" matrix and . Then , i.e. the columns of the "inverse-unembedding" matrix are the residual vectors that approximately correspond to each token after unembedding. I've put "inverse-unembedding" and "basis" in scare quotes because I am being sloppy and hiding some complexity behind the sign.
In this post I try to explain a whole host of logit lens variants. If you have a specific lens you'd like to understand, this post's best read in order according to the graph of contents. Otherwise, you can read this top-to-bottom; I've arranged the sections such that a lens' prerequisites precede it. You may or may not find the prerequisites helpful, but I'd recommend reading the transformer architecture recap at a minimum before you continue if you're not already familiar with transformers.
If you just want to know which lens to choose for your interpretability project, the MATS Which lens should I use? decision table might be a good place to start.
WorkspaceBench is a benchmark for global workspace lenses. It's worth reading the LW post (especially the section Desiderata of a workspace reader) to understand the kind of tasks that we'd like our lenses to do well on.
If you're reading this on LW, I'd recommend looking at the version on my website! It has interactive figures.
what is a lens?
Loosely, a lens is anything that takes model activations and produces a potentially workspace-like[1], somewhat human-interpretable, maybe causally relevant output. This output is usually a distribution over tokens, or sometimes multi-token trajectories. Tools like labelled SAE features, labelled MLP neurons, and NLAs probably also count as lenses, but they don't have "lens" in the name so I won't discuss them here.
transformer architecture recap & notation reference
further reading: A Mathematical Framework for Transformer Circuits, Anthropic (2021)
notation
the logit lens
prerequisites: what is a lens?, transformer architecture recap.
further reading: interpreting GPT: the logit lens,
nostalgebraist(2020)The logit lens is simple to implement; we apply the unembedding matrix at an intermediate point in the residual stream. An equivalent way of thinking about this is that we "cut out" further transformer blocks past some point in the residual stream. Mathematically, the logit lens on replaces with the identity function.
Why does this work at all?
If a layer "wants" to push the next-token prediction towards a specific token , the best way for it to transmit this information is by writing the vector to the residual stream, where .
On the other hand, if a layer has information that it intends for a later layer to read as part of a circuit, there's no reason that the way it writes this information to the residual stream should have any relation to the unembedding matrix, since the later layer(s) can easily transform these directions arbitrarily.
So, we might think that the interpretable part of the logit lens output is the model's "best guess" at what the next token is, since information that is supposed to be further processed before affecting the prediction is unlikely to "line up" with directions that strongly push the output distribution towards a specific token.
As you'd expect, the output of the logit lens is not very interpretable when applied on the lower layers, since much of the residual stream content is written to transmit information to later layers for further computation. Despite this, it's still likely that a model represents concepts that correspond well to certain tokens even in earlier layers. We'll call the tendency for average token-concept representations at intermediate layers to drift from the "inverse-unembedding" "basis"[2], representational drift.
Another important limitation of the logit lens is that it doesn't target the model's global workspace well.
The global workspace is (handwavingly) the space of concepts which a model has "conscious" access to, i.e. that it can accurately report on and manipulate at will. For instance, when answering a dastardly difficult multi-step reasoning problem like "What colour are the buses in the city containing Buckingham Palace?", we might expect to observe concepts relating to the words "bus", "city", "Buckingham Palace", "London", and "red" in the workspace.
As explained earlier, the logit lens can be thought of as a best-guess, given an intermediate residual stream vector, at the final logits. For the multi-step reasoning problem stated above, it's quite clear that "London" is an unlikely final answer, so a model might avoid pushing the next-token prediction towards "London", even though it's likely the model represents a concept for "London" internally as part of an intermediate reasoning step.
next: tuned lens, j-lens, future lens, chain lens, or coda lens.
tuned lens
prerequisites: the logit lens.
further reading: Eliciting Latent Predictions from Transformers with the Tuned Lens, Belrose et al. (2023)
We saw earlier that the logit lens fails to account for representational drift, that is, the same token-concepts being represented differently at different points in the residual stream. To account for this, the tuned lens on trains an affine[3]"translator" to approximate .
As long as the representational drift is well approximated by an affine transformation, the tuned lens should correct for this and provide a more interpretable readout, especially at earlier layers where the drift is worse.
As long as the computation done by the transformer layers after some point is not well approximated by an affine transformation, the translator that replaces them should be incapable of learning to "shortcut" intermediate activations to last-layer activations. If our translator copies the computation done by the transformer layers it replaces too well, it becomes useless, since we lose access to the intermediate steps we're interested in.
Of course, neither of these assumptions are entirely true. Tuned lenses do tend to produce more coherent outputs at earlier layers compared to logit lenses, but in practice they sometimes have the capacity to approximate the remaining transformer layers fairly well, skipping over intermediate token-concept representations that other lenses can recover.
Unfortunately, like its younger sibling, the tuned lens still doesn't target the model's workspace well.
The aim of a tuned lens is to Elicit Latent Predictions, and therefore it shouldn't be surprising that tuned lens output distribution at later layers roughly monotonically converges towards the model's actual output distribution. We trained our "translators" to minimise prediction error, and it's intuitive that at later layers the output is easier to predict from the hidden state.
However, we might expect the workspace token distributions to occasionally diverge from the final next-token prediction when the model does multi-step reasoning. This suggests that the tuned lens, too, doesn't reliably target the model's workspace.
next: future lens.
j-lens
prerequisites: the logit lens.
further reading: Verbalizable Representations Form a Global Workspace in Language Models, Anthropic (2026)
The J-lens is a significant improvement on the logit lens, allowing us to observe workspace-like behaviour.
How does it work? From 'Verbalizable representations...' (emphasis mine):
This means that how a direction in the residual stream tends to change the token distribution, averaged over many contexts, tells us its meaning.
Mathematically, the logit shift that we want to assign to is
For intuition though, it's helpful to think about the effect of small perturbations of . Over a large number of contexts we could perturb by some small amount , then take the mean of differences
as the "average linearised effect of an activation on the model's likelihood of producing a particular token". Repeating this for all basis vectors through yields an estimate for which we can use to transform arbitrary .
We'll call the space with "basis" given by the rows of the J-space. Actually, the rows of form an overcomplete set, but if we say that the J-space is the set of sparse, non negative combinations of those rows, then we get something that looks like a high-dimensional space.
Empirically, the J-space acts like a workspace. Intervening on by adding/subtracting J-lens vectors to it affects the model's output the way we'd expect it to if the J-space were a global workspace, and the model can "introspect" on the concepts in its J-space, and manipulate them on command.
Why would we expect the J-lens to access the model's global workspace?
next: template lens, r-lens, chain lens, j++ lens, or k-lens.
future lens
prerequisites: the logit lens, tuned lens.
further reading: Future Lens: Anticipating Subsequent Tokens from a Single Hidden State, Pal et al. (2023)
The future lens is quite different from the lenses we've seen up to this point. We take advantage of the model's latent capability to understand its own activations to produce multiple tokens from a hidden state.
Suppose we measure from a model prompted with context that produces output and "patch" into the model at the same layer under another context , forcing .
You might naively hope that the output after this intervention, , will be much closer to than the output without this intervention is. This is plausible, since remaining layers, , are able to understand the contents of and output differently based on this. However, is also dependent on . The conflicting context prevents the patched activation from steering well.
The future lens optimises the same "soft prompt" over many interventions so that
The idea here is that will be optimised to only contain information which helps generalised prediction capability like "output grammatically correct text" or "output more common words instead of rarer ones" and therefore the output on the soft prompt + unseen activation is only a function of the unseen activation.
The future lens also nicely generalises to multi-token readouts. On decoding further tokens we give the soft prompt concatenated with the earlier decoded tokens and perform the same hidden state intervention:
training for multiple token continuation
As far as I am aware, the future lens was the first lens to produce a multi-token readout. We'll see some other examples later.
The future lens is in principle not a workspace lens. might contain circuits that the injected residual-stream vector happens to contain the global workspace inputs for. The output then "skips over" these intermediate inputs we'd like our lens to access and instead computes the next-token prediction.
template lens
prerequisites: j-lens.
further reading: Verbalizable Representations Form a Global Workspace in Language Models, Anthropic (2026)
The output of the J-lens is restricted to single tokens. This is quite a severe limitation, because many of the concepts we care about can't be represented in a human-interpretable way by a single token. The template lens is a J-lens-esque technique for these multi-token concepts.
We start with a list of D multi-token words/phrases . For each , we prompt our model to write a large number of diverse passages where is the natural completion, but doesn't appear anywhere in the passage. We run the model over our passages for and collect at the last token of the passage, taking the mean as 𝛍 . We'll call the mean over all passages and words 𝛍 .
The template lens is then defined as follows:
Essentially, we compare how similar is to the difference-in-mean-activations for a given concept 𝛍 𝛍 𝛍 . We whiten[4] and 𝛍 to account for the fact that some directions have lower variance than others, so in those directions a larger or 𝛍 is more significant.
next: oracle lens.
r lens
prerequisites: j-lens.
further reading: R-lens: Making J-lens More Faithful on Early Layers,
camilablanket al. (2026)The R-lens is a modification to the J-lens which uses Layerwise Relevance Propagation instead of backpropagation. I'll focus on intuition & differences in modelling assumptions between the J-lens and R-lens, because the implementation is not very illuminating in my opinion. Importantly, the R-lens has improved empirical performance in early layers compared to the J-lens. It's since been outperformed by the J++, which also uses relevance propagation.
I have two basic intuitions for why LRP might be better to use than good-old-fashioned backprop.
1. denoising gradients
LRP can be thought of as a modification of backpropagation. It might stop / downweight gradient terms where we'd have a systematically wrong approximation of finite differences in given alone. This reduces their effect on the estimate of . Therefore our estimate of using LRP should work better to approximate finite differences.
2. sensitivity vs contribution
Contribution is defined fairly intuitively: if , contributes , and contributes . and both contribute .
On the other hand, the sensitivity of to tells us how a change in affects . 's sensitivity to is entirely described by , etc. In general, the sensitivity of an output to an input is described by the (potentially infinite) sequence of -th derivatives, and might be dependent on other inputs (consider ).
It turns out that if we replace backprop with LRP in our J-lens estimation process, instead of a matrix ( ) telling us the average first order sensitivity of to , we get a matrix ( ) telling us the average contribution of to .
In principle, can model the average contributions entirely, whereas can only ever model the average first-order sensitivity. It could be that for our purposes, a complete model of average contributions is better than an incomplete model of average sensitivity, even though our intuition from the J-lens was that the concept of sensitivity better captures what we want a good lens to read:
next: j++ lens or s-lens.
chain lens
prerequisites: the logit lens, j-lens.
further reading: The Chain Lens
The chain lens is a straightforward improvement on the J-lens which uses multi-token prediction heads[5]with contrastive decoding[6]to elicit multi-token predictions from the J-lens.
j++ lens
prerequisites: j-lens, r lens.
further reading: J++ Lens: Jacobian Filtering Enables More Faithful Workspace Lenses, Ayonrinde and Lindsey (2026)
The J++ lens is another J-lens variant, incorporating LRP as introduced by the R-lens. Importantly, the J++ lens does Jacobian Filtering. Also, the J++-lens restricts its readouts to tokens with semantic meaning ("readout filtering" in the jargon of the paper).
The core idea for Jacobian filtering is quite simple. We first partition the activation space into subsets through . We then fit Jacobians for each , by using the same procedure as the R-lens but restricted to average for . These Jacobians are referred to as "expert" Jacobians, by analogy to the mixture of experts architecture in transformers[7]. We create a benchmark of latent-variable extraction problems (like the example in the penultimate paragraph of the logit lens section) to test how well the lens accesses the model's workspace, and then optimise weights for each so that has good performance on this benchmark.
The authors show empirically that Jacobian filtering is responsible for most of the J++ lens' uplift over the J and R lenses[8].
This makes sense, because we chose weights that perform well on our benchmark. If we assume that some noisy components are responsible for making the J-lens perform poorly, then downweighting or zeroing the noisy components should make the lens perform better. The authors find some evidence for this; removing the worst-performing experts from the R-lens improves performance[9], and the single best expert recovers most of the uplift of the J++-lens[10]. However, it's not so clear to me what mechanism explains the rest of the uplift.
You could argue there is potential for overfitting . Empirically, this doesn't seem to be the case[11]. In this case, if the activation space partition is sufficiently coarse, it is unlikely that the weights have enough capacity to overfit to the training benchmark.
The authors also explore some hypotheses as to why some expert Jacobians are worse than others. They find some evidence that the poorly performing experts were more often fit on non-semantic tokens[12], although this doesn't exclusively explain the bad experts.
oracle lens
prerequisites: template lens.
further reading: Verbalizable Representations Form a Global Workspace in Language Models, Anthropic (2026)
The oracle lens is another lens from Anthropic's Global Workspace paper, but it's quite a bit more elaborate than the J-lens and template lens, using a pipeline of self-supervised models to recover arbitrary multi-token phrases from a residual-stream vector.
First, we train a reconstructor. This is a copy of our base model fine-tuned to map a short[13]phrase of text to , an activation vector which is ideally equal to . We sample at the token position immediately before the phrase.
Like in the template lens, our s and s are whitened so that errors in directions which typically vary less are up-weighted and vice-versa. I won't keep mentioning whitening explicitly since it's not that consequential to understanding how the lens works, but it's used consistently throughout the process.
Next, we build a list of multi-token phrases sampled from model-generated text (you can read the Anthropic paper for more detail on how exactly this is done). We'll then pass our phrases through the reconstructor model to produce a dictionary mapping phrases to phrase vectors.
The dictionary of phrase vectors is used to label unseen activations from the model while it is generating text in the phrase vectors from our dictionary which hopefully explain the variance of .
<|assistant|>turn. We ‘decompose’ these activations into an ordered list of (at most)how does the decomposition work?
The algorithm for decomposing an activation vector into phrase vectors looks like this:
https://en.wikipedia.org/wiki/Matching_pursuit
Finally, we train an oracle: yet another fine-tuned copy of our base model, which will reproduce our phrase-vector lists given an injected , and a prompt including , the desired phrase length, and , the desired number of phrases in the phrase-vector list. The oracle's training target is the first phrase-vectors corresponding to phrases of length generated by our "teacher", the decomposition algorithm. The rank-ordering produced by the oracle ideally matches the teacher's order.
This might seem pointless, since at best the oracle will match the performance of the decomposition algorithm. However, after this self-supervised fine-tuning step, we further RL-train our oracle model on new assistant-turn activations to maximise the fraction of activation variance its reconstructions explain. There are also slight penalties for high phrase count and deviating from the target phrase count and phrase length given in the prompt.
At inference-time we:
coda lens
prerequisites: the logit lens.
further reading: Interpreting Inkling 2 Mini, Lee et al. (2026)
This is a simple lens, conceptually similar to the logit lens, for looped models with architecture similar to Inkling 2 Mini.
Inkling 2 Mini's architecture consists of a 6-transformer-layer "prelude", followed by a 12-layer "core" and then a 6-layer "coda". The core is looped 3 times, which means after the first forward pass through the core we take the output and pass it through the core 2 times subsequently.
The coda lens simply cuts out some number of passes through the core (much in the same manner as the last few transformer blocks are cut out for the logit lens), and applies the coda to read out the inter-pass state. Note that the coda can attend to prior tokens and is therefore not exclusively a function of the inter-pass hidden state at the current token position.
This method is useful as a starting point to interpret what computation is being done in subsequent passes, but is quite limited as a workspace lens. Each pass of the core can do significant computation, which would obscure the intermediate states we wish to recover. Inkling 2 Mini's coda has 6 transformer blocks and is therefore capable of significant computation, which is not desirable for a workspace lens.
k-lens
prerequisites: j-lens.
further reading: K-lens, Vogel (2026), with attribution and method in the neuron-lens documentation
The K-lens is a natural extension of the J-lens. Instead of finding the Jacobian , we find the transpose of the Jacobian, :
what does the Jacobian transpose mean? What does mean?
The -th element of tells us the dot product between the -th column of and . So is basically telling us how similar is to
In a similar vein tells us how similar is to the embedding of the -th token,
We estimate in the same manner as . We can interpret the output of as telling us which input tokens would push the state at layer in the direction of on average.
next: s-lens.
s-lens
prerequisites: r lens, k-lens.
further reading: neuron-lens,
_a9limandtreetowntree(2026)S-lens is to R-lens as K-lens is to J-lens :3
Psychology term referring to the space of consciously accessible and manipulable concepts — see Baars (2002)
An affine transformation of a vector to is described by a matrix and vector , and computed as
en.wikipedia.org/wiki/Whitening_transformation. is the covariance matrix of s over all words & all passages. We add as a ridge regularisation term which prevents directions with very small variance from dominating .
as the name implies, an MTP head allows multiple tokens to be decoded from a single last-layer residual . Introduced by Gloeckle et al. (2024)
An interesting technique, but slightly out of scope for this post. Introduced by Li et al. (2022)
https://en.wikipedia.org/wiki/Mixture_of_experts
Appendix H: Ablations, Figure 18 and Table 4, “without Jacobian Filtering (Pooled Jacobian)”.
Appendix H: Ablations, Table 4, “Pooled Jacobian, two worst experts dropped”.
Appendix H: Ablations, Table 4, “best expert per layer”.
Appendix H: Ablations, Table 4, “leave one out, dev set has no overlap with evaluation task”.
Appendix G: What Is in the Bad Experts?, Figure 13.
phrase length is variable, the Anthropic paper says they sample uniformly from .