Skip to content
K2 Chat

Evaluation K2 engineering

Measure evidence before judging answers

A reproducible retrieval benchmark can tell you whether the right sources surfaced. It cannot, by itself, certify generated answer quality or production behavior.

Retrieval-augmented generation is often summarized with a single question: did the answer look right? That question matters, but it combines several steps. A model can receive the right passages and still reason poorly; a fluent response can also conceal that retrieval missed the evidence entirely.

Separating evidence retrieval from answer generation gives teams a more useful first measurement. It asks whether a retriever returned the passages labeled as relevant, in what order, and whether the citations point to valid evidence. It does not claim that a generated answer is accurate, or that a deployed application performs well under real users and provider behavior.

Make the evidence set reviewable

K2 Chat's v2 offline evaluation uses a synthetic corpus with 11 documents, 30 source paragraphs, and 38 questions. Thirty questions are answerable from the corpus and eight are deliberately unanswerable. Cases include multiple supporting paragraphs, stale document versions, failed documents, and a conflicting document owned by another tenant.

The source and label files are sealed with SHA-256 hashes. That makes the benchmark inputs reproducible and helps detect accidental edits. A scorer rejects missing results and mixed corpus hashes, while execution errors remain in metric denominators. These details matter because a score without a stable question set and clear failure accounting is difficult to compare across runs.

The benchmark keeps development, frozen-test, and holdout questions separate. Development is the appropriate split for iteration; repeatedly tuning against a frozen test set turns it into another development set. Corpus changes require a new version so that a result can always be tied to the evidence it measured.

Read retrieval metrics for what they say

Recall asks what fraction of the labeled relevant evidence was retrieved. Precision asks how much of the returned list was relevant. The scorer uses a fixed K denominator for precision, so empty ranking slots count as misses. Mean reciprocal rank rewards finding a relevant item near the top, while nDCG accounts for graded relevance and ranking position.

Citations receive separate checks. Validity asks whether a cited passage belongs to the question's tenant, is from a current ready version, and appears among the first K retrieved paragraphs. Citation precision measures how much cited material is relevant; citation recall asks how much of the labeled evidence was cited. These measures expose different failure modes: a citation may be structurally valid but unhelpful, or useful in content but invalid for the current document state.

Abstention is reported for questions whose evidence is absent. A system that confidently invents an answer to an unanswerable question has a different failure from one that retrieves too little evidence for an answerable question. Keeping those outcomes distinct prevents a high retrieval score from obscuring unsafe behavior.

Use the reference as a calibration point

The committed development reference uses a deterministic lexical retriever at K=5. Across 14 development questions, it retrieves 91.7% of labeled answerable evidence, with precision@K of 23.3%, MRR of 69.7%, and nDCG of 75.7%. Citation validity is 100% under the scorer's authority rules. It does not abstain correctly on either of the two unanswerable development questions, so its abstention rate is zero.

Those numbers describe the lexical reference and the labeled synthetic evidence. They are not application model performance. In particular, the benchmark does not run a generation model to score answer correctness, and it does not measure latency, sustained throughput, cost, or real-world user satisfaction. Its purpose is narrower: to give retrieval and citation changes a stable, inspectable baseline.

Keep the claim proportional to the measurement

When a retrieval change improves recall, the result supports a statement about labeled evidence coverage on that split. It does not prove every resulting answer improved. When citation validity is perfect, that supports the authority checks represented in the corpus; it does not prove all possible access-control paths are correct.

Useful evaluation is not a contest for one impressive number. It is a way to locate which part of the evidence path changed, preserve the input set, and expose known limitations alongside the result. Measure retrieval, citations, abstention, generation, and system behavior with methods suited to each claim—and say plainly which of those measurements you actually ran.