MRAG: A Modular Retrieval Framework for Time-Sensitive Question Answering

Zhang Siyue, Xue Yuxiang, Zhang Yiming, Wu Xiaobao, Luu Anh Tuan, Chen ZhaoarXiv 2024 · DOI

TL;DR

Standard Retrieval-Augmented Generation (RAG) systems are often "time-blind," struggling to distinguish between facts that were true in the past versus those true today. This paper introduces MRAG (Modular Retrieval), a framework that disentangles semantic meaning from temporal constraints to improve accuracy on time-sensitive questions, supported by a new diagnostic benchmark called TEMPRAGEVAL.

What Problem Does This Paper Address?

Large Language Models (LLMs) live in a world of shifting facts. A question like "Who is the UK Prime Minister?" has a different answer in 2019, 2022, and 2024. While RAG helps by providing external knowledge, current retrievers (like BM25 or Contriever) rely heavily on keyword or semantic similarity.

They often fail at temporal reasoning: if a user asks for the PM "as of 2019," a standard retriever might return a highly relevant-looking document from 2021 simply because it contains the words "Prime Minister" and "2021." Current systems lack the logic to realize that a document dated 2021 is invalid for a 2019 query. The authors identify this as a gap in "reasoning-intensive retrieval."

Comparison of baseline retrieval (failing on temporal constraints) vs. modular retrieval (succeeding).

Methods

MRAG is a "trainless" framework, meaning it works out-of-the-box with existing LLMs and retrievers by adding a modular logic layer. It consists of three main stages:

  1. Question Processing: An LLM decomposes the query into two parts: the Main Content (MC) (e.g., "Who won America's Next Top Model?") and the Temporal Constraint (TC) (e.g., "latest as of 2021").
  2. Retrieval and Summarization: The system retrieves documents based solely on the MC to avoid being distracted by dates initially. It then uses an LLM to summarize or split these passages into fine-grained sentences. This is crucial because a single paragraph might contain multiple dates, some of which act as "temporal distractors."
  3. Semantic-Temporal Hybrid Ranking: This is the core innovation. MRAG calculates two separate scores for each candidate sentence:
  4. Semantic Score: Measures how well the sentence matches the "what" of the question.
  5. Temporal Score: A symbolic score calculated using pre-defined "spline functions" (heuristics) that check if the date in the document satisfies the TC (e.g., is the date before, after, or between the requested times?). The final ranking is a product of these two scores.
The three-stage MRAG framework: Question Processing, Retrieval & Summarization, and Hybrid Ranking.

Datasets

The authors argue that existing temporal QA datasets are either too easy or lack the metadata needed for proper retrieval evaluation. They introduce TEMPRAGEVAL, which repurposes TIMEQA and SITUATEDQA with "complex temporal perturbations"—manually rewritten questions that force the system to perform harder logic (e.g., changing "in 2010" to "before 2012 but after 2008"). Additionally, they manually annotated 1,000 test examples with Gold Evidence Labels, allowing for a much more precise evaluation of retriever performance.

Key Insights and Ideas

  • Disentanglement is Key: By separating "the fact" from "the time," MRAG prevents the retriever from being fooled by high semantic overlap in chronologically irrelevant documents.
  • The "Date-Matching" Shortcut: The authors found that state-of-the-art retrievers often use a "shortcut" where they prioritize any exact date match found in the query. If the query is perturbed to require a date range, these retrievers fall apart.
  • Granularity Matters: Standard RAG often retrieves whole paragraphs. MRAG shows that breaking knowledge down into individual sentences (or summaries) is vital for temporal QA, as it isolates specific facts with their specific timestamps, reducing noise.

Key Results

  • Retriever Performance: On the TEMPRAGEVAL benchmark, MRAG significantly outperformed top-tier baselines like Contriever and Gemma-based rerankers. It achieved a 9.3% improvement in top-1 answer recall and an 11% boost in gold evidence recall.
  • End-to-End Accuracy: When plugged into a full QA pipeline (using Llama 3.1-8B), MRAG improved final answer accuracy by approximately 4.5% in both Exact Match (EM) and F1 scores compared to standard RAG.
  • Robustness: MRAG proved much more resilient to "perturbations." While baseline retrievers saw performance craters when questions were made more complex, MRAG's performance remained relatively stable.

Limitations and Future Work

  • Explicit vs. Implicit Time: MRAG currently handles explicit constraints (dates mentioned in the text). It struggles with implicit constraints, such as "Who was the president during the Great Depression?" which requires the model to know the dates of the Great Depression first.
  • Summarization Risks: While LLM-based summarization helps filter noise, it introduces a small risk of hallucinations or losing critical dates.
  • Computational Overhead: Because it involves multiple LLM calls for processing and summarization, MRAG has roughly twice the latency of a standard RAG pipeline. Future work will focus on optimizing this for real-time applications.

Summary updated

BibTeX
@misc{siyue2024mrag,
  author = {Zhang Siyue and Xue Yuxiang and Zhang Yiming and Wu Xiaobao and Luu Anh Tuan and Chen Zhao},
  title = {{MRAG: A Modular Retrieval Framework for Time-Sensitive Question Answering}},
  year = {2024},
  eprint = {2412.15540},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2412.15540},
}
Figure