Beyond RAG vs. Long-Context: Learning Distraction-Aware Retrieval for Efficient Knowledge Grounding

Seong-Woong Shim, Myunsoo Kim, Jae Hyeon Cho, Byung-Jun Lee

TL;DR

LDAR (Learning Distraction-Aware Retrieval) is a lightweight, adaptive retriever that finds the "sweet spot" between traditional Retrieval-Augmented Generation (RAG) and long-context Large Language Models (LLMs). By learning to select an optimal "band" of passages based only on similarity score distributions, it achieves higher accuracy than providing the full context while using roughly half the tokens.

The Problem: RAG vs. Long-Context

We are currently in a "context window arms race," with models like GPT-4o and Gemini 1.5 Pro supporting 128K tokens or more. This has led to a debate: Should we use Retrieval-Augmented Generation (RAG) to find a few snippets, or just rely on Long-Context (LC) capabilities to feed the model the whole document?

The authors argue that both approaches have flaws. RAG is efficient but often misses the "gold" information. Conversely, feeding an LLM a massive context isn't just expensive—it's actually detrimental. LLMs suffer from the "lost in the middle" phenomenon and can be easily "distracted" by irrelevant or misleading passages, even when the correct answer is present. The challenge is determining exactly how much information a specific LLM can handle before distraction outweighs the benefit of broader coverage.

Methods: Introducing LDAR

The authors introduce LDAR (Learning Distraction-Aware Retrieval). Unlike traditional rerankers that "read" text to determine relevance, LDAR is a "text-free" retriever.

  1. Input: It takes the cosine similarity scores of all candidate passages (from a standard retriever like BGE).
  2. Architecture: These scores are processed through a Periodic Embedding layer and a Transformer Encoder. An attention-pooling layer then summarizes the distribution into a global vector.
  3. The "Banded" Strategy: Instead of picking individual passages, LDAR predicts two parameters for a Beta distribution to sample a "lower quantile" and an "upper quantile." This defines a contiguous "band" of ranked passages to send to the LLM.
  4. Optimization: The system is trained using Reinforcement Learning (REINFORCE). The "reward" is simply whether the LLM correctly answered the query based on the retrieved set. This allows LDAR to learn the specific "distraction threshold" of the LLM it is paired with.

Key Insights and Ideas

  • The Inverted-U Curve: Performance doesn't scale linearly with more context. Most LLMs show an "inverted-U" pattern where accuracy peaks at a certain number of passages and then drops as "distraction" sets in.
  • LLMs have different "Stomachs" for Context: Stronger, closed-source models (like GPT-4o) have a higher tolerance for distraction and benefit from wider retrieval bands. Smaller, open-source models (like Llama-3.1-8B) are more fragile and perform better with tighter, more precise retrieval.
  • Similarity Distributions are Diagnostic: Even without reading the text, the shape of the similarity scores tells a story. If the scores are "flat," LDAR learns to expand the search range to ensure coverage. If there is a sharp peak at the top, it narrows its focus to avoid noise.
  • Bands over Bernoulli: The authors found that retrieving a "band" (a range of ranks) is much more effective than trying to pick passages independently. It simplifies the search space and helps the retriever generalize to new tasks.
Performance and passage usage of Band vs. Bernoulli strategies

Key Results

LDAR was evaluated across six knowledge-intensive benchmarks (including LaRA, HELMET, and Ada-LEval) with context lengths of 32K and 128K.

  • Superior Accuracy: LDAR consistently outperformed both "Top-k" RAG and full Long-Context approaches across almost all tasks.
  • Token Efficiency: LDAR achieved these results using only 25% to 63% of the tokens required by the full-context approach.
LDAR achieves higher performance at a lower token cost compared to standard RAG and Long-Context baselines
  • Speed: Because LDAR doesn't use a heavy cross-encoder to re-read text, it is significantly faster than reranking baselines like RankZephyr or BGM. In open-source settings, it was nearly 4x faster than the full-context approach.
  • Zero-Shot Generalization: A retriever trained on one type of task (e.g., identifying locations) successfully generalized to entirely different datasets (e.g., multi-hop reasoning in HotpotQA) without further tuning.

Limitations and Future Work

  • Passage Ordering: LDAR currently focuses on which passages to select, but it doesn't explicitly optimize the order in which they are presented to the LLM, which is known to affect performance (e.g., putting the most relevant info at the beginning or end).
  • Task Specificity: While it generalizes well, the authors suggest that a "meta-classifier" could eventually be used to detect the task type (e.g., "this is a comparison task") and adapt the retrieval strategy even more precisely.
  • Fixed Retriever/LLM: The current framework assumes the underlying embedding model and LLM are fixed. Future work could explore joint optimization.

Summary updated

BibTeX
@inproceedings{shim2026beyond,
  author = {Seong-Woong Shim and Myunsoo Kim and Jae Hyeon Cho and Byung-Jun Lee},
  title = {{Beyond RAG vs. Long-Context: Learning Distraction-Aware Retrieval for Efficient Knowledge Grounding}},
  booktitle = {International Conference on Learning Representations},
  year = {2026},
  url = {https://openreview.net/forum?id=c8CZWLy4T4},
}
Figure