- In short
- A well-specified prompt is built from up to five recurring components: role (the professional lens Claude should adopt), context (the background it cannot infer), task (the single unambiguous instruction verb), constraints (the boundaries on length, tone, and content), and output format (the shape of the result). Not every prompt needs all five, but naming them turns prompting from guesswork into a checklist you run before sending a request.
Why the same request produces two different results
Ask Claude to write something about your quarterly results and you get a plausible paragraph that could describe almost any company. Specify who will read it, which three figures matter, the format, and the length, and you get a draft you can nearly send as-is. The model did not get smarter between those two requests. The specification changed. The Claude Certified Associate - Foundations (CCAO-F) exam opens its prompting section here because consistent output quality comes from structure, not from cleverness or luck.
That structure has a name in Anthropic's AI Fluency Framework: Description, the competency of telling Claude precisely what you want. This first knowledge point is a remember-level skill: you need to know the five components exist, what each one controls, and that a strong prompt is usually built from a deliberate selection of them rather than a single sentence of hope.
- The five-component prompt structure
- The set of up to five recurring components that carry almost every professional prompt: role (the professional lens Claude adopts), context (the background it cannot infer), task (the single unambiguous instruction verb), constraints (the boundaries on length, tone, inclusions and exclusions), and output format (the shape of the result). Not every prompt needs all five.
What each component controls
The five components each govern a different aspect of the response, and naming them is what lets you reason about a prompt instead of guessing.
Role tells Claude which professional lens to adopt: a financial analyst, an editor, a policy reviewer. That choice sets the vocabulary, the depth of reasoning, and the assumptions Claude brings to the work. Context is the background Claude cannot know unless you supply it: the audience, the situation, prior decisions, the source material. Task is the specific action, stated as one clear instruction verb - summarise, compare, draft, identify - so there is no ambiguity about what to do. Constraints are the boundaries: length, tone, what to include and what to leave out. Output format is the shape of the result: a table, a bulleted list, a short memo, a draft email.
Two of these are easy to conflate, and the exam knows it. Role and task feel similar but do opposite jobs. Role shapes how the answer reads; task determines what the answer does. A prompt that assigns a role but never states the action leaves Claude to guess at the deliverable, while a prompt with a sharp task but no role gets the right action in the wrong register.
Not every prompt needs all five
The five components are a palette, not a mandatory checklist. A quick factual question needs a task and maybe a single constraint - asking for all five would be noise. A client-facing deliverable, by contrast, usually needs every one of them, because each unstated component becomes a place where Claude has to guess and often guesses wrong.
The real skill this knowledge point builds is noticing which components a given task requires. That judgement is what separates a thirty-second specification habit from a rigid template applied everywhere. You are not trying to maximise the number of components; you are trying to make explicit exactly the things Claude cannot infer for this particular request.
What the CCAO-F exam trips candidates on
Two traps recur on this knowledge point, and both come from misreading how the components relate.
The first is assuming every prompt must include all five components regardless of how simple the request is. A scenario will present a short factual question and a padded prompt that bolts on a role, elaborate context, and a format specification the task never needed. The credited reading is that specification should match what the task actually requires - over-specifying a trivial request adds friction without adding quality.
The second is treating role and task as interchangeable. A distractor will "fix" a weak prompt by adding a grander role when the real gap was an ambiguous or missing task verb, or vice versa. The reliable move is to keep the two functions distinct in your mind: role controls tone and depth, task controls the action. When output does the wrong thing, that is a task problem; when it does the right thing in the wrong voice, that is a role problem.
Worked example
A new user sends 'Write something about our product launch' and gets a generic three-paragraph blurb. Using the five components, which parts of the prompt were left implicit, and how would you name the fix?
Run the prompt against the five components one by one. There is a task of sorts - "write something" - but the verb is vague, so even the action is under-specified. There is no role, so Claude has no vocabulary or depth signal. There is no context: no audience, no product details, no sense of what makes this launch worth announcing. There are no constraints on length or tone, and no output format, so Claude defaults to a middle-of-the-road blurb.
The diagnosis is not that the model is weak; it is that four of the five components were left implicit. Naming them gives you the repair directly: assign a role (say, a product marketer), supply context (the audience, the one feature that matters, the channel), sharpen the task ("draft an announcement"), add constraints (length and tone), and state the output format. You do not need to add all five in every case, but here the request is a professional deliverable, so it earns all of them. The point of the exercise is that the fix is legible the moment you hold the prompt against the component stack.
Common misreadings to avoid
Misconception
A good prompt always includes all five components, so longer and more structured is always better.
What's actually true
Misconception
Role and task are basically the same thing - either one tells Claude what to produce.
What's actually true
How this shows up on the exam
Domain 1 questions on this knowledge point show a weak prompt and ask you to name what is missing, or present a padded prompt and ask whether the extra structure actually helps. The reliable frame is the five-component stack: identify which components are present, which are absent, and whether the task genuinely needs the ones that were added.
This is the foundation the rest of the prompting domain builds on. It leads directly into context as the most commonly omitted component, which explains why context is the one professionals forget most often, and into role framing for vocabulary, depth, and assumptions and constraints and output format as usability levers, which unpack the individual components. Once you can name the stack, you can diagnose a weak prompt against it.
A colleague asks Claude 'What is the capital of France?' but wraps it in an assigned expert role, two paragraphs of context, and a required table format. The answer is correct but the effort feels disproportionate. What is the most accurate assessment?
People also ask
What are the five components of a prompt?
Does every prompt need all five components?
What is the difference between role and task in a prompt?
Watch and learn
Official Anthropic Academy lessons first, then hand-picked walkthroughs. Videos load only when you press play.
No videos curated for this concept yet
We are still curating the best official and community videos for this topic.
Official prep for this domain
Anthropic's own free prep module for this part of the syllabus, on the official prep course. Free with an Anthropic Academy sign-in.
References & primary sources
Master this concept with Archie
Practice it inside an adaptive study session. Archie, your Socratic AI tutor, tracks your mastery with Bayesian Knowledge Tracing and schedules the perfect next review.