Claude Certified Associate · Foundations

Module 2 · Prompts that work the first time

Study notes written by Sanjay Shah. Not official Anthropic material. Facts marked "check before relying on it" may have changed.

Practice this module

On this page

Claude study notes · Claude at Work · Exam domain (guide v1.0): Prompting and Task Execution (14%) · Our own notes, written for this course.

Use with: checklist AF-C2 · Six-part prompt card · exercise AF-E2 · Repair three weak prompts · video script · sample prompts · practice questions

All companies, people, policies and invoices here are fictional sample data.


What you'll be able to do

  • Explain why short, vague prompts give generic or wrong answers.

  • Write a prompt with six parts: role, goal, context, constraints, format, example.

  • Know which parts matter most for writing, replies, data extraction and analysis.

  • Break a big task into steps: outline → draft one part → check what's missing.

  • Improve results by fixing the prompt, not the answer, and save the prompt for reuse.


Key ideas

1. Every gap gets a guess

Claude doesn't know where you work, what your policy says, who will read the output or how your team writes. When a prompt leaves those out, Claude doesn't stop. It fills each gap with a reasonable guess: a made-up company name, "as per company policy" with no clause, a tone your HR team would never use.

So a short prompt isn't a quick prompt. It's a prompt full of gaps. The job of a good prompt is to close the gaps that matter. Not every gap: the ones that decide whether you can use the result.

2. The six parts

#PartAsk yourselfExample (HR warning letter)
1RoleWho is writing, or what job is Claude doing?"You are the HR officer at Demo Traders Pvt. Ltd."
2GoalWhat exactly do I want at the end? One sentence."A first written warning to Ram Sample for repeated late arrival."
3ContextWhat facts does Claude not know?The attendance record, the policy clauses, the letter date, the reply deadline.
4ConstraintsWhat are the rules? Tone, length, must-include, must-not."Polite and factual. No threats. Quote dates exactly. Under 200 words."
5FormatWhat should it look like?"Our letter layout. [Placeholders] for anything not given."
6ExampleCan I show one?"Match the style of the attached older letter. Don't copy its facts."

Writing the parts as labelled blocks (ROLE:, GOAL:, CONTEXT: …) makes the prompt easy to check, easy to fix and easy to reuse. You don't need every part every time; you need the ones that close the important gaps.

3. Habits that make each part work

  • Numbers beat adjectives. "Under 200 words", not "be concise". "Reply by Tue 1 Dec", not "soon". A number can be checked; "concise" can't.

  • Upload or paste the source instead of describing it. Context is strongest when Claude reads the real record and the real policy.

  • Business rules come from the source, not from memory. Copy the rule from the policy into the constraints.

  • Work out facts yourself when a tool does it better. Deadlines, working days and totals belong to a calendar or a spreadsheet. Give Claude the answer.

  • Say what to do when something is missing. "If a date isn't given, write [ASK]." "If anything is unreadable, write UNCLEAR. Don't guess." Without this line, the gap gets a guess.

  • Give the reason behind a rule when it isn't obvious. "Put the action first, because parents read this on a phone" helps Claude apply the rule sensibly.

  • With an example, say what to copy and what not to. "Match its structure and tone; don't copy its facts."

4. Different tasks, different strongest parts

One prompt style doesn't fit every task. The prompt that writes a great email will ruin your spreadsheet.

Task typeStrongest partsWhy
Writing (letters, notices, posts)Role · Constraints · ExampleThe voice and the rules decide whether you can send it.
Replies (customers, staff)Context · ConstraintsWhat happened, what the policy allows, what you're offering.
Data (tables from documents)Format · ExampleExact columns and one finished row, or Claude picks its own.
Analysis (questions about data)Goal · ContextThe exact question, and the data to answer it from.

5. Break big tasks into steps

Ask for a whole new-joiner welcome pack in one prompt and you get something long and shallow. Break it up:

  1. Outline only. Headings and one line each.

  2. Draft one part at a time. "Now write only the first-week section, under 250 words."

  3. Check what's missing. "What would a new sales assistant need that isn't here?"

You stay in control at every step, and each answer is short enough to actually read and check. The same idea works for analysis: first "list the questions this data can answer", then answer one, then check.

6. Iterate: fix the prompt, not the answer

When the output is wrong, the tempting fix is to edit the letter by hand. Next week you'll fix the same thing again. Instead, find which part of the prompt caused the problem and fix it there. Then it's fixed for good.

Change one thing at a time so you can see what each change does. And when the prompt works, save it: a text file, a note, a snippet, or (Module 5) a Project's instructions. Next time you change only the name and the dates.

Even a six-part prompt can produce a wrong date or a wrong number. A good prompt makes good output more likely; it doesn't replace checking (Module 3).


Worked examples

These match the Module 2 video and the files in associate-m2/assets/.

Example 1 · The HR warning letter (writing)

Weak: "write a warning letter for late employee". The letter that comes back is correct English, but Claude has guessed the company, the policy ("as per company policy") and the tone (one line sounds like a threat).

Six parts:

