Matteo He commited on
Add model card
Browse files
README.md
ADDED
|
@@ -0,0 +1,88 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: mit
|
| 3 |
+
library_name: sparse-readout-prism
|
| 4 |
+
tags:
|
| 5 |
+
- sparse-autoencoder
|
| 6 |
+
- mechanistic-interpretability
|
| 7 |
+
- interpretability
|
| 8 |
+
- unembedding
|
| 9 |
+
- logit-lens
|
| 10 |
+
base_model:
|
| 11 |
+
- Qwen/Qwen3.5-0.8B
|
| 12 |
+
- Qwen/Qwen3.5-2B
|
| 13 |
+
- Qwen/Qwen3.5-9B
|
| 14 |
+
- deepseek-ai/DeepSeek-R1-Distill-Llama-8B
|
| 15 |
+
- deepseek-ai/DeepSeek-R1-Distill-Qwen-7B
|
| 16 |
+
- google/gemma-4-E2B-it
|
| 17 |
+
- google/gemma-4-E4B-it
|
| 18 |
+
- mistralai/Ministral-3-8B-Base-2512
|
| 19 |
+
---
|
| 20 |
+
|
| 21 |
+
# Sparse Readout Prism — pretrained readout-feature dictionaries
|
| 22 |
+
|
| 23 |
+
Pretrained dictionaries for **Sparse Readout Prism**, which factorizes a language
|
| 24 |
+
model's unembedding rows (`W_U`) into reusable *readout features* and decomposes
|
| 25 |
+
selected logits / logit contrasts into signed feature contributions plus an
|
| 26 |
+
explicit residual, gated by a per-query fidelity test.
|
| 27 |
+
|
| 28 |
+
- **Code:** https://github.com/hematteo/sparse-readout-prism
|
| 29 |
+
- **Paper:** *Sparse Readout Prism: A Sparse Accounting Layer for the Final Readout* (preprint forthcoming)
|
| 30 |
+
|
| 31 |
+
Each dictionary is a TopK factorizer trained on the centered + row-normalized
|
| 32 |
+
`W_U` of its base model, at two operating points: `k128` (strict budget) and
|
| 33 |
+
`k256` (fidelity). See the GitHub registries for the full per-checkpoint manifest
|
| 34 |
+
(`configs/registries/exp2_selected_sae_checkpoints.yaml`,
|
| 35 |
+
`result1_query_fidelity_cluster.yaml`).
|
| 36 |
+
|
| 37 |
+
## Layout
|
| 38 |
+
|
| 39 |
+
```
|
| 40 |
+
<model>/<operating_point>/checkpoint.pt
|
| 41 |
+
```
|
| 42 |
+
|
| 43 |
+
| Path | base model | d_features | k |
|
| 44 |
+
|---|---|---:|---:|
|
| 45 |
+
| `qwen3.5-0.8b/k128_16x/checkpoint.pt` | Qwen/Qwen3.5-0.8B | 16384 | 128 |
|
| 46 |
+
| `qwen3.5-0.8b/k256_32x/checkpoint.pt` | Qwen/Qwen3.5-0.8B | 32768 | 256 |
|
| 47 |
+
| `qwen3.5-2b/k128_16x/checkpoint.pt` | Qwen/Qwen3.5-2B | 32768 | 128 |
|
| 48 |
+
| `qwen3.5-2b/k256_32x/checkpoint.pt` | Qwen/Qwen3.5-2B | 65536 | 256 |
|
| 49 |
+
| `qwen3.5-9b/k128_8x/checkpoint.pt` | Qwen/Qwen3.5-9B | 32768 | 128 |
|
| 50 |
+
| `qwen3.5-9b/k256_16x/checkpoint.pt` | Qwen/Qwen3.5-9B | 65536 | 256 |
|
| 51 |
+
| `qwen3.5-9b/k256_32x/checkpoint.pt` | Qwen/Qwen3.5-9B | 131072 | 256 |
|
| 52 |
+
| `gemma-4-e2b/k128_16x/checkpoint.pt` | google/gemma-4-E2B-it | 24576 | 128 |
|
| 53 |
+
| `gemma-4-e2b/k256_32x/checkpoint.pt` | google/gemma-4-E2B-it | 49152 | 256 |
|
| 54 |
+
| `gemma-4-e4b/k128_16x/checkpoint.pt` | google/gemma-4-E4B-it | 40960 | 128 |
|
| 55 |
+
| `gemma-4-e4b/k256_32x/checkpoint.pt` | google/gemma-4-E4B-it | 81920 | 256 |
|
| 56 |
+
| `ministral-3-8b/k128_16x/checkpoint.pt` | mistralai/Ministral-3-8B-Base-2512 | 65536 | 128 |
|
| 57 |
+
| `ministral-3-8b/k256_32x/checkpoint.pt` | mistralai/Ministral-3-8B-Base-2512 | 131072 | 256 |
|
| 58 |
+
| `r1-distill-qwen-7b/k128_16x/checkpoint.pt` | deepseek-ai/DeepSeek-R1-Distill-Qwen-7B | 57344 | 128 |
|
| 59 |
+
| `r1-distill-qwen-7b/k256_32x/checkpoint.pt` | deepseek-ai/DeepSeek-R1-Distill-Qwen-7B | 114688 | 256 |
|
| 60 |
+
| `r1-distill-llama-8b/k128_16x/checkpoint.pt` | deepseek-ai/DeepSeek-R1-Distill-Llama-8B | 65536 | 128 |
|
| 61 |
+
| `r1-distill-llama-8b/k256_32x/checkpoint.pt` | deepseek-ai/DeepSeek-R1-Distill-Llama-8B | 131072 | 256 |
|
| 62 |
+
|
| 63 |
+
Gemma dictionaries are provisional (pre-softcap fidelity caveat; see the paper).
|
| 64 |
+
|
| 65 |
+
## Usage
|
| 66 |
+
|
| 67 |
+
```python
|
| 68 |
+
from huggingface_hub import hf_hub_download
|
| 69 |
+
from sparse_readout_prism import load_factorizer # pip install -e . from the GitHub repo
|
| 70 |
+
|
| 71 |
+
path = hf_hub_download("matteohe/sparse-readout-prism", "qwen3.5-2b/k256_32x/checkpoint.pt")
|
| 72 |
+
sae = load_factorizer(path, freeze=True) # rebuild + load + eval
|
| 73 |
+
```
|
| 74 |
+
|
| 75 |
+
Decompose a token logit against it as shown in the GitHub README quickstart. The
|
| 76 |
+
checkpoint embeds its factorizer config plus the `row_mean` / `row_norms`
|
| 77 |
+
preprocessing pinned at training time.
|
| 78 |
+
|
| 79 |
+
## Citation
|
| 80 |
+
|
| 81 |
+
```bibtex
|
| 82 |
+
@misc{he2026sparsereadoutprism,
|
| 83 |
+
title = {Sparse Readout Prism: A Sparse Accounting Layer for the Final Readout},
|
| 84 |
+
author = {He, Matteo},
|
| 85 |
+
year = {2026},
|
| 86 |
+
note = {Preprint forthcoming; see the repository for the up-to-date reference},
|
| 87 |
+
}
|
| 88 |
+
```
|