Faithfulness and Hallucination

Does the evidence support the claim?

Faithfulness measures something specific and narrower than "is the answer true": whether the claims made in an answer are actually supported by the context that was supplied to the model. This distinction matters a lot in practice - an answer can be factually correct in the wider real world and still be unfaithful to the evidence it was supposedly grounded in, if the model happened to already know the fact from its training data rather than genuinely reading it out of the provided context. A hallucination, introduced back in the very first module of this track, is unsupported content the model generated and presented as though it were grounded in real evidence - faithfulness checking is essentially a way to systematically catch that specific failure mode.

Simple, deterministic checks can go a surprisingly long way here without needing another LLM at all: compare the meaningful words in the answer against the words actually present in the retrieved context, verify that any document IDs the answer cites were genuinely among the documents that were retrieved (rather than invented), and require every specific number appearing in the answer to actually occur somewhere in the supplied evidence. These checks have real, known limits - they can be fooled by a legitimate synonym the checker doesn't recognize, and they can't judge genuine multi-step reasoning - but they're fast, fully explainable (you can point to exactly why a check passed or failed), and stable from one run to the next.

answer_numbers = extract_numbers(answer)
context_numbers = extract_numbers(retrieved_context)
unsupported = [n for n in answer_numbers if n not in context_numbers]
assert not unsupported, f"unsupported numbers in answer: {unsupported}"

Ragas is a well-known real framework specifically for evaluating RAG systems, offering metrics that include faithfulness and relevance among others. Many of Ragas's evaluation approaches, and similar tools generally, work by calling out to another, typically much larger and more capable, LLM to act as a judge of the answer under test. That approach runs into a real problem on this platform: a tiny 0.5-billion-parameter local model can be genuinely inconsistent when used as a judge, which would make the lesson flaky, confusing, and hard to trust rather than illustrative.

Warning: Never treat one single automated score as absolute truth, no matter which method produced it. Review a sample of the actual failures by hand, test how well an automated evaluator's scores line up with real human judgment (its calibration), and keep any pass/fail thresholds tied to a specific, named risk you're trying to catch - not just tuned until the number looks acceptable.
Scenario: An answer confidently states that data is retained for 90 days, while the runbook document it cites contains no retention rule at all. A number-support check (does every number in the answer appear in the evidence?) and a citation check (was the cited document actually retrieved?) both immediately expose this specific unsupported claim, without needing a second LLM to judge it.