Skip to content

Retrieval-Augmented Generation Evaluation

Overview

RAG system evaluation is the process of measuring the quality of retrieval-augmented generation components: the retriever, the generator, and their interaction. Evaluation is divided into retrieval evaluation and generation evaluation, as well as end-to-end evaluation of the final response.

Retrieval Metrics

  • Recall@k — the proportion of relevant documents among the top k results.
  • Precision@k — the proportion of relevant documents in the retrieval.
  • MRR (Mean Reciprocal Rank) — the average inverse position of the first relevant document.
  • NDCG@k — normalized discounted cumulative gain.

Generation Metrics

  • Faithfulness — the correspondence of the response to the extracted documents.
  • Answer Relevancy — the relevance of the answer to the query.
  • Context Precision / Recall — the precision and recall of context usage.

End-to-End Evaluation

Frameworks (RAGAS, TruLens) and LLM-as-a-judge are used for automatic evaluation. Manual evaluation on labeled datasets remains the gold standard.

See Also

← All Terms