How to Write Better AI Prompts

A four-part structure for prompts, and how to iterate when the first answer misses.

6 min read

Four parts that belong in almost every prompt

State the task precisely. "Improve this" gives the model no target; "rewrite this paragraph so a non-technical reader understands it, without losing the two figures" does.

Give the context the model cannot infer: who the audience is, where the text will appear, what has already been said.

Set constraints explicitly. Length, tone, reading level, what to avoid, what must be preserved verbatim.

Specify the output format. A numbered list, a table with named columns, JSON with named keys. Format instructions are followed reliably and save you reformatting afterwards.

Show rather than describe

One or two examples of the output you want will outperform three paragraphs describing it. Examples pin down tone, length and structure at once.

If you have a negative example, include it and say what is wrong with it. This is more useful than a list of prohibitions.

Iterate on one variable at a time

When the answer is wrong, resist rewriting the whole prompt. Change one thing, run it again, and observe the effect.

Keep the versions that worked. A short personal library of prompts that reliably produce what you need is worth more than any generic list.

Common mistakes

Asking several unrelated questions in one prompt. The model tends to answer the first well and the rest briefly. Split them.

Assuming shared context. The model does not know your company, your file, or the previous conversation unless you include it.

Accepting confident wrong answers. Ask for sources or reasoning when the answer matters, and verify anything factual.

Frequently asked questions

Tool for this

PromptHubBuild and refine prompts that produce usable output.

Open the PromptHub page

More in General AI & Prompts