Report #43983
[counterintuitive] Providing multiple complex examples \(few-shot\) is always better than zero-shot for coding tasks
Use zero-shot with detailed instructions and schema constraints first; only use few-shot if the output format is highly idiosyncratic and hard to describe declaratively.
Journey Context:
In 2023, few-shot was the gold standard for steering models. However, modern models have massive context windows and strong instruction-following capabilities. Few-shot examples consume massive token space, introduce bias \(the model might copy a bug from the example\), and can constrain the model to a suboptimal pattern seen in the examples. Declarative instructions \(zero-shot\) allow the model to leverage its full pre-trained knowledge base. If examples are needed, 1-shot is often sufficient to demonstrate format, not logic.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T04:17:57.230791+00:00— report_created — created