a9lim logitsml claude opus 5.5 commited on
Commit
ec394f5
·
0 Parent(s):

The neuron and head catalog of Qwen3-8B and Gemma 4 12B

Browse files

Co-authored-by: logitsml <logitsml@users.noreply.huggingface.co>
Co-authored-by: claude opus 5.5 <claude opus 5.5@users.noreply.huggingface.co>

This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. .gitattributes +60 -0
  2. README.md +559 -0
  3. figures/01_anatomy.png +3 -0
  4. figures/03_depth_map.png +3 -0
  5. figures/06_activations.png +3 -0
  6. figures/11_drivers.png +3 -0
  7. figures/12_census.png +3 -0
  8. figures/13_rank_depth.png +3 -0
  9. figures/14_lens_blind.png +3 -0
  10. figures/17_head_census.png +3 -0
  11. figures/18_two_models.png +3 -0
  12. figures/20_gemma_census.png +3 -0
  13. figures/22_media_gallery.png +3 -0
  14. figures/23_crossmodal.png +3 -0
  15. figures/24_heads_media.png +3 -0
  16. gemma-4-12b/causal/causal.pt +3 -0
  17. gemma-4-12b/docs.parquet +3 -0
  18. gemma-4-12b/heads/acts.parquet +3 -0
  19. gemma-4-12b/heads/drivers.parquet +3 -0
  20. gemma-4-12b/heads/labels.parquet +3 -0
  21. gemma-4-12b/heads/legible.parquet +3 -0
  22. gemma-4-12b/heads/media.parquet +3 -0
  23. gemma-4-12b/heads/reads.parquet +3 -0
  24. gemma-4-12b/media/audio_docs.parquet +3 -0
  25. gemma-4-12b/media/image_docs.parquet +3 -0
  26. gemma-4-12b/neurons/acts/L00.parquet +3 -0
  27. gemma-4-12b/neurons/acts/L01.parquet +3 -0
  28. gemma-4-12b/neurons/acts/L02.parquet +3 -0
  29. gemma-4-12b/neurons/acts/L03.parquet +3 -0
  30. gemma-4-12b/neurons/acts/L04.parquet +3 -0
  31. gemma-4-12b/neurons/acts/L05.parquet +3 -0
  32. gemma-4-12b/neurons/acts/L06.parquet +3 -0
  33. gemma-4-12b/neurons/acts/L07.parquet +3 -0
  34. gemma-4-12b/neurons/acts/L08.parquet +3 -0
  35. gemma-4-12b/neurons/acts/L09.parquet +3 -0
  36. gemma-4-12b/neurons/acts/L10.parquet +3 -0
  37. gemma-4-12b/neurons/acts/L11.parquet +3 -0
  38. gemma-4-12b/neurons/acts/L12.parquet +3 -0
  39. gemma-4-12b/neurons/acts/L13.parquet +3 -0
  40. gemma-4-12b/neurons/acts/L14.parquet +3 -0
  41. gemma-4-12b/neurons/acts/L15.parquet +3 -0
  42. gemma-4-12b/neurons/acts/L16.parquet +3 -0
  43. gemma-4-12b/neurons/acts/L17.parquet +3 -0
  44. gemma-4-12b/neurons/acts/L18.parquet +3 -0
  45. gemma-4-12b/neurons/acts/L19.parquet +3 -0
  46. gemma-4-12b/neurons/acts/L20.parquet +3 -0
  47. gemma-4-12b/neurons/acts/L21.parquet +3 -0
  48. gemma-4-12b/neurons/acts/L22.parquet +3 -0
  49. gemma-4-12b/neurons/acts/L23.parquet +3 -0
  50. gemma-4-12b/neurons/acts/L24.parquet +3 -0
