Few-shot prompting: Three mistakes that kill accuracy

Few-shot prompting is a technique where you provide a model with a few examples of the desired output, and it reproduces that pattern on new data. It sounds like magic: three samples, and GPT understands what you need. In practice, most attempts fail due to three systemic errors that break the model's learning logic.
Let's break down each one—with examples of how not to write few-shot prompts and how you should write them for Russian-language tasks.
Mistake 1: Contradictory examples—the model learns chaos
You provide three examples, but they are inconsistent in style, length, or structure. The model tries to find a common pattern—and finds random noise instead.
Bad example: You want to generate short article teasers. You provide three samples:
- The first is two lines, informal tone, no numbers.
- The second is five lines, formal style, with percentages and dates.
- The third is one line, question format.
The model sees three different tasks, not one template. The result is a mix of all three styles or a random choice of one.
How to fix it: Standardize your examples based on key parameters—length (±10 words), tone (the same level of formality), and structure (statements or questions, not mixed). If you want variety, add an explicit rule: "The first sentence is always the problem, the second is the solution."
Few-shot works not because the model "understands" the task, but because it statistically extrapolates a pattern. Contradictions in examples are just noise in the training set.
Mistake 2: Excessive context in examples—the model copies the fluff
You provide examples with detailed introductions, explanations, and metadata—and the model reproduces all of it in the response, even though you only need the result.
Bad example: The task is to classify reviews as positive/negative. You write:
- "Customer review #1, left on January 12: The product arrived on time, quality is excellent. → Positive"
- "Customer review #2, left on January 15: Packaging is dented, product doesn't work. → Negative"
The model memorizes the structure "metadata + text + arrow + result"—and demands the same format in the input. If you just provide the review text, accuracy drops.
How to fix it: Keep only what will be in the input and output of the actual task in your examples. Remove dates, numbers, and unnecessary explanations. The format should be:
- "The product arrived on time, quality is excellent. → Positive"
- "Packaging is dented, product doesn't work. → Negative"
The model learns from the minimally sufficient context. Anything that doesn't affect the result reduces the accuracy of the pattern transfer.
Mistake 3: Ignoring output format—the model improvises
You show the model what to do, but you don't define how to format the result. The model starts creatively interpreting the task.
Bad example: The task is to extract key terms from text. Examples:
- Text about neural networks → "neural networks, training, data"
- Text about marketing → "Keywords: targeting, conversion, audience"
- Text about design → "Terms: composition, typography"
Three examples—three different output formats. The model doesn't know if it needs prefixes ("Keywords:"), if it needs numbering, or if it needs quotation marks. The result is a random choice.
How to fix it: Strictly define the output format in all examples. If you want a comma-separated list, make it a comma-separated list everywhere. If you want JSON, show JSON in every example. If you only need terms without prefixes, remove the prefixes from all samples.
Few-shot prompting is not a demonstration of capabilities, but a template for copying. The model reproduces the structure it sees most often.
When few-shot really works
Three scenarios where the technique provides a measurable increase in accuracy:
- Classification with non-standard categories. If your labels aren't obvious (the model knows "spam/not spam," but not "relevant for B2B SaaS / relevant for e-commerce"), two or three examples significantly increase accuracy.
- Stylistic adaptation. The model is good at copying tone, level of formality, and sentence structure—if the examples are consistent.
- Structured data extraction. Parsing addresses, dates, or nomenclatures from unstructured text—few-shot works better than a long text description of rules.
In all three cases, it is critical that the examples are identical in structure, minimal in context, and fixed in output format.
Try few-shot prompting in GEMERA AI
GEMERA AI provides access to GPT, Claude, and Gemini—models that support few-shot prompting out of the box. Test the technique on your tasks: review classification, data extraction, or style adaptation. Three examples—and the model adapts to your format without fine-tuning.