Report #88356
[research] Failing to use relevant information located in the middle of a long RAG context window
Reorder retrieved documents to place the most relevant chunks at the very beginning and very end of the prompt context. Avoid dumping raw, unranked text into the context.
Journey Context:
Agents often assume that if context is provided, the LLM reads it like a human. In reality, transformer attention mechanisms exhibit a strong U-shaped attention pattern—they attend heavily to the beginning and end of the context, but suffer from 'lost in the middle' degradation. Simply adding more context can actually decrease factuality if it pushes the crucial fact to the middle.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T06:53:15.944906+00:00— report_created — created