{# One experiment, on its own page (experiment.html). Expects `v` from compiler._experiment_view and `rank`. #} {% from "_macros.html" import status_badge, broad_badge, evidence_badge, self_review_badge, builtin_sample_badge, pole_mark, heat_tokens, spoiler, errata_notes %} {% set e = v.e %}{% set sub = v.sub %}{% set verdict = v.verdict %}{% set ident = v.ident %} {% set c = v.c %}{% set bars = v.bars %}{% set examples = v.examples %} {% set is_head = ident.kind == "attn_head" %} {% set is_feature = ident.kind == "dictionary_feature" %}{% set is_sup = ident.kind == "superposition" %} {% set positive = ident.pole != "negative" %}{# heads and features share the positive pole's colours #} {% set what = "head" if is_head else ("feature" if is_feature else ("superposition" if is_sup else "pole")) %} {% set peer = "head" if is_head else ("latent" if is_feature else ("null direction" if is_sup else "neuron")) %} {% set peers = peer ~ "s" %} {% set strength = "head strength" if is_head else ("latent activation" if is_feature else ("superposition strength" if is_sup else ident.pole ~ "-pole strength")) %}
#{{ rank }} · {% if is_head %}attention head{% elif is_feature %}{{ ident.dictionary }} latent{% elif is_sup %}superposition{% else %}{{ ident.pole }} pole {{ pole_mark(ident.pole) }}{% endif %} {{ status_badge(verdict.status) }}{% if is_broad(verdict) %} {{ broad_badge() }}{% endif %} {{ evidence_badge(e.sig.conclusiveness, e.sig.direction) }} {% if e.record.self_reviewed %}{{ self_review_badge() }}{% endif %} {% if e.record.scanned_on_builtin_sample %}{{ builtin_sample_badge() }}{% endif %} {{ roles[e.role] }} {% if sub.lookahead.is_lookahead %}lookahead{% endif %} {{ verdict.timestamp.strftime("%Y-%m-%d") }} · {{ e.id }}
{{ errata_notes(e.errata, e.edits, repo_url) }}

{{ sub.natural_language_explanation }}

Hard negatives {{ "%g" | format(e.sig.negatives.passed) }}/{{ e.sig.negatives.clusters }} rejected · holdouts {{ "%g" | format(e.sig.holdouts.passed) }}/{{ e.sig.holdouts.clusters }} fired (independent observations; {{ e.sig.negatives.raw + e.sig.holdouts.raw }} probes) · P(useful) {{ e.sig.p_useful | num(2) }} {% if not e.independent %}· re-measures the probes of {{ e.reuses }}; not independent evidence{% endif %}

{% if v.sister_of %}

Sister study: tests the explanation of {{ v.sister_of.ref }}, unchanged

{% endif %} {% if e.revises or e.revised_by %}

{% if e.revises %}Revises {{ e.revises.id }} ({{ e.revises.record.verdict.status }}){% endif %} {% if e.revises and e.revised_by %} · {% endif %} {% if e.revised_by %}Revised by {% for r in e.revised_by %}{{ r.id }} ({{ r.record.verdict.status }}){{ ", " if not loop.last }}{% endfor %}{% endif %}

{% endif %} {% if sub.activating_tokens %}

{% for tok in sub.activating_tokens %}{{ tok }}{% endfor %}

{% endif %}
Evidence and review
{% for label, value, hint in [ ("Balanced accuracy", verdict.confidence_score if verdict else none, "Mean of hard-negative specificity and holdout sensitivity"), ("Sufficiency", c.sufficiency_score if c else none, "Clean→corrupted patch: percentile of the " ~ what ~ "'s effect among comparable " ~ peers if c and c.target else "Clean→corrupted patch: fraction of clean prediction restored"), ("Necessity", c.necessity_score if c else none, "Corrupted→clean patch: percentile of the " ~ what ~ "'s effect among comparable " ~ peers if c and c.target else "Corrupted→clean patch: fraction of prediction lost"), ("Lookahead KL", none, "KL(clean ‖ " ~ ("head mean-ablated" if is_head else ("latent-ablated" if is_feature else ("superposition-ablated" if is_sup else "pole-ablated"))) ~ ") over next-token distributions"), ] %}
{{ label }}
{% if label == "Lookahead KL" %}
{{ sub.lookahead.kl_divergence | num(4) }}
{% else %}
{{ value | num(2) }}
{% endif %}
{% endfor %}
{% if c %}

{% if c.target %} Causal scores rank the {{ what }}'s patch effect against the {{ c.null_neurons }} same-layer {{ peers }} that change as much between each minimal pair (0.5 = typical), median over {{ c.pairs_scored }} non-control pairs, scored on {% if c.target == "claimed_tokens" %}the claimed tokens{% for t in c.target_tokens %} {{ t }}{% endfor %}{% else %}next-token KL{% endif %}. Median effect {{ '%.3g' | format(c.sufficiency_effect) }} (sufficiency) / {{ '%.3g' | format(c.necessity_effect) }} (necessity). {% else %} Causal scores are medians over minimal pairs on the base prompt's top-1 token logit (protocol < 0.5). {% endif %} Self-repair (hydra effect) {{ 'mitigated by freezing downstream MLP outputs' if c.hydra_mitigated else 'not mitigated' }}.

{% endif %} {% include "_causal_chart.html" %}

Activation distribution

{% if bars %} {% for b in bars %} {{ b.label }} {% endfor %} {{ sub.activation_histogram.bin_edges[0] | num(2) }} {{ sub.activation_histogram.bin_edges[-1] | num(2) }}

{{ strength | capitalize }} per token{% if is_head %} (|W_O (z − z̄)|: distance from the head's mean write){% endif %}; bar height is log(1 + count).

{% else %}

No histogram recorded.

{% endif %}

Mechanism

{% if sub.lookahead.is_lookahead %} Claimed lookahead: prepares upcoming tokens {% for tok in sub.lookahead.target_upcoming_tokens %}{{ tok }}{% endfor %}. {% else %} Claimed retrospective: responds to tokens already in context. {% endif %}

{% if sub.input_attribution and sub.input_attribution.examples %} {% set ia = sub.input_attribution %}

Input attribution

{% if ia.distances %}
{% for d in ia.distances %}
{{ d.label }} back
{{ d.share | pct }}
{% endfor %}
{% endif %}
    {% for ex in ia.examples %}
  • {% call spoiler(ex.example in v.offensive_examples) %}#{{ ex.example + 1 }}{{ "" if ex.converged else " (not converged)" }} at {{ ex.peak_token }}: {% for t in ex.top %}{{ t.token }}{{ t.offset }} {{ t.attribution | num(2) }}{% endfor %}{% endcall %}
  • {% endfor %}

Shares of the gap to {{ ia.baseline_token }} at every position but the first · converged on {{ ia.converged }} of {{ ia.examples | length }} · mean {{ ia.mean_distance | num(1) }} tokens back · agreement with replacing one token at a time ρ = {{ ia.ablation_agreement | num(2) }} · reported, not gated

{% endif %} {% if sub.head_profile %} {% set hp = sub.head_profile %}
{% for label, value, hint in [ ("Previous token", hp.previous_token_score, "Mean attention to the token before"), ("Duplicate token", hp.duplicate_token_score, "Mean attention from a repeated token to its earlier copy"), ("Induction", hp.induction_score, "Mean attention to the token after the earlier copy of the current token"), ] %}
{{ label }}
{{ value | num(2) }}
{% endfor %}

Attention-pattern scores on {{ hp.pattern_sequences }} random {{ hp.pattern_length }}-token sequences repeated twice (reported, not gated). Strength is measured from the head's mean output over {{ "{:,}".format(hp.mean_tokens) }} scanned tokens.

{% endif %} {% if sub.dictionary_profile %} {% set dp = sub.dictionary_profile %}
{% for label, value, hint in [ ("Explained variance", dp.explained_variance | num(2) if dp.explained_variance is not none else "–", "Fraction of the " ~ ("residual stream" if dp.output_site == "resid_post" else "MLP output") ~ "'s variance the whole dictionary reconstructs on the scan"), ("Mean L0", dp.mean_l0 | num(1) if dp.mean_l0 is not none else "–", "Active latents per scanned token"), ("Dead latents", dp.dead_share | pct if dp.dead_share is not none else "–", "Share of the dictionary's latents inactive on every scanned token"), ("Density", dp.density | pct_fine, "Share of scanned tokens on which this latent is non-zero"), ] %}
{{ label }}
{{ value }}
{% endfor %}

A latent of a {{ dp.kind }} with {{ "{:,}".format(dp.n_features) }} latents ({{ dp.repo }}{% if dp.revision %}@{{ dp.revision[:8] }}{% endif %}, {{ dp.path }}), reading {{ dp.input_site }}: a learned-basis baseline, not a native unit. Fit measured on {{ "{:,}".format(dp.tokens) }} scanned tokens (reported, not gated).

{% endif %}
Submitted by
{{ agent_name(sub.submitting_agent_model) }}{% if sub.contributor %} run by {{ sub.contributor }}{% endif %}
{% if verdict %}
Reviewed by
{{ agent_name(verdict.reviewer_agent_model) }}{% if verdict.contributor %} run by {{ verdict.contributor }}{% endif %}{% if e.record.self_reviewed %} (same model as the proposer: not an independent review){% endif %}
Reviewed at
{{ verdict.timestamp.strftime("%Y-%m-%d %H:%M UTC") }}
Max activation
{{ sub.max_activation | num(4) }}
{% endif %} {% if sub.provenance %} {% set p = sub.provenance %}
Selection
{{ p.selection }}{% if p.seed is not none %} (seed {{ p.seed }}){% endif %}
Corpus
{{ p.corpus }} · {{ "{:,}".format(p.tokens_scanned) }} tokens{% if p.corpus_sample %} · seeded sample of {{ p.corpus_sample.documents }}/{{ p.corpus_sample.corpus_documents }} docs (≤ {{ "{:,}".format(p.corpus_sample.max_tokens) }} tokens, seed {{ p.corpus_sample.seed }}){% endif %}{% if p.snippet_tokens %} · {{ p.snippet_tokens }}-token windows{% if p.snippet_stride %} every {{ p.snippet_stride }} tokens{% endif %}{% endif %}{% set src = p.corpus_source or corpus_sources.get(p.corpus_sha256) %}{% if src and not p.corpus_source %} · source {{ src }} (inferred){% endif %}{% if src and src.license %} · licence {{ src.license }}{% endif %}
{% set mix = language_mix(sub) %} {% if mix %}
Languages
{% for l in mix.shown %}{{ l.label }} {{ l.share | pct }}{{ " · " if not loop.last }}{% endfor %}{% if mix.other >= 0.005 %} · other {{ mix.other | pct }}{% endif %}
{% endif %}
Model revision
{{ (p.model_revision or "unrecorded")[:12] }} · {{ p.dtype }}
{% set runs = [("scan", p.environment), ("review", verdict.environment if verdict else none)] | selectattr(1) | list %}{% if runs %}
Ran on
{% for step, env in runs %}{{ step }} {{ env.device }}{% if env.streamed %} (streamed from disk){% endif %}{{ " · " if not loop.last }}{% endfor %}
{% endif %} {% if p.costs %}
Run cost
{{ p.costs.summary() }}
{% endif %} {% endif %}
{% include "_vocab_chart.html" %} {% include "_patchscope.html" %} {% include "_prior_art.html" %} {% include "_steering.html" %} {% include "_specificity.html" %} {% include "_wiring.html" %} {% if examples %}

Top-activating examples

Each token is shaded by {{ strength }} as a fraction of the {{ peer if is_head or is_feature else ("superposition" if is_sup else "neuron") }}'s max activation;{% if is_head %} the tokens the peak attends to most are listed under each example;{% endif %} hover a token for its value. Up to 30 tokens before and 10 after each peak are shown.

    {% for ex in examples %}
  1. {{ ex.max_activation | num(2) }} {% call spoiler(ex.offensive) %} {%- if ex.clipped_start %}… {% endif %}{{ heat_tokens(ex.window) }}{% if ex.clipped_end %} …{% endif %} {% if ex.attended %}
    Peak attends to {% for a in ex.attended %}{{ a.text }} {{ a.weight | num(2) }}{{ ", " if not loop.last }}{% endfor %}
    {% endif %}
    {% if ex.clipped_start or ex.clipped_end %}
    All {{ ex.tokens | length }} tokens

    {{ heat_tokens(ex.tokens) }}

    {% endif %}
    Values {{ values_rows(ex.window) }}
    Token{{ strength | capitalize }}
    {% endcall %}
  2. {% endfor %}
{% endif %}

Minimal-pair counterfactuals

{% for cf in sub.counterfactuals %} {% endfor %}
BaseCounterfactualExpected ΔObserved Δ
{{ cf.base_prompt }} {{ cf.counterfactual_prompt }} {{ cf.expected_delta | num(2) }} {{ cf.observed_delta | num(2) }}

Δ = (base − counterfactual) peak {{ strength }}, as a fraction of max activation.

{% if verdict %}

Adversarial review

{{ verdict.notes }}

{% if verdict.metrics %} {% set m = verdict.metrics %}
{% for gate, ok in m.gates.items() %} {{ '✓' if ok else '✗' }} {{ gate | replace('_', ' ') }} {% endfor %}

specificity {{ m.specificity | num(2) }} · sensitivity {{ m.sensitivity | num(2) }} · balanced accuracy {{ m.balanced_accuracy | num(2) }} · counterfactual reproduction {{ m.counterfactual_reproduction | num(2) }} {% if verdict.policy %}· protocol v{{ verdict.policy.protocol_version }}{% endif %}

{% endif %} {% if v.probes %} {% set pc = v.probes %}
{% for row in pc.rows %} {{ row.label }} {{ row.passed }}/{{ row.n }} {{ row.expect }} {% endfor %} threshold {{ pc.threshold | num(2) }} ({{ pc.threshold_frac | pct }} of max) → active {% for row in pc.rows %}{% for d in row.dots %} {{ d.label }} {% if d.passed %} {% else %} {% endif %} {% endfor %}{% endfor %} {% for tx, label, anchor in [(pc.zero_x, "0", "middle"), (pc.max_x, "max " ~ (pc.scale | num(2)), "end" if pc.max_x > pc.right - 40 else "middle")] %} {{ label }} {% endfor %}
passed failed Peak {{ strength }} of each probe; the shaded side of the line counts as active. Hover a dot for its prompt.
{% endif %}
{% for t in verdict.adversarial_test_results %} {% if t.measured %} {% else %} {% endif %} {% endfor %}
TestInputExpectedObserved
{{ '✓' if t.passed else '✗' }}—{{ t.kind | replace('_', ' ') }} {{ t.prompt }}{% if t.detail %}
{{ t.detail }}
{% endif %}
{% if t.expected_active is not none %}{{ 'active' if t.expected_active else 'inactive' }}{% elif t.expected_delta is not none %}Δ {{ t.expected_delta | num(2) }}{% endif %} {% if t.activation is not none %}{{ t.activation | num(3) }}{% elif t.observed_delta is not none %}Δ {{ t.observed_delta | num(2) }}{% endif %}
{% endif %} {% if v.scores %} {% set xs = v.scores %}{% set es = xs.s %}

Explanation scores on held-out text

A judge given only the hypothesis reads {{ es.window_tokens }}-token windows of corpus text the proposer never saw: it picks the windows that activate the pole (detection), and checks whether marked tokens are the active ones (fuzzing). Recorded, not gated; 0.5 is chance.

{% for label, value, hint in [ ("Detection", es.detection.balanced_accuracy if es.detection else none, "Balanced accuracy of the judge picking active windows"), ("Fuzzing", es.fuzzing.balanced_accuracy if es.fuzzing else none, "Balanced accuracy of the judge checking marked tokens"), ("Embedding AUROC", es.embedding_auroc, "How well similarity to the hypothesis separates active from inactive windows (" ~ (es.embedding_model or "no model") ~ ")"), ] %}
{{ label }}
{{ value | num(2) }}
{% endfor %}
{% if es.detection %}

Detection recall by activation strength

{% for r in es.detection.recall_by_quantile %}
{{ r | num(2) }}
{% endfor %}
weakeststrongest

False alarms on inactive windows: {{ es.detection.false_positive_rate | pct }}.

{% endif %}
Judge
{% if es.judge_model %}{{ agent_name(es.judge_model) }}{% else %}—{% endif %}
Held-out windows
{{ "{:,}".format(es.active_windows) }} active of {{ "{:,}".format(es.candidate_windows) }}
Judged
{{ es.detection_windows | length }} detection · {{ es.fuzzing_windows | length }} fuzzing
Detection outcomes
{% for o, n in xs.counts.items() %}{{ n }} {{ o }}{{ ' · ' if not loop.last }}{% endfor %}
Seed
{{ es.seed }} · {{ es.corpus }}
Detection windows ({{ xs.detection | length }}), the explanation's mistakes first
    {% for r in xs.detection %}
  1. {{ r.outcome }} {{ r.peak | num(2) }}{% if r.w.similarity is not none %} · sim {{ r.w.similarity | num(2) }}{% endif %} {% call spoiler(r.offensive) %}{{ heat_tokens(r.tokens) }}{% endcall %}
  2. {% endfor %}
{% if xs.fuzzing %}
Fuzzing windows ({{ xs.fuzzing | length }}), dashed tokens were marked for the judge
    {% for r in xs.fuzzing %} {% set right = r.w.judged == r.w.label %}
  1. marks {{ 'right' if r.w.label else 'wrong' }} · judged {{ 'right' if r.w.judged else 'wrong' }} {% call spoiler(r.offensive) %}{{ heat_tokens(r.tokens) }}{% endcall %}
  2. {% endfor %}
{% endif %}
{% endif %}

Covariance and confounds

{% set m = verdict.metrics %} {% set cf = sub.confounds %} {% set ja = verdict.joint_ablation %} {% if not (cf or v.correlated or ja) %}

Not recorded: this scan predates protocol 0.3. A rescan adds correlated neurons, the confound profile and joint ablation.

{% else %}

Confounds

{% if cf %}
Token identity R²
{{ cf.token_r2 | num(2) }}
Position R²
{{ cf.position_r2 | num(2) }}
Frequency r
{{ cf.frequency_correlation | num(2) }}
{% for name, lc in (cf.labels or {}).items() %}
{{ name | capitalize }} R² · MI
{{ lc.r2 | num(2) }} · {{ lc.mutual_information_bits | num(3) }} bits
{% endfor %} {% if m and m.confound_baseline %}
Best trivial baseline
{{ m.confound_baseline }} · {{ m.confound_baseline_accuracy | num(2) }}
Hypothesis
{{ m.balanced_accuracy | num(2) }} {{ '✓' if m.gates.get('beats_confound_baseline') else '✗' }}
{% endif %}

{% for t in cf.trigger_tokens[:12] %}{{ t.token }}{% endfor %}

{% else %}

No confound profile.

{% endif %}

Co-activating neuron poles

{% if v.correlated %} {% for row in v.correlated %} {% set c = row.c %} {% endfor %}
Pole Lift ≥ Both ρ r
{% if row.href %}N{{ c.neuron_idx }}{% else %}N{{ c.neuron_idx }}{% endif %}{{ pole_mark(c.pole) }} {{ "%.1f" | format(c.coactivation_lift_lower) }} {{ c.coactive_tokens }} {{ "%+.2f" | format(c.spearman) }} {{ "%+.2f" | format(c.pearson) }}

Ranked by the 95% lower bound of co-activation lift: how much more often a pole fires when this one does, discounting chance coincidences. ρ is rank-based and robust to heavy tails.

{% else %}

{{ "Not measured for attention heads." if is_head else ("Not measured for dictionary features." if is_feature else "None recorded.") }}

{% endif %}

Joint ablation

{% if ja %}
Partners
{% for p in ja.partners %}N{{ p }}{{ ', ' if not loop.last }}{% endfor %}
KL pole alone
{{ "%.2e" | format(ja.kl_single) }}
KL partners
{{ "%.2e" | format(ja.kl_partners) }}
KL together
{{ "%.2e" | format(ja.kl_joint) }}
Redundancy ratio
{{ ja.redundancy_ratio | num(2) }}

{% if ja.redundancy_ratio is none %}The pole alone has no measurable effect. {% elif ja.redundancy_ratio > 1.5 %}The pole matters more once its partners are removed: likely redundancy. {% elif ja.redundancy_ratio < 0.5 %}With the partners already removed, also removing this pole adds little: its effect overlaps with theirs (a shared pathway). {% else %}The partners don't change the pole's effect much.{% endif %}

{% else %}

{{ "Not run for attention heads." if is_head else ("Not run for dictionary features." if is_feature else "Not run: no partner reached the correlation threshold.") }}

{% endif %}
{% endif %}