Profile

Settings

Loading…

← Papers

Help

FAQ

Which features require signing in?

You can read the commentary, paper info, Model Structure and related papers of public papers without signing in. Sign in to manage your account or contact us about your inquiries.

Can I upload a PDF file?

Upload papers with an arXiv or DOI link; the commentary is public to everyone. Papers whose source and terms of use can't be verified, so the commentary can't be made public, can't be uploaded. Uploading PDF files and keeping papers private are for subscribers only, and a paper uploaded as a file is saved as private only. Searching for official info by title runs only when you press the button.

Are the figures and AI commentary accurate?

Figures come only from the original paper, and only those whose terms of use are verified are shown. The commentary is written by AI and may be wrong. Check important claims, numbers and figure context against the evidence in the original paper.

I want to report a copyright issue.

Terms of use and the source of the original paper are on the Paper info tab. If there's a problem, choose "Paper content, figures and copyright" under Contact us and send the paper link, the part in question, and evidence that you hold the rights. Receiving your report doesn't confirm any rights or remove anything right away. You can see the result of the review under My inquiries.

I forgot my password.

If you signed up with email, use Forgot password in the sign-in window to reset it with your verified email. If you signed up with Google, Naver or Kakao, change your password with that service.

What should I include in an inquiry?

Tell us which screen you were on and what you were doing when the problem happened, along with the paper link. Don't include personal information such as passwords, API keys, verification codes or phone numbers. Inquiries and replies are stored in Refivu and you can see them under My inquiries.

How do I delete my account?

In Settings, under My account, press Delete account. Review what will be deleted and complete identity verification to delete your account. For other requests, choose "Account" under Contact us.

Paper commentary

Length Is Cheap, Competition Is Not: Attention Predicts Context Rot in Retrieval

Attention on the evidence, not length, predicts context rot in retrieval

  • Problem Retrieval accuracy falls as inputs grow, and length has been blamed. Earlier masked-filler tests could not separate length from the gaps that masking leaves.
  • Method The authors fill the same positions with neutral or competing text. They then score each trial by the attention the evidence keeps, not by length alone.
  • Results Attention on the evidence explains up to 58% of the variance in loss, while log length explains at most 8%.

Why length gets blamed

Retrieval accuracy falls as inputs grow, and length is the usual suspect. Because the positions stayed fixed, that remaining loss looks like a pure length effect. They reported drops of at least 7.9% at 30K tokens and concluded that length alone hurts. If length is the cause, the fix must sit in the architecture, so each extra token costs something.

Length never grows alone, because every added token also brings content. Softmax attention turns that resemblance into a problem, because the weight on the evidence depends on the scores of all other keys. Hence the authors read context rot as competition, and they expect a∗ to predict the loss better than length does.

Chiang and Cholak, with Veličković et al., proved that spreading attention hampers precise lookup as contexts lengthen. These accounts predict that degradation should follow how much attention stays on the evidence. Nobody had checked that prediction against measured attention, one trial at a time, in pretrained models.

The authors don't claim the phenomenon or the dilution theory, and they close the loop instead. Their key-value task hides one evidence statement about a river's secret code, placed at a uniformly drawn depth. They vary context length from 512 to 32K tokens across five open models from 0.5B to 3B parameters. Du et al. used a visible whitespace baseline, which the authors also find harmful on MMLU.

Attention as the test

The idea is that a context hurts retrieval when its contents draw attention away from the evidence, not when it simply grows longer. To test it, the authors score every trial on two things: the log-probability of the correct value and the attention the model puts on the evidence.

Each trial hides one evidence statement that maps a common-noun key to a four-digit value, and a query at the end asks for that value. The score is the teacher-forced log-probability of the value's tokens, and because tokenizers split values differently, losses are compared only within a model. Each trial is built in four versions: a short context, a neutral one, a competing one and a masked one.

The loss of a condition c is \[ \Delta_c = \log\left(p_{\mathrm{short}}/p_c\right) \] measured in nats, where p_c is the probability of the correct value under condition c.

Keys are drawn uniformly from 51 nouns, so some competing statements share the queried key and give it another value; these same-key conflicts are the strongest rivals. The conflict count grows with length, from a mean of 0.8 at 512 tokens to 50.5 at 32,768. The masked condition uses a 2D attention mask that hides filler from later queries, while the position indices keep counting through it, which keeps the evidence the same distance from the query as before.

In the short context, the authors select the eight layer-head pairs that send the most attention to the evidence tokens. a∗ is then read at the final query token: the weights these heads send to the evidence are summed and averaged across the heads. The softmax form behind it is \[ a^{*} = \frac{e^{s^{*}}}{e^{s^{*}} + \sum_{j \neq *} e^{s_j}} \] where s∗ is the score of the evidence and the s_j are the scores of all other keys.

The sink isn't removed before the measurement, and predictors are compared by the R2 of univariate least-squares fits.

Neutral filler versus competing statements

