learn.web Back to the curriculum ↗

Context / Tools / Evals / Safety / 06

Evals before vibes

Build representative test sets, graders, traces, red-team cases, and release criteria tied to user outcomes.

Time
105 min
Mode
Learn → Make → Check
Path
AI Product Engineering

By the end, you can…

Evaluation replaces demo-driven development

A few impressive examples reveal possibility, not reliability. Build a dataset from real tasks, common cases, edge cases, failures, and adversarial inputs. Keep a holdout set away from prompt tuning.

Evaluate the whole system: retrieval, answer quality, groundedness, tool choice, safety, latency, cost, and user task success. Aggregate scores can hide catastrophic failures, so track critical slices separately.

Make failures inspectable

Store traces of inputs, context selection, model and prompt version, tool calls, outputs, validation, and feedback with appropriate privacy controls. A regression should be reproducible.

Use deterministic checks where possible, model graders with calibration where judgment is needed, and human review for high-impact or ambiguous cases. Define thresholds before seeing the new score.

Your studio task

Make — Build a 30-case evaluation set from real tasks, edge cases, and adversarial inputs.

  1. Collect 30 representative cases across normal, edge, and adversarial behavior.
  2. Define task success, groundedness, safety, latency, and cost measures.
  3. Create a holdout set and release thresholds.
  4. Run a change, inspect failed slices and traces, then record the ship decision.
Definition of done

Release criteria cover task success, groundedness, safety, latency, cost, and regression.

Open the interactive lesson with its workspace ↗

Knowledge check

Why keep a holdout evaluation set?
  1. To make the dataset larger
  2. To test generalization on cases not used while tuning
  3. To avoid reviewing failures
Reveal answer (B)

A holdout set reduces the chance that improvements merely overfit the examples used during development.

Aggregate evaluation scores can…
  1. Hide failures in important slices
  2. Replace human review
  3. Guarantee safety
Reveal answer (A)

Averages smooth over catastrophic failures; critical slices need separate tracking.