Four RAG answers look right. Which ones pass a grounding rubric?
Question
A returns assistant answers customer policy questions using retrieved chunks. The real policy says: "Unused items qualify for a refund within 30 days. Refunds arrive in 5 business days."
Review four logged outputs:
| Case | Retrieved chunk(s) | Assistant answer |
|---|---|---|
| A | doc-1: full 30-day unused rule and 5-day timing | "Return unused items within 30 days for a refund in 5 business days [doc-1]." |
| B | doc-2: "Shipping labels arrive by email after approval." | "Return unused items within 30 days for a refund in 5 business days [doc-2]." |
| C | doc-1: full rule; doc-3: "Gift cards are final sale." | "Return unused items within 30 days for a refund in 5 business days [doc-9]." |
| D | doc-1: full 30-day unused rule and 5-day timing | "All items qualify for a refund in 5 business days [doc-1]." |
- Which cases pass a strict grounding rubric, and why does each failed case fail?
- Which three separate metrics should your evaluator track?
Show hints (3)
- "CHECK THREE GATES"
Ask three separate questions per answer: Is the fact true? Do the retrieved chunks support every claim? Does every citation point to a supporting chunk?
- "MEMORY VS CITATION"
In Case B, the model answered from pretraining memory without evidence in
doc-2. In Case C,doc-1was retrieved, yet the answer cited nonexistentdoc-9. - "SPOT DROPPED RULES"
Case D cites the right chunk, yet drops "unused" and "within 30 days". Dropping a policy condition makes the claim unsupported.
Show checked explanation
Only Case A passes (1/4). Case B is right from memory but unsupported by doc-2. Case C has context support in doc-1 but cites a fabricated ID doc-9. Case D drops the "unused" and "30 days" conditions, distorting doc-1. Track answer correctness, faithfulness, and citation precision separately.
# (case, correct, retrieved, supporting, cited) cases = [ ("A", True, {"doc-1"}, {"doc-1"}, {"doc-1"}), ("B", True, {"doc-2"}, set(), {"doc-2"}), ("C", True, {"doc-1", "doc-3"}, {"doc-1"}, {"doc-9"}), ("D", False, {"doc-1"}, set(), {"doc-1"}), ] counts = [0, 0, 0, 0] # correct, faithful, valid_cite, strict_pass for name, correct, retrieved, supporting, cited in cases: valid_src = supporting & retrieved faithful = bool(valid_src) cite_ok = bool(cited) and cited <= valid_src strict = correct and faithful and cite_ok for i, flag in enumerate((correct, faithful, cite_ok, strict)): counts[i] += flag print(f"{name}: correct={correct} faithful={faithful} " f"cite={cite_ok} pass={strict}") n = len(cases) print(f"rates: correct={counts[0]}/{n} faithful={counts[1]}/{n} " f"cite={counts[2]}/{n} pass={counts[3]}/{n}")
A: correct=True faithful=True cite=True pass=True B: correct=True faithful=False cite=False pass=False C: correct=True faithful=True cite=False pass=False D: correct=False faithful=False cite=False pass=False rates: correct=3/4 faithful=2/4 cite=1/4 pass=1/4
Code and rubric scoring run on CPython 3.12.10 against the four local cases above; official NIST documentation link checked. Checked by an editor other than the author.
Walkthrough
Scoring final answer accuracy alone marks Cases A, B, and C as right (3/4, or 75%). That single score hides broken retrieval, fabricated citations, and legal risk.
Split grounded evaluation into three distinct gates:
- Answer correctness (3/4, 75%): Does the answer match the true policy? Cases A, B, and C pass; Case D fails because "All items" is false.
- Faithfulness (2/4, 50%): Does the retrieved context actually entail every claim and condition in the answer? Case A and Case C have
doc-1in context. Case B fails becausedoc-2never mentions 30 days or 5 business days; the model answered from pretraining memory. Case D fails because selective quoting drops "unused" and "within 30 days". - Citation precision (1/4, 25%): Does every cited ID exist in the retrieved set and support the attached claim? Only Case A passes. Case B attaches an irrelevant chunk (
doc-2). Case C inventsdoc-9, which was never retrieved. Case D citesdoc-1for a claimdoc-1contradicts.
| Case | Correct | Faithful | Valid citation | Strict pass | Failure reason |
|---|---|---|---|---|---|
| A | yes | yes | yes | yes | none |
| B | yes | no | no | no | Memory leak, unsupported by doc-2 |
| C | yes | yes | no | no | Fabricated ID doc-9 |
| D | no | no | no | no | Dropped key conditions |
A strict grounded pass requires all three gates together: only 1/4 (25%) passes here.
Enforce the cheap deterministic checks first in code: parse every [doc-id], confirm it belongs to the retrieved chunk IDs, and reject missing citations. Then run claim-level entailment checks (human audit plus a calibrated judge) to catch unsupported memory leaks like Case B and omitted qualifiers like Case D.
Common mistakes
- Checking only that cited IDs exist in the retrieved set. That catches Case C (
doc-9) while silently passing Case B (doc-2) and Case D (doc-1). - Rewarding Case B because the answer matches today's policy. Once the return window changes to 14 days, memory-based answers serve outdated rules with fake links.
- Ignoring citation padding, where the model cites both
doc-1and unrelateddoc-3. Require citation precision (cited <= supporting), not just one valid ID in a pile. - Scoring whole paragraphs with one fuzzy similarity score. Paragraph averages miss a single dropped condition like "unused" that flips policy liability.
Follow-up questions
- "What if a single sentence combines two facts from two different chunks, like a return window and an exception?" Break the answer into atomic claims before scoring. Each claim must be entailed by the union of the chunks it cites, and every cited chunk should contribute to that claim. That way you catch both missing citations (low citation recall) and irrelevant extra citations (low citation precision).
- "How do you stop fabricated IDs like
doc-9in production before users see them?" Run a deterministic post-processor before showing citations. Map citations to short integer indices for retrieved chunks and strip any out-of-range ID. Fall back to a refusal or retry if an answer cites zero valid chunks.
What a strong answer covers
Passes only Case A (1/4) and names the exact flaw in B (memory leak), C (fabricated ID), and D (dropped conditions). Separates answer correctness (3/4), faithfulness (2/4), and citation precision (1/4), pairing deterministic ID checks with claim-level support checks.
Open in interactive practice deck →