Writing a Good Brief

How to write a brief for a larger AI task: the goal, the context, the constraints and the definition of done, and what goes wrong when one is missing.

11 minLesson 3 of 7
On this page
  1. The four parts of a brief
  2. Example: a brief for a newsletter analysis
  3. Specific mistakes when writing a brief
  4. How a brief changes what you do
  5. Check yourself
  6. What to practise next

A brief is the written instruction you give an AI assistant for a larger task, such as research, a document or a change across a codebase, where the model makes many decisions without checking with you. A good brief has four parts: the goal, the context, the constraints and the definition of done. It matters because the model cannot ask what you meant, so every question you leave unanswered is settled by a guess.

With a one-line request, the model picks a purpose, an audience, a length and a stopping point for you. If the task takes many steps, each wrong guess shapes the steps after it, and you may only notice when the whole result is wrong. A brief is a prompt (see Prompting Basics) that is written for this situation.

The four parts of a brief

A useful test for a brief is to ask which questions a capable contractor would ask before starting, and to answer those questions in writing. The four parts below cover most of them.

Goal

The goal states the outcome you want and what you will use it for. "Decide by Friday whether to revert the new subject-line style" is a goal. "Look into the newsletter numbers" is only a topic. Knowing the purpose lets the model choose between a long report and a one-line verdict, and lets it notice when a detail does not matter for your decision. Put the goal first, so that everything after it is read in light of it.

Context

The context is whatever the model cannot find out on its own: the data to use, who will read the result, what you have already tried, and what else changed recently. The last item is the one people forget most often. Models tend to blame the only cause they were told about, so a change you leave out of the context is a change they cannot consider. Include only the context the task needs; a long history with no stated goal makes the model guess which parts matter (see Context Engineering).

Constraints

Constraints say what the model must and must not do: which sources to use, which files it may change, how long the answer may be. Give the reason with each constraint. A rule such as "only change src/billing" covers the case you thought of. A rule with its reason, "because another team is releasing from src/checkout this week", also tells the model what to do in a case you did not think of, which is to report a checkout bug and leave it alone.

Definition of done

The definition of done says what to hand back, in what form and how long, and what to do if the task cannot be completed. Without it, the model stops after the first plausible result, or keeps going far beyond what you wanted. Always say what a valid failure looks like, such as "say that the data cannot decide". If you do not, the model is pushed to produce a confident answer even when the evidence does not support one.

Example: a brief for a newsletter analysis

The example is a newsletter whose open rate dropped. The tracer shows how each part of the brief closes some of the questions the model would otherwise answer by guessing.

Building a brief, one part at a timeUse the arrows or ← → keys
  1. questions
    0why?
    1for whom?
    2data?
    3other changes?
    4limits?
    5how long?
    6hand back?
    open questions
    7
    brief parts
    0

    1The one-line request leaves all seven questions open, and the model will answer each of them with a guess.

  2. questions
    0why?
    1for whom?
    2data?
    3other changes?
    4limits?
    5how long?
    6hand back?
    open questions
    5
    brief parts
    1

    2The goal says to decide by Friday whether to revert the subject-line style, for the editor. That answers why and for whom.

  3. questions
    0why?
    1for whom?
    2data?
    3other changes?
    4limits?
    5how long?
    6hand back?
    open questions
    3
    brief parts
    2

    3The context names the last 20 sends and says that the send time also moved from 9am to 7am. Without the second fact, the model would blame the subject lines.

  4. questions
    0why?
    1for whom?
    2data?
    3other changes?
    4limits?
    5how long?
    6hand back?
    open questions
    2
    brief parts
    3

    4The constraints say to use only the attached data and to give no general advice, which closes the question of limits.

  5. questions
    0why?
    1for whom?
    2data?
    3other changes?
    4limits?
    5how long?
    6hand back?
    open questions
    0
    brief parts
    4

    5The definition of done asks for under 200 words, a verdict, its numbers, and a plain statement if the data cannot decide. Nothing is left to guess.

