Track 05 · EvalsLesson 02 of 10
Golden datasets and the metrics that matter
Write the test set down, pin it to numbers, and improve against it.
- The FDE path · Stage 5 of 6
- 45 min read
- 60 min hands-on
- Pro
What you'll be able to do
01- Explain what makes a golden set "golden", and the difference between dev, held-out test, regression, canary and adversarial sets.
- Design a sampling plan from production logs, stratified by intent, difficulty, language and segment, and re-weight results to the production mix.
- Calculate a Wilson confidence interval for a pass rate, and the number of cases a decision needs.
- Write labelling guidelines, and detect contamination and leakage between the golden set and everything that shapes the system.
- Choose metrics by task type, and explain what BLEU and ROUGE can and cannot tell you.
- Defend dataset sourcing, versioning, ownership and data handling to a data-platform owner and a CISO.
Before you start
- From requirements to eval criteria: criteria decide what each case must contain.
- Picking embeddings on your corpus, not a leaderboard: recall@k, MRR and nDCG, reused here for retrieval components.
- Querying a month of traces: how you pull candidate cases from logs. Read in parallel.
- Basic probability: a pass rate is a proportion, and proportions have sampling error.
The short version
A golden set is a curated, labelled, versioned sample of the work the system must do, with a known procedure for each label and a named owner. It is the reference every eval runs against, so its flaws become your conclusions. Build it mostly from real production traffic, masked, and stratified so rare but important cases are present in useful numbers. Add SME-written edge cases and past incidents, and use synthetic inputs carefully and labelled as such. Size it from the confidence interval you need, not from a round number: 20 cases can tell you something is broken, but it takes hundreds to show something meets a threshold. Write labelling guidelines, double-label a share, and keep the set away from everything that shapes the system: prompt examples, judge examples and fine-tuning data. Version it like code. Choose metrics that match the task, and do not trust n-gram overlap metrics for open-ended text.
- Representative first, then enriched. Sample from production by stratum, then add edge and adversarial cases in separate suites.
- Report intervals, not just rates. Use the Wilson interval; re-weight stratified samples to the production mix for headline numbers.
- Guidelines make labels reproducible. Double-label, measure agreement, adjudicate, record rationale.
- Leakage makes scores meaningless. Keep dev and test splits, deduplicate, and never put test cases in prompts.
- Datasets are versioned artefacts with owners. Every result records the dataset version that produced it.
Practise this in the lab
Pro lesson
The rest of this lesson is in Pro.
The mental model, worked example, field note, failure table, exercise and self-check, with the voice tutor.
Pro opens this stage
Stage 5 · Prove it and pass review- 7 lessons, with the voice tutor
- Lab · Clean a golden set before you trust it, graded here
- Halden week 4 · First slice due
- Halden week 6 · Instructions hidden in an invoice
- The lab kit, to run Halden weeks on your machine
Also in Pro
- Every stage and specialisation, in full
- Every lab and every role project
- Halden weeks 2–10, on your record
- Every drill, live in the playground
- All solutions, plus the server judge
- Lab Assistant and every Teach with AI