Datasets:
- Presets and hookpoints
- Top-level layout
- File schemas
entropy_comparison_<site>_layer<L>.pt(per-preset Γ per-dataset)entropy_vs_context_len_<site>_layer<L>_<ts>.pt(FineWeb ctx-len sweep)cherry_picked_feature_entropy/<ts>/ctx<N>.csvcherry_picked_feature_entropy/<ts>/influences_ctx<N>.npzfeature_activation_autocorr/<ts>/activation_traces.npzfeature_geometry_vs_entropy/<ts>/manifest.json
- Caveats
- Citation / contact
SAE Locality Data
Raw experimental artefacts and summary figures for sparse-autoencoder (SAE) feature-locality experiments across six base language models.
This README mirrors DATASET.md in the source repository
lccqqqqq/sae-analysis.
See that repository for the analysis pipelines that produce the
artefacts documented below.
This document describes the on-disk layout and per-file schemas for the
HuggingFace dataset lccqqqqq/sae-locality-data,
which mirrors the data/ tree produced by the
sae-analysis pipelines.
It is the single source of truth for the dataset; the HuggingFace dataset README is generated from this file. For how the artefacts are produced, see the main repository README.
Format note.
.ptfiles are PyTorch pickles. Loading them executes arbitrary code viapickle; only load on a trusted machine.torch.load(..., weights_only=True)will not work for these files because they contain Python dicts/lists, not tensors.
Presets and hookpoints
<preset> is one of:
pythia-70m, gpt2-small, qwen2-0.5b, llama-3.2-1b, gemma-2-2b, llama-3-8b.
<site> is the hookpoint name (resid_post, resid, resid_out, β¦)
and varies per preset; the canonical site for each preset is set in
scripts/analysis/presets.py in the source repository.
<dataset> is one of wikitext, gsm8k, code-python β the
corpus the run drew its windows from. Window-acceptance filters are
defined per dataset in scripts/analysis/window_filters.py.
Top-level layout
data/
βββ <preset>/<dataset>/<timestamp>/ # per-preset, per-corpus entropy-vs-depth run
β βββ run_config.json # preset, layers, ctx_len, num_batches, β¦
β βββ bench.json # wallclock + memory bench
β βββ entropy_comparison_<site>_layer<L>.pt
β βββ entropy_plots_<site>_layer<L>/ # per-layer plot dir
β
βββ ctxlen_xmodel_fineweb/<timestamp>/ # FineWeb-Edu cross-model ctx-len sweep
β βββ run_config.json # presets, max_context_len, step, prompt_file
β βββ prompt.txt # the prompt held fixed during the sweep
β βββ prompt.txt.meta.json # FineWeb provenance + trim strategy
β βββ <preset>/
β βββ entropy_vs_context_len_<site>_layer<L>_<ts>{,.pt}
β
βββ cherry_picked_feature_entropy/<timestamp>[_variant]/ # H_pos pipeline (current)
β βββ manifest.json # preset, sae_id, layer, ctx_len, source
β βββ corpus_tokens.pt # tokenised window source (virtual corpus)
β βββ top_contexts_layer<L>.json
β βββ ctx<N>.csv # per-event H_pos rows
β βββ influences_ctx<N>.npz # raw J_a(t') vectors
β βββ adapter_log.json # only on the Neuronpedia path
β βββ figures/
β βββ feature_continuum_ctx<N>.png
β βββ feature_profile_contrast_ctx<N>.png
β βββ h_pos_overview_ctx<N>.png
β βββ h_pos_vs_ctxlen.png
β βββ feature_table_ctx<N>[_variant].html
β
βββ feature_case_studies/<timestamp>_<setname>/
β βββ feature_case_studies.html # per-feature card view, J-tinted contexts
β βββ manifest.json
β
βββ feature_geometry_vs_entropy/<timestamp>/
β βββ manifest.json # decoder-cos vs |ΞH_pos| corr + null
β βββ per_feature.csv
β βββ decoder_vectors.pt
β βββ cosine_matrix.pt
β βββ pairwise.csv
β βββ feature_neighbour_summary.csv
β βββ neuronpedia_xcheck.csv
β βββ figures/
β βββ clusters3d.html
β βββ clusters3d_tsne.html
β
βββ feature_activation_autocorr/<timestamp>/ # FineWeb feature autocorrelation
β βββ run_config.json
β βββ selected_features.csv # feature pool + quality filters used
β βββ top_examples.csv # top activating (doc, position) per feature
β βββ activation_traces.npz # Β±64-token peak-normalised activation strips
β βββ autocorr_curves.csv # per-feature lag autocorrelation
β βββ entropy_targets.csv # 256-tok-lookback H_pos at active positions
β βββ feature_summary.csv
β βββ sanity_contexts.md
β βββ fineweb_corpus_meta.json
β βββ corner_features.html # case-study cards (locally rendered traces)
β βββ corner_features_neuronpedia.html # case-study cards (Neuronpedia activations)
β βββ corner_categories.json
β βββ figures/
β
βββ neuronpedia_cache/<model>/<sae>/<fid>.json # raw Neuronpedia per-feature responses
β
βββ <preset>/{candidate_features_l*.md, pilot_picks_l*.md}
β # human-readable curation lists (Gemma-2-2B at L12, L18, L22)
β
βββ figures/ # cross-model summary plots
β βββ entropy_vs_depth__<preset>__<dataset>.png
β βββ entropy_vs_depth_crossmodel_grid_violin__<dataset>.png
β βββ entropy_vs_depth_crossmodel_grid_boxplot.png (wikitext only)
β
βββ _readme_assets/ # static screenshots of HTML reports
β
βββ legacy/ # superseded artefacts kept for provenance
βββ cherry_picked_feature_entropy/<ts>/ # tier-faceted runs (token/phrase/concept/abstract)
βββ figures/entropy_plots_resid_out_layer<L>_20260414_053350/ # 2026-04-14 pythia-70m batch plots
H_pos here means:
H_pos(a, t) = entropy(J_a(t')/Ξ£_t' J_a(t'), base 2), a per-event
complexity proxy β low H_pos β feature a depends on a narrow
window of preceding tokens (localised); high H_pos β broad
dependence.
File schemas
entropy_comparison_<site>_layer<L>.pt (per-preset Γ per-dataset)
{
"batch_results": [
{
"batch_idx": int,
"start_idx": int, # offset into the loader's text stream
"feature_entropies": {feat_idx: float}, # per-feature entropy in bits
"token_vector_entropy": float,
"num_active_features": int,
"feature_influences": {feat_idx: np.ndarray}, # length-N influence vector per feature
"feature_activations": {feat_idx: np.ndarray},
"token_vector_influence": np.ndarray,
},
... # one entry per batch (50 by default)
],
"summary": {"site": str, "preset": str, "dataset": str, "timestamp": str, "layer": int, ...},
"config": {"preset": str, "threshold": float, "total_features": int, ...},
"plots_dir": str, # absolute path on the originating machine
"batch_start_indices": [int, ...],
}
entropy_vs_context_len_<site>_layer<L>_<ts>.pt (FineWeb ctx-len sweep)
{
"results_by_context_len": {
ctx_len: {
"feature_entropies": {feat_idx: float},
"token_vector_entropy": float,
"num_active_features": int,
...
},
... # one entry per context length (8, 136, 264, β¦)
},
"summary": {"preset": str, "site": str, "layer": int, "timestamp": str,
"max_context_len": int, ...},
"config": {"preset": str, "threshold": float, "total_features": int,
"sae_source": str, ...},
"plots_dir": str,
}
The top-level run_config.json in each
ctxlen_xmodel_fineweb/<ts>/ directory records the global sweep
parameters (presets, per-preset max_context_len/step, prompt
provenance, git commit, host).
cherry_picked_feature_entropy/<ts>/ctx<N>.csv
Single CSV per context length N. One row per (feature, top-activating event) pair, with
columns including feature_id, event_idx, H_pos,
peak_token_idx, peak_value, sum_J, plus auto-interp metadata
when available. Replaces the per-tier files
ctx<N>_{token,phrase,concept,abstract}.csv used by the legacy
runs under legacy/cherry_picked_feature_entropy/.
cherry_picked_feature_entropy/<ts>/influences_ctx<N>.npz
Raw J_a(t') gradient vectors per (feature, event). Loaded with
numpy.load(...); keys match the row index of ctx<N>.csv.
feature_activation_autocorr/<ts>/activation_traces.npz
numpy.savez archive. One array per feature, shape
(n_top_examples, 129) β peak-centred Β±64-token activation
strips, peak-normalised so the activating token has value 1.0.
Companion top_examples.csv lists (feature_id, doc_id, peak_position)
and autocorr_curves.csv gives the per-feature lag autocorrelation.
feature_geometry_vs_entropy/<ts>/manifest.json
Includes correlation_decoder_cos_vs_abs_dH_pos,
null_distribution_quantiles (randomisation check),
n_features, n_pairs, plus preset/layer metadata.
Caveats
plots_dirinside each.ptand thehostfield inrun_config.jsonreflect the originating machine and are not portable.- The
entropy_plots_*/PNG directories are derived artefacts and can be regenerated from the corresponding.pt. - Symlinks named
latestwere used locally to point at the most recent run; they are intentionally not included here. The most recent run is the timestamped subdirectory with the largest<timestamp>value. legacy/contains artefacts kept for provenance. The tier-faceted (token/phrase/concept/abstract) cherry-picked runs there predate the H_pos pivot of 2026-05-06 and use the retired tier axis as a complexity proxy. The 2026-04-14 pythia-70m per-batch plots underlegacy/figures/are superseded bypythia-70m/wikitext/20260427_105943/.
Citation / contact
For questions about specific artefacts or to report issues with the
dataset, open an issue on the
sae-analysis repository.
- Downloads last month
- 5,751