A well-formed AI response can still make the wrong decision. Prompt Engineering: 30 Essential Techniques is a free, 30-page illustrated PDF that shows how to write a clear prompt, provide the right context, and check the answer before relying on it. It follows one fictional case from the first task brief to a set of repeatable checks.
Start with a task you can check
Instead of asking an AI assistant to “handle the inbox,” specify what it can read, what decision it should make, and where it must stop. At the fictional Elm Reading Room, request R-17 belongs in the booking queue, but the input does not confirm room availability. A useful draft asks the scheduling desk to check. It does not promise a time or make a reservation. The G2 source supports routing to the desk, not a claim that the room is free at 10:00.
Separate the response format from the decision
Start by checking that the expected fields are present and have the right types. Then read the category and next step, and ask whether each cited source supports the claim beside it. One page shows a response with a valid format, a wrong category, and evidence IDs that still pass the checklist. It is a concrete example of why a schema is not a fact-check.
The guide also explains how to handle gaps in the input, write short examples with contrasting outcomes, change one prompt instruction at a time, and compare versions on the same cases. When you are ready to work on which information reaches the model in the first place, try Context Engineering: Beyond Prompt Engineering. For a related developer review workflow, see Agentic Software Engineering.
Run the Elm Reading Room practice lab
Extract the companion ZIP, open its folder in a terminal, and run python3 -B -m unittest -v. All nine unit tests passed locally. Try replacing a category with a different valid category, adding an unknown source ID, or inserting a date not present in the case. The illustrated guide discusses missing availability broadly; the companion narrows that idea to an availability_date field. The lab tests deterministic fixtures, not model performance. It cannot send anything or make a reservation.
Download the companion practice files
The optional practice archive contains the project files described in this handbook.
Frequently asked questions
Who is this prompt engineering book for?
Anyone who writes or reviews AI instructions for recurring tasks. No coding is needed to follow the illustrated examples; Python is only needed for the optional lab.
How many pages and techniques does it include?
The PDF has 30 pages with bookmarks. It covers 30 techniques, with some pages pairing two related techniques and the final page collecting the lab command and reference links.
Do I need an AI account or an API key?
No. The examples can be read without an account. The optional lab uses the Python standard library and runs without a model, credentials, or a network connection.
What does the practice archive contain?
It contains the Elm Reading Room checker, the fictional test cases, and a short README. A copy is embedded in the PDF for readers that support attachments.
Can the lab tell me whether my model’s answer is true?
No. It checks expected field types, decisions and a limited set of evidence values for the supplied fixtures. Human review is still needed to decide whether a source supports a claim.