Good Recall, Bad Answers: Fixing LLM Generation

GT

GigaRAG team

Retrieval23 min read
On this page
Good Recall, Bad Answers: Fixing LLM Generation hero
Good Recall, Bad Answers: Fixing LLM Generation hero

Your retrieval metrics look perfect: hit rate above 95%, embeddings tested, re-ranking tuned. And still the answer is wrong. If you build RAG pipelines or agent memory systems, you've hit this wall. The uncomfortable truth is that the LLM itself is often the bottleneck, not your retrieval stack. No amount of chunking or vector tuning will fix it.

Here's why. Most debugging effort goes into the retrieval half: what got pulled, how it was ranked, whether the right context made it into the prompt. But the generation half is where the answer actually gets built, and LLMs fail there in predictable, diagnosable ways. They ignore context. They conflate sources. They hallucinate details. They lose track of state.

This guide gives you a practical taxonomy of LLM failure modes in RAG systems, a diagnostic checklist to separate retrieval problems from generation problems, and an honest look at what you can and cannot fix. GigaRAG helps with parts of this, but the diagnosis comes first.

At a glanceDetails
Core problemRetrieval works, but LLM generation fails
Key symptomHigh recall, wrong or irrelevant answers
Main causeLLM reasoning, not retrieval
Diagnostic focusSeparate retrieval vs generation errors
Fix approachTargeted LLM tuning and evaluation
Honest limitNo perfect fix; manage expectations

In This Guide

The Recall Trap: Why Good Retrieval Masks Bad Generation

You've hit 95% recall. Your embeddings are solid, your re-ranking is tuned, your chunking strategy is dialed in. The right documents are landing in the context window almost every time. And the answer is still wrong.

That's the trap. Retrieval metrics tell you the right information reached the model. They tell you nothing about what the model did with it. A pipeline can have perfect recall and still produce answers that are irrelevant, contradictory, or flat-out fabricated. The LLM is not a passive summarizer of whatever you hand it. It's an active interpreter, and it makes mistakes that no amount of retrieval tuning will fix.

What "good recall" actually measures

Recall measures whether the relevant document made it into the retrieved set. That's it. It's a property of your search stack: embeddings, vector database, re-ranker, chunking. High recall means the needle is in the haystack you handed to the model.

It does not mean the model found the needle. It does not mean the model used the needle correctly. It does not mean the needle was even the right needle. Recall is a retrieval-side metric, and it stops being meaningful the moment the context window closes and generation begins.

Why retrieval metrics don't predict answer quality

Here's the uncomfortable truth: retrieval metrics and answer quality are weakly correlated in practice. You can push recall from 80% to 95% and see zero improvement in user-perceived answer quality. Or you can see answers get worse, because you're now stuffing more context into the window and the model is drowning in it.

The reason is simple. Retrieval optimizes for "did we find the relevant text." Answer quality depends on "did the model read it, understand it, reason about it, and produce a correct response." Those are different systems with different failure modes. Optimizing the first does not constrain the second.

The generation bottleneck: where good context goes to die

The generation bottleneck is the gap between what the model receives and what it outputs. It's where good context goes to die. The model can ignore the retrieved text entirely. It can misread it. It can conflate two sources that contradict each other. It can hallucinate details that were never in the context. It can reason incorrectly about what it read.

None of these failures show up in your retrieval dashboard. You'll see them only when you inspect the actual answers, or when a user reports that the system confidently told them something wrong. The fix is not better retrieval. It's understanding what the LLM does with the context you give it, and designing around those failure modes directly.

[!note] High recall does not guarantee correct answers; LLMs can still misinterpret or ignore retrieved context, leading to plausible but wrong responses.

Retrieval Problems vs Generation Problems

FactorRetrieval ProblemGeneration Problem
SymptomMissing relevant documentsAnswer contradicts or ignores context
Recall metricLow recallHigh recall but low answer accuracy
FixImprove indexing, query expansionPrompt engineering, model fine-tuning
EvaluationRecall@k, precisionAnswer correctness, faithfulness
Root causeData or search issuesLLM reasoning or instruction-following

