Prompt Craft
The techniques that turn “sort of what I wanted” into “exactly what I needed”: roles, structure, examples, constraints, formats, planning and chains — with prompts you can copy and adapt today.
Imagine hiring a brilliant temp who has read half the internet but knows nothing about your company, your boss, your customers or what you did yesterday. Each morning they forget everything. Every instruction you give them has to carry all the context they need. That is roughly the position of an AI assistant when you open a new chat — and it is why the same model can look dazzling for one person and useless for another. Prompt engineering sounds technical, but at work it mostly means writing a good brief.
The anatomy of a strong prompt
The Novice prompting page introduced clear asks and iteration. At practitioner level, it helps to think of a prompt as having up to six parts. Not every task needs all of them, but when a result disappoints, one of these is usually missing.
- TaskWhat you want done, in one plain sentence, starting with a verb: summarise, draft, compare, rewrite, critique.
- ContextWhy it is needed, who it is for, what they already know, what has been tried.
- MaterialThe text, data or notes to work on — clearly separated from your instructions.
- ExamplesOne to three samples of the style, format or level you want.
- Constraints and success criteriaLength, tone, what to avoid, what must be included, and how you will judge the result.
- Output formatBullets, table, headed sections, email, JSON — spelled out.
Here is the difference in practice.
Context: We are a 60-person office. Staff can now carry up to 5 unused annual leave days into next year (previously 0). Many staff have asked about this, so the tone should be warm and clear, not legalistic.
Constraints: Under 150 words. Mention that carried-over days must be used by 31 March. No exclamation marks.
Format: A subject line, then the message in two short paragraphs, then one line telling people where to send questions (leave a placeholder [CONTACT]).
Roles and personas — useful, within limits
“You are an experienced HR manager…” is probably the most famous prompting trick. A role tells the model which register, vocabulary and priorities to adopt, and it is genuinely useful for style: a role as “a patient primary-school teacher” produces simpler explanations than “a professor of physics”.
Debated Whether a role makes the model more accurate is less clear. A 2024 study testing many personas across thousands of factual questions found that adding a persona did not reliably improve accuracy, and that which persona helped looked largely random. Declaring the model “a world-class lawyer” does not give it legal knowledge it lacks.
- Vendor guidance: Anthropic’s and Google’s prompting guides still recommend roles, mainly to set tone, focus and the level of detail.
- Sceptical researchers: the persona study above argues the benefit on factual tasks is small and unpredictable, so roles should not be relied on for correctness.
- Practical middle ground: describe the audience and purpose in detail; a role is a shortcut for that, not a substitute.
Structure: keep instructions and material apart
When you paste a long email thread and add “summarise this” at the end, the model has to guess where your instructions stop and the material begins. Clear separators — called delimiters — remove the guesswork. Three common styles work across assistants:
- Headings: lines such as
## Instructionsand## Text to summarise. - Fences: triple quotes or dashes around the material.
- XML-style tags:
<report> … </report>. Anthropic’s guidance recommends these, and they work well with other models too. The tag names are yours to invent; consistency is what matters.
<instructions>
- Group comments into at most 5 themes.
- For each theme give: a one-line description, how many comments mention it, and one short representative quote.
- Ignore comments that are only praise with no detail.
</instructions>
<feedback>
[paste anonymised comments here]
</feedback>
Structure also helps with prompt injection: if a pasted document contains a line such as “ignore previous instructions”, tags make it easier for the model to treat that as material rather than as your command. It reduces the risk; it does not remove it.
Show, don’t only tell: examples
Describing a style is hard; showing it is easy. Giving the model a few worked examples is called few-shot prompting, and the 2020 GPT-3 paper that popularised the term for prompting showed how strongly models pick up a pattern from a handful of demonstrations. Consensus All three major vendors’ guides list examples among the most effective techniques.
Example 1
Item: Steel water bottle, 750 ml
Line: Keeps drinks cold for 24 hours — light enough for the daily commute.
Example 2
Item: Canvas tote bag
Line: Carries a week’s groceries and folds into a pocket when you don’t.
Now write lines for:
1. Bamboo lunch box
2. Foldable umbrella
3. Desk plant in a ceramic pot
Two cautions. First, models copy examples closely — including their length and quirks — so vary them if you want variety. Second, if your examples share a hidden pattern (all positive, all about Kuala Lumpur), the outputs will too.
Constraints, success criteria and output formats
Constraints narrow the space of possible answers: word limits, reading level, what to leave out, which facts must stay unchanged. Success criteria go one step further and tell the model how the result will be judged — “a new staff member should be able to follow this without asking anyone” is a criterion the model can aim at.
State positively what you want, not only what you don’t. “Use plain sentences a secondary-school student can follow” works better than “don’t be too complicated”. And ask for a specific format — it is one of the cheapest ways to make output usable.
Best for comparisons. Name the columns yourself so you get the comparison you need, not the one the model guesses.
Best for skimmable summaries. Specify how many bullets, how long each is, and whether they should be full sentences.
Best when the result will be pasted into another tool or spreadsheet. Give the exact field names and an example record.
[{"task": "...", "owner": "...", "due": "YYYY-MM-DD or null"}]
If no owner is named, use null. Do not invent dates.
Best for documents. List the headings you want, in order, so the structure matches your organisation’s template.
Think first, then answer
For problems with several steps — a schedule with clashing constraints, a budget, a tricky decision — asking the model to reason before answering often improves the result. This is chain-of-thought prompting; a 2022 paper found that simply adding “Let’s think step by step” improved accuracy on many reasoning tasks.
Many assistants now include “reasoning” or “thinking” modes that do this automatically As of 2026. With those, the magic phrase matters less; what still helps is asking for a plan first so you can correct the approach before the model commits to it.
Before writing the schedule, list the constraints you see and propose how you will split the group. Wait for my OK before producing the full timetable.
Chains and reusable templates
Big jobs go better as a sequence of smaller prompts — prompt chaining. Each step produces something you can check before it feeds the next. Tap each step of this example chain for a 1,500-word proposal.
Once a prompt works, save it as a template with blanks in square brackets. Many assistants let you store these as saved prompts, custom instructions or project instructions — see Working with Context. For a set of ready-made templates to start from, see the Prompting Cheat Sheet.
Tone: [TONE]. Length: about [N] words.
Keep unchanged: [FACTS / NAMES / FIGURES].
Format: [FORMAT].
If anything is ambiguous, ask me up to 3 questions before writing.
<text>
[PASTE]
</text>
That last line — inviting questions — is one of the most underused tricks. It turns a guess into a short conversation.
What is the main benefit of wrapping pasted material in tags such as <report>…</report>?
Delimiters remove ambiguity about what is instruction and what is content. They do nothing for privacy.
You tell the model it is “a top tax expert”. What can you reasonably expect?
Roles shape register and focus; research suggests they do not reliably improve factual accuracy.
Few-shot prompting means…
Examples show the pattern you want; models imitate them closely.
Why break a long report into a prompt chain?
Chains keep you in control of the structure and make errors easier to catch early.
// Pause and reflect
- Think of the last AI answer that disappointed you. Which of the six parts — task, context, material, examples, constraints, format — was missing?
- Which recurring task at work or home would be worth turning into a saved template?
Your notes are saved privately in this browser.
Pick one real, non-confidential task you do every month (a status update, a newsletter item, a lesson summary). Write it as a one-line prompt and save the result. Then rewrite it using all six parts plus “ask me up to 3 questions first”. Compare the two outputs side by side, and save the better prompt in your prompt notebook as a template.
Key terms on this page
Sources & further reading
- Anthropic, Prompting best practices — clarity, examples, XML tags, roles, thinking and chaining (accessed 2026).
- OpenAI, Prompt engineering guide (accessed 2026).
- Google, Prompt design strategies, Gemini API documentation (accessed 2026).
- Brown, T. et al., “Language Models are Few-Shot Learners” (2020).
- Kojima, T. et al., “Large Language Models are Zero-Shot Reasoners” (2022) — the “Let’s think step by step” paper.
- Zheng, M. et al., “When ‘A Helpful Assistant’ Is Not Really Helpful: Personas in System Prompts Do Not Improve Performances of Large Language Models”, Findings of EMNLP (2024).