Datasets:
image imagewidth (px) 3.25k 3.87k |
|---|
Causal Dimensionality of Transformer Layers — Research Artifacts
Large-file artifact store for two companion papers on the causal dimensionality of transformer layers:
- ICML 2026 Mechanistic Interpretability Workshop — Causal Dimensionality of Transformer Layers: SAE Encoder Filtering and AtP Recall Collapse
- NeurIPS 2026 (under review) — Causal Dimensionality of Transformer Representations: Measurement, Scaling, and Layer Structure
This HuggingFace dataset repo holds the large files that do not fit in the GitHub repo (GitHub rejects files over 100 MB and the project does not use Git LFS). The code, paper sources, all result JSONs, all figures, and run logs live on GitHub; this repo holds only the heavy binary artifacts.
GitHub (code + results + papers):
https://github.com/nileshsarkar-ai/NeurIPS-Causal-Capacity-in-SAEsAnonymous mirror (for double-blind review):
https://anonymous.4open.science/r/NeurIPS-Causal-Capacity-in-SAEs-7D20/
What the papers are about
Sparse autoencoders (SAEs) decompose transformer residual streams into a sparse feature dictionary, on the implicit assumption that each feature is a unit of computation. We show this fails for the vast majority of features: on Gemma-2-2B layer 12, 97.9% of firing SAE features have no measurable causal effect on model output.
We define causal dimensionality κ — the effective rank of the expected Jacobian outer product at a layer (Roy & Vetterli 2007) — as the layer's causal budget, measure it via an SAE width sweep paired with attribution patching, and find:
- The representational–causal wedge: across 64× SAE width growth, representational capacity grows 15.6× but causal capacity grows only 4.35×, saturating at κ̂ ≈ 1,990 (bootstrap 95% CI [545, 5130]).
- The encoder is a sparsity filter: a four-cell encoder/decoder ablation shows replacing the trained encoder with a random orthonormal matrix inflates the causally active feature count 9.27×.
- AtP measures activation patterns, not directions: on a synthetic ground-truth model, AtP recovers zero of the planted causal directions by cosine similarity.
- κ is model-intrinsic: invariant under 3.46× Gemma scaling and within ±0.1pp across Gemma and LLaMA at matched hook.
Repository contents
pythia-70m-deduped/ Marks et al. pretrained Pythia-70m SAEs
├── embed/10_32768/ae.pt (used by the SVA-circuit
├── attn_out_layer{0..5}/10_32768/ae.pt validation experiment, Exp 9)
├── mlp_out_layer{0..5}/10_32768/ae.pt
└── resid_out_layer{0..5}/10_32768/ae.pt
(19 files, ~134 MB each, 2.4 GB total)
results/ mirror of every experiment's JSON ground truth + figures
logs/ mirror of per-experiment run logs
paper_draft/ NeurIPS + ICML LaTeX sources, figures, compiled ICML PDF
pythia-70m-deduped/ — Marks SAE weights
These are the pretrained Pythia-70m sparse autoencoders from
Marks et al. "Sparse Feature Circuits"
(ICLR 2025). They are required to re-run the SVA-circuit recall
experiment (experiments/exp9_rctrain.py in the GitHub repo).
They are mirrored here for convenience and archival; the canonical
source is the Marks et al. repository. Each ae.pt is a
JumpReLU-style SAE checkpoint with d_sae = 32768.
How to use
Download the SAE dictionaries
pip install huggingface_hub
huggingface-cli download nileshsarkar-ai/causal-dimensionality-sae \
--repo-type dataset --local-dir ./hf_artifacts
# place them where the experiment expects:
cp -r ./hf_artifacts/pythia-70m-deduped /path/to/repo/feature-circuits/dictionaries/
Or in Python:
from huggingface_hub import snapshot_download
snapshot_download(
repo_id="nileshsarkar-ai/causal-dimensionality-sae",
repo_type="dataset",
local_dir="./hf_artifacts",
)
Reproduce the papers
The full reproduction recipe is in the GitHub repo's
RECREATING_FROM_SCRATCH.md. In short:
- Clone the GitHub repo (code + result JSONs + figures + papers)
- Download this HF repo for the SAE dictionaries
- Create the Python env from
requirements.txt - Run
experiments/exp*.py
Every numerical claim in both papers is verifiable from the result
JSONs on GitHub (results/<exp>/*.json) — see INTEGRITY_ALL_EXPS.md
in the GitHub repo for the verification script.
Headline numbers
| Quantity | Value | Source |
|---|---|---|
| Inert fraction (Gemma-2-2B layer 12, 16k SAE) | 97.95% | exp1 |
| Wedge ratio (causal / representational growth) | 4.35× / 15.6× | exp1 |
| Curve-fit κ̂ | 1,990 (bootstrap median 1,705, CI [545, 5130]) | exp B |
| κ̂ / d_model | 0.86 | exp B |
| Random-encoder inflation | 9.27× | exp 5b |
| AtP vs exact-ablation ρ | 0.838 | exp 0 |
| SVA recall (p99 / p98 / p95) | 42.9% / 76.8% / 98.2% | exp 9 |
| Cross-family inert (LLaMA / Pythia) | 97.86% / 95.23% | LLaMA / Pythia |
Models and data used
- Gemma-2-2B, Gemma-2-9B (Google) — primary measurements
- LLaMA-3.1-8B (Meta) — cross-family validation
- Pythia-70m-deduped, Pythia-410m (EleutherAI) — SVA validation, cross-family
- GemmaScope SAEs (
gemma-scope-2b-pt-res,gemma-scope-9b-pt-res) - Llama Scope, EleutherAI Pythia SAEs
- Marks et al. Pythia-70m SAEs (this repo,
pythia-70m-deduped/)
All base models and SAEs except pythia-70m-deduped/ are public on
HuggingFace and auto-download via from_pretrained().
License
MIT. The pythia-70m-deduped/ weights are redistributed from Marks et al.
under their original license; see
https://github.com/saprmarks/feature-circuits.
Citation
@misc{causaldim2026,
title = {Causal Dimensionality of Transformer Layers:
SAE Encoder Filtering and AtP Recall Collapse},
author = {Sarkar, Nilesh and Deka, Dawar Jyoti},
year = {2026},
note = {ICML 2026 Mechanistic Interpretability Workshop;
companion NeurIPS 2026 submission under review}
}
- Downloads last month
- 13