AI glossary
Few-shot prompting
Few-shot prompting puts a handful of worked examples in the prompt so the model copies their pattern, format and judgement on a new input.
Instead of describing a format, you show it. Three examples of a support email and the label it should get teach the model more than a paragraph of rules, and the new email follows them.
Zero-shot means no examples, one-shot means one. A few is usually enough; more examples cost tokens on every call without always helping.
The examples teach their accidents too. If every example is labelled "billing", or every answer is short, the model leans that way, so pick examples that cover the cases you care about.
Learn it hands-on
These free lessons teach it with commands to run in a lab and checked tasks. Read them whole with no account.