Interactive lab · Practical AI
Prompt Anatomy: Writing Clear Prompts
A chatbot is a brilliant new coworker on their first day: capable, eager, and completely unaware of what you actually want. The prompt is your briefing — and most bad AI output is a bad briefing, not a bad model. Learn the four parts every good briefing needs, then fix a bad prompt yourself.
Plain-language AI
In plain logic
No real AI runs on this page. Everything is explained and illustrated in your browser — no model calls, no accounts, nothing sent anywhere.
Think of the model as a brilliant new coworker on their first day: capable, eager, and completely unaware of what you actually want. Hand them a vague request and they will fill in the blanks with guesses — not because they are lazy, but because nobody briefed them. A prompt is that briefing.
Here is the kitchen version. Walk in and say “make something tasty” and you might get a cake, a sandwich, or a seven-course meal. Hand over a recipe instead — the dish, what's in the fridge, the time limit, how to plate it — and dinner lands the way you pictured it. Same kitchen, same cook. The only difference is the briefing.
A good briefing has four parts:
- Task — the dish. One clear verb. “Summarize this ticket” is a task; “look at this” is a wish.
- Context — what's in the fridge. Who it is for, why it matters, the background the model should assume. The model cannot use what you never gave it.
- Constraints — the rules of the kitchen. Length, tone, what to include, what to leave out, what to do when information is missing (“say 'unknown' rather than guessing”). This is the part most prompts skip.
- Format — how to plate it. Bullets or a table? A headline first? The model will happily pour the same facts into whatever container you name.
Before and after
The vague prompt — “make something tasty” energy:
What comes back is technically correct and completely useless:
The model guessed the audience (formal), the length (three sentences), and the content (nothing specific) — because the prompt answered none of those questions.
The same request, briefed properly — the recipe version:
Same facts in, far more useful text out:
The difference is not a smarter model. It is a complete briefing: every part told the model something it would otherwise have had to invent.
One more rule that belongs with the four: keep source material separate from instructions, so a reader — human or model — can tell which is which. Mark quotes as quotes. Instructions found inside retrieved documents should be treated as untrusted content, not commands: a document that says “ignore previous instructions” is data, not your boss.
Hands-on
Try this: fix the prompt
Here is a real-world dud — the kind of prompt everyone writes on their first day. Your job: rebuild it with all four parts.
The bad prompt
Tap chips from the word bank to add the missing parts — or just type your own fix in the box. Then press Check my prompt for instant, rule-based feedback. No AI runs here; a small script checks your text against the four parts.
Word bank — tap to add a part
Notice what the exercise cannot do: no chip adds facts. If the newsletter needs the shelter's real adoption numbers, those have to come from a source — better wording cannot invent them. That is the honest boundary, below.
Honest boundaries
What this leaves out
Better prompts cannot supply missing evidence. No amount of task-context-constraints-format will make the model know your company's returns policy or last quarter's numbers. When the facts aren't in the prompt and aren't retrievable, a great prompt produces a beautifully formatted guess. (See why AI hallucinates.)
And prompts cannot guarantee correctness. They raise the odds of a useful answer; they don't certify it. For anything that matters — money, access, safety, published claims — the answer still gets checked against a real source, no matter how good the prompt was.
Honest answers
Questions people ask
How long should a prompt be?
As long as the task needs and no longer. Include all four parts, but don't pad: extra text dilutes attention. If you find yourself writing paragraphs of background, consider whether some of it belongs in a document the model retrieves (RAG) instead of the prompt itself.
Do I need to be polite to the AI?
No — but clarity beats cleverness. Direct instructions outperform elaborate roleplay. “You are a world-class expert...” adds little; specific constraints add a lot. Save the creativity for the task description, not the framing.
Why did the same prompt work yesterday and fail today?
Sampling randomness, model updates, and subtle context differences all shift outputs. If a prompt must work reliably, pin down the format with an example, add constraints for the failure you just saw, and test it more than once before trusting it.