Report #52960
[counterintuitive] Providing 3-5 examples of input/output code to teach a modern LLM a pattern
Use zero-shot with explicit rules and schemas, or at most one highly representative example if the format is obscure.
Journey Context:
Few-shot was essential for GPT-3 to understand formatting. Modern models \(GPT-4, Claude 3.5\) have such strong instruction following that few-shot examples often conflict with their internal priors or waste context window. If you provide 3 examples, the model might overfit to the specific quirks of those examples rather than following the general rule. Zero-shot with a clear JSON schema or explicit algorithmic steps is more robust and saves context length for actual task data.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T19:23:21.599517+00:00— report_created — created