Prompting and evals · L2 · 15 min
Prompt diff
Learn in five minutes
- A diff shows the lines you changed.
- Score the old and the new on the same set.
- Keep both outputs.
- A prettier sentence that fails the refusal test is a regression.
- Write the reason for the change in one line.
The reason line stops you from collecting prompt variants you cannot explain. If you cannot say why the line changed, revert it.
Visual
One line, one reason
- Copy a prompt.
- Add one sentence: 'If the note is silent, refuse.'
- Run the missing-price case.
- Keep the pair only if the refusal now happens and the earlier cases still pass.
Quiz
Ecosystem
- Diff
- The lines that changed between two versions.
Sisters: JSON schema, Rubrics, Regression tests.
The same job-shape-test card works for chat, voice, and a tool result.
The capstone reuses this card.
Config
- Write the goal in one sentence.
- Name the input and the allowed output.
- Save the trace next to the result.
Troubleshooting
- The answer looks fluent and is wrong. Check whether a source passage actually contains the claim.
- The loop never stops. Set a step cap and stop when the tool result repeats.
Sources and go deeper
- Brown and co-authors, Language Models are Few-Shot Learners, 2020 paper last checked 2026-10
- Prompt engineering — Wikipedia wikipedia last checked 2026-10