A Practical Taxonomy of LLM Failure Modes in RAG Systems

LLMs fail in predictable ways even when the retrieved context is correct: they ignore it, misread it, reason badly about it, invent details, lose state, or trust the wrong source. These are generation-side failures, not retrieval failures, and each needs a different fix.

Ignoring retrieved context entirely

The model receives the right document and answers as if it never saw it. It produces a plausible-sounding response from its pretraining weights instead. This happens most often when the retrieved text is long, dense, or formatted in a way the model doesn't recognize as authoritative. The fix is usually context formatting: put the retrieved content first, label it explicitly, and keep it short enough that the model can't skip past it.

Misinterpreting or conflating multiple sources

You retrieve three documents. Two agree, one contradicts them. The model blends all three into a single answer that's subtly wrong. Or it attributes a claim from source A to source B. This is a reasoning failure, not a retrieval failure. The documents were all relevant. The model just couldn't keep them separate. Shorter context windows and explicit source labels help, but they don't eliminate the problem.

Reasoning errors in chain-of-thought

The model walks through a multi-step reasoning process and makes an arithmetic error, skips a step, or draws a conclusion that doesn't follow from its own premises. The chain looks convincing on the surface. It's only when you trace it step by step that you find the break. This is the hardest failure mode to catch automatically, because the answer is often formatted correctly and sounds authoritative.

Hallucinating details not present in context

The retrieved text says the product launched in 2021. The model says 2019. The retrieved text lists three features. The model adds a fourth. These aren't retrieval failures. The correct information was in the context window. The model generated something else. This is the failure mode that most damages user trust, because it's confident and specific.

Losing track of conversation or task state

In multi-turn interactions, the model forgets what it said three turns ago. It contradicts its own earlier answer. It repeats a question the user already answered. This is a state-tracking failure, and it gets worse as conversations get longer. Agent memory systems amplify this problem, because the model now has to track both the conversation and its own stored memories.

Over-trusting irrelevant retrieved content

The retrieval system returns a document that's tangentially related but not actually relevant. The model treats it as authoritative and builds an answer around it. This is a retrieval failure that becomes a generation failure. The model's job is to judge whether the retrieved content actually answers the question. It often doesn't. Re-ranking helps, but the model still needs explicit instructions to reject irrelevant context.

[!tip] For RAG builders: always log both retrieved documents and generated answers side-by-side during development to quickly spot whether errors stem from retrieval or generation.

Good Recall Bad Answers: A Step-by-Step Guide

  1. Verify retrieval quality: manually inspect top-k documents for relevance.
  2. Check if the answer is grounded in retrieved context or hallucinated.
  3. Test with a simpler prompt to isolate instruction-following issues.
  4. Evaluate the LLM's reasoning by asking it to explain its answer.
  5. Compare outputs across different models to identify model-specific weaknesses.
  6. Review evaluation metrics: ensure they capture answer correctness, not just retrieval.
  7. Implement targeted fixes: prompt adjustments, fine-tuning, or model switching.
GigaRAG infographic showing a five-step diagnostic checklist for separating retrieval problems from generation problems when recall is high but answers are wrong.

Diagnosis vs. Correction: What the Research Actually Shows

Here's the uncomfortable finding from the research: LLMs are bad at finding their own reasoning errors, but they can often fix them when you point to the exact spot. This asymmetry matters for how you build evaluation and debugging into a RAG pipeline.

Why LLMs can't reliably self-diagnose

When a model generates a chain-of-thought trace, it commits to a reasoning path. Asking it to review that same trace and spot mistakes doesn't work well. The model re-reads its own output with the same biases that produced it. It tends to endorse what it already wrote rather than challenge it.

