Basic prompting established task, context, and format. Zero-shot is the simplest pattern that uses those skills: give the model a clear instruction and ask it to perform the task with no labeled examples in the prompt.
Zero-shot is the baseline for Module 13.1. Later lectures add demonstrations (one-shot, few-shot) and reasoning scaffolds (chain-of-thought). Always measure zero-shot first so you know what the examples are buying.
Learning Objectives
By the end of this lesson, students should be able to:
- Define zero-shot prompting and contrast it with one-shot and few-shot.
- Write a zero-shot instruction that includes labels, format, and edge-case rules.
- Identify tasks where zero-shot is enough versus where examples are needed.
- Use label lists and output schemas to reduce free-form drift.
- Explain why model capability and instruction tuning affect zero-shot quality.
- Design a fair A/B comparison between zero-shot and few-shot on the same task.
Zero-shot prompting asks a model to perform a task using only natural-language instructions (and optional context), without including any input–output demonstration examples in the prompt.
What “Zero” Means
“Zero” refers to in-prompt demonstrations, not to the model’s pretraining. Modern instruction-tuned models have seen millions of tasks during training; zero-shot prompting activates that prior knowledge with a fresh instruction.
| Pattern | Demonstrations in prompt | Main lever |
|---|---|---|
| Zero-shot | 0 | Clear instruction + format |
| One-shot | 1 | Single worked example |
| Few-shot | 2+ | Pattern coverage via examples |
A Clean Zero-Shot Classifier
When Zero-Shot Works Well
Good fits
- Common NLP tasks (summarize, translate, extract).
- Clear label sets the model already “knows.”
- Formats the model follows from instructions alone.
Weak fits
- Idiosyncratic house style or schemas.
- Subtle decision boundaries between labels.
- Novel scoring rubrics with private meaning.
Tighten Zero-Shot Without Examples
Before jumping to demos, squeeze more from zero-shot: enumerate allowed outputs, forbid extras, and define ambiguity policy.
Strengths and Tradeoffs
Strengths
- Shortest prompts; lowest token cost.
- Fast to prototype and A/B test.
- No demo curation or leakage risk from examples.
Tradeoffs
- Weaker on niche formats and edge cases.
- Label wording can swing accuracy.
- Harder to convey rare decision rules.
“Zero-shot means the model never saw this task.” It means you provided no examples in this prompt. Instruction-tuned models often excel at zero-shot precisely because training already covered similar tasks.
Knowledge Check
- Short Answer: Define zero-shot prompting. Answer: Performing a task from instructions alone with no in-prompt demonstrations.
- True/False: Zero-shot means the model has never been trained on similar tasks. Answer: False.
- Multiple Choice: How many demos are in a zero-shot prompt? (a) 0, (b) 1, (c) 3–5. Answer: (a).
- Short Answer: Name one way to improve zero-shot without adding examples. Answer: Enumerate labels / fix output format / define ambiguity rules (any).
- True/False: You should usually measure zero-shot before adding few-shot demos. Answer: True.
- Multiple Choice: Zero-shot is often weakest for: (a) common summarization, (b) idiosyncratic private rubrics, (c) translating English to Spanish. Answer: (b).
- Short Answer: What should a classifier prompt request when unsure? Answer: An explicit fallback label such as other / unknown (as defined).
- True/False: Asking for “label only” can reduce formatting noise. Answer: True.
- Multiple Choice: After weak zero-shot on a custom schema, try next: (a) one/few-shot demos, (b) delete the schema, (c) random temperature 2.0 only. Answer: (a).
- Short Answer: Why is zero-shot cheap? Answer: No demonstration tokens; shorter prompts.
Key Takeaways
- Zero-shot = instructions + context, zero demonstrations.
- It is the baseline against which one-shot and few-shot gains are measured.
- Label lists and strict formats often unlock most of the available quality.
- Next: One Shot.
Hands-on idea: Run the same 20 tickets with (1) a vague zero-shot prompt and (2) a label-enumerated zero-shot prompt; score accuracy before adding any demos.
Discussion prompt: When is a bad zero-shot result a prompting problem versus a model-capability problem?
Recap: Zero-shot solves tasks from instructions alone and sets the Module 13.1 baseline. Continue with One Shot.