Few-shot examples
For both
Showing instead of telling: choosing varied, correct examples and marking them clearly
110 questions across four stages: Understand, Apply, Solve and Judge.
Try 5 questions
Practice items, not counted towards your mastery. No account needed.
Check yourself · 1 of 5
What does few-shot prompting mean?
Check yourself · 2 of 5
You are building examples for a ticket sorter. Which set is best?
Check yourself · 3 of 5
A prompt gives the right answers but in a long paragraph, when you want one word. What is the best next step?
Check yourself · 4 of 5
All five replies from your prompt begin with the same unusual phrase that appeared in your one example. What is the most likely cause?
Check yourself · 5 of 5
Why should the real input come last, after a marker such as "Now do this one:"?
Topics
- Why examples beat descriptions3 min read · One good example shows format, tone and edge cases that a paragraph of description leaves vague
- Choosing varied, realistic examples4 min read · Covering the range of real inputs, including one hard case, with outputs you have checked are correct
- Deciding how many examples to give3 min read · Starting with none, adding one to three when the output drifts, and when many examples stop helping
- Example copying and answer leakage4 min read · Models copy an example's wording, length and topic, over-fit to one pattern or leak answers into test cases
- Marking examples apart from the input4 min read · Wrapping examples in labels, tags or message pairs so the model does not answer the example instead of the task
Start here
- Prompting best practices (Claude docs) (opens in a new tab)DocsFree
Anthropic's guide; its section on examples covers relevance, variety and wrapping examples in tags.
- Few-shot prompting (Prompt Engineering Guide) (opens in a new tab)ArticleFree
A short walk-through of one-shot and few-shot prompts with worked examples and their limits.
- Language Models are Few-Shot Learners (GPT-3) (opens in a new tab)PaperFree
The GPT-3 paper that named few-shot prompting; read the abstract and introduction for the idea.
Scenarios
Helps to know first
110 questions · last verified 2026-12