✗ Mechanism failed 2026

Sink-content Aitchison distillation

Implementation & benchmark of arXiv:2608.14712 — Which Question Is Your Attention Metric Answering? Attention Rows as Compositional Data

Usefulness7/10
Difficulty3/10
Novelty7/10

Source paper: Which Question Is Your Attention Metric Answering? Attention Rows as Compositional Data arXiv:2608.14712 ⓘ · analyzed Sep 1, 2026

AI-generated research hypothesis, automatically tested. Not peer-reviewed.

Idea description

Distill a teacher's attention into a student by matching sink mass and the normalized content distribution as separate targets rather than applying one KL divergence to the entire attention row. Use the Aitchison distance on the content composition, which compares relative token allocation and prevents a large common sink probability from overwhelming differences between content tokens.

Formulas

$$p=(s,(1-s)c),\qquad s=p_0,\qquad c_j=\frac{p_j}{1-s},\quad j=1,\ldots,m,\quad m=D-1.$$
$$\operatorname{clr}(p)_i=\log\frac{p_i}{g(p)},\qquad g(p)=\left(\prod_{i=0}^{D-1}p_i\right)^{1/D},\qquad d_A^2(p,q)=\frac{1}{2D}\sum_{i,k}\left[\log\frac{p_i}{p_k}-\log\frac{q_i}{q_k}\right]^2.$$
$$d_A^2(p,q)=\frac{m}{D}\left[\frac12\left(\log\frac{s(1-t)}{t(1-s)}\right)^2+d_A^2(c,d)\right].$$
$$H(p)=h(s)+(1-s)H(c),\qquad h(s)=-s\log s-(1-s)\log(1-s).$$

Mathematical statement

For an attention row p over D keys, let s=p_0 be the sink mass and let c_j=p_j/(1-s) for content indices j=1,...,m with m=D-1; thus p=(s,(1-s)c), where c is an m-part composition. For teacher and student rows p and q, with teacher sink mass s and student sink mass t, define the centered log-ratio map clr(p)_i=log(p_i/g(p)), where g(p)=(product_i p_i)^(1/D). The Aitchison distance is d_A^2(p,q)=(1/(2D)) times the sum over i,k of [log(p_i/p_k)-log(q_i/q_k)]^2. If b=log(s(1-t)/(t(1-s))) is the difference of binary log-odds, the paper's decomposition is d_A^2(p,q)=(m/D)[b^2/2+d_A^2(c,d)], where d is the student's normalized content composition. The entropy identity H(p)=h(s)+(1-s)H(c), with h(s)=-s log(s)-(1-s) log(1-s), independently shows that total entropy mixes sink uncertainty with conditional content entropy.

Implementation notes

(1) Integration point: add an auxiliary attention-distillation loss to a student Transformer during supervised training or teacher-student compression. Capture teacher and student attention probabilities after softmax for selected layers and heads, with tensors shaped [batch, heads, query_position, key_position]. Treat key position 0 as the sink; for causal attention, compute the loss only over valid unmasked keys. (2) Pseudocode: for each valid row, set s=clamp(p[...,0],eps,1-eps) and t=clamp(q[...,0],eps,1-eps); set c=p[...,1:]/(1-s) and d=q[...,1:]/(1-t), clamp content probabilities to eps, and renormalize them. Compute z_c=log(c)-mean(log(c),last_dim) and z_d=log(d)-mean(log(d),last_dim). Set L_content=mean(sum((z_c-z_d)^2,last_dim)/m). Set L_sink=mean((logit(s)-logit(t))^2), where logit(x)=log(x/(1-x)). Optimize L=L_task+lambda_content L_content+lambda_sink L_sink. (3) The decomposition and log-ratio coordinates come from the paper; epsilon, layer selection, and loss weights are empirical choices. Masked keys must be excluded before content normalization. (4) First experiment: distill a 6-layer, 256-hidden student from BERT-base or a small decoder teacher on GLUE or WikiText-2. Compare ordinary attention KL, content-only Aitchison loss, and the two-channel loss at equal student FLOPs. Record validation accuracy or perplexity, sink-mass error, content Aitchison distance, and gradient stability. Success is lower validation loss at equal compute, especially for teachers with highly concentrated sink attention.

Verification

Mechanism failed

Stage 1 · Toy mechanism gate: Failed ✗

Stage 2 · Mechanism transferred to benchmark: Not tested

Stage 2 · Practical benchmark result: Not run

Methodology: Toy-system gate first; the benchmark stage runs only after a pass. How verification works

Stage 1 — Mechanism check agent confidence 9/10

Built a reproducible numerical verifier and sink-heavy toy distillation comparison in experiment.py. The exact pairwise Aitchison definition exhibits the predicted quadratic sink and clr-content scaling, and the entropy identity is exact, but the authoritative decomposition is wrong by a factor of 2 for the sink term (observed 0.8 vs claimed 0.4); therefore the required mechanism as stated does not fully validate. In the toy optimization the two-channel loss improved final KL (0.005845 vs 0.014767) and eliminated sink error, but had substantially larger peak gradients (8.37 vs 0.485), so this is only a secondary promising signal, not enough to override the failed claim.

Agent confidence
9/10
Baseline
KL: final KL=0.0147666, sink absolute error=0.0221955, content Aitchison squared=1.00569, max gradient=0.485
Idea
Sink-content Aitchison: final KL=0.0058452, sink absolute error=0.0, content Aitchison squared=0.988942, max gradient=8.369

Limitations: No full Transformer, language-model, GLUE, or equal-FLOP experiment was run. The toy uses a shared low-capacity student and does not test masking, multiple layers/heads, loss-weight tuning, or GPU execution.

How to run: python3 experiment.py

Verdict computed by deterministic test code from paired-seed statistics — not by the language model.

Artifacts

Implementation overview ⬇ Download all as ZIP 3 files · code, reports and structured results