2026-08-28·作者 Sijie Wang#cybernetics#engineering#testing

golden-set

Golden set — the dataset that IS the test suite

A golden set is the versioned collection of cases against which a prompt-program is evaluated: each case = an input (user request, scenario, document, trace-precondition) + an expectation (an ideal output, required facts/entities, banned content, a rubric to judge by). It plays the role a unit-test suite plays in Software 1.0 — and the mainstream's first commandment is blunt: a team without a golden set has no tests, only vibes.

Where cases come from (the three feeds)

  1. Production logs — real requests sampled from live traffic, the distribution you actually face (synthetic-only sets drift from reality).
  2. Constructed edge cases — adversarial phrasings, boundary lengths, multilingual variants, empty/garbage inputs.
  3. Incident fossilization — every production failure becomes a permanent case the moment it's fixed. The suite grows monotonically from pain, never shrinks. (Structurally identical to the um ratchet: every caught defect is promoted into the machine.)

Mechanics

Sets live as JSONL in the repo or as datasets in LangSmith/Braintrust (versioned, annotatable). Typical scale: 50–100 cases to start, hundreds at maturity; small enough that a full run fits CI (~30 min), large enough to cover the behavior surface. Expectations range from exact strings (cheap, brittle) through required/banned assertions to rubric text consumed by an LLM judge. Cases carry tags (capability, risk area) so regressions localize.

Pitfalls on record

Overfitting to the set (the prompt learns the tests — refresh from production regularly); stale expectations (the product's definition of "good" moved, the set didn't); score-without-baseline (a set is only meaningful relative to the current system's baseline — see regression-ci).

um relation: the audited ledger is a golden set accumulating for free — every passed artifact + its per-rule verdicts is a labeled case; what's missing is only the harness that re-runs it on machine changes (regression-ci).

Up: testing-software-3-0

Source: evals mainstream practice (DeepEval/Promptfoo/LangSmith/Braintrust guides, 2026-07 landscape check) — the foundation layer of Software-3.0 testing

關於這一條

sijie 的一條 wiki 條目。本站的 AI 以同一套語料庫為依據、以 sijie 的口吻作答,並附有指向此類條目的引用——回答會花 sijie 的錢,所以它在存取碼後等待: 輸入存取碼 →