The arXiv paper on BIG-Bench Mistake tested this directly. Models were asked to find reasoning mistakes in CoT traces. Performance was poor. The same models that could solve the underlying task couldn't reliably identify where their own reasoning broke down. This isn't a prompt-tuning problem. It's a structural limitation of having the same system act as both generator and critic.

The error-location insight: pointing helps

The picture changes when you give the model the location of the error. If you highlight the specific step where the reasoning went wrong, the model can often correct it. The hard part is finding the step. The correction part is comparatively easy.

This maps to a practical workflow. Don't ask an LLM to review its own answer and tell you if it's wrong. Instead, use a separate process to flag likely error locations, then ask the model to fix those specific spots. The separation of diagnosis from correction is the key design principle.

What this means for your RAG evaluation pipeline

You can't rely on the generation model to grade its own output. If you're using LLM-as-judge for evaluation, use a different model than the one that produced the answer. Even better, use a model with a different architecture or training distribution. Same-model self-evaluation inherits the same blind spots.

For debugging bad answers, build tooling that surfaces the reasoning trace and lets a human or a separate model mark the step where things went wrong. Then feed that marked trace back for correction. This is slower than asking the model to self-correct, but it actually works. The honest tradeoff: you're moving the diagnostic burden onto your evaluation infrastructure, not onto the model.

Agent Memory: Where the Problem Gets Worse

Single-turn RAG is hard enough. Agent memory systems stack additional failure modes on top of everything we've covered. The core issue: in a multi-turn agent, the LLM's output from one turn becomes input context for the next. Errors don't just appear and disappear. They persist, accumulate, and influence future answers.

Memory contamination: when bad answers poison future context

Here's what happens behind the scenes. Your agent retrieves context, generates an answer, and then writes something to memory. If that answer contains a hallucination or a reasoning error, the bad content gets stored. On the next turn, the agent retrieves that stored content as if it were ground truth. The error is now part of the context window, sitting alongside your carefully curated knowledge base.

This is worse than a single bad answer. A hallucination in one turn is a one-off failure. A hallucination written to memory is a persistent poison. The model can't tell the difference between a fact you gave it and a fact it invented earlier. Both look identical in the memory store. The contamination compounds because each subsequent turn may build on the corrupted memory, generating new errors that also get stored.

State tracking failures in multi-turn agents

Agents maintain state across turns: what the user asked, what the agent already did, what remains to be done. LLMs are bad at maintaining this state reliably. They lose track of constraints set three turns ago. They forget that a subtask was already completed. They re-ask questions the user already answered.

The problem isn't retrieval. The state is in the context window. The model simply fails to attend to it correctly. Long conversations make this worse. As the context grows, the model's attention gets diluted across more tokens. Early constraints fade. Recent turns dominate. The agent behaves as if the conversation started two turns ago.

Compounding errors: how one bad answer cascades

A single reasoning error in a multi-step agent task doesn't stay isolated. The agent uses the wrong intermediate result to make the next decision. That decision produces another wrong result. By the time the agent reaches the final answer, the error has propagated through every subsequent step.

This is the failure mode that separates agent systems from single-turn RAG. In single-turn, you get one bad answer and the user can rephrase or retry. In an agent loop, the bad answer becomes an input to the next action. The agent may take a wrong action based on the bad answer, observe a confusing result, and generate yet another wrong answer trying to explain it. The system drifts further from correct with each iteration.

The honest answer is that agent memory makes LLM failures structural rather than incidental. You're not debugging individual answers anymore. You're debugging a system where errors feed back into themselves.

How to Evaluate LLM Responses in a RAG Pipeline

Evaluating LLM responses is different from evaluating retrieval. Retrieval metrics tell you whether the right documents came back. Response evaluation tells you whether the answer is actually good. They're separate problems, and you need separate tools for each.

Faithfulness: does the answer match the retrieved context?

Faithfulness measures whether every claim in the answer is supported by the retrieved context. It's the most important metric for RAG systems because it catches hallucinations directly. The check is simple: take the answer, break it into individual claims, and verify each claim against the context you provided. If a claim isn't in the context, it's unfaithful.

