What it is
Zero-shot prompting asks an AI model to perform a task based solely on instructions, with no examples. Few-shot prompting includes 2-5 examples of the desired input/output pattern before the actual request. Few-shot typically produces more consistent, formatted results because the model can pattern-match against the examples.
Why it matters
Choosing the right prompting strategy directly affects agent quality. Few-shot prompting is especially valuable for tasks with specific output formats — like generating structured case summaries or qualifying leads against specific criteria.
Key components
- Zero-shot instructions
- Few-shot examples
- Chain-of-thought prompting
- Output formatting
How it connects
Prompt Builder supports both strategies. When creating Prompt Templates in Salesforce, you can include example outputs in the template instructions to guide the AI.
Good to know
Few-shot examples should represent the full range of expected inputs — include edge cases. Bad examples teach bad behavior.
