PromptCorrectlyPromptCorrectly
StudioAI CoursesLibraryBlogPricingAbout
Log inStart free
PromptCorrectlyGLOSSARY · TECHNIQUES
Home/Glossary/Few-shot prompting

What is Few-shot prompting?

Also called: few-shot learning · in-context examples

Few-shot prompting shows the model two to five examples of the input → output you want, so it copies the pattern instead of guessing it from a description.

Describing a format is weaker than demonstrating it. A few-shot prompt includes examples — "Input: … Output: …" — before the real task, and the model matches their style, length, tone and structure with remarkable fidelity. It's the most reliable way to get consistent output across many runs.

Examples teach everything, including your mistakes. Keep them consistent, representative (simple → hard → edge case), and few: three good examples beat ten sloppy ones.

Example
Rewrite support replies in our voice.
Input: "Your order is late." → Output: "You're right, and I'm sorry — your parcel left our warehouse Tuesday; here's the tracking link, and I've added a 10% code for the wait."
Input: "The app crashed." → Output: …
How to use it well
  1. Use identical formatting for every example.
  2. Include one example of what to do in a tricky case.
  3. Only show positive examples — "don't do this" examples get copied too.
Go deeper
Few-shot prompting: teaching AI by exampleFew-Shot Pattern Recognition (course)
Related terms
Zero-shot promptingPrompt templateOutput formatAll terms →

Use it right now

Ask our brain anything on the homepage — it remembers the whole conversation — or write a brief in the Studio and see the prompt it compiles to.

Ask the brainOpen the Studio
promptcorrectly.comFROM VAGUE INTUITION TO STRUCTURED INSIGHTBYOK · ANTHROPIC · OPENAI · GROK
PromptCorrectlyPromptCorrectly

The visual workspace for people who actually use AI. Built in the open, priced for humans, powered by your own keys.

Product
  • Studio
  • AI Courses
  • Library
  • Pricing
Resources
  • How it works
  • Templates
  • Community library
  • Repository
  • All 3,600 prompts
  • How to prompt correctly
  • Prompts for every field
  • AI glossary
Company
  • About
  • Contact
  • FAQ
  • Pricing
© 2026 PromptCorrectly · From vague intuition to structured insight.
TermsPrivacyRefundDisclaimerAcceptable useCookies