Text
ROLE: You are the HR officer at Demo Traders Pvt. Ltd., a trading company.
GOAL: A first written warning to Ram Sample, sales assistant, for repeated late arrival.
CONTEXT: [attendance record: late on 16, 18, 22 and 24 Nov 2026] [attendance policy:
  clause 3.3, three late arrivals in a month means a first written warning;
  clause 3.4, five working days to reply]. Letter date: 25 Nov 2026.
  Reply deadline: Tue 1 Dec 2026.
CONSTRAINTS: Polite and factual. No threats, no guessing why he was late.
  Quote dates and clauses exactly. Mention the support we offer. Under 200 words.
FORMAT: Our letter layout: reference, date, PRIVATE AND CONFIDENTIAL, subject line.
  [Placeholders] for anything not given.
EXAMPLE: [older letter in our house style] Match its structure and tone.
  Don't copy its facts.

Note that the reply deadline was worked out with a calendar, not left to the chat. The result has the real company, the four dates, clause 3.3, the deadline, an offer of help and the house tone. It is still checked against the record and signed by a person in HR.

Example 2 · The customer complaint (reply)

Gita Example runs Sample Fancy Store on New Road, Kathmandu. Her order DT-ORD-5534 arrived four days late, after her weekend sale, and she had paid NPR 400 for fast delivery.

For a reply, context and constraints do the work. Version 1 of the prompt said "offer a 10% discount on her next order". Claude did exactly that. Version 2 changed one line: "offer a full refund of the NPR 400 delivery charge, as our policy says". The reply now promised a refund to her original payment method.

The lesson is in the policy: Customer Care may not offer discounts. The first prompt asked Claude to break the company's own rule, and it did what it was asked. The mistake was in the prompt. Constraints are where business rules go, and they come from the policy.

Example 3 · Invoice lines into a spreadsheet (data)

Supplier invoice DT-INV-1057 has eight lines. "Put this in a table" lets Claude choose the columns, maybe add a total row, maybe keep commas in numbers so the spreadsheet reads them as text.

Format and example win here:

  • FORMAT: exactly six columns in this order: line | item | quantity | unit | rate | amount. The unit goes in its own column (on the invoice it's hidden in brackets, like "(box of 50)").

  • EXAMPLE: row one, done for you.

  • CONSTRAINT: if anything is unreadable, write UNCLEAR. Don't guess.

One finished row shows the column order, number style and unit split better than a paragraph of rules. Pasted into the sheet, =SUM of the amount column gives NPR 36,700, matching the invoice, and the sum was done in the sheet, not in the chat.

Example 4 · Repairing "write a notice about exams"

The school office knows the classes (6 to 10), the exam fee (NPR 1,200 by Thursday 3 December 2026), admit cards (Friday 4 December), the reporting time (9:30 am), the holiday (Saturday 12 December) and the dates for each class. None of that is in the weak prompt, so Claude would invent dates, and a wrong date on a notice to every parent is the worst outcome. The strongest parts: context (all the facts) and constraints ("keep every date, time and amount exactly as given; do not add any; if something isn't given, write [ASK OFFICE]; action first; under 150 words").

Example 5 · "check this invoice" and "summary of meeting"

  • "check this invoice" leaves the biggest gap in the goal: check against what? The repair names the purchase order (DT-PO-2311), the line-by-line comparison and the exact columns of the weekly check sheet, and says "don't say whether to pay; a person decides". (The data has one real problem: line 7, correction pens, billed at NPR 75 against a PO rate of 70.)

  • "summary of meeting" leaves the goal and format open: a summary for whom? The repair says it's for the managing director, who wants decisions and actions; separates decisions from discussion; and asks for an actions table with owner and due date, writing [NOT SET] where the notes don't say. Without that, "Puja thinks new courier?" can turn into a decision, and the fact that the price list was not decided can disappear.


Common mistakes

  • Thinking a short prompt saves time. You pay for it in editing and re-asking.

  • Vague constraints ("be concise", "professional") instead of numbers and named rules.

  • Business rules from memory, like offering a discount the policy forbids.

  • Describing the source instead of uploading or pasting it.

  • No rule for missing information, so dates and names get invented.

  • Using the same prompt style for every task: tone-heavy prompts for data, or column rules for a letter.

  • One giant prompt for a big task, giving a long, shallow answer nobody reads closely.

  • Editing the answer instead of the prompt, so the same fix is needed every week.

  • Changing several parts at once and not knowing which change worked.

  • Trusting a good prompt instead of checking the output.


Remember

  • Every gap gets a guess: close the gaps that matter.

  • Six parts: role, goal, context, constraints, format, example.

  • Numbers beat adjectives: "under 200 words", "by Tue 1 Dec".

  • Rules come from the policy; dates and totals come from a calendar or spreadsheet.

  • Say what to do when something is missing: [ASK] or UNCLEAR.

  • Writing: role, constraints, example. Replies: context, constraints. Data: format, example.

  • Big task: outline → draft one part → ask what's missing.

  • Fix the prompt, not the answer, one change at a time, then save it.


Previous: Module 1 · Next: Module 3 · Check before you trust · Back to: course README

Our own notes, written for this course. Not taken from any official lesson.

↑ ↓ navigate · ↵ select · esc close