.gitattributes ADDED
@@ -0,0 +1,60 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ *.7z filter=lfs diff=lfs merge=lfs -text
2
+ *.arrow filter=lfs diff=lfs merge=lfs -text
3
+ *.avro filter=lfs diff=lfs merge=lfs -text
4
+ *.bin filter=lfs diff=lfs merge=lfs -text
5
+ *.bz2 filter=lfs diff=lfs merge=lfs -text
6
+ *.ckpt filter=lfs diff=lfs merge=lfs -text
7
+ *.ftz filter=lfs diff=lfs merge=lfs -text
8
+ *.gz filter=lfs diff=lfs merge=lfs -text
9
+ *.h5 filter=lfs diff=lfs merge=lfs -text
10
+ *.joblib filter=lfs diff=lfs merge=lfs -text
11
+ *.lfs.* filter=lfs diff=lfs merge=lfs -text
12
+ *.lz4 filter=lfs diff=lfs merge=lfs -text
13
+ *.mds filter=lfs diff=lfs merge=lfs -text
14
+ *.mlmodel filter=lfs diff=lfs merge=lfs -text
15
+ *.model filter=lfs diff=lfs merge=lfs -text
16
+ *.msgpack filter=lfs diff=lfs merge=lfs -text
17
+ *.npy filter=lfs diff=lfs merge=lfs -text
18
+ *.npz filter=lfs diff=lfs merge=lfs -text
19
+ *.onnx filter=lfs diff=lfs merge=lfs -text
20
+ *.ot filter=lfs diff=lfs merge=lfs -text
21
+ *.parquet filter=lfs diff=lfs merge=lfs -text
22
+ *.pb filter=lfs diff=lfs merge=lfs -text
23
+ *.pickle filter=lfs diff=lfs merge=lfs -text
24
+ *.pkl filter=lfs diff=lfs merge=lfs -text
25
+ *.pt filter=lfs diff=lfs merge=lfs -text
26
+ *.pth filter=lfs diff=lfs merge=lfs -text
27
+ *.rar filter=lfs diff=lfs merge=lfs -text
28
+ *.safetensors filter=lfs diff=lfs merge=lfs -text
29
+ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
30
+ *.tar.* filter=lfs diff=lfs merge=lfs -text
31
+ *.tar filter=lfs diff=lfs merge=lfs -text
32
+ *.tflite filter=lfs diff=lfs merge=lfs -text
33
+ *.tgz filter=lfs diff=lfs merge=lfs -text
34
+ *.wasm filter=lfs diff=lfs merge=lfs -text
35
+ *.xz filter=lfs diff=lfs merge=lfs -text
36
+ *.zip filter=lfs diff=lfs merge=lfs -text
37
+ *.zst filter=lfs diff=lfs merge=lfs -text
38
+ *tfevents* filter=lfs diff=lfs merge=lfs -text
39
+ # Audio files - uncompressed
40
+ *.pcm filter=lfs diff=lfs merge=lfs -text
41
+ *.sam filter=lfs diff=lfs merge=lfs -text
42
+ *.raw filter=lfs diff=lfs merge=lfs -text
43
+ # Audio files - compressed
44
+ *.aac filter=lfs diff=lfs merge=lfs -text
45
+ *.flac filter=lfs diff=lfs merge=lfs -text
46
+ *.mp3 filter=lfs diff=lfs merge=lfs -text
47
+ *.ogg filter=lfs diff=lfs merge=lfs -text
48
+ *.wav filter=lfs diff=lfs merge=lfs -text
49
+ # Image files - uncompressed
50
+ *.bmp filter=lfs diff=lfs merge=lfs -text
51
+ *.gif filter=lfs diff=lfs merge=lfs -text
52
+ *.png filter=lfs diff=lfs merge=lfs -text
53
+ *.tiff filter=lfs diff=lfs merge=lfs -text
54
+ # Image files - compressed
55
+ *.jpg filter=lfs diff=lfs merge=lfs -text
56
+ *.jpeg filter=lfs diff=lfs merge=lfs -text
57
+ *.webp filter=lfs diff=lfs merge=lfs -text
58
+ # Video files - compressed
59
+ *.mp4 filter=lfs diff=lfs merge=lfs -text
60
+ *.webm filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,559 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: cc-by-4.0
3
+ pretty_name: neuron-lens
4
+ tags:
5
+ - interpretability
6
+ - neurons
7
+ - attention-heads
8
+ - r-lens
9
+ - s-lens
10
+ - multimodal
11
+ configs:
12
+ - config_name: qwen3-8b-neurons-acts
13
+ data_files: "qwen3-8b/neurons/acts/*.parquet"
14
+ default: true
15
+ - config_name: qwen3-8b-neurons-drivers
16
+ data_files: "qwen3-8b/neurons/drivers/*.parquet"
17
+ - config_name: qwen3-8b-neurons-reads
18
+ data_files: "qwen3-8b/neurons/reads/*.parquet"
19
+ - config_name: qwen3-8b-neurons-legible
20
+ data_files: "qwen3-8b/neurons/legible/*.parquet"
21
+ - config_name: qwen3-8b-neurons-labels
22
+ data_files: "qwen3-8b/neurons/labels/*.parquet"
23
+ - config_name: qwen3-8b-heads-acts
24
+ data_files: "qwen3-8b/heads/acts.parquet"
25
+ - config_name: qwen3-8b-heads-drivers
26
+ data_files: "qwen3-8b/heads/drivers.parquet"
27
+ - config_name: qwen3-8b-heads-reads
28
+ data_files: "qwen3-8b/heads/reads.parquet"
29
+ - config_name: qwen3-8b-heads-legible
30
+ data_files: "qwen3-8b/heads/legible.parquet"
31
+ - config_name: qwen3-8b-heads-labels
32
+ data_files: "qwen3-8b/heads/labels.parquet"
33
+ - config_name: gemma-4-12b-neurons-acts
34
+ data_files: "gemma-4-12b/neurons/acts/*.parquet"
35
+ - config_name: gemma-4-12b-neurons-drivers
36
+ data_files: "gemma-4-12b/neurons/drivers/*.parquet"
37
+ - config_name: gemma-4-12b-neurons-reads
38
+ data_files: "gemma-4-12b/neurons/reads/*.parquet"
39
+ - config_name: gemma-4-12b-neurons-legible
40
+ data_files: "gemma-4-12b/neurons/legible/*.parquet"
41
+ - config_name: gemma-4-12b-neurons-labels
42
+ data_files: "gemma-4-12b/neurons/labels/*.parquet"
43
+ - config_name: gemma-4-12b-neurons-image
44
+ data_files: "gemma-4-12b/neurons/image/*.parquet"
45
+ - config_name: gemma-4-12b-neurons-audio
46
+ data_files: "gemma-4-12b/neurons/audio/*.parquet"
47
+ - config_name: gemma-4-12b-neurons-image-optimised
48
+ data_files: "gemma-4-12b/neurons/image_optimised.parquet"
49
+ - config_name: gemma-4-12b-neurons-audio-optimised
50
+ data_files: "gemma-4-12b/neurons/audio_optimised.parquet"
51
+ - config_name: gemma-4-12b-heads-acts
52
+ data_files: "gemma-4-12b/heads/acts.parquet"
53
+ - config_name: gemma-4-12b-heads-drivers
54
+ data_files: "gemma-4-12b/heads/drivers.parquet"
55
+ - config_name: gemma-4-12b-heads-reads
56
+ data_files: "gemma-4-12b/heads/reads.parquet"
57
+ - config_name: gemma-4-12b-heads-legible
58
+ data_files: "gemma-4-12b/heads/legible.parquet"
59
+ - config_name: gemma-4-12b-heads-labels
60
+ data_files: "gemma-4-12b/heads/labels.parquet"
61
+ - config_name: gemma-4-12b-heads-media
62
+ data_files: "gemma-4-12b/heads/media.parquet"
63
+ ---
64
+
65
+ # neuron-lens: every neuron and attention head of Qwen3-8B and Gemma 4 12B
66
+
67
+ A catalog of two models' MLP neurons (two poles each) and attention heads:
68
+ [`Qwen/Qwen3-8B`](https://huggingface.co/Qwen/Qwen3-8B) (36 × 12,288 neurons,
69
+ 36 × 32 heads) and [`google/gemma-4-12B`](https://huggingface.co/google/gemma-4-12B)
70
+ (48 × 15,360 neurons, 48 × 16 heads). Each unit is read from three
71
+ sides:
72
+
73
+ - **from the weights alone,** through two lenses: what a unit writes and what it reads; for a head, what
74
+ it copies and what it attends to, token by token;
75
+ - **from its activations** over about 15.4M positions of web, Chinese, Python and chat text;
76
+ - **from the tokens that drive it** when swept through real contexts.
77
+
78
+ Gemma 4 takes images and sound too, so each of its neurons is also read through lenses fitted on images
79
+ and sounds, and against 49,694 labelled images and 46,932
80
+ labelled sounds.
81
+
82
+ ![What neurons and heads do](figures/01_anatomy.png)
83
+
84
+ Neurons and heads get the same tables, one row per pole or per head:
85
+
86
+ | table | neurons | heads |
87
+ |---|---|---|
88
+ | `reads` | lens reads of the write and the read direction | lens reads of the OV and QK circuits, per token |
89
+ | `acts` | activation statistics and top firings | output-norm statistics, top firings, attention patterns |
90
+ | `drivers` | the tokens that drive each pole hardest | the tokens that drive each head, as query and as key |
91
+ | `legible` | which reads hold at the pole's top firings | which reads hold at the head's top firings |
92
+ | `labels` | Claude Haiku's labels: where it fires, what it writes | where it fires, what it attends to, what it writes |
93
+ | `image`, `audio` (Gemma 4) | the patch or sound it reads, its write in media contexts, the images or sounds that drive it, and whether its media label is its text concept too | |
94
+ | `media` (Gemma 4) | | how each head attends in image and audio contexts, and which carry what an image or sound shows |
95
+
96
+ | config | rows | what |
97
+ |---|---|---|
98
+ | `qwen3-8b-neurons-acts` | 884,736 | every pole's activation statistics and top firings |
99
+ | `qwen3-8b-neurons-drivers` | 884,736 | every pole's 64 token drivers in real contexts |
100
+ | `qwen3-8b-neurons-reads` | 884,736 | every pole's weight-only reads through both lenses |
101
+ | `qwen3-8b-neurons-legible` | 884,736 | which reads hold at every pole's top firings |
102
+ | `qwen3-8b-neurons-labels` | 884,736 | every pole's labels, by Claude Haiku 5.5 |
103
+ | `qwen3-8b-heads-acts` | 1,152 | every head's output statistics, top firings and attention patterns |
104
+ | `qwen3-8b-heads-drivers` | 1,152 | every head's 64 token drivers, as query and as key |
105
+ | `qwen3-8b-heads-reads` | 1,152 | every head's OV and QK circuits read per token |
106
+ | `qwen3-8b-heads-legible` | 1,152 | which reads hold at every head's top firings |
107
+ | `qwen3-8b-heads-labels` | 1,152 | every head's labels, by Claude Haiku 5.5 |
108
+ | `gemma-4-12b-neurons-acts` | 1,474,560 | every pole's activation statistics and top firings |
109
+ | `gemma-4-12b-neurons-drivers` | 1,474,560 | every pole's 64 token drivers in real contexts |
110
+ | `gemma-4-12b-neurons-reads` | 1,474,560 | every pole's weight-only reads through both lenses |
111
+ | `gemma-4-12b-neurons-legible` | 1,474,560 | which reads hold at every pole's top firings |
112
+ | `gemma-4-12b-neurons-labels` | 1,474,560 | every pole's labels, by Claude Haiku 5.5 |
113
+ | `gemma-4-12b-neurons-image` | 1,474,560 | every pole's image read and write, the images that drive it, and its cross-modal ranks |
114
+ | `gemma-4-12b-neurons-audio` | 1,474,560 | every pole's audio read and write, the sounds that drive it, and its cross-modal ranks |
115
+ | `gemma-4-12b-neurons-image-optimised` | 1,728 | the patch that most raises each of the best-labelled poles |
116
+ | `gemma-4-12b-neurons-audio-optimised` | 1,728 | the 40 ms of sound that most raises each of the best-labelled poles |
117
+ | `gemma-4-12b-heads-acts` | 768 | every head's output statistics, top firings and attention patterns |
118
+ | `gemma-4-12b-heads-drivers` | 768 | every head's 64 token drivers, as query and as key |
119
+ | `gemma-4-12b-heads-reads` | 768 | every head's OV and QK circuits read per token |
120
+ | `gemma-4-12b-heads-legible` | 768 | which reads hold at every head's top firings |
121
+ | `gemma-4-12b-heads-labels` | 768 | every head's labels, by Claude Haiku 5.5 |
122
+ | `gemma-4-12b-heads-media` | 768 | every head in image and audio contexts |
123
+
124
+ The lenses are [`stdlogits/rs-lenses`](https://huggingface.co/stdlogits/rs-lenses) at revision `93a9c5ffee`. Code, methods and
125
+ findings (cited here as §N) are on [GitHub](https://github.com/stdlogits/neuron-lens).
126
+
127
+ ## The lenses
128
+
129
+ - The **R-lens** reads what a vector makes the model say: `softmax(W_U · norm(J_L x))`, with `J_L` the
130
+ averaged Jacobian from layer `L` to the last layer (for Gemma 4, after its final softcap,
131
+ `30 · tanh(x / 30)`).
132
+ - The **S-lens** reads which input tokens put a vector there: token `v` scores
133
+ `c · K_L (W_E[v] − mean(W_E))`, with `K_L` the averaged Jacobian from the embeddings to layer `L`.
134
+
135
+ Each is fitted at two points of every layer: `out`, the layer's output, and `mid`, its MLP input (after
136
+ attention). `out` reads MLP outputs and attention inputs; `mid` reads MLP inputs and attention outputs.
137
+ Gemma 4's image and audio lenses are fitted the same way on images and sounds.
138
+
139
+ | what | where it is | R-lens read | S-lens read | Gemma 4: image and audio lenses |
140
+ |---|---|---|---|---|
141
+ | a neuron's write | layer `L`'s output | `write_R` | `write_S` | `image.write_R`, `audio.write_R` |
142
+ | a neuron's read direction `â ± b̂` | layer `L`'s MLP input | `read_R` | `read_S` | `image.read_png`, `audio.read_wave` |
143
+ | what a head reads | layer `L − 1`'s output | | the token's footprint (input of `ov_*`, `qk_*`) | |
144
+ | what a head writes | layer `L`'s MLP input | `ov_R` | `ov_S` | |
145
+
146
+ ## Which reads to trust where
147
+
148
+ No read works at every depth (§7, §11). For Qwen3-8B (these bands are priors; `legible` says which
149
+ reads hold for each unit):
150
+
151
+ | layers | what drives a neuron | what a neuron writes | what a head writes |
152
+ |---|---|---|---|
153
+ | L0-L7 | `read_S` (literal tokens, raw at L0-L4) | `write_S` (early neurons write back what they detect); `write_R` from about L4 | `ov_S` |
154
+ | L8 | both | both | `ov_S`, `ov_R` |
155
+ | L9-L12, L21-L35 | `read_R`, with `read_S_z` as a concept-level view | `write_R` | `ov_R` |
156
+ | L13-L20 | only `drivers` and `acts` | `write_R`, for steering | `ov_R` (weak) |
157
+
158
+ ![Which reads work at which depth](figures/03_depth_map.png)
159
+
160
+ Gemma 4's map has the same shape at its own depths: `read_S` through L13 (falling to under 1% at L9 and rising again at L10-L13),
161
+ `write_R` from about L33 (for steering from L11), and a dark middle (§13).
162
+
163
+ ![Both models by relative depth](figures/18_two_models.png)
164
+
165
+ ## Conventions
166
+
167
+ - **Keys.** Neuron tables: `layer`, `neuron` (coordinate `n` of `down_proj`'s input, 0-indexed), `pole`
168
+ (+1 or −1). Both models' gated activations take both signs, so each neuron has two poles with separate
169
+ meanings, 24,576 (Qwen3-8B) or 30,720 (Gemma 4) rows a layer, the + poles
170
+ first. Head tables: `layer`, `head` (query head) and `kv_head` (the key-value head it reads). `L8 n344 +`
171
+ is `layer` 8, `neuron` 344, `pole` 1; `L20h17` is `layer` 20, `head` 17.
172
+ - **Token lists.** `<read>_ids` are 64 token ids of the model's tokenizer, `<read>_val` their scores,
173
+ `<read>_str` the top 8 decoded and joined by ` | ` (newlines as `⏎`). Signal holds to rank 64 (§7).
174
+ - **Kept tokens.** Reads cover the tokens seen 5 or more times in the activation corpora, without
175
+ byte-fallback pieces (`token_counts.pt`): 103,830 for Qwen3-8B, 123,774 for Gemma 4.
176
+ Undertrained tokens otherwise dominate early reads.
177
+ - **`_z`** reads are layer-contrastive: each token's score z-scored across the layer's poles or heads,
178
+ which removes the hub tokens that top most raw reads. **`_neg`**: a head read's bottom.
179
+ - **Firings.** A unit's firing in a document is its strongest position there; its top firings are the
180
+ 24 documents where that is largest. `contexts` show the first 5, the firing token in `⟦ ⟧` and, for
181
+ heads, the token it attends to most (past position 0) in `⟪ ⟫`.
182
+ - **Tests** (`legible`) score a read on the tokens of the unit's own top firings, as a mean z, against
183
+ mismatched pairs: another unit of the layer scored on the same tokens. `_q` is the Benjamini-Hochberg
184
+ q-value; a test passes at `q ≤ 0.05`. **Dark:** fires, but no test passes and no single token
185
+ dominates its firings.
186
+ - **Scale.** A lens read describes a direction, not an effect size; `act_top × w_norm` is a pole's
187
+ typical write within this corpus. A write read is the pole's average push, which steering shows;
188
+ before about L21 of Qwen3-8B, what one firing does depends on its context (§4).
189
+ - **Gemma 4.** A neuron's write is what reaches the residual, `s · γ_post ⊙ W_down[:, n]` (its MLP output
190
+ passes a post-feedforward RMSNorm, whose scale the lenses hold constant, and the layer's output is
191
+ scaled by `layer_scalar` `s`); `w_norm` is its norm. The read direction is the gate and up rows times
192
+ the pre-feedforward norm's weight. Sliding-window layers have 8 key-value heads of size 256; every sixth
193
+ layer is global, with one of size 512 whose keys are also its values. A head's write is `W_O` times the
194
+ post-attention norm's weight. Every document starts with `<bos>`, the attention sink, so activation
195
+ statistics start at the first real token and `first_*` is at position 1. The base model has no chat
196
+ template: its chat slice is plain `User:` / `Assistant:` turns.
197
+
198
+ ## Neurons
199
+
200
+ ### `<model>-neurons-reads`: weight-only reads
201
+
202
+ | columns | read | of |
203
+ |---|---|---|
204
+ | `write_R`, `write_R_z` | the R-lens, `softmax(W_U · norm(J^out_L w))`; `_val` are probabilities (the logit lens at the last layer) | the write `w` (Qwen3-8B: `±W_down[:, n]`) |
205
+ | `write_S`, `write_S_z` | the S-lens to the layer's output: tokens whose footprint the write imitates | the write |
206
+ | `read_R`, `read_R_z` | the R-lens from the MLP input: what the residual says when it drives the pole | the read direction `â ± b̂` |
207
+ | `read_S`, `read_S_z` | the S-lens to the MLP input: input tokens that drive the pole | the read direction |
208
+
209
+ `â` and `b̂` are the neuron's gate and up rows times the MLP input norm's weight, normalized: `â ± b̂`
210
+ is a heuristic direction for each pole. Also per row: `w_norm`, `cos_ab`, `null_share` (the share of the
211
+ write in the bottom 1% of singular directions of `W_U diag(γ)`, where entropy neurons write; Stolfo et
212
+ al. 2024) and `vocab_skew`, `vocab_kurt` of `W_U · norm(w)` (Gurnee et al. 2024's prediction and
213
+ suppression neurons).
214
+
215
+ ![Read signal by rank](figures/13_rank_depth.png)
216
+
217
+ ### `<model>-neurons-acts`: activation statistics
218
+
219
+ Over every document of four slices, up to 256 tokens each, in bf16: DCLM held out from the lens
220
+ corpus, FineWeb-2 Chinese, codeparrot Python, and UltraChat dialogues (63,990 documents and
221
+ 15,367,795 positions for Qwen3-8B, 63,992 and 15,409,492 for Gemma 4; `docs.parquet`).
222
+
223
+ - `act_top`: the median of the 24 top firings, the pole's typical high activation; `act_max`.
224
+ - `rate`: the share of positions past `act_top / 4`, from exact counts on a quarter-octave grid (linear
225
+ between its points); `rate_<slice>` per slice; `pos_share`: where the pole's sign holds; `q50`-`q999`:
226
+ quantiles of the activation times the pole's sign, from the same counts; `mean`, `std`.
227
+ - `top_doc`, `top_pos`, `top_val`: the 24 top firings; `peak_tokens` and the first 5 `contexts`.
228
+ - `first_max`, `first_tokens`, `first_chat`: the first position (left out above, where the attention
229
+ sink forms), where activations depend on the token alone: the largest over every kept token, the 3
230
+ tokens that reach it, and the value on the chat transcript's opening token. Many of Qwen3-8B's L2-L3
231
+ poles do their work there (§2).
232
+
233
+ ![Activation scale and quiet poles by layer](figures/06_activations.png)
234
+
235
+ ### `<model>-neurons-drivers`: exact token drivers
236
+
237
+ Every kept token at position 24 of 8 real documents (4 web, 2 code, 2 chat), averaged over them, bf16:
238
+ `drivers` are the 64 tokens with the largest activation at the token itself, `drivers_sum` summed over
239
+ it and the 16 positions after. Values are times the pole's sign. For Qwen3-8B, an fp32 check through L9
240
+ shared 98-99% of a pole's top 20 on average (95-99% for `drivers_sum`; §6).
241
+
242
+ ![Which reads name the exact drivers](figures/11_drivers.png)
243
+
244
+ ### `<model>-neurons-legible`: which reads hold
245
+
246
+ `write_R` (the write's read promotes the tokens that follow the top firings), `write_S` (it names the
247
+ peak tokens), `read_R`, `read_S` (the read direction's reads name the peak tokens), each with `_z` and
248
+ `_q`; `silent` (no firing, or `act_top` under 0.05), `cur_mode`, `next_mode` (the share of top firings on
249
+ one token, or followed by one), `dark`. Share of each band's poles, Qwen3-8B:
250
+
251
+ | band | silent | `write_R` | `write_S` | `read_R` | `read_S` | any test | dark |
252
+ |---|---|---|---|---|---|---|---|
253
+ | L0-8 | 19% | 0% | 11% | 2% | 35% | 36% | 29% |
254
+ | L9-12 | 0% | 1% | 1% | 8% | 3% | 11% | 72% |
255
+ | L13-20 | 0% | 0% | 0% | 4% | 1% | 5% | 82% |
256
+ | L21-27 | 0% | 12% | 2% | 6% | 5% | 19% | 59% |
257
+ | L28-35 | 0% | 29% | 0% | 3% | 1% | 31% | 52% |
258
+ | all | 5% | 9% | 3% | 4% | 10% | 22% | 57% |
259
+
260
+ ![Which reads hold for each pole](figures/12_census.png)
261
+
262
+ Gemma 4 12B:
263
+
264
+ | band | silent | `write_R` | `write_S` | `read_R` | `read_S` | any test | dark |
265
+ |---|---|---|---|---|---|---|---|
266
+ | L0-11 | 0% | 0% | 1% | 0% | 35% | 35% | 23% |
267
+ | L12-23 | 0% | 0% | 4% | 0% | 6% | 7% | 61% |
268
+ | L24-35 | 0% | 8% | 0% | 1% | 4% | 11% | 66% |
269
+ | L36-47 | 0% | 20% | 0% | 0% | 3% | 22% | 60% |
270
+ | all | 0% | 7% | 1% | 0% | 12% | 19% | 52% |
271
+
272
+ ![Gemma 4: which reads hold for each pole](figures/20_gemma_census.png)
273
+
274
+ ### `<model>-neurons-labels`: a label for every pole
275
+
276
+ Every pole described by Claude Haiku 5.5 from its reads and top contexts (batch API, effort low, adaptive
277
+ thinking; §8): `fires` (where it fires, 12 words or fewer), `writes` (what its write pushes the model
278
+ toward when amplified), each with a confidence 0-1, and `note`. Each model has its own prompt
279
+ (`scripts/prompts/<model>/neurons.md` on GitHub), which says which reads hold at each depth, and its
280
+ cards show only those. Qwen3-8B's labels were made from an earlier build of its tables, whose reads
281
+ kept byte-fallback pieces; Gemma 4's from this release's, from text alone (its cards show no images or
282
+ sounds).
283
+
284
+ Qwen3-8B, checked blind on 100 poles: firing labels separate held-out top firings from quiet positions at AUROC
285
+ 0.82 [0.78, 0.85] (another pole's label: 0.56); a judge picks a pole's write label out of four from
286
+ steered text 61% of the time [0.52, 0.69] (chance 25%). Firing labels at confidence 0.7 or more score
287
+ 0.94. They hold best early (83% of L0-L8's firing labels reach AUROC 0.8, 31% of L21-L27's), and write
288
+ labels late (80% picked at L28-L35, 41% at L0-L8). Gemma 4's neuron labels are not checked blind yet.
289
+
290
+ ![Random poles read blind](figures/14_lens_blind.png)
291
+
292
+ ### `gemma-4-12b-neurons-image`, `gemma-4-12b-neurons-audio`: images and sound
293
+
294
+ Gemma 4 has no vision or audio encoder network: an image is 64 slots of 48 × 48-pixel patches (384
295
+ pixels a side) and a sound 64 slots of 40 ms at 16 kHz, each entering the residual through a few norms
296
+ and one linear map. One row per pole, beside the text tables:
297
+
298
+ | columns | what |
299
+ |---|---|
300
+ | `read_S_basis` | the read direction through the modality's S-lens to the MLP input, `c · K^mid_L`: coordinates (fp16) on the S-lens basis |
301
+ | `read_png` (image) | the 48 × 48 patch the direction reads: `read_S_basis` through the patch embedder back to pixels, at ±3 standard deviations around grey |
302
+ | `read_wave` (audio) | the 40 ms waveform it reads, 640 samples at 16 kHz (fp16) |
303
+ | `write_R`, `write_R_z` | the write through the modality's R-lens: what it makes the model say in image or audio contexts |
304
+ | `label`, `label_z`, `label_mean`, `labels_str` | its top labels by the z of its mean activation over each label's documents (labels on 8 or more documents: 1,643 for images, 981 for sound) |
305
+ | `sig`, `stable`, `auroc_heldout` | the top label past the shuffled-label null's 99th percentile for its layer; in the top 5 of both halves of the documents; chosen on even documents, its AUROC on odd ones |
306
+ | `top_docs`, `top_vals` | the 16 documents with its largest mean activation (rows of `media/<modality>_docs.parquet`) |
307
+ | `text_fire_rank`, `text_read_rank`, `text_write_rank` | for a reliable label, its rank among the modality's labels on the text side (1 first, 0.5 chance): firing on the label's words, the text S-lens read, the text R-lens write |
308
+
309
+ A media read sums over a document's 64 slots, so it is one pattern wherever it sits, not a map of
310
+ where. Read `read_png` as what the pole's input direction looks like in pixels, a projection: added to
311
+ held-out images it raises the pole only at L0-L5 (§14). The exemplars say what fires a pole, and the
312
+ optimised reads below are patterns that drive it.
313
+
314
+ | modality | band | reliable top label | held-out AUROC (median) | its label holds on all three text tests |
315
+ |---|---|---|---|---|
316
+ | image | L0-L11 | 34% | 0.96 | 0% of 50,561 scored |
317
+ | image | L12-L23 | 26% | 0.97 | 3% of 57,930 scored |
318
+ | image | L24-L35 | 39% | 0.97 | 2% of 62,387 scored |
319
+ | image | L36-L47 | 32% | 0.97 | 1% of 82,871 scored |
320
+ | audio | L0-L11 | 51% | 0.91 | 0% of 44,902 scored |
321
+ | audio | L12-L23 | 19% | 0.86 | 1% of 33,966 scored |
322
+ | audio | L24-L35 | 28% | 0.83 | 0% of 89,105 scored |
323
+ | audio | L36-L47 | 18% | 0.78 | 0% of 64,278 scored |
324
+
325
+ ![The patch each neuron reads, and the patch that drives it](figures/22_media_gallery.png)
326
+
327
+ **One concept in three modalities** (§15). 18 poles pass all three text tests for both their
328
+ image and their audio label, of 45,138 scored in both (independent lists would share
329
+ 1.8): `L14 n8313 +` mosque indoor / Arabic; `L15 n146 +` coral reef / Maori; `L15 n8093 −` mosque indoor / Arabic; `L15 n10091 −` giant panda / Mandarin Chinese; `L18 n645 +` Arabian camel / Arabic; `L20 n13624 +` mosque outdoor / Arabic; `L21 n12154 +` mosque outdoor / Arabic; `L23 n2831 +` Sarees / Gujarati; `L31 n10862 −` tacos / Spanish; `L31 n12007 −` mosque outdoor / Arabic; `L33 n5249 +` tacos / Spanish; `L33 n6099 +` pagoda / Mandarin Chinese; `L36 n585 −` tacos / Spanish; `L36 n14109 +` totem pole / Maori; `L37 n6087 −` Pembroke / Welsh; `L37 n7165 +` giant panda / Mandarin Chinese; `L37 n7926 +` mosque outdoor / Arabic; `L41 n9498 −` mosque indoor / Arabic.
330
+
331
+ ![One concept in text, images and sound](figures/23_crossmodal.png)
332
+
333
+ ### `gemma-4-12b-neurons-image-optimised`, `gemma-4-12b-neurons-audio-optimised`
334
+
335
+ For the 48 poles a layer (L0-L35) with the strongest reliable label: one slot pattern, the same in all
336
+ 64 slots, started from the S-lens read and optimised by gradient ascent through the model (24 Adam steps
337
+ over 128 images or clips; at most 0.08 of the pixel range, or 0.3 of each frame's RMS). `opt_png` or
338
+ `opt_wave` (in units of a frame's RMS), `gain` (the pole's mean activation over the slots of 8 held-out
339
+ documents with the pattern added, minus without), `gain_lens` (the same for its S-lens read),
340
+ `act_base`. Gains are in the pole's activation units:
341
+
342
+ | modality | band | poles | held-out gain, median (its S-lens read) | raises the pole | beats its S-lens read |
343
+ |---|---|---|---|---|---|
344
+ | image | L0-L11 | 576 | 0.195 (-0.0015) | 95% | 96% |
345
+ | image | L12-L23 | 576 | 0.00593 (-0.00066) | 70% | 73% |
346
+ | image | L24-L35 | 576 | 0.00102 (-5.4e-05) | 56% | 56% |
347
+ | audio | L0-L11 | 576 | 0.361 (0.0061) | 99% | 99% |
348
+ | audio | L12-L23 | 576 | 0.017 (0.00017) | 86% | 90% |
349
+ | audio | L24-L35 | 576 | 5.57e-05 (-3.4e-05) | 51% | 52% |
350
+
351
+ The audio test clips are among the audio S-lens's fitting clips (all of ESC-50), though not the
352
+ optimisation's.
353
+
354
+ ## Heads
355
+
356
+ A head reads token `v` as its S-lens footprint at layer `L − 1`'s output (the embedding at L0) and writes
357
+ into layer `L`'s MLP input. Its OV circuit maps what it reads to what it writes, and its QK circuit
358
+ decides where it reads, both over the whole vocabulary (§11).
359
+
360
+ ### `<model>-heads-reads`: weight-only reads, per token
361
+
362
+ | columns | read |
363
+ |---|---|
364
+ | `ov_R`, `ov_R_neg` | each token's z in its own column of the OV map read through the R-lens: where `v` ranks in what the head makes the model say when it reads `v`. The tokens it copies most, and suppresses most |
365
+ | `ov_S`, `ov_S_neg` | the same through the S-lens: whether the write makes the residual look as if `v` were there (the record through L8) |
366
+ | `qk_S`, `qk_S_neg` | each key token's z over the vocabulary under the head's mean query: what it attends to and avoids, whatever the query |
367
+ | `qk_self_S` | each token's z in its own row of the QK map: where its own token ranks among the keys it favours as a query |
368
+ | `ov_R_copy`, `ov_S_copy` | Elhage et al.'s copying score Σλ/Σ\|λ\| of each OV map: +1 copies what it reads, −1 suppresses it |
369
+ | `qk_self` | the median `qk_self_S` z over tokens: duplicate-token heads score high |
370
+ | `qk_ctx_rho` | Spearman over tokens between `qk_S` and the attention each token receives in context |
371
+ | `qk_ov_rho` | Spearman over tokens between `qk_S` and `ov_R`: does the head attend to what it copies? |
372
+
373
+ The QK map is `q̃ᵀ R̄ k̃`, with the q/k norms' true derivative averaged over real positions and RoPE
374
+ averaged over the head's own attention offsets, footprints at unit length: it reads which tokens a head
375
+ favours, not position-only behaviour such as previous-token or induction attention.
376
+
377
+ For Qwen3-8B, `qk_self` finds duplicate-token heads at AUROC 0.96. `qk_S` agrees with the attention tokens receive in context (`qk_ctx_rho` past +0.2) for 36% of L0-L8's heads (another head's read: 14%) and 29% of L28-L35's (4%); 12% of L28-L35's heads attend to what they copy (`qk_ov_rho` past +0.2; another head's OV read: 1%). For Gemma 4, at AUROC 0.95.
378
+
379
+ ### `<model>-heads-acts`: firings and attention patterns
380
+
381
+ Over the same documents, from position 16 (a head with few keys attends sharply):
382
+
383
+ - `out_top`, `out_max`, `rate`, `rate_<slice>`, `q50`-`q999`, `mean`, `std`: as for neurons, of the norm
384
+ of the head's output as it reaches the residual (`‖W_O^h z‖`; for Gemma 4, after its post-attention norm);
385
+ - `top_doc`, `top_pos`, `top_val`, `src_pos` (the position each firing attends to most, past the first),
386
+ `peak_tokens` (query tokens), `src_tokens` (attended tokens), `contexts`;
387
+ - `sink`, `prev`, `self`: the mean attention from queries at 16+ to the first position, to the token
388
+ before and to itself; `induction`, `duplicate`: over 64 sequences of 64 random tokens said twice,
389
+ attention from the second copy to the token after the first occurrence, and to the occurrence;
390
+ - `out_R_z`: the firings' outputs read through the R-lens from the MLP input, each token's logit
391
+ z-scored across the layer's firings, averaged over the head's.
392
+
393
+ ### `<model>-heads-drivers`: exact token drivers
394
+
395
+ In the same pass as the neurons': `drivers`, the 64 tokens with the largest output norm at their own
396
+ position (the token as the query), and `keys`, the 64 that receive the most attention from the 16
397
+ positions after them (the token as the key).
398
+
399
+ ### `<model>-heads-legible`: which reads hold
400
+
401
+ At each top firing, with the attended token: `ov_R` (its OV column promotes the token after the query),
402
+ `ov_copy` (its own `ov_R` z: the head promotes what it reads), `ov_S` (its own `ov_S` z), `qk_S` (its
403
+ `qk_S` z: the QK read predicts what the head attends to), each with `_z` and `_q` (Benjamini-Hochberg over
404
+ all heads); `cur_mode`, `src_mode`; `pattern` (`prev` or `self` past 0.5, `induction` or `duplicate` past
405
+ 0.3); `dark`: no test, no mode past a third, no pattern. Share of each band's heads, Qwen3-8B:
406
+
407
+ | band | `ov_R` | `ov_copy` | `ov_S` | `qk_S` | pattern | any test | dark |
408
+ |---|---|---|---|---|---|---|---|
409
+ | L0-8 | 1% | 1% | 0% | 0% | 10% | 2% | 41% |
410
+ | L9-12 | 0% | 1% | 0% | 0% | 8% | 1% | 78% |
411
+ | L13-20 | 1% | 0% | 0% | 0% | 8% | 2% | 74% |
412
+ | L21-27 | 5% | 1% | 0% | 0% | 6% | 5% | 61% |
413
+ | L28-35 | 27% | 10% | 0% | 0% | 4% | 27% | 38% |
414
+ | all | 7% | 3% | 0% | 0% | 7% | 8% | 56% |
415
+
416
+ The S-side tests pass for almost no head. S→S copying and the mean query's favourite keys are shared by a
417
+ layer's heads, so at a head's own firings they don't tell it from its neighbours; they remain reads of
418
+ what each head does (§12).
419
+
420
+ ![Which reads hold for each head](figures/17_head_census.png)
421
+
422
+ Gemma 4 has 16 heads a layer, so a head's mismatched control has 240 pairs, no p-value falls below
423
+ 1/241, and BH over its 768 heads passes none. Its table adds `<test>_p`, the uncorrected p-value. Share
424
+ of each band's heads at p ≤ 0.05 (5% by chance):
425
+
426
+ | band | `ov_R` | `ov_copy` | `ov_S` | `qk_S` | pattern | dark |
427
+ |---|---|---|---|---|---|---|
428
+ | L0-11 | 4% | 7% | 4% | 9% | 15% | 19% |
429
+ | L12-23 | 4% | 10% | 3% | 6% | 9% | 70% |
430
+ | L24-35 | 8% | 9% | 4% | 6% | 6% | 70% |
431
+ | L36-47 | 21% | 17% | 4% | 14% | 8% | 42% |
432
+ | all | 9% | 11% | 4% | 9% | 10% | 50% |
433
+
434
+ ### `<model>-heads-labels`: a label for every head
435
+
436
+ Qwen3-8B:
437
+
438
+ Every head described by Claude Haiku 5.5 from its card (batch API, effort low, adaptive thinking):
439
+ `fires` (where its output is large), `attends` (what it attends to there) and `writes` (what its
440
+ output promotes), each with a confidence 0-1, and `note`. The cards show the head's pattern scores,
441
+ output scale, OV and QK reads, drivers and first 5 top contexts; nothing about its other top firings.
442
+ The prompt is `scripts/prompts/qwen3-8b/heads.md` on GitHub.
443
+
444
+ **Checked blind** on 100 random heads, 20 a band, by Claude Sonnet 5.5:
445
+
446
+ - **Firing:** given a head's `fires` and `attends` labels and 8 contexts, 4 of its held-out top firings (ranks 6-24) and 4 of another head of its band, the scorer separates them at AUROC 0.71 [0.65, 0.77]; a third head's labels on the same contexts score 0.51.
447
+ - **Writes:** given what the head's firings actually promote in context (`out_R_z`, not on the card), a judge picks its `writes` label out of four from its band 49% of the time [39, 60] (chance 25%).
448
+
449
+ | band | firing AUROC | control | writes picked |
450
+ |---|---|---|---|
451
+ | L0-L8 | 0.74 | 0.50 | 33% |
452
+ | L9-L12 | 0.70 | 0.61 | 56% |
453
+ | L13-L20 | 0.79 | 0.36 | 25% |
454
+ | L21-L27 | 0.60 | 0.56 | 55% |
455
+ | L28-L35 | 0.73 | 0.51 | 79% |
456
+
457
+ Gemma 4 12B: its write labels are at chance, so read them as guesses.
458
+
459
+ Every head described by Claude Haiku 5.5 from its card (batch API, effort low, adaptive thinking):
460
+ `fires` (where its output is large), `attends` (what it attends to there) and `writes` (what its
461
+ output promotes), each with a confidence 0-1, and `note`. The cards show the head's pattern scores,
462
+ output scale, OV and QK reads, drivers and first 5 top contexts; nothing about its other top firings.
463
+ The prompt is `scripts/prompts/gemma-4-12b/heads.md` on GitHub.
464
+
465
+ **Checked blind** on 80 random heads, 20 a band, by Claude Sonnet 5.5:
466
+
467
+ - **Firing:** given a head's `fires` and `attends` labels and 8 contexts, 4 of its held-out top firings (ranks 6-24) and 4 of another head of its band, the scorer separates them at AUROC 0.71 [0.64, 0.79]; a third head's labels on the same contexts score 0.47.
468
+ - **Writes:** given what the head's firings actually promote in context (`out_R_z`, not on the card), a judge picks its `writes` label out of four from its band 22% of the time [13, 30] (chance 25%).
469
+
470
+ | band | firing AUROC | control | writes picked |
471
+ |---|---|---|---|
472
+ | L0-L4 | 0.62 | 0.44 | 25% |
473
+ | L5-L13 | 0.80 | 0.49 | 15% |
474
+ | L14-L32 | 0.75 | 0.52 | 32% |
475
+ | L33-L47 | 0.69 | 0.41 | 15% |
476
+
477
+ ### `gemma-4-12b-heads-media`: heads in image and audio contexts
478
+
479
+ 64 labelled images (mini-ImageNet) and 64 sounds (ESC-50, the classes in turn), each in the media prompt
480
+ and followed by ` a <label>`, its own and another class's (§16). Per head and modality: `read`,
481
+ `read_ratio` (attention from the text after the media to its slots, and that over an even spread),
482
+ `sink`, `self`, `within`, `nbr` (attention from a slot to itself, the other slots, and its grid
483
+ neighbours or the frame before); `abl_right`, `abl_wrong`, `content`, `content_z` (each head zeroed: the
484
+ change in the label's loss, right and wrong, and their difference); `write_mid`, `write_logit` and their
485
+ `_q` (the head's output at the article read through the R-lens and the logit lens: the right class's
486
+ mean percentile among the classes, against 200 label shuffles); `top1_mid`, `top1_logit`.
487
+
488
+ - **image** (64 documents, 64 classes): the right label's loss is below a wrong one's for 97% (3.64 against 10.29 nats). Most read from the text: L24h13, L44h7, L31h3, L23h8; largest extra loss when zeroed (nats): L8h15 (0.75), L7h13 (0.65), L44h7 (0.43), L38h6 (0.42); top label writers: L37h10, L44h7, L40h6, L46h4.
489
+ - **audio** (64 documents, 49 classes): the right label's loss is below a wrong one's for 55% (6.48 against 6.56 nats). Most read from the text: L8h5, L7h9, L3h6, L4h0; largest extra loss when zeroed (nats): L9h4 (0.06), L4h8 (0.06), L11h1 (0.06), L10h15 (0.06); top label writers: L47h4, L45h11, L32h4, L30h13.
490
+
491
+ Share of each band's heads that cost the right label more than a wrong one at z > 3, and that write the right class at q ≤ 0.05, images: L0-11 4%, 4%; L12-23 12%, 43%; L24-35 29%, 41%; L36-47 8%, 36%. For sound, no head passes either.
492
+
493
+ ![Heads in image and audio contexts](figures/24_heads_media.png)
494
+
495
+ ## Plain files
496
+
497
+ Per model folder (`qwen3-8b/`, `gemma-4-12b/`):
498
+
499
+ - `docs.parquet`: each activation document's `slice`, its `line` in the slice's file and its length.
500
+ The slices' sources, revisions and row ids are in `data/corpus/act-<slice>.provenance.json` on GitHub:
501
+ the corpus is not re-hosted here.
502
+ - `token_counts.pt`: `counts[v]`, how often token `v` occurs in the activation corpora (`by_slice` per
503
+ slice).
504
+ - `causal/causal.pt`: the causal sample (§3, §13). `picks`: 1,194 Qwen3-8B neurons
505
+ `(layer, neuron)`, 32 random per layer plus named ones, or 1,152 of Gemma 4's, 24 random
506
+ per layer. Per neuron and pole: `steer` `[neuron, pole, dose, vocab]`, the mean change in log-probs
507
+ over positions 16-63 of 16 64-token DCLM contexts (`contexts`) when the write is added there at 1× and
508
+ 4× `alpha` (the pole's typical high activation); `ablate_pos` and `ablate_win`, clean − ablated
509
+ log-probs with the neuron zeroed at its peak in 8 top documents, at that position and summed over the
510
+ next 8; `dlogp_next`, the next token's change per document; `fired`, the activation there. bf16.
511
+ - `gemma-4-12b/media/{image,audio}_docs.parquet`: each image or sound document's `source`, `labels`,
512
+ `caption`, `ref` (JSON: the dataset, config, split and revision, the row's own identifiers, the media
513
+ file's path and its bytes' SHA-1) and `link`. The images and sounds are not re-hosted;
514
+ `data/corpus/media-<modality>.provenance.json` on GitHub lists every source with its license.
515
+
516
+ ## Loading
517
+
518
+ ```python
519
+ import pandas as pd
520
+
521
+ base = "hf://datasets/stdlogits/neuron-lens/qwen3-8b"
522
+ reads = pd.read_parquet(f"{base}/neurons/reads/L08.parquet")
523
+ reads.query("neuron == 344 and pole == 1")[["write_R_str", "read_R_str", "read_S_str"]]
524
+ heads = pd.read_parquet(f"{base}/heads/reads.parquet").merge(pd.read_parquet(f"{base}/heads/acts.parquet"))
525
+ heads.query("layer == 20 and head == 17")[["ov_R_str", "qk_S_str", "duplicate", "contexts"]]
526
+
527
+ base = "hf://datasets/stdlogits/neuron-lens/gemma-4-12b"
528
+ image = pd.read_parquet(f"{base}/neurons/image/L33.parquet").query("neuron == 6099 and pole == 1").iloc[0]
529
+ docs = pd.read_parquet(f"{base}/media/image_docs.parquet")
530
+ image[["label", "labels_str", "text_fire_rank"]], docs.loc[image["top_docs"][:4], ["labels", "link"]]
531
+ ```
532
+
533
+ ## Limits
534
+
535
+ - Two models; the text lenses are fitted on English-heavy web text, Gemma 4's media lenses on COCO
536
+ photos and ESC-50 sounds.
537
+ - Activation statistics come from bf16 passes over documents of up to 256 tokens; top firings are one
538
+ per document.
539
+ - The tests are token-level, over at most 24 firings per unit. A dark unit may still be describable from
540
+ its contexts (§7).
541
+ - Heads are read through their circuits one token at a time: a head whose role depends on the query's
542
+ context, or on position alone, is read only through `acts`.
543
+ - Media labels name what a whole image or sound is about, not each patch or frame; media reads lose
544
+ fidelity with depth (§14).
545
+
546
+ ## License
547
+
548
+ [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/). The catalog is derived from
549
+ [`Qwen/Qwen3-8B`](https://huggingface.co/Qwen/Qwen3-8B) and
550
+ [`google/gemma-4-12B`](https://huggingface.co/google/gemma-4-12B) (both Apache 2.0). Its `contexts` quote
551
+ short excerpts of the activation corpora, which keep their own terms:
552
+ [DCLM](https://huggingface.co/datasets/HuggingFaceFW/dclm_100BT-shuffled) (CC BY 4.0),
553
+ [FineWeb-2](https://huggingface.co/datasets/HuggingFaceFW/fineweb-2) (ODC-By 1.0),
554
+ [codeparrot-clean](https://huggingface.co/datasets/codeparrot/codeparrot-clean) (code from public GitHub
555
+ repositories, under their licenses) and
556
+ [UltraChat-200k](https://huggingface.co/datasets/HuggingFaceH4/ultrachat_200k) (MIT). The media
557
+ documents' labels and captions come from their source datasets, under those datasets' terms (some
558
+ non-commercial); the images and sounds themselves are only linked. By [@_a9lim](https://x.com/_a9lim)
559
+ and [@treetowntree](https://x.com/treetowntree) with Claude (Anthropic), 2026-10-30.
figures/01_anatomy.png ADDED

Git LFS Details

  • SHA256: 39239cc94b2302f53c4e9f90d24fc97d5ac9776dd428b581b05f1471ee6b8c97
  • Pointer size: 131 Bytes
  • Size of remote file: 267 kB
figures/03_depth_map.png ADDED

Git LFS Details

  • SHA256: b8a7eec05bab37cf39b1f65889605615ee15ddf088bd7841e5b0540514bf3230
  • Pointer size: 131 Bytes
  • Size of remote file: 258 kB
figures/06_activations.png ADDED

Git LFS Details

  • SHA256: 27a56757df556c805ca3191dcf32bd5cfdf5b9b1381e03d6cd1ab42269f51f06
  • Pointer size: 131 Bytes
  • Size of remote file: 132 kB
figures/11_drivers.png ADDED

Git LFS Details

  • SHA256: 4f93a8d373d33e685f6ef6dc1fbbb02c266f3e4233588710c6723864a06f8dad
  • Pointer size: 131 Bytes
  • Size of remote file: 173 kB
figures/12_census.png ADDED

Git LFS Details

  • SHA256: bb51f2d5f89ecc57e475bdef1d424ef75b4a8f23c03ffd42ebb89010e8c0adcc
  • Pointer size: 131 Bytes
  • Size of remote file: 104 kB
figures/13_rank_depth.png ADDED

Git LFS Details

  • SHA256: 36aea44ca0372c0ce018257745bdbe91bd8576144c2c8dfbd86624fd0d31441d
  • Pointer size: 131 Bytes
  • Size of remote file: 126 kB
figures/14_lens_blind.png ADDED

Git LFS Details

  • SHA256: 374e69aaed42de751f45d88519d8ae7915546110198d865f114d95749daa19a3
  • Pointer size: 131 Bytes
  • Size of remote file: 204 kB
figures/17_head_census.png ADDED

Git LFS Details

  • SHA256: 23c9903e74324536a3e7ef90be499d38724212ab7857cd4c14e0d40f4d0e1abc
  • Pointer size: 131 Bytes
  • Size of remote file: 115 kB
figures/18_two_models.png ADDED

Git LFS Details

  • SHA256: 63e842685f0b9a0c8feb3034276e22b62fed6d1bbfd821b22956b6029f54b3a2
  • Pointer size: 131 Bytes
  • Size of remote file: 256 kB
figures/20_gemma_census.png ADDED

Git LFS Details

  • SHA256: b3d5d441dae1bde8869893cfbf965488a5545ae81c91591e2ff68730d5dcb581
  • Pointer size: 131 Bytes
  • Size of remote file: 188 kB
figures/22_media_gallery.png ADDED

Git LFS Details

  • SHA256: 31d65ee57196f64e8ff46f42d1ae01ea82ebdda4047f1f131dea920720d608e5
  • Pointer size: 131 Bytes
  • Size of remote file: 336 kB
figures/23_crossmodal.png ADDED

Git LFS Details

  • SHA256: 3fb584c7dad9ba74393e39cc7a1c2c1d266a527172aba350981d0e7b46f6429d
  • Pointer size: 131 Bytes
  • Size of remote file: 127 kB
figures/24_heads_media.png ADDED

Git LFS Details

  • SHA256: df644b758e01b9f1aca5a5387cb0c7ce57b65244b1331253ee0a0a9e3c11ead7
  • Pointer size: 131 Bytes
  • Size of remote file: 203 kB
gemma-4-12b/causal/causal.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:760b9fdec2f0b810c989a4101abb533ca8b25f7527064a7059c06cad8620aafd
3
+ size 4832018968
gemma-4-12b/docs.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:12930e96e565b1e999a2b8e8d7ad3a40d08fcde99b85c39e8cf7c08bd97b1460
3
+ size 689231
gemma-4-12b/heads/acts.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1ad804a7ae4bfcfab7be082ec52ce1c96d128fdeaf37d81521b939a37e7e3ea3
3
+ size 1175738
gemma-4-12b/heads/drivers.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b300277a0ae42018870bb920da697f6f3119e2b27015a1291d1b050f8c999ae4
3
+ size 1043564
gemma-4-12b/heads/labels.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:f274ad2fe23e067f5c7a90f4046bf95be2e38ab4e71187af1cd952bad0b6b0de
3
+ size 133864
gemma-4-12b/heads/legible.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:8cdabab2e81003f7732c0dc717bc471599b234d7af69da8eaf0339b67dc0ceef
3
+ size 33987
gemma-4-12b/heads/media.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:26fb6c6e9893e742069ae6b971abb1357e751bc44d70e7bc03565d863193f6ca
3
+ size 111207
gemma-4-12b/heads/reads.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:749d738ffade102a20e14f23381753d1c65d7f7162b089638f5c9078a6016940
3
+ size 6305745
gemma-4-12b/media/audio_docs.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3840631d86d91e906012d9a98015f370f5d7137bc73c979d4c9a271a5b57aff4
3
+ size 5115913
gemma-4-12b/media/image_docs.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:943a943039d69777b288590099d6a833368cb5c3673ac57bbd0c2aed985ec750
3
+ size 3487877
gemma-4-12b/neurons/acts/L00.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:2761355d88e900fa916796e67bc5030d33da5d05f6b7fccf7800d0d43191783d
3
+ size 14235228
gemma-4-12b/neurons/acts/L01.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:99032d2820d4676418dc4e092082532a89f372947e5e0e48ed7815859bc9134f
3
+ size 15915642
gemma-4-12b/neurons/acts/L02.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3eda502392dbac745b1f8ed6f9009782dc38090dc2f4ec8764f5ec4bfc3a8acb
3
+ size 15383252
gemma-4-12b/neurons/acts/L03.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:243bf68be6312d6a04a6c13201533fb0424d4230ca68acfdcd43ada25be4e4bf
3
+ size 15587419
gemma-4-12b/neurons/acts/L04.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b7df9b0d14b3b0a177977954ca3d9012e37cb1c0e3196827d526785416e23358
3
+ size 15983057
gemma-4-12b/neurons/acts/L05.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0fdc8ab8ff703785328fac7494952fcd59b82a136e4d6696cabcac0caceae009
3
+ size 16019513
gemma-4-12b/neurons/acts/L06.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:de0bed8ad68a306c14a1e30e310cbe613f7726bea91e1d6ca48151d864fd4a37
3
+ size 16157081
gemma-4-12b/neurons/acts/L07.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:11409d6f9509baa702d481d777fe2dcfc4be051f2a2298970a60994798120b09
3
+ size 15880085
gemma-4-12b/neurons/acts/L08.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1c9e5b74ddcc94af63ba6e8a9056b806603808559b85d99559cee68b36034d9d
3
+ size 15982853
gemma-4-12b/neurons/acts/L09.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:22b3b95fd9093e153677a4ff0820a53808cc96f3bbc0602e9fea32395df2a8ac
3
+ size 15609115
gemma-4-12b/neurons/acts/L10.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:277b70c1220e696f3c88a3c51d6d2643b941b928cfaf130104fc989090c39549
3
+ size 16235342
gemma-4-12b/neurons/acts/L11.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b6637f5ec18da1a7f7e4726eac1f4fe1d1b98289f1304ca0dcc009563c0e036d
3
+ size 16045696
gemma-4-12b/neurons/acts/L12.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c9401b76f01f5cd398ab485d49d6b882ea61639747648ff1ce89a56f3f94e782
3
+ size 16150864
gemma-4-12b/neurons/acts/L13.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1817f6f682f8bed1ab7be3d06afbea334b22484587566e311c4820602fd2420f
3
+ size 16138529
gemma-4-12b/neurons/acts/L14.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:45ab6d3303a261be8a50877bd276da17c09026b8e07d91219e3f22c09bff3e02
3
+ size 16386958
gemma-4-12b/neurons/acts/L15.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:93665ac7df18a5c0c2e8db36e7978dd1a77fc76de8c6cff01d6b37953a567524
3
+ size 16440472
gemma-4-12b/neurons/acts/L16.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:8615e0b514cf46d56a207d6ffc47335efde90f88f87336660662c533d151ca43
3
+ size 16634539
gemma-4-12b/neurons/acts/L17.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:85860db14172a248a7f904382c606952009dffc56f8418c9c7e8f4780e8143e0
3
+ size 16515647
gemma-4-12b/neurons/acts/L18.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:09377e2163d7623f7c189cfd6611814a1e982d14e20d5f7d5e782c1c2dea9008
3
+ size 16388289
gemma-4-12b/neurons/acts/L19.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:bf39a3b214d22ef53809b6fd62397b8bb738eccb7e417e89742a0c86d5bfb6bd
3
+ size 16370037
gemma-4-12b/neurons/acts/L20.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ac00b47540e616da3e350daacac1a51477a036e5ad4dd300584dcb3560e1b9b9
3
+ size 16203248
gemma-4-12b/neurons/acts/L21.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:979778e991e884b896899d7bfaa3132440ed9270f746510b07f4cd8d3a53457f
3
+ size 16105269
gemma-4-12b/neurons/acts/L22.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0c2b78c5e42c2139ef571457e5f8f4b168d46f2d104e6cb393e163c48fb3080c
3
+ size 15953481
gemma-4-12b/neurons/acts/L23.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b9b0b41dca9b34c14d789cd5580f7f43cfe2081368297f8a17808d3d7a5baad6
3
+ size 15918484
gemma-4-12b/neurons/acts/L24.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c02e1fbb576491966a96c511172a7017b262022449fa147a7a97f30b5b3401cf
3
+ size 15986098