Skip to content

SOP-002: Context Rot & Hidden State Drift

Fresh Updated January 2026
Document Control
SOP IDSOP-002
Version1.0
StatusActive
SourceChroma Research (2025), LongReD paper

Overview

Context Rot refers to the systematic degradation of LLM performance as input context length increases. Hidden State Drift describes the underlying mechanism where attention scores and hidden-state similarity degrade across transformer layers.

The Problem Visualized

Key Research Findings

Chroma Study (2025) - 18 Models Tested

Context LengthPerformanceDegradation
Baseline100%-
50k tokens70-85%15-30% drop
100k+ tokens40-60%40-60% drop

Critical Finding

Performance degradation is worst near the middle of context - models preferentially cite early/late tokens.

Hidden State Metrics

MetricMeasurementImpact
KL DivergenceIncreases with contextAttention becomes less focused
Similarity ScoreDrops 10-30%Hidden states drift from baseline
Attention EntropyIncreasesLess decisive attention patterns

Counterintuitive Finding: Shuffled > Coherent

Explanation: Structural coherence appears to interfere with attention mechanisms. Models may process text as "noise" at scale, making shuffled content easier to parse.

Real-World Task Performance

LongMemEval Study (306 prompts, 113k tokens)

ModelFocused PromptFull ContextGap
Claude90-100%40-70%30-50%
GPT85-100%50-75%25-35%

WARNING

This gap persists even with "thinking mode" enabled on reasoning models.

Distractor Sensitivity

  • Low-similarity distractors: 100% → <50% at long lengths
  • High-similarity distractors: <20% drop (less severe)

Mitigation Strategies

1. Keep Contexts Short

  • Stay under 50k tokens when possible
  • Split long documents into focused chunks

2. Front-Load Critical Information

  • Place key points in first 20% of context
  • Repeat critical info at end if necessary

3. Use RAG Instead of Long Context

RAG systems produce 2-3x more diverse citations than parametric models.

4. Minimize Distractors

  • Remove competing content from context
  • Filter irrelevant information before submission

Verification Checklist

  • [ ] Audit context lengths in production systems
  • [ ] Identify content buried in "middle" positions
  • [ ] Test critical content retrieval at various positions
  • [ ] Implement RAG for long-form information needs
  • [ ] Remove unnecessary distractors from prompts

Implications for GEO/AEO

  1. Long-form content is unreliable for LLM citation
  2. Position your key points early in any content
  3. Competitive content hurts you - distractors reduce citation probability
  4. RAG-based systems (Perplexity) outperform parametric (ChatGPT default)
  5. Benchmark results are misleading - NIAH success doesn't mean real-world success

See Also

Citations

"18 models tested; performance degrades 20-60%+ as input length increases; worst near middle of context" — Chroma Context Rot Study (2025)

"Claude: focused ~90-100%, full ~40-70%; gap persists with thinking mode" — Chroma LongMemEval (2025)

Based on research from Thinking Machines Lab, Chroma Research, and ACL 2024-2025