Zero-shot prompting asks the model to perform a task using only the task description — no examples provided. Modern frontier models (GPT-4o, Claude Sonnet, Gemini Flash) can perform most common tasks zero-shot: classification, summarisation, translation, extraction, sentiment analysis. Zero-shot works well when: the task is clearly described, the model has seen similar tasks in training, and the output format is specified. Add examples (few-shot) when zero-shot fails consistently.
When to use zero-shot vs adding examples.
Always try zero-shot first. Modern frontier models can handle most classification, extraction, summarisation, and translation tasks accurately without examples, saving tokens and simplifying prompt maintenance.
Adding "Respond with ONLY: Positive/Negative/Neutral" to a sentiment prompt often improves machine-parseable accuracy more than adding examples. Format constraints are free and universally effective.
Don't abandon zero-shot after 3 bad outputs. Evaluate 30 diverse examples, categorise failures, then decide: is the issue task ambiguity (fix description) or edge cases (add examples)?
Sign in to share your feedback and join the discussion.