# Few-shot prompting

**Source:** https://promtable.com/glossary/few-shot-prompting

> Few-shot prompting supplies 2–10 input–output examples inside the prompt so the model imitates the pattern on a new input.

---
Few-shot prompting supplies 2–10 input–output examples inside the prompt so the model imitates the pattern on a new input.

Few-shot prompting (a form of in-context learning) gives the model a handful of demonstrations directly inside the prompt. It is the highest-leverage technique for steering tone, format, and edge-case handling without fine-tuning. Effective few-shot prompts use examples that mirror the real input distribution, cover failure modes, and follow a consistent format. The number of shots that helps plateaus quickly — for most tasks 3–5 well-chosen examples beat 20 mediocre ones. Newer long-context models also support "many-shot" prompts (hundreds of examples) which approach fine-tuning quality for narrow tasks.

## When to use

- Strict output format (JSON, CSV, custom DSL).
- Domain-specific tone (legal, medical, brand voice).
- Edge cases that zero-shot keeps getting wrong.

## Common mistakes

- Using examples that don't match the real input distribution.
- Inconsistent formatting across examples — the model copies the inconsistency.
- Padding with redundant easy examples instead of edge cases.

## Related terms

- [chain-of-thought](https://promtable.com/glossary/chain-of-thought)
- [zero-shot-prompting](https://promtable.com/glossary/zero-shot-prompting)
- [system-prompt](https://promtable.com/glossary/system-prompt)
- [in-context-learning](https://promtable.com/glossary/in-context-learning)

*Last updated: 2026-06-01*
---

Original page: https://promtable.com/glossary/few-shot-prompting
Maintained by Promtable (https://promtable.com). Content: CC BY 4.0. Cite as "Promtable — https://promtable.com/glossary/few-shot-prompting".
Contact: info@vibecodingturkey.com.