RAG Motivation: Solving Hallucinations & Knowledge Gaps › A Worked Example: Knowledge Cutoff in Action

Michael BrenndoerferJanuary 20, 20263 min read
Language AI HandbookAll chapters
Part 44 of 67Retrieval-Augmented Generation
Chapter 332RAG Motivation: Solving Hallucinations & Knowledge Gaps › A Worked Example: Knowledge Cutoff in Action
Reading section 4 of 9 · A Worked Example: Knowledge Cutoff in Action · 3 minSection 4 of 9 · 3 min

Book contents

Section 4 of 9 · 3 min read

RAG Motivation: Solving Hallucinations & Knowledge Gaps › A Worked Example: Knowledge Cutoff in ActionOne section · Sections in this chapter4 / 9 ↓
Reading tools Definitions & inline links

Choose your expertise level to adjust how many terms are explained. Beginners see more tooltips, experts see fewer to maintain reading flow. Hover over underlined terms for instant definitions.

Article links

Make inline references clickable

To make the knowledge problems concrete, let's trace through a specific scenario step by step. Imagine we're building a question-answering system for a financial services firm, and a user asks: "What was the federal funds rate as of January 2025?"

Step 1: The baseline parametric model responds. A model with a training cutoff of December 2022 has no information about 2025 interest rates. When asked this question, the model faces a choice: it can correctly say "I don't have information about 2025," or it can generate a plausible-sounding number based on patterns from its training data. In practice, models often do the latter, especially when the question is framed as a factual inquiry. The model might respond with a rate from 2022 or an extrapolation based on patterns in historical data. Both would be wrong for January 2025, which saw rates that reflected two years of monetary policy decisions the model never observed.

Step 2: We quantify the error. The federal funds rate fluctuated significantly between 2022 and 2025. A model trained on data through December 2022 would have seen rates in the 4-4.5% range. By January 2025, the rate had changed substantially. Any parametric answer would be either a lucky guess or simply wrong. For a financial application, being off by even 50 basis points on an interest rate question could lead to materially incorrect calculations.

Step 3: We add a RAG component. We index a corpus of Federal Reserve press releases and FRED economic data into a retrieval system. The retrieval system is updated daily with new documents. When the user asks about the January 2025 rate, the system:

  1. Embeds the query: "federal funds rate January 2025" becomes a dense vector
  2. Searches the index for semantically similar documents
  3. Retrieves the relevant FRED data entry or Fed statement from January 2025
  4. Provides this document as context to the language model
  5. The model synthesizes the retrieved data into a direct, accurate answer

Step 4: We compare outcomes. The parametric model produces a confident but incorrect answer. The RAG model produces an accurate answer grounded in retrieved data, and can cite its source. The user can verify the answer by checking the cited document. If the rate changes next month, the RAG system will automatically reflect the new rate without any model updates.

This worked example shows why RAG becomes a reliability requirement in applications involving current, specific, or domain-specific facts. The failure mode of the parametric system is silent: it gives a wrong answer without any indication that it's wrong. The RAG system's success mode is explicit: it gives a correct answer and tells you exactly where the answer came from.