Book a call

Daniel & Friends / Glossary / Few-shot and zero-shot prompting

AI and automation

Few-shot and zero-shot prompting

Zero-shot prompting gives a model a task without a single example, while few-shot adds several sample pairs of input and output to the prompt. The examples show the required format, tone or way of sorting, and results tend to be steadier.

Daniel Votruba ·


In practice

Start with zero-shot. If the model holds the format poorly, add three to five examples from real data, including one edge case.

Related terms

  • Prompt: A prompt is the instruction a model receives.
  • Prompt engineering: Prompt engineering is the design and testing of instructions for a model: choosing the role, context, examples and answer format so that the output is reliably usable.
  • Chain of thought: Chain of thought is an approach where a model writes out intermediate steps before the final answer.
  • System prompt: A system prompt is a hidden or predefined instruction that sets a model’s role, tone, rules and limits for an entire conversation.

More terms in the group AI and automation

Fine-tuning · Explainable AI (XAI) · Foundation model · EU AI Act · Function calling (tool use) · Embedding · Generative AI · Diffusion models · Grounding · Deep learning · Guardrails · Deepfake and synthetic media · Hallucination · Custom GPTs and projects · Human in the loop · Copilot (AI assistant) · Inference and latency · Context window · Jailbreak (AI) · Computer vision · Large language model (LLM) · ChatGPT Ads · Machine learning (ML) · MCP (Model Context Protocol)

Full glossary (590 terms)

Terms in practice

Need help putting them to work?

Terms are one thing, putting them to work is another. We go through which of them pay off for you and say so plainly. You get a first opinion for free and we reply within 24 hours.

Book a call

Enjoyed the article? Share it with friends.