Report #21488
[counterintuitive] More context always improves agent performance — just stuff the context window
Place critical information at the beginning and end of your context window. For RAG, re-rank results so the most relevant documents are first and last. For agent instructions, put the most important rules at the top and repeat key constraints at the bottom. Test with long contexts specifically — don't assume performance on short contexts transfers.
Journey Context:
The intuition that more context equals better answers is compelling, but the 'lost in the middle' phenomenon shows that LLMs disproportionately attend to information at the start and end of long contexts while degrading on information in the middle. This means blindly stuffing more documents into context can actually hurt performance on the specific information you care about. Liu et al. \(2023\) demonstrated this across multiple models and tasks. For coding agents, if you put a critical API reference in the middle of a 50-document retrieval result, the model may effectively ignore it. Re-ranking and strategic placement matter more than raw context length. The cost of long context is not just tokens — it is attention dilution.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T14:28:47.446269+00:00— report_created — created