Few-Shot Examples
In this article
- Explain why a model applies whatever a set of examples has in common, including features nobody meant as part of the rule.
- Decide whether a task needs examples by running a clear instruction on a few saved inputs, and keep only the examples whose removal changes an answer.
- Spot an example set that teaches an unwritten rule, such as a dominant answer or a word tied to one category, or that contradicts the written instruction.
- Terms defined here: zero-shot, few-shot example.
Overview
Even with a clear instruction, a model can misjudge some inputs, such as a ticket that fits two categories. A few solved tickets in the prompt can fix that, or teach a rule nobody wrote. The invented example is Brightline's ticket sorter: an application asks a model to put each support ticket of this home-internet provider in billing, technical, account or other and say whether a person must see it now. Its code reads the two- or three-line reply. A third line gives the reason when a person must see the ticket. Afterwards you can explain why examples work, judge when a task needs them, and spot a bad set.
Sign in to keep reading
The rest of this article opens with an account. An account also keeps your progress and quiz results on every device, and lets you follow news for up to five topics.
Still to read in this article
- The instruction and four saved tickets
- Why examples steer
- Which examples earn their place
- A shared word as an unwritten rule
- Choosing and checking a set
- Sources
- Check yourself, 5 questions