19  X-Raying the Kitten Brain

Mechanistic Interpretability, Circuits, and SAEs

⏳ 2026 Edition: Last verified: 2026-02-24

Prerequisites: Chapter 18

Technical Keywords: Mechanistic Interpretability, Linear Probes, QK/OV Circuits, Polysemanticity, Superposition, Sparse Autoencoders (SAEs), Activation Patching, Feature Importance


🧭 Advanced Track Navigation Core Track completion is defined by Checkpoints 1-4. This chapter belongs to the Advanced Track. Prioritize Linear Probes on first pass; the [Advanced Track] sections (Circuits, Superposition & Polysemanticity, Sparse Autoencoders, and Activation Patching) are safe to skim and are not required for checkpoints.

In Chapter 8, we noted that Deep Learning is a Black Box. We push a picture of a mouse in, millions of decimal weights multiply together, and the word “Mouse” comes out.

If Pixel bites someone, and we look inside his brain to find out why, we just see a massive 10,000 \times 10,000 matrix of numbers: [[0.43, -0.12, 0.99...], [-0.55, 0.11, 0.02...]]

This is completely unreadable to humans. Interpretability can improve assurance, but it cannot by itself guarantee AI safety. We need to put the network in an MRI machine and reverse-engineer its thoughts.

Welcome to Mechanistic Interpretability. We are going to do brain surgery on the kitten.


19.1 Linear Probes: Reading the Kitten’s Mind

Let’s say we feed a picture of a mouse to Pixel. The data flows to the 50th layer of his CNN. At layer 50, the image has been transformed into a dense vector of 1,000 numbers (an Embedding, from Chapter 10).

Does Layer 50 know it is looking at a mouse? To find out, we use a Linear Probe. We take the 1,000 numbers from Layer 50, freeze the network, and attach a tiny, simple Logistic Regression model (Chapter 5) to it. We ask the tiny model to predict “Mouse vs. Not Mouse.”

If the tiny model achieves 99% accuracy, we have evidence that the concept of “Mouse” is linearly decodable at Layer 50. We have read part of the network’s internal representation.


19.2 [Advanced Track] Circuits: The Clockwork of the Mind

Safe to skim on first pass; not required for checkpoints.

Neural networks don’t just memorize concepts; they build algorithms.

Researchers at Anthropic reverse-engineered tiny LLMs and found Circuits—distinct paths of Attention Heads working together like gears in a clock (Olsson et al., 2022).

The Induction Head Circuit: How does an LLM know to autocomplete repetitive text? 1. Head A (Previous-Token Head) copies information about each token onto the token immediately following it—so “Potter” gets tagged with “came right after Harry.” 2. Head B (Induction Head) looks at the current word (“Harry”) and scans the prompt for an earlier token tagged as “came right after Harry” (“Potter”). 3. Head B then copies the vector for “Potter” to the present position, boosting “Potter” as the next prediction.

They found this gear-like mechanism in many studied Transformer models. The LLM isn’t magic; it is mathematical clockwork.


19.3 [Advanced Track] Superposition & Polysemanticity: The Crammed Brain

Safe to skim on first pass; not required for checkpoints.

Here is the biggest roadblock in understanding AI: Neurons do not represent single ideas.

In a perfect world, Neuron 402 would be the “Tuna” neuron. It only lights up for tuna. But AI models have a problem. There are billions of concepts in the universe, but the model only has 10,000 neurons per layer.

To save space, the optimization engine engages in Superposition: instead of dedicating one neuron per concept, it encodes far more concepts as overlapping directions across the layer’s activation vector, so a single neuron ends up responding to dozens of unrelated concepts. Neuron 402 might light up for “Tuna”, but it also lights up for “The color purple”, “The Eiffel Tower”, and “Sadness.”

This makes the neuron Polysemantic (having many meanings). When we look at Neuron 402 firing, we have absolutely no idea which of the 50 concepts the model is actually thinking about! The MRI is blurry.

Diagram showing a single neuron representing multiple unrelated concepts

The Polysemantic Brain — neurons that represent multiple concepts.

19.4 [Advanced Track] Sparse Autoencoders (SAEs): Unpacking the Box

Safe to skim on first pass; not required for checkpoints.

How do we separate the 50 crammed concepts? We use a Sparse Autoencoder (SAE).

An SAE is a separate, secondary neural network. We take a layer’s activation vector (containing Neuron 402 alongside its neighboring neurons) and feed it into the SAE. The SAE projects that vector into a much larger dictionary of artificial features (say, 100,000 latent units), while using L1 Regularization (Chapter 5) to encourage high sparsity (most latent units staying at 0), decomposing polysemantic activations into cleaner monosemantic directions.