You can do this manually for small test sets. For larger volumes, use an LLM judge: give it the context and the answer, and ask it to flag unsupported claims. The judge itself can hallucinate, so spot-check its output regularly.

Relevance: does the answer address the query?

Relevance measures whether the answer actually responds to what the user asked. A faithful answer can still be irrelevant. The model might correctly summarize retrieved context that doesn't answer the question.

Evaluate relevance by asking: does this answer resolve the user's need? A binary yes/no per response works for most teams. Track the rate of irrelevant answers separately from unfaithful ones. They have different root causes and different fixes.

Correctness: is the answer factually right?

Correctness is the hardest metric because it requires ground truth. Faithfulness checks against your context. Correctness checks against reality. If your retrieved context is wrong, a faithful answer will be wrong too.

For domains with verifiable answers, build a test set with known-correct responses. Score each generated answer against the reference. For open-ended domains, you'll need human evaluation. There's no shortcut here. Correctness is the metric that actually correlates with user trust, and it's the most expensive to measure.

Practical evaluation setups for small teams

Start with a test set of 50 to 100 real queries. Run them through your pipeline. Evaluate faithfulness and relevance with an LLM judge, and correctness manually. That's a day of work, not a month.

Log every evaluation result. When you change prompts, models, or retrieval settings, re-run the same test set. Track the three metrics separately. A change that improves faithfulness but hurts relevance tells you something different from one that improves both.

Don't build a complex evaluation harness before you have a baseline. Fifty queries, three metrics, manual review. That's enough to catch most problems.

What You Cannot Fix (And Should Stop Trying To)

Some problems in RAG pipelines are not engineering problems. They're limits of the current technology. You'll save weeks of work by knowing which is which before you start tuning.

You cannot guarantee zero hallucinations

No prompt, no retrieval strategy, no model makes hallucination impossible. Hallucination is a property of how LLMs generate text: they predict likely tokens, not verified facts. You can reduce the rate. You can catch most failures in evaluation. You cannot get to zero.

The honest target is a low, measured, monitored rate. Teams that claim zero hallucinations are either not testing hard enough or not looking at enough responses. Set a threshold you can live with, track it over time, and build guardrails for the failures you know will happen.

You cannot make LLMs reliably self-correct

LLMs are bad at finding their own mistakes. Research on chain-of-thought traces shows models often fail to spot reasoning errors in their own output, even when the error is obvious to a human reader. Asking a model to "check your work" produces confident confirmations, not reliable corrections.

What does work: pointing to the specific location of an error and asking for a fix. The model can often correct a mistake once you tell it where the mistake is. That's a human-in-the-loop pattern, not self-correction. Build your pipeline assuming the model won't catch its own failures.

You cannot fix reasoning errors with better retrieval alone

If the model misreads context, conflates two sources, or botches a multi-step inference, no amount of retrieval tuning will help. The context was there. The model didn't use it correctly.

This is the core message of the whole article, stated plainly: retrieval quality and reasoning quality are separate failure modes. Better embeddings, better chunking, better re-ranking fix the first. They do nothing for the second. When recall is already good and answers are still wrong, stop touching retrieval. The problem is in the generation layer, and that's where the fix has to happen.

A Diagnostic Checklist for Good Recall, Bad Answers

When recall is good and answers are still wrong, you need a process. Not another metric dashboard. A sequence of checks that isolates the failure before you spend time fixing the wrong layer. Here's the order I use, and it works because each step rules out a whole class of problems.

Step 1: Verify the retrieved context is actually correct

Before you blame the model, check the input. Pull the exact context chunks that went into the prompt for a failing query. Read them. Does the retrieved content actually contain the answer?

You'd be surprised how often "good recall" means "the right document was in the top 10," not "the right passage was in the context window." If the answer isn't in the retrieved text, your problem is still retrieval, just one layer deeper than your metrics show. Fix chunking or re-ranking before touching anything else.