Visible neutral filler barely moves Qwen2.5-1.5B, which keeps accuracy between 0.96 and 1.00 from 8K to 32K tokens. At 32K tokens, neutral numeric text costs the median trial 0.004 nats. Masking the same filler costs 1.20 nats, and competing statements cost 4.76 nats. The three conditions share total length and evidence position, so only the content separates them.

Masking removes filler from attention while position indices keep counting, so the evidence stays at its original distance. OLMo-2-1B is the exception, losing 0.57 nats with neutral filler at 2,048 tokens and dropping to accuracy 0.91.

Swapping the neutral text for competing statements at the same positions drives the loss up. Figure 1 plots accuracy against context length for Qwen2.5-0.5B and Qwen2.5-1.5B under all three conditions. On Qwen2.5-1.5B, accuracy falls to 0.11 to 0.21 at 8K to 32K tokens. The median loss on the same model reaches 2.82 nats at 8K and 4.76 nats at 32K.

Competing statements cost 56 to 87 points of accuracy at every length.

Figure 1: Retrieval accuracy against context length, with length and evidence position fixed. Neutral
text left visible (green) costs almost nothing; the same…

Figure 1 : Retrieval accuracy against context length, with length and evidence position fixed. Neutral text left visible (green) costs almost nothing; the same text masked at preserved positions (blue) costs up to 47 points on Qwen2.5-1.5B; competing statements (orange) cost 56 to 87 points at every length. Mean over trials, pooled over the three neutral fillers; shaded bands are 95% bootstrap intervals.

Original paper · CC BY 4.0 · Yinuo Liu · Length Is Cheap, Competition Is Not: Attention Predicts Context Rot in Retrieval · Original paper figure · Extracted the figure area from page 5 of the original PDF.

A competing statement becomes a conflict when it shares the queried key and assigns it a different value. Across five models at 2,048 tokens or less, contexts with no conflict lose 0.02 to 0.34 nats. Contexts with at least one conflict lose 1.38 to 3.24 nats. On Qwen2.5-1.5B at 2,048 tokens, the mean loss rises from 0.03 with no conflict to 3.45 nats at six or more.

Explicit distractors that share only the format explain at most 0.3% of the variance in loss. The failure therefore tracks rival values for the queried key, not the amount of filler around the evidence.

Attention predicts the loss better than length

Attention on the evidence, log(1/a∗), tracks the loss far better than log length across the trial pool. On Qwen2.5-1.5B, the fit on log(1/a∗) gives R2 of 0.58 against 0.05 for log L, over 40,632 trials. Over 126,473 trials, log(1/a∗) reaches R2 from 0.35 to 0.58 on each model, while log L stays between 0.02 and 0.08. A bootstrap interval on the difference excludes zero for every model, and the ranking persists inside every length and depth grouping.

Attention on the evidence falls from 0.51 to 0.77 in the short context to 0.17 to 0.31 under competing filler.

Over the same range, log length manages only 0.02 and 0.03 on those two models. On SmolLM2-1.7B, which the authors could only test up to its 8K window, log(1/a∗) gives 0.45 against 0.18 for log L. Figure 2 plots 4,500 Qwen2.5-1.5B trials with competing filler, and the lengths overlap while the loss still follows attention. Mean loss in 15 quantile bins of log(1/a∗) traces the trend, and the fit on that axis reaches R2 of 0.32.

Figure 2: Loss∆(nats) against log(1/a∗)for 4,500 trials of Qwen2.5-1.5B with competing filler at
8K to 32K tokens, colored by length. Black: mean loss in 15 qu…

Figure 2 : Loss∆(nats) against log(1/a∗)for 4,500 trials of Qwen2.5-1.5B with competing filler at 8K to 32K tokens, colored by length. Black: mean loss in 15 quantile bins oflog(1/a∗). Lengths overlap completely, while attention orders the loss.

Original paper · CC BY 4.0

Adding the number of conflicts to log(1/a∗) lifts R2 by at most 0.04, so attention already holds most of the conflict effect. Slopes exceed 1 on every model but differ across them, so the authors don't claim a universal law.

Masking against a visible control

The authors reproduce the masked-filler protocol of Du et al. on 1,000 MMLU questions, using the base Llama-3.2-3B and Qwen2.5-7B-Instruct. They insert 3,750, 7,500, 15,000 or 30,000 masked tokens between each question and its answer options. Masking here means deleting the filler and advancing position indices by the same amount, which they checked against explicit attention masking on Llama.

At 30K masked tokens, accuracy falls by 11 to 18 points on the two models. From 7,500 tokens onward, Qwen2.5-7B loses 11.3 to 17.7 points, while Du et al. report 15.5 to 21.1 points for Llama-3.1-8B. On Llama-3.2-3B, accuracy stops falling beyond 15,000 masked tokens, and every paired McNemar test against the baseline gives p ≤ 0.007.

In retrieval, the same masking on Qwen2.5-1.5B costs 46 accuracy points and 1.20 nats at 32K tokens. The identical filler left visible costs nothing, with accuracy at 0.96 to 0.99 across the three neutral fillers. Masked accuracy at 32K sits at 0.48 to 0.54 for those same three fillers. The authors argue that masking leaves long positional gaps the model never meets in training, so the cost isn't a cost of length.

