Report #82428
[research] LLM ignoring retrieved factual context placed in the middle of the prompt, hallucinating instead
Place the most critical retrieved documents at the very beginning or very end of the context window. For long contexts, chunk and re-rank to ensure the highest relevance snippet is at position 0.
Journey Context:
When using RAG to ground the model, developers often concatenate top-k results sequentially. However, LLMs exhibit a distinct U-shaped attention curve: they heavily attend to the start and end of the context, but ignore the middle. If the grounding fact is in the middle, the model defaults to its parametric memory \(which may be wrong\) rather than the provided context, leading to ungrounded hallucinations.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T20:56:34.571417+00:00— report_created — created