20 prompt engineering examples, before and after
The gap between a prompt that disappoints and one that works is usually two sentences of context and one constraint. Here are twenty pairs — the version people actually type, and the version that gets a useful answer — with what changed named each time.
How to read these
Every pair below is the same request twice: the version people actually type, and the version that gets a useful answer. Under each one is a single line naming what changed, because the point is not to collect twenty prompts — it is to see the same four or five moves applied twenty times until they become automatic.
Those moves are the subject of the complete guide to prompt engineering: give the model a role, the context it cannot infer, one specific task, real constraints, and the format you want back. Watch for them below.
Email and messages
1. Declining a meeting
write an email declining a meeting
Write a short reply declining a 90-minute workshop invitation from a client I want to keep. I am declining because the agenda is not something my team can affect, not because I am busy. Offer one alternative: a 20-minute call with whoever owns the decision. Warm but not apologetic, under 80 words, no exclamation marks.
2. Chasing an unpaid invoice
follow up on an invoice politely
Write a second follow-up on a €4,200 invoice that is 18 days overdue. This is a client we have worked with for two years and want to keep, and the first reminder got no reply. Firm, not passive-aggressive, no threat of escalation yet. Ask one direct question that needs an answer. Under 90 words.
3. Asking a colleague to redo something
help me tell someone their work needs redoing
Draft a Slack message to a designer on my team. The screens they delivered solve a different problem than the brief — good work, wrong problem, which is partly my fault for a vague brief. I need them redone this week. Take responsibility for the brief, be specific about what is wrong, do not soften it into ambiguity. Four sentences maximum.
4. Telling a customer about a delay
write an apology for a delay
Write an in-app message telling users that a feature we announced for March is slipping to May. Reason: we found a data-loss bug in testing and will not ship around it. Audience: people who have been waiting and have said so publicly. Lead with the new date, give the real reason in one sentence, no corporate hedging, no "we appreciate your patience". Under 70 words.
Writing and editing
5. Cutting a paragraph down
make this shorter
Cut the paragraph below by about half. Keep every fact and every number. Cut adverbs, hedges and any sentence that restates the one before it. Do not change my vocabulary for something more formal, and keep the contractions. Show the cut version only.
6. Making a bio sound like a person
write my linkedin bio, im a backend developer
Write a LinkedIn summary for me. Backend developer, 6 years, mostly Go and Postgres, currently on payments infrastructure at a mid-size fintech. The thing I am actually good at is making slow systems fast and boring. Audience: hiring managers, not recruiters. First person, three short paragraphs, no "passionate", no "results-driven", one concrete example rather than a list of adjectives.
7. Turning notes into something readable
clean up these meeting notes
Below are my raw notes from a customer call. Turn them into a summary for colleagues who were not there. Structure: what they want, what they are currently doing instead, what would have to be true for them to switch, and open questions. Do not add anything that is not in the notes — if something is unclear, list it under open questions rather than guessing.
Research and learning
8. Explaining something at the right level
explain kubernetes
Explain what Kubernetes actually does to a backend developer who has shipped services with Docker Compose and has never used an orchestrator. Start from the problem it solves, not the architecture. Use one running example. Skip anything I would only need at 50+ services. Under 400 words.
9. Comparing two options
postgres vs mongodb which is better
We are building an appointment-booking product: heavy relational reads, strong consistency requirements, a two-person team with SQL experience and no NoSQL experience. Compare Postgres and MongoDB for this specific case as a table — data model fit, consistency, operational burden for two people, hiring. Then recommend one in two sentences and name the strongest argument against your pick.
10. Getting a study plan you will follow
help me learn spanish
Build me a 12-week Spanish plan. Starting point: I can read menus and understand slow speech, I freeze when I have to speak. 30 minutes on weekdays, an hour on Sunday. Goal: hold a 10-minute conversation with my partner's family at Christmas without switching to English. Weight it heavily toward speaking. Give me week 1 in full detail and the other 11 as one line each.
Planning and decisions
11. Weighing a real decision
should I take the job offer
Help me think through a job offer. Current: senior dev, stable, bored, good team. Offer: staff role at a 30-person startup, 15% more, 18 months of runway, a manager I liked in interview. I have a mortgage and no other dependents. List what I should find out before deciding that I probably have not asked, then the two strongest arguments for each side. Do not recommend — I want the questions, not the answer.
12. Preparing for a difficult conversation
how do I ask for a raise
Prepare me for a raise conversation. I am 20% below market for my role by two salary surveys, I have been here three years, and I led the migration that cut our infrastructure bill by a third. My manager is supportive but does not control budget. Give me: an opening line, the two objections I am most likely to hear with a response to each, and the sentence I should not say.
13. Turning a goal into a week
help me be more productive
I want to ship a side project that currently has no users. I have about 8 hours a week, spread over weekday evenings. The failure pattern is that I rebuild the landing page instead of talking to anyone. Give me one week of concrete tasks with hours attached, weighted toward the thing I am avoiding, and one rule to stop the avoidance.
Code
14. Debugging
why is my code slow
This endpoint takes 4 seconds on a list of ~2,000 rows and under 100ms on 50 rows. Postgres, Go, no caching layer. I have already checked that the index on user_id is being used. Give me the three most likely causes in order of probability given that scaling shape, and for each one the exact thing I should measure to confirm or rule it out. Do not rewrite the code yet.
15. Getting a real code review
review my code
Review the function below as if it were a pull request from a colleague you respect. Priorities in order: correctness under concurrent calls, then error handling, then readability. Ignore style and naming. For each issue give the line, what breaks, and a concrete input that triggers it. If nothing is actually wrong, say so instead of finding something.
16. Writing tests worth having
write unit tests for this function
Write table-driven tests for the function below. Cover: the empty input, a single element, duplicate keys, and a value at the boundary of the length cap. Skip the happy path with three normal items — that one never catches anything. Use the standard library only, and name each case after the behaviour it pins, not after its inputs.
Images and music
17. A portrait that looks intentional
a portrait of a woman
Weathered fisherwoman in her sixties on a harbour wall at first light, salt-crusted oilskins, deep laugh lines, looking past the camera, overcast north-Atlantic light, shallow depth of field, 85mm portrait photograph, muted blues and rust --ar 4:5 --stylize 250
18. A product shot
photo of a coffee bag for my shop
Matte kraft coffee bag standing on pale oak, front label facing camera, scattered whole beans, soft window light from the left, single soft shadow, clean minimal styling, shallow depth of field, commercial product photograph --ar 1:1 --style raw
19. An image that has to contain words
poster that says grand opening
Vintage letterpress poster, the words "GRAND OPENING" in large condensed serif capitals across the upper third, "Saturday 14th" beneath in a smaller sans, cream paper with visible texture, two-colour print in deep red and black, subtle ink misregistration --ar 2:3
20. A track that sounds like the one in your head
sad piano song
Style: melancholic neo-classical piano, close-mic'd felt piano, faint room noise, sparse cello underneath, no drums, rubato, 62 BPM, intimate and unresolved. Lyrics with structure tags: [Intro] [Verse] [Chorus] [Bridge] [Outro]
What all twenty have in common
Read the "after" column on its own and the same handful of moves keep reappearing:
- One specific detail nobody else would have. The €4,200 invoice, the 18 days, "slow systems fast and boring". Specifics are what make an answer yours rather than generic.
- The reader, named. Half of these prompts fail only because the model does not know who is reading.
- A constraint on what not to do. No "we appreciate your patience", no adverbs, do not rewrite the code yet, do not recommend. Negative constraints are the most under-used instruction there is.
- Permission to say nothing. "If nothing is wrong, say so", "list it as an open question rather than guessing". Models fill gaps confidently unless given somewhere else to put uncertainty.
- A stated shape. A table, four sentences, week 1 in detail and the rest in one line each. Naming the format removes an entire round of asking again.
None of that requires memorising a framework. It requires noticing, before you send, that you have described the task and not the situation.
Twenty examples, or one key
Prompt AI Keyboard does this to whatever you have already typed — role, context, constraints and format, built for the tool you are writing to — without leaving the app you are typing in. It also fixes grammar, changes tone, translates and types what you say out loud.
FAQ
What makes a good prompt example?
One that shows the same request twice and names what changed. A prompt on its own is a template you will not adapt; a before-and-after pair teaches the move, which transfers to your own work.
What do the best prompts have in common?
One specific detail nobody else would have, the reader named explicitly, at least one constraint on what not to do, permission to say nothing rather than invent, and a stated output shape. Most weak prompts describe the task and skip the situation.
Do these prompt examples work in ChatGPT, Claude and Gemini?
Yes — everything here is model-agnostic, because the five ingredients are. The per-model differences sit on top: Claude rewards heavier structure, Gemini rewards very long inputs and an explicitly named output format, and image and music models want dense descriptive phrases rather than sentences.