Few-shot prompting
Few-shot prompting is a technique where you include a handful of worked examples of the task, inputs paired with the outputs you want, in a prompt so an AI model copies the pattern on a new input.
"Shot" simply means example. Zero-shot prompting gives the model only an instruction; one-shot gives a single example; few-shot gives several, often two to five. The examples show the model the format, tone and level of detail far more precisely than a description can.
Few-shot prompting does not train or change the model. The examples live only in that request and are forgotten afterwards. That makes it different from fine-tuning, which permanently adjusts a model using many examples, and it is usually the cheaper first step to try.
How it works
A large language model continues text in the most likely way. If a prompt contains three pairs of "customer review" and "reply", followed by a fourth review with no reply, the most likely continuation is a reply in the same style as the first three. The model picks up length, structure, wording and even small habits such as how you sign off.
The choice of examples matters more than their number. Good examples cover the range of real cases, including an awkward one, and are consistent with each other. If all your examples are short, positive and formal, the model will struggle with a long, angry review. Models also tend to copy surface features, so an example that happens to mention a discount may lead the model to mention discounts where you did not intend it.
Each example adds tokens to every request, so there is a cost trade-off. In software, the examples often sit in the system prompt, and providers that support prompt caching can make repeating them cheaper. Order can matter too: models tend to lean towards the style of the last example, so put your most typical case at the end and keep the examples clearly separated from the instruction and the new input, for instance with labels such as Example 1, Example 2 and New review.
Example
A restaurant wants an AI tool to draft replies to online reviews. A plain instruction, "reply politely and thank the customer", produces stiff, generic text. The owner instead pastes four real replies she wrote herself: one to a glowing review, one to a complaint about slow service, one to a review in another language, and one to a mixed review mentioning a specific dish.
With those examples in the prompt, drafts start using her greeting, mention the dish by name and keep to three sentences. She tests on ten new reviews and finds one draft offering a free dessert, copied from an example where she had made that offer. She replaces that example with one that offers to talk in person, and the problem disappears.
Why it matters for your business
Few-shot prompting is the quickest way to get AI output that sounds like your business rather than like everyone else's. It needs no developer and no extra cost beyond slightly longer prompts. The limit is scale: if you need the model to learn hundreds of patterns or a deep house style, examples in a prompt may not be enough, and fine-tuning or a better-structured process becomes worth considering. For most small-business writing tasks, a few good examples are all you need. Keep your best examples in a shared document so the whole team uses the same ones.
Common mistakes
- Using examples that are all alike, so the model fails on the cases that differ.
- Including an example with a one-off promise or detail that the model then repeats everywhere.
- Giving examples without a clear instruction, leaving the model to guess what matters about them.
- Assuming the model will remember the examples in a new conversation.
Questions people ask
How many examples should a few-shot prompt have?
Usually two to five is enough for format and tone. Add more only if the outputs still miss important cases, and make each new example cover a different situation. Beyond a handful, returns tend to shrink while every request gets longer and slightly more expensive.
What is the difference between few-shot and zero-shot prompting?
Zero-shot prompting gives the model only an instruction and relies on its general training. Few-shot prompting adds worked examples of the task. Zero-shot is quicker to write and works for common tasks; few-shot gives much more control over format, tone and edge cases.
Is few-shot prompting the same as fine-tuning?
No. Few-shot examples sit inside a single prompt and affect only that request. Fine-tuning trains the model on many examples and changes it permanently. Few-shot is cheaper and faster to change, while fine-tuning suits large, repetitive tasks where prompts alone fall short.