When you write a prompt, you have three basic techniques at hand: no examples, a few examples, and chain-of-thought. None is absolutely better than the others; each is built for a particular kind of task. The skill is in knowing when to choose which.
Zero-shot
In the zero-shot approach, you give only the instruction and rely on the model’s pre-trained knowledge — without showing any example. This is the simplest and cheapest route, and it works well for straightforward tasks. If a task is clear enough to express with a good description, start here.
Few-shot
In the few-shot approach, you include a few examples of the input and desired output in the prompt to demonstrate the pattern you want. This is valuable when:
- Rules alone can’t convey the pattern.
- The output format is complex and hard to describe in words.
- A reasoning style or particular edge cases need to be shown, not told.
And avoid it when the rules are clear and sufficient, or when examples bias the model toward one specific pattern, or when a modern model already handles the task well without examples.
Chain-of-thought
In chain-of-thought, you ask the model to show its reasoning steps before the final answer. This shines for multi-step problems:
- Multi-step reasoning and mathematical or logical deduction.
- Tasks where the intermediate steps matter.
- Where you want to see the reasoning process itself.
But for straightforward classification, pattern matching, or tasks the model handles well anyway, chain-of-thought just adds words without benefit.
An important modern caveat
A recent finding is worth noting: for sufficiently capable models, chain-of-thought examples mostly enforce the output format rather than genuinely increasing reasoning ability. In other words, in many cases a clear zero-shot instruction performs as well as — or even better than — a prompt full of examples. That means before stuffing a prompt with samples, it’s worth trying the simple version.
The golden rule: start simple
A simple decision path: start with zero-shot if the task is straightforward. If you need a specific format or style, add a few examples. If the task calls for reasoning or explanation, add chain-of-thought. The guiding principle is just this: start simple, and add complexity only when it’s genuinely needed. A good prompt is the shortest prompt that does the job right.