AI GLOSSARY · AI CONCEPTS

Zero-shot learning

Markdown version · Wikidata Q96416030

Definition

Zero-shot learning is when a model handles a task or recognises a category it was given no labeled examples of. It relies on other information, such as a description, an instruction or what it learned in pretraining.

Also called: zero shot learning, zero-shot, zero shot classification, zero-shot classification.

In plain language

Zero-shot means asking an AI to do something without showing it a single worked example. If you tell a chatbot to sort customer emails into billing, bug and praise, and give no sample emails, you are asking for zero-shot classification. It works because the model already learned a great deal about language, so the words billing and bug mean something to it. The limit is that the model has only your short instruction to go on, so it can misread what you meant, and its answers still need a spot check on real cases. Adding a few worked examples is often the next step when answers drift.

Technical definition

In the classic machine learning sense, IBM describes zero-shot learning as a scenario in which a model is not trained on any labeled examples of the unseen classes, so it relies on auxiliary knowledge such as textual descriptions, attributes or embeddings. IBM contrasts this with few-shot learning, which uses a few labeled examples, and one-shot learning, which uses a single example. With large language models the term is also used for prompting: the prompt carries an instruction and no demonstrations. The FLAN paper reports that instruction tuning substantially improves zero-shot performance on unseen tasks.

Worked examples in this catalogue

Catalogue examples point at a skill, guide or coding tool listed on this site, with what to run and what you see. An example marked illustrative describes the item from its own documentation; it was not executed for this page. Platform Scores are our assessment under a published method, not a safety guarantee.

  1. Guide · Illustrative, not executed

    Prompt Engineering for Agents vs Chat Models

    What you see
    A worked agent prompt for a failing test that states scope, a completion check and a fallback, and gives no sample outputs. The guide also advises 3 to 5 examples inside example tags when you do add examples.
    Why it exercises the concept
    The instruction-only prompt is a zero-shot prompt, and the guide's note on examples shows the step you take when it is not enough.
  2. Skill by Skill Almanac · Illustrative, not executed

    regex-from-labeled-examples 37/100 · Provisional, not yet measuredScored · Method v0.2 · How we score

    What you see
    A Python regular expression proposed from labeled match and non-match strings, then checked against every supplied example in a row-by-row table.
    Why it exercises the concept
    It is the contrast case: the task is defined by labeled examples you supply, which is what zero-shot leaves out.
  3. Skill by Skill Almanac · Illustrative, not executed

    prompt-writing 57/100 · Provisional, not yet measuredScored · Method v0.2 · How we score

    What you see
    LLM prompts written and linted with a fixed structure, injection rules and a numeric test plan.
    Why it exercises the concept
    A zero-shot prompt succeeds or fails on how clearly the instruction is written, and a test plan tells you which.
  4. Coding tool · Illustrative, not executed

    Claude Code

    What to try
    claude
    What you see
    Claude Code's overview shows a one-line instruction passed to it, such as asking it to write tests for a module, run them and fix any failures, with no examples attached.
    Why it exercises the concept
    A plain instruction to a coding agent is zero-shot use of a model in everyday work.

How it shows up when you use agents

Many plain requests to Claude Code, Codex or a chat model are zero-shot: you describe the task and attach no sample of the output you want. That is why the wording of the request matters so much. The model relies on what it learned in pretraining and on your instruction. A large language model can often do a reasonable job from that alone, and sometimes it guesses wrong about format, scope or tone.

What breaks when it is misunderstood: assuming a zero-shot answer is verified, or rewriting a long prompt again and again when two worked examples would settle the format. A better habit is to try the plain instruction first, check the output on a few real cases, and only then add examples. That step is few-shot prompting.

Next action: take one task you give an agent often, run it with an instruction alone, and note what goes wrong. If the failures are about format, add examples. If they are about scope, state the scope and the check, as in the prompt engineering guide for agents. See prompt engineering for the wider practice.

Common confusions

  • Zero-shot versus few-shot. Zero-shot gives no examples of the task. Few-shot gives a handful, and one-shot gives one. IBM's page makes the same three-way split for classic learning. See Few-shot prompting.
  • Zero-shot versus untrained. A zero-shot model has been trained, usually on a large amount of text. What it lacks is labeled examples of this particular task or class.
  • Zero-shot versus fine-tuning. See Fine-tuning.
  • Myth. Zero-shot results are as reliable as a model built for the task. IBM lists limits such as bias toward seen classes in the generalized setting, and a spot check on real cases is the safer habit.

Terms that mention Zero-shot learning

14 terms mention this one

More in AI concepts

Next steps

  1. Prompt Engineering for Agents vs Chat Models The long-form guide.
  2. regex-from-labeled-examples A skill that exercises it.
  3. Few-shot prompting Related term.
  4. Large language model (LLM) Related term.
  5. All glossary terms A to Z and by family.

Sources

Definitions are written by Skill Almanac from these sources and were checked against them on 2026-11-24. Wikipedia is never the only source.

Review record

Last verified

Drafted by claude-sonnet-5-5; sources and example targets checked by claude-haiku-5-5 source check; claude-sonnet-5-5 editor pass on 2026-11-24. Last verified .

This entry is still in review, so it is not listed in search engines yet.

Change log (2)
  • : First version.
  • : Verifier pass: softened Most to Many, removed unsourced fine-tuning claim.