Step 2: Check if the LLM used the context at all

If the context is correct but the answer ignores it, you've found a generation failure. The model had the information and didn't use it.

Test this directly: take the same context and query, and ask the model to quote the specific sentence that supports its answer. If it can't, or quotes something irrelevant, the model is not grounding on your context. This is a prompt or model problem, not a retrieval problem.

Step 3: Test with a stronger model to isolate the bottleneck

Swap your current model for a more capable one on the same failing queries, same context, same prompt. If answers improve, the bottleneck is model capability. If answers stay bad, the bottleneck is your prompt structure or context formatting.

This is the cheapest experiment you can run. It takes an afternoon and tells you whether to invest in prompt engineering or model selection. Don't skip it.

Step 4: Examine the reasoning trace for specific error types

Ask the model to show its work. Then read the trace looking for the failure modes from earlier in this article: conflation of two sources, a skipped step in a multi-hop inference, a hallucinated detail that wasn't in context.

The trace won't always be honest. Models confidently produce reasoning that doesn't match their actual answer. But the trace still gives you a place to look. When you find the error type, you know which fix applies: grounding instructions for ignored context, source separation for conflation, explicit step requirements for reasoning gaps.

Step 5: Review memory and conversation state for contamination

In agent systems, check what the model actually had in its memory when it answered. A bad answer from three turns ago may still be sitting in the context window, poisoning every response after it.

Look for stale summaries, unpruned conversation history, or memory entries that should have been overwritten. If contamination is present, the fix is memory design: shorter retention windows, better summarization, or explicit reset points. This is a system problem, not a model problem, and no prompt tweak will solve it.

Run these five steps in order. Most teams find the problem by step 3. The ones that don't usually find it in step 5.

Practical Fixes That Actually Move the Needle

Once you've found the failure mode, the fix is usually cheap. Here are the interventions that produce measurable improvements, in rough order of effort.

Context formatting: make retrieved content impossible to ignore

The model can't use what it can't distinguish. Wrap each retrieved chunk in explicit delimiters and label them by source. Put the query last, after the context. Add a line that says "Answer using only the sources above."

This sounds trivial. It isn't. Models attend to position and formatting. A chunk buried mid-prompt with no label gets treated as background noise. Labeled, delimited chunks get treated as evidence.

Prompt-level interventions: explicit grounding instructions

Tell the model what to do when context is insufficient. "If the answer is not in the sources, say so." That one line cuts hallucination rates more than most retrieval tweaks.

For reasoning-heavy queries, require the model to cite the source chunk for each claim. This forces grounding and gives you a hook for evaluation.

Memory design: isolation, summarization, and reset strategies

Keep retrieved context separate from conversation memory. Don't let them blur into one long prompt. Summarize old turns aggressively. Set explicit reset points where memory is cleared or archived.

The goal is simple: the model should never see a stale answer and mistake it for current context.

Model selection: when to upgrade, when to fine-tune

If step 3 from the checklist showed a stronger model fixes your failures, upgrade. Don't fine-tune. Fine-tuning teaches style and format, not reasoning. It won't fix a model that can't follow grounding instructions.

If a stronger model doesn't help, the problem is your prompt or context design. Fix those first. Fine-tuning is the last resort, and it's usually not worth it for RAG.

Why LLM Outputs Are Unpredictable, and What That Means for Your Roadmap

You can feed the same prompt, the same context, and the same model twice, and get two different answers. That's not a bug. It's how these systems work. The unpredictability is baked in, and it doesn't disappear just because you wrapped retrieval around it.

Temperature, sampling, and nondeterminism

LLMs generate text one token at a time. At each step, the model produces a probability distribution over the next token. It doesn't pick the most likely one. It samples from that distribution. Temperature controls how flat or peaked the distribution is before sampling happens.

