Lesson 711 of 1570
Few-Shot Prompting: Teaching AI by Showing Examples
Tell AI 'don't do it like this' with a real bad example, and it learns the line you're drawing.
Lesson map
What this lesson covers
Learning path
The main moves in order
- 1The big idea
- 2AI and Show Not Tell: Give Examples Instead of Adjectives
- 3The big idea
- 4AI and Anchor Examples: Show, Don't Tell
Concept cluster
Terms to connect while reading
Section 1
The big idea
Most people only show AI what they want. Pros also show what they don't want. A 'bad example' next to a 'good example' helps AI see the actual difference, not just guess.
Some examples
- 'GOOD: short and punchy. BAD: long and full of filler. Now write mine.'
- 'Don't write like THIS [boring sample]. Write like THIS [great sample].'
- Pair a cringe Instagram caption with a great one and ask for more like the great one.
- Show two emails — too formal vs. just right — and ask AI to match the right one.
Try it!
Pick a kind of writing you do (texts, captions, essays). Find one bad version and one good version. Paste both into AI with 'avoid the first, mimic the second.' Watch the quality jump.
Key terms in this lesson
Section 2
AI and Show Not Tell: Give Examples Instead of Adjectives
Section 3
The big idea
Adjectives like 'punchy' or 'professional' mean different things to different people. If you show AI an actual example of what you want, it can copy the pattern way better than guessing what your adjective means.
Some examples
- Bad: 'Write a punchy headline.' Better: paste 3 headlines you love.
- Show AI a sample email in your style, then say 'Now write one to my new boss.'
- Give AI a JSON shape and say 'Match this structure exactly.'
- Show AI two bad examples too: 'Avoid this style.'
Try it!
Pick a piece of writing you want help with. Find three examples you love and paste them. Then ask AI to make one in that style.
Section 4
AI and Anchor Examples: Show, Don't Tell
Section 5
The big idea
Telling AI 'be funny' is vague. Showing AI 3 jokes you love trains it instantly. Anchor examples make AI match your taste, your tone, your style.
Some examples
- Paste 3 emails you wrote, then ask AI to write one like them.
- Paste 5 captions from your favorite creator, then have AI mimic the rhythm.
- Paste 2 essays the teacher loved, then have AI copy that voice.
- Paste 3 product names you love before asking for new ones.
Try it!
Find 3 captions in your style. Use them as anchors and have AI write 5 new ones. Notice the match.
Section 6
Why 'Show Me an Example' Beats 'Make It Good' in ChatGPT
Section 7
The big idea
'Make it sound professional' is vague — every model has a different idea of professional. 'Make it sound like THIS [paste paragraph]' is concrete. Pasting one example you like is the single biggest prompting upgrade you can make. Pros call this 'few-shot' prompting. You can call it 'show, don't tell.'
Some examples
- Bad: 'Write a cold email.' Good: 'Write a cold email like this one: [paste]. Same length, same tone.'
- Bad: 'Make this caption fun.' Good: 'Caption like this Instagram post: [paste]. Use the same energy.'
- Bad: 'Write a summary.' Good: 'Summarize like this: [paste 2-line summary]. Match length and structure.'
- Bad: 'Format the README nicely.' Good: 'Format like this README: [paste link or content].'
Try it!
Pick a task you ask AI for often. Find one example you'd love to copy. Save it. Use it as your new template.
Section 8
Show, Don't Tell — Pasting an Example Beats Describing One
Section 9
The big idea
Telling AI 'write in a casual tone' is fuzzy. Pasting one sentence written in your tone is exact. Examples beat instructions every time when style or format matters.
Some examples
- You paste one tweet you wrote and ChatGPT matches your voice on the next 10.
- Claude gets one example of your bug-report format and produces 5 in the same shape.
- Showing one row of the JSON output you want fixes 90% of formatting issues.
- One sample test case teaches Cursor your testing style better than 'write Jest tests'.
Try it!
Next prompt where you describe a style or format, replace the description with one real example. Compare results.
Section 10
Show, Don't Tell: Examples Beat Adjectives in Prompts
Section 11
The big idea
models copy the shape of examples; they guess at adjectives
Some examples
- Pasting two real product descriptions you love
- Skipping the word professional and showing professional
- Letting the model match tone from samples
Try it!
Open your favorite AI tool and try one of the examples above. Pick the one that matches what you are actually working on this week. Spend 10 minutes, no more. Notice what worked and what did not — that's the real lesson.
Section 12
Few-shot: show, don't just tell
Section 13
The big idea
Few-shot prompting puts example input/output pairs in your prompt so the model learns your exact format.
Some examples
- Give 2-3 examples (more isn't always better).
- Make examples cover variety, not just easy cases.
- Put your real input AFTER the examples.
Try it!
Need AI to format something a specific way? Give it 3 examples and watch it match.
Understanding "Few-shot: show, don't just tell" in practice: Prompting is a skill: the more specific and structured your input, the more useful the output. Show AI 2-3 examples of what you want and it nails the pattern — and knowing how to apply this gives you a concrete advantage.
- Use role, context, task, and format in every prompt
- Iterate: treat first outputs as drafts, not finals
- Use few-shot examples for complex formatting tasks
- Test prompts at different temperatures for creative vs. factual tasks
- 1Rewrite one of your best prompts using role + context + task + format
- 2Ask an AI to critique your prompt and suggest improvements
- 3Compare outputs from two models using the same prompt
Section 14
AI and Examples Beat Instructions: Show, Don't Tell
Section 15
The big idea
AI imitates what it sees. One good example beats five rules. Two beat ten. Most teens write rules; the few who paste examples ship better work in half the time.
Some examples
- Ask Claude to write in your voice — but paste 3 paragraphs you actually wrote first.
- Ask ChatGPT for an Instagram caption — paste 5 captions you love before asking.
- Ask Gemini to format a study guide — show one of yours from last semester.
- Ask Perplexity for related research — paste the abstract of the paper you already love.
Try it!
Take your next prompt. Add three examples of what good looks like before you ask. Notice the jump.
End-of-lesson quiz
Check what stuck
15 questions · Score saves to your progress.
Tutor
Curious about “Few-Shot Prompting: Teaching AI by Showing Examples”?
Ask anything about this lesson. I’ll answer using just what you’re reading — short, friendly, grounded.
Progress saved locally in this browser. Sign in to sync across devices.
Related lessons
Keep going
Explorers · 40 min
Show AI What You Mean: Examples and Demonstrations
AI works MUCH better when you show it an example of what you want..
Builders · 40 min
Output Format Control: JSON, Tables, Schemas, and Structure
Tell AI the shape of the answer (table, bullets, JSON) and you stop wasting time reformatting.
Creators · 40 min
Few-Shot Example Curation: Quality, Rotation, and Counter-Examples, Part 1
Chain-of-thought prompts show real performance gains on reasoning tasks — and zero benefit on tasks that don't need reasoning. Here's how to tell which is which.
