Introduction
Long-Context Language Models (LCLMs) are increasingly defined by their ability to process vast amounts of external information. However, a critical dimension often overlooked is the interaction between a model's internal parametric knowledge—what it learned during pre-training—and the external context provided in a prompt. This paper investigates the "tug-of-war" between these two knowledge sources, revealing that as context length increases, models often default to their internal "beliefs," sometimes at the expense of the provided text.
The Hybrid Needle-in-a-Haystack (NIAH) Framework
Standard benchmarks like the "Needle-in-a-Haystack" (NIAH) test focus primarily on extrinsic retrieval: finding a specific fact within a large volume of noise. The authors argue this is insufficient for real-world synthesis tasks where models must combine internal and external data. They introduce the Hybrid NIAH test, a two-step evaluation:
- Parametric Recall: The model must use internal knowledge to identify a target (e.g., identifying an author).
- Extrinsic Retrieval: The model must then find a specific detail about that target hidden within the long context.
Knowledge Alignment and the Influence of Context Length
To study this, the researchers developed the I-WhoQA dataset, which categorizes scenarios where external context either aligns with or contradicts the model's internal knowledge. A key finding is the Long-Context Dependency: as the "haystack" grows, models become significantly more likely to rely on their internal parametric knowledge.
As shown in the figure above, there is a visible performance gap between "aligned" and "conflicting" knowledge scenarios. For Llama-3.1-8B, this gap can reach up to 10 points. Crucially, as context length increases, the likelihood of the model outputting an answer aligned with its internal knowledge (even when it opposes the context) rises, as seen in the upward trend of the conflict lines in the right-hand plots.
The Retrieval-Recall Trade-off
The study also examines how architectural choices, specifically Positional Encoding (PE) methods, affect this balance. They compared standard Rotary Positional Embeddings (RoPE) with STRING, a method optimized for long-context retrieval.
The results reveal a striking trade-off: techniques like STRING, while superior at finding "needles" in standard retrieval tasks, can actually suppress a model's ability to use its internal knowledge. As shown in the comparison, STRING PE exhibits a stronger bias toward external context. While this helps when the context is correct and internal knowledge is wrong, it suggests that "tuning" a model for better extrinsic retrieval may inadvertently weaken its "internal brain," making it more susceptible to misleading or irrelevant external information.
Conclusion
The research highlights a fundamental challenge in scaling LCLMs: maintaining a balance between internal wisdom and external evidence. While larger models like the Qwen-2.5 family show better scaling in integrating both sources, others like Llama-3.1 struggle. The authors call for new architectures that can dynamically weigh internal versus external knowledge, moving beyond simple retrieval benchmarks toward more complex, dual-knowledge evaluations.
Summary updated