1 / 5

The first prompt below is the one-line request. The second is the full brief with the four parts labelled.

One-line requestIllustrative example. Real replies vary.
You
Find out why our newsletter open rate dropped.
Model
Open rates usually drop for one of a few reasons: 1. Deliverability: emails may be landing in spam folders... 2. List fatigue: subscribers may be getting too many emails... 3. Subject lines: weaker subject lines can reduce opens... I recommend reviewing your sender reputation and segmenting your list...
BriefIllustrative example. Real replies vary.
You
Goal: our newsletter open rate has fallen from about 41% to 32% over the last four sends. I need to decide by Friday whether to revert the new subject-line style we started on 2 September. I will forward your answer to our editor. Context: the attached CSV has the last 20 sends (date, subject line, recipients, opens). Two weeks after the subject change, we also moved the send time from 9am to 7am. Nothing else changed that we know of. Constraints: use only the attached data. No general email-marketing advice. Done: under 200 words. Start with one of: revert, keep, or can't tell. Then give the two or three numbers that support it. If the data cannot separate the subject change from the send-time change, say so plainly and suggest the smallest test that would.
Model
Can't tell yet, but the send time looks more likely. - The two sends after the subject change, still at 9am, had open rates of 40% and 39%, close to the earlier average of 41%. - The drop starts with the first 7am send: 34%, then 32%. - The timing matches the send-time change, but two sends on each side is too few to be sure. Smallest test: next week, split the list in half. Send the new-style subject to both halves, one half at 9am and the other at 7am. Compare open rates.

The first reply is a generic list of causes, because the request gave the model nothing specific to work on. The second reply is short because the brief said what to leave out. It is also correct about the likely cause because the brief included the send-time change, which the model could not have known. You can verify it quickly, since every claim in it is a number in the CSV.

Specific mistakes when writing a brief

How a brief changes what you do

Write the four parts as four short labelled paragraphs, as in the example above. The labels make it obvious when a part is missing, and a model reads them as clearly as a person does. For work that can do damage, such as editing files or sending messages, ask for a plan first and approve it before the model acts (see Coding With AI). A plan costs a minute to read and shows you the model's guesses before they become changes.

When a result comes back wrong, read it as a list of the questions your brief left open and add the missing answers, rather than only asking the model to try again. If the same task will be repeated, keep the improved brief and reuse it.

Try it: Brief a coding agent

With the request below, a coding assistant renamed dozens of functions, deleted two files it thought were unused (one of them was not), and reformatted everything. Rewrite the request as a brief with a goal, context, constraints and a definition of done.

Show a sample answer
Rewritten briefIllustrative example. Real replies vary.
You
Goal: utils/ has grown messy and new teammates cannot find things. I want it easier to navigate, without changing how anything behaves. Context: utils/dates.js and utils/format.js overlap; both have date-formatting helpers. Some helpers in utils/ are used by the mobile app, which lives in a separate repository, so "no callers here" does not mean unused. Constraints: do not delete any file or exported function. Do not rename exports. Do not reformat code you are not otherwise changing. Keep each change small enough to review on its own. Done: first, reply with a plan only: which helpers overlap, and what you would merge or move. Wait for my approval. After I approve, make the changes, run npm test, and give me a list of every function that moved and where it went.

The context contains the fact that made the first run destructive, which is that another repository uses this code. The constraints rule out the deletions, renames and reformatting. The definition of done asks for a plan first and then waits, which gives you a checkpoint before anything changes.

Check yourself

Quick check

Which line is a definition of done?

In the newsletter brief, which part mattered most for getting a useful answer?

Why give the reason for a rule such as "do not touch src/checkout"?

What to practise next

Before your next long AI task, write the four parts as four short labelled paragraphs and send that instead of a single line. Then continue with Learning With AI, where the goal of the work is your own understanding.