Faithfulness measures whether the generated answer is grounded in the retrieved context: every claim in the answer should be supported by a chunk the retriever returned. A RAG answer can sound confident and still invent a date, a number or a condition that no chunk contains. Checking faithfulness is a claim-by-claim comparison, not a general impression of quality, and it is one of the standard RAG evaluation metrics alongside context precision and answer relevancy.
What you need
- A RAG answer to check
- The chunks the retriever returned for that question
- A rule for what counts as supported: the exact fact must appear in a chunk
Step 1: Split the answer into claims
Break the answer into single facts: each date, number, name and condition is one claim. A sentence that packs three facts is three claims, not one.
Step 2: Check each claim against the chunks
For each claim, find the chunk that supports it, or mark it unsupported. A claim that is true in the world but absent from the chunks is still unfaithful, because the answer was supposed to come from the retrieved context.
Step 3: Score and fix the worst claim
Faithfulness is the share of supported claims. If the score is low, check first whether the retriever returned the right chunks: a faithful answer cannot be built from the wrong context.
Worked example: synthetic faithfulness check of one answer
The table below is a synthetic example. It shows the expected result of checking an answer; no answer was generated.
| Claim in the answer | In the chunks? | Verdict |
|---|---|---|
| Refund window is 30 days | Yes – chunk 2 | Supported |
| Support is open 24 hours | No – chunks say business hours | Unsupported |
| Plan costs $20 a month | Yes – chunk 1 | Supported |
| Free tier has no limit | No – chunks say 100 queries | Unsupported |
Expected result (UNTESTED). 2 of 4 claims are supported, so faithfulness is 0.50, and the two unsupported claims must be corrected or removed. This check was not run live; the table shows the expected result for the synthetic example.
Limits
- Faithfulness is usually judged by an LLM call, so the judge itself can be wrong; spot-check its verdicts on your own questions.
- An answer can be faithful and still wrong if the retrieved chunks themselves are wrong or out of date.
- A refusal to answer when the context lacks the answer is faithful; an invented answer is not.
- Faithfulness says nothing about whether the answer addresses the question; measure answer relevancy separately.
