Learn · Prompt engineering & structured output · CCAR-F task 4.1

Explicit criteria beat vague instructions

Too many false positives? Say exactly what counts, what doesn't, and what to do when unsure. "Be careful" is not a criterion.

Key ideas

Worked example: Vague vs explicit, side by side

"Check that comments are accurate" invites opinion on every comment. "Flag a comment only when the behaviour it claims contradicts the code" gives Claude a test it can apply. The same goes for invoices: define an error as line total != qty x unit price (tolerance 0.01), or a VAT rate outside {0, 5, 12, 18, 28}%, and say to ignore formatting.

Exam traps

Official docs

Practise CCAR-F questions · Next lesson: Few-shot prompting for consistency