Example-Driven Specification
Specifies desired model behavior through concrete examples rather than abstract rules.

Problem
Abstract instructions often underspecify format, granularity, and edge-case behavior, causing inconsistent outputs despite correct intent.
Solution
Provide examples as the primary specification so the model infers the contract from input-output patterns, boundaries, and conventions. In-context pattern induction stabilizes behavior more reliably than long abstract rules.
Example
One worked example. The book has 2–4 per technique.
Extract action items from meeting notes. For each item include the owner, task, and deadline. Example input: Jordan will send the revised rollout plan by Thursday. Elena needs to update the support playbook sometime this month. Example output: - Jordan | Send revised rollout plan | Thursday - Elena | Update support playbook | This month Now extract from these notes: Maya said we need to finalize the payroll rollout checklist by Friday. Ben will update the admin access runbook next week. Priya said she would review the audit export flow when she has time.
- Maya | Finalize payroll rollout checklist | Friday - Ben | Update admin access runbook | Next week - Priya | Review audit export flow | Unspecified
Techniques
Concrete ways to implement Example-Driven Specification. Each technique fits a different situation.
- 01
Demonstration Examples
Show complete input-output pairs so the model learns the task and expression style by continuing the demonstrated pattern.
- 02
Contrastive Examples
Include both desirable and undesirable outputs for the same input so the model infers boundaries and avoids known failure modes.
- 03
Convention Mirroring
Provide samples of a target tone, structure, or style so the model absorbs and continues the convention without explicit rules.