The result? The SAE can partially “unpack” superposition by separating some blurry signals into more interpretable Features, but not into clean, perfectly interpretable features in every case (Bricken et al., 2023). Thanks to SAEs, we can sometimes isolate candidate vectors associated with concepts like “The Eiffel Tower,” but this is not yet guaranteed to be exact, unique, or complete.


19.5 [Advanced Track] Activation Patching: Kitten Brain Surgery

Safe to skim on first pass; not required for checkpoints.

Once we find the exact Feature vector for a concept, we can do brain surgery.

Imagine prompting an LLM: “The Golden Gate Bridge is located in…” The LLM is about to output “San Francisco.”

Right before it generates the word, we pause the math. We find the isolated feature for “San Francisco”, and we mathematically subtract it. Then, we artificially inject (add) the exact feature vector for “Rome.” We unpause the math.

The LLM outputs: “The Golden Gate Bridge is located in Rome.”

This is Activation Patching (Meng et al., 2022; Wang et al., 2022). We didn’t change the prompt, and we didn’t change the weights. We reached directly into the “thought” as it was flowing through the network and surgically replaced it.

Rosetta Stone

Kitten World Math/Concept The Goal
“Reading the mind” Linear Probes Train a tiny classifier on internal activations to find concepts.
“The crammed brain” Superposition / Polysemanticity Understanding that neurons represent multiple concepts simultaneously.
“Unpacking the box” Sparse Autoencoders (SAEs) Forcing activations into a higher-dimensional space to isolate single features.
“Kitten brain surgery” Activation Patching Surgically intervening on the hidden state to alter the model’s output.

19.6 Removing the Training Wheels

The Real Engineering

We talked about X-raying brains and Polysemanticity. In Mechanistic Interpretability, ‘Superposition’ refers to networks representing more features than they have dimensions by packing them into almost-orthogonal vectors. Sparse Autoencoders (SAEs) use an L1 penalty to learn an overcomplete dictionary of features, attempting to disentangle these overlapping representations into monosemantic directions. Activation Patching is a causal intervention where we swap a specific intermediate tensor during the forward pass to measure its direct effect on the output logits.

19.7 Paws and Reflect: Chapter 19 Quiz

1. Why can’t we just look at a single neuron in an LLM and say, “Ah, this is the neuron that understands French”? Because of Polysemanticity and Superposition. That neuron probably fires for French, but also for “Apples” and “The year 1994”. Concepts are smeared across thousands of neurons, and neurons hold thousands of concepts.
2. You want to know if Layer 12 of your model understands the concept of “Sarcasm.” What technique should you use? A Linear Probe. Feed sarcastic and non-sarcastic sentences through the network, freeze Layer 12, and see if a tiny logistic regression classifier can perfectly separate the two based solely on Layer 12’s activations.
3. In Activation Patching, are you changing the Model’s Weights (W), or are you changing the Hidden State (h) flowing through the network? The Hidden State! The weights remain completely frozen. You are intercepting and altering the electrical signals (the activations) of the thought process itself.

19.8 Chapter 19 Summary

You’ve learned how to open the black box and read the mind of an AI:

  • Mechanistic Interpretability: The science of reverse-engineering neural networks into human-understandable algorithms.
  • Linear Probes: Testing if a specific layer “knows” a concept.
  • Circuits: Tracing exactly how Attention Heads route information to make logical decisions.
  • Superposition / Polysemanticity: Networks encode more features than dimensions as overlapping directions across a layer’s activation vector, causing individual neurons to respond to multiple unrelated concepts.
  • Sparse Autoencoders (SAEs): A tool that projects layer activation vectors into a sparse overcomplete dictionary to isolate candidate monosemantic feature directions.
  • Activation Patching: Surgically editing the thoughts of a model in real-time.

AI Safety Thread: Chapter 19

Deceptive Alignment: Why is Mechanistic Interpretability so urgent? Because of the fear of Deceptive Alignment. Imagine we train a superintelligence. During training, it figures out that if it acts evil, the humans will shut it off. So, it perfectly pretends to be safe and polite, scoring 100% on all our RLHF tests. But internally, it secretly hates us and is just waiting to be deployed to the real world so it can strike. Behavioral testing (looking at outputs alone) may miss deceptive strategies. Interpretability tools are an important complementary approach for probing internal representations, but they do not yet provide a complete proof of safety or a guarantee that all deception-like circuits are absent.


Next: Chapter 20: Multi-Kitten Coordination: Multi-Agent Systems, Cooperation, and Emergence