Temperature 0 doesn't guarantee determinism either. Floating-point arithmetic on GPUs isn't associative. The same computation run on different hardware, or even the same hardware with different batch sizes, can produce slightly different results. Those tiny differences compound across thousands of tokens.

So when a stakeholder asks why the answer changed between runs, the honest answer is: because sampling is random, and the hardware math isn't exact. You can reduce variance. You can't eliminate it.

Sensitivity to prompt and context variations

Small changes produce large swings. Reordering two retrieved chunks can flip the answer. Adding one irrelevant sentence to the context can derail the reasoning chain. Changing "explain" to "describe" shifts the output structure.

This matters for RAG because your retrieval step is inherently noisy. The same query retrieves slightly different chunks on different days. The model then responds to those differences in ways you can't predict from the retrieval scores alone.

Planning for variance in production systems

Don't build a pipeline that assumes stable outputs. Build one that tolerates variance. Run the same query multiple times and look at the spread of answers. If the spread is wide, your prompt or context is too loose. If it's narrow, you've got a stable configuration.

Set stakeholder expectations early. Say plainly: the model will sometimes give different answers to the same question. That's not a defect you can patch out. It's a property of the system. What you can do is measure the variance, tighten the prompt, and catch bad answers before they reach users.

Final Thoughts: Good Recall Is Necessary, Not Sufficient

You can hit 95% recall and still ship wrong answers. That's the uncomfortable truth this whole article has been circling. Retrieval gets the right chunks into the context window. The LLM then ignores them, misreads them, or hallucinates around them. No amount of embedding tuning fixes that.

The LLM is a first-class citizen in your pipeline. Treat it like one. That means evaluating its outputs directly, not just the retrieval step upstream. It means building memory systems that don't let one bad answer poison the next ten turns. It means accepting that some failure modes are structural, not fixable with a better prompt.

Good recall, bad answers is a generation problem wearing a retrieval costume. The diagnostic checklist earlier in this article exists because the two are easy to confuse. Separate them. Test with a stronger model. Check whether the context was used at all. Look at the reasoning trace. Only then will you know what you're actually debugging.

GigaRAG was built for exactly this. It gives agent memory and RAG pipeline builders a way to structure context, track what the model actually used, and catch bad answers before they reach users. It won't make LLMs deterministic. Nothing will. But it helps you see the failure clearly, and that's the first step toward fixing what can be fixed.

Frequently Asked Questions

How does LLM handle spelling mistakes?

LLMs are generally robust to minor spelling errors due to subword tokenization, but severe misspellings can lead to misinterpretation. In RAG, spelling errors in queries may also affect retrieval quality, so preprocessing can help.

Can AI reduce human error?

AI can reduce certain human errors by automating routine tasks and providing consistent outputs, but it introduces its own error modes. In RAG systems, human oversight is still needed to catch LLM misinterpretations.

How to evaluate the LLM response?

Evaluate LLM responses using both automatic metrics (e.g., answer correctness, faithfulness to context) and human judgment. For RAG, compare generated answers against ground truth and check if they are supported by retrieved documents.

Why are LLM outputs sometimes unpredictable?

LLM outputs can be unpredictable due to stochastic sampling, sensitivity to prompt phrasing, and inherent model limitations. In RAG, unpredictable outputs often arise when the model struggles to reconcile conflicting or noisy retrieved context.

What if retrieval metrics are high but answers are still wrong?

This indicates the bottleneck is likely in the generation phase. Focus on prompt design, model selection, and fine-tuning to improve the LLM's ability to use retrieved information correctly.

How can I tell if my LLM is hallucinating?

Check if the answer contains facts not present in the retrieved documents. Hallucinations often appear as plausible but unsupported details. Using faithfulness metrics and manual review can help detect them.

About GigaRAG

GigaRAG is for agent memory and RAG pipeline builders. get this right. Whether you are working through good recall, bad answers: when the LLM is the problem or something adjacent, we publish what we have actually tested, including where it falls short.

All posts