Skip to content

Evaluating RAG Systems

How to measure a RAG system properly: retrieval quality, answer correctness, faithfulness and the test set that ties them together.

Editorial team 2 min read

RAG systems fail in two places: retrieval and generation. Evaluate both, separately and together.

Build a Test Set

Collect realistic questions — ideally from real users — each with:

  • the expected answer or key facts;
  • the source passages that contain it;
  • questions that shouldn't be answered (out of scope or not in the documents).

Retrieval Metrics

  • Recall@k: does the right passage appear in the top k?
  • Precision@k / MRR: how much noise, and how high the first relevant result ranks.

Answer Metrics

  • Correctness: does the answer match the expected facts?
  • Faithfulness (groundedness): is every claim supported by the retrieved context?
  • Answer relevance: does it address the question?
  • Citation quality: are citations present and supportive?
  • Refusal accuracy: does it decline when the information isn't there?

How to Grade

Use exact checks where possible, model-based graders with clear rubrics for faithfulness and relevance, and human review on a sample to validate the graders.

Diagnose by Stage

If retrieval recall is low, fix parsing, chunking, search or filters. If retrieval is good but answers are poor, fix the prompt, context assembly or model.

Run It Continuously

Re-evaluate whenever documents, chunking, embedding models, prompts or language models change, and track results over time.

More in RAG

All RAG guides →
RAG Guide · 1 min

RAG Architecture: The Components End to End

A map of a complete retrieval-augmented generation system, from ingestion to answer, and what each component is responsible for.

RAG 1 min read 6 Dec 2025

RAG Guide · 2 min

Document Parsing for RAG

Turning PDFs, slides, HTML and scans into clean, structured text — the unglamorous step that decides RAG quality.

RAG 2 min read 5 Dec 2025

RAG Guide · 2 min

Chunk Size and Overlap Tuning

How to choose chunk size and overlap for retrieval by testing against real questions rather than guessing.

RAG 2 min read 4 Dec 2025

RAG Guide · 2 min

Hybrid Search for RAG

Combining keyword and vector search so RAG finds both exact terms and paraphrased meaning.

RAG 2 min read 3 Dec 2025