The effect depends on the model: on Qwen2.5-0.5B, masking costs 0.1 to 0.4 nats.

On MMLU at 4,096 tokens, Qwen2.5-1.5B scores 59.1% without filler and 57.5% with visible neutral filler. Masking the filler lowers the score to 53.9%, the same ordering the retrieval results show. So some forms of length do hurt reasoning, although the MMLU drops can't be pinned on the positional gap alone. The authors recommend a visible neutral-text control at the same positions for any claim about the effect of length.

What curation means in practice

A retrieval pipeline that treats neutral tokens as nearly free can spend its effort on the statements instead. Under that view, the useful size of a context depends on how many rivals the query faces, not on its length. Removing duplicates and settling contradictions upstream could matter more than shortening the context.

Conflicts, length and depth all reach the loss through one measurable quantity, the attention left on the evidence. Once log(1/a∗) is known, adding the number of conflicts raises R2 by at most 0.04. Because a∗ needs only a forward pass, a team can check it on any open model before trusting a context. The authors see a threshold near a∗ of 0.35 on Qwen2.5-1.5B, where the loss rises steeply after staying near zero.

They predict that long-range attention sharpening methods pay off most when a∗ stays above that threshold.

Masking tokens at preserved positions costs 46 accuracy points at 32K tokens in retrieval. The same filler left visible costs none, so the masked loss can't be read as the cost of length. The authors recommend a visible neutral-text control at the same positions for any claim about length.

The authors ran no intervention on a∗, so their evidence is predictive rather than causal. They didn't test format-only competitors above 2K tokens, since every context of 4,096 tokens or more holds a conflict.

What the predictor and intervention results don't establish

The attention measure comes from the same forward pass that produces the loss, and the authors ran no intervention on it. So the link between attention and loss is predictive, not causal. Its predictor work spans 512 to 2,048 tokens across five models, plus 8K to 32K on two.

Format-only competitors above 2K tokens go unmeasured, because the number of conflicts grows with length. The authors didn't preregister the conflict analysis. The scope is narrow: one synthetic retrieval task, with models of at most 3B parameters. The 7B model appears only in the MMLU replication, where it has no visible-filler arm beyond 4K tokens.

The attention sink stays in the measurement, since nothing removes it. The a∗ value reads a single query token, using eight heads. Loss values compare within a model, because value tokenization differs across models. Loss levels therefore don't rank one model against another. The MMLU replication lacks a visible-filler arm beyond 4K tokens, so its drops can't be tied to the positional gap alone.

According to the authors, masked tokens at preserved positions create long positional gaps absent from pretraining. The 46-point drop at 32K tokens comes from masking, while the identical filler left visible costs none. They didn't test whether removing the positional gap would restore accuracy.

Paper info

Authors
Yinuo Liu
Venue
arXiv · Preprint
First published
2026-11-3
Added
2026-11-5
Updated
2026-11-3
Version
v1
arXiv
2611.04169
Category
cs.CL · cs.AI
Original paper terms
CC BY 4.0
What we show
Paper info, commentary and permitted figures from the original paper

AI commentary is a separate explanation from the original paper and may contain errors. The original paper and figures follow each source's terms of use and any rights noted separately.

Abstract

Why do language models fail on long inputs? The common answer is length. We show that, for retrieval, length is cheap and competition is not. On five open models (0.5B to 3B parameters, four families), neutral filler costs nothing: accuracy stays at 0.97 to 1.00, up to 32K tokens on Qwen2.5-1.5B. Statements in the format of the evidence, placed at the same positions, drop it to 0.16 to 0.33. A single statement that gives the queried key a rival value multiplies the loss by 9 to 110, and every additional rival adds to it. Inside the model, one quantity tracks the failure: the attention mass left on the evidence. Across 126,473 trials it explains up to 58% of the variance in loss; log length explains at most 8%. The masked-filler protocol behind the claim that length alone hurts reproduces on MMLU (11 to 18 points lost at 30K tokens), but fails a visible control in retrieval: masking costs 45 accuracy points at 32K tokens, while the same filler left visible costs none. In retrieval, context rot is a competition for attention. We release the probe and all 126K trial-level measurements.

Quote from the paper

Yinuo Liu (2026). Length Is Cheap, Competition Is Not: Attention Predicts Context Rot in Retrieval. arXiv:2611.04169v1. https://arxiv.org/abs/2611.04169v1

BibTeX
@misc{liu2026length,
  title = {{Length Is Cheap, Competition Is Not: Attention Predicts Context Rot in Retrieval}},
  author = {Yinuo Liu},
  year = {2026},
  eprint = {2611.04169},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.04169v1}
}

See related papersBrowse other papers

Paper preview
Account security

Connect Google account

If you connect a Google account, you can sign in with it too.

Refivu

Delete account

Refivu
Refivu

Sign up