Before you begin
Open the existing project so your instruction is grounded in the current app.
Write the instruction from the user’s perspective, then state the exact result you want to inspect.
Write the instruction
One good example can teach more than a long paragraph of instructions.
Add
Example input
[The exact information a user might provide]
Ideal output
[The exact result the app should return]
Why it is good
[The rule or judgment the example demonstrates]
For a document extractor, that could be
Input
A contract with a 90-day termination clause and automatic annual renewal.
Ideal output
Termination notice: 90 days
Renewal: Automatic, annually
Risk flag: Notice period exceeds our 30-day standard
Next action: Legal review required
Why
The app must extract the fact, compare it with policy, and route the exception.
Examples make hidden expectations visible. They also become useful test cases later.
Use representative examples, not only perfect ones.
Common mistakes
Providing only a good example and no difficult or incorrect example.
Using an example that contains sensitive information.
Assuming one example is the final evaluation set.
Frequently asked questions
How long should a prompt be?
Long enough to define the user, job, input, rules, output, and important constraints. Clear structure matters more than word count.
Can I make several changes in one prompt?
Small related changes can be combined, but changes to different systems are easier to test and recover when requested separately.
