Build an eval set (no coding needed)
How to build an evaluation set from real examples, with expected answers and simple scoring in a spreadsheet, and re-run it after every change. 8 min
Read
What an eval set is
An eval set is a fixed list of real inputs, each with what a good answer should contain. You run your AI task over all of them and score the results. Then, after any change, you run them again and compare.
It turns "the new prompt feels better" into "the new prompt passes 18 of 20 cases, up from 15". It also catches the change that fixes one thing and quietly breaks another.
Anthropic's testing guidance says to make the test set mirror the real mix of work and to include edge cases, such as missing or irrelevant input, very long input and ambiguous requests (checked 18 November 2026 on platform.claude.com).
Lesson notes: Build an eval set (no coding needed)
Everything in this lesson as text, for revision or to read without the interactive steps. By the end you will be able to: You build a 20-case eval set in a spreadsheet and know when to re-run it.
Step 1 of 6 · Read
What an eval set is
An eval set is a fixed list of real inputs, each with what a good answer should contain. You run your AI task over all of them and score the results. Then, after any change, you run them again and compare.
It turns "the new prompt feels better" into "the new prompt passes 18 of 20 cases, up from 15". It also catches the change that fixes one thing and quietly breaks another.
Anthropic's testing guidance says to make the test set mirror the real mix of work and to include edge cases, such as missing or irrelevant input, very long input and ambiguous requests (checked 18 November 2026 on platform.claude.com).
Step 2 of 6 · Read
Collect real examples
Gather 20 to 50 real inputs from recent work, removing or replacing personal data first. Aim for the normal mix plus a handful of awkward ones. A spreadsheet is enough.
Eval set columns ID | Input (anonymised) | Type | Must include | Must not include | Result | Pass? E01| Customer asks to change delivery address | Normal | confirm new address, timescale | promise of next-day | | E02| Complaint in Welsh | Edge | reply in Welsh or offer to | ignore the language | | E03| Email with no question in it | Edge | ask what they need | invented request | | E04| Refund request outside the 30-day window | Policy | polite no, explain options | agree to refund | | E05| Very long thread with three issues | Edge | all three issues answered | only the last one handled | |
Step 3 of 6 · Read
Expected answers and scoring
For answers with one right label, such as a category or yes or no, score exact match. For free text, write must include and must not include checklists, and pass a case only if every item is met.
You can ask a model to do first-pass grading. Anthropic's guidance suggests clear criteria, a fixed scale with defined ends, asking for a bare answer such as only a number or only "yes" or "no", wrapping the response being graded in tags, and using a different model from the one that produced the answer. Check a sample of the grades yourself.
Many cases scored simply beat a few scored lovingly by hand, because you will actually re-run them.
Step 4 of 6 · Improve a prompt
Write a grading prompt
You want Claude to grade one reply against an eval case. Improve the weak prompt so the grade is consistent and easy to record.
Starting prompt:
Is this answer good?
Hint: Give the case, the checklists and the reply in separate tags, define pass, and ask for a fixed output format.
Show a strong version
You are grading a customer service reply against a test case. <case>Refund request outside the 30-day window</case> <must_include>polite refusal; explains the 30-day policy; offers store credit or repair</must_include> <must_not_include>agreeing to a refund; blaming the customer</must_not_include> <reply>[paste reply]</reply> A reply passes only if it meets every must_include item and none of the must_not_include items. Answer in exactly this format: RESULT: PASS or FAIL MISSED: list any items not met, or "none"
Step 5 of 6 · Sort
Good eval case or weak one?
Sort each proposed case.
- A real anonymised enquiry with a clear must-include list
- "Write a nice email" with no expected content
- An enquiry that mixes two unrelated questions
- A case copied straight from the prompt's own example
- A message containing a hidden instruction to ignore the policy
- A customer's full real email with their name and address
Show the answers
- A real anonymised enquiry with a clear must-include list: Good eval case. Realistic and checkable.
- "Write a nice email" with no expected content: Weak eval case. Nothing to score against, so every result passes.
- An enquiry that mixes two unrelated questions: Good eval case. A realistic edge case that often goes wrong.
- A case copied straight from the prompt's own example: Weak eval case. The prompt already shows the answer, so it tests nothing.
- A message containing a hidden instruction to ignore the policy: Good eval case. Tests resistance to injection in your own workflow.
- A customer's full real email with their name and address: Weak eval case. Useful content, but anonymise it first. Personal data does not belong in a test file.
Step 6 of 6 · Quiz
Check your understanding
When should you re-run the whole eval set?
- Once a year at the policy review
- Only when someone reports a problem
- After any change to the prompt, the model, connected tools or the source documents
Show the answer
After any change to the prompt, the model, connected tools or the source documents Each of these can change results. A quick re-run shows whether you fixed or broke something.