Language Models are Few-Shot Learners

GPT-3 showed that a large decoder-only Transformer can use natural-language prompts and in-context examples as a task interface without gradient updates at evaluation time.

Metadata

FieldValue
PaperLanguage Models are Few-Shot Learners
AuthorsTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, Sandhini Agarwal, Ariel Herbert-Voss, Gretchen Krueger, Tom Henighan, Rewon Child, Aditya Ramesh, Daniel M. Ziegler, Jeffrey Wu, Clemens Winter, Christopher Hesse, Mark Chen, Eric Sigler, Mateusz Litwin, Scott Gray, Benjamin Chess, Jack Clark, Christopher Berner, Sam McCandlish, Alec Radford, Ilya Sutskever, Dario Amodei
Year2020
VenueNeurIPS 2020
arXiv2005.14165
ProceedingsNeurIPS paper
Statusfull note started

One-Line Takeaway

GPT-3 keeps the decoder-only language-model objective:

but shows that scale changes how the interface is used:

The durable architecture lesson is that a causal Transformer can become a general text-conditioned task machine when the prompt itself carries the task specification.

Question

Before GPT-3, the common transfer recipe was:

GPT-3 asks whether a much larger autoregressive language model can instead use context as the adaptation mechanism:

This is not a new attention formula. It is a major architecture-interface result:

Architecture Contract

ItemContract
Inputtext token prefix containing instructions, examples, and query
Outputnext-token distribution and generated continuation
Backbonedense decoder-only Transformer
Attention patterncausal self-attention
Training objectiveautoregressive next-token prediction
Evaluation adaptationzero-shot, one-shot, or few-shot prompting without gradient updates
Main scale point175B-parameter GPT-3 model family endpoint
Main riskbenchmark contamination, prompt sensitivity, and mistaking in-context behavior for reliable reasoning

The note belongs in Architecture Papers because it made the decoder-only Transformer a practical task interface. It should not be read as a block-level invention like attention, RoPE, or MoE routing.

Decoder-Only Objective

The training objective is next-token prediction:

The causal mask is:

Attention at a layer is:

The architecture is therefore still in the Decoder-Only Transformer family.

Prompt as Task Interface

GPT-3’s important interface is:

The model produces:

For a few-shot classification task, the prompt can be abstracted as:

The model then predicts the continuation:

No gradient update is applied at evaluation time:

That is the key contrast with fine-tuning.

Zero-Shot, One-Shot, Few-Shot

SettingPrompt ContentsParameter Update?What It Tests
zero-shotinstruction or task text onlynotask inference from language
one-shotone demonstration plus querynoformat induction from one example
few-shotseveral demonstrations plus querynoin-context pattern use
fine-tuninglabeled task datasetyestask-specific parameter adaptation

The paper’s core claim is about prompt-conditioned evaluation, not supervised fine-tuning.

Scaling View

GPT-3 is part of a model family. The central empirical pattern is:

This should be read with three variables separated:

The architecture family is decoder-only Transformer. The paper’s claim is that scaling this family improves task-agnostic performance under prompt conditioning.

Relation to GPT-2 and LLaMA

PaperMain RoleInterface
GPT-2zero-shot decoder-only LM transfertask as text continuation
GPT-3few-shot/in-context scaling milestonetask as prompt with demonstrations
LLaMAefficient open-weight foundation model recipemodern decoder-only pretraining recipe

The rough progression is:

GPT-3 sits between GPT-2’s prompt-as-continuation framing and later foundation-model recipes that standardize RMSNorm, RoPE, SwiGLU, larger data mixtures, instruction tuning, and tool use.

What Is Architectural Here?

GPT-3 is easy to misfile as only a scaling or capability paper. For this wiki, keep it in architecture because it changes the practical contract of the decoder-only Transformer:

it becomes:

That means the architecture is evaluated not just as a sequence model, but as a conditional computation system whose behavior is controlled through the context window.

Evidence to Read

ClaimEvidence TypeWhat It SupportsCaveat
larger autoregressive LMs improve few-shot performancemodel-size sweep across benchmarksscale improves prompt-conditioned task behaviordata, task choice, and prompt formatting matter
no evaluation-time gradient update is needed for many taskszero/one/few-shot protocolprompt context can act as adaptation signalnot equivalent to robust task learning
performance is broad across NLP tasksmulti-benchmark evaluationdecoder-only LM can serve as a general interfacesome tasks remain weak or brittle
generated text becomes hard to distinguish in some settingshuman evaluation of samplesfluent generation reaches a notable thresholdsocial and measurement risks are central

Implementation Reading

Check:

  • context window length and whether demonstrations fit;
  • prompt format and demonstration ordering;
  • whether evaluation uses exact-match, likelihood ranking, or free generation;
  • whether labels are verbalized consistently;
  • whether train/test contamination was audited;
  • whether results compare zero-shot, one-shot, few-shot, and fine-tuned baselines separately;
  • whether the claim is about architecture, scale, data, or prompting.

For reproduction, the hard part is not writing a decoder-only Transformer equation. It is reproducing scale, data mixture, evaluation protocol, and contamination checks.

Limitations

  • The architecture family is not new; the contribution is the scaled interface behavior.
  • Prompt sensitivity can dominate conclusions on individual tasks.
  • In-context examples do not guarantee robust reasoning or stable calibration.
  • Benchmark contamination and web-scale data overlap are hard to rule out completely.
  • Few-shot performance is not a substitute for controlled domain evaluation in high-stakes settings.

Common Misreadings

MisreadingCorrection
”GPT-3 invented the Transformer.”It scales a decoder-only Transformer and changes the task interface through prompting.
”Few-shot means parameter-efficient fine-tuning.”In GPT-3, few-shot examples are in the context; parameters are not updated.
”Prompting proves reasoning.”It shows prompt-conditioned behavior; reasoning claims need stricter tests.
”Architecture explains all gains.”Data, compute, scale, prompt format, and benchmark protocol are inseparable.

What to Remember

GPT-3 is the canonical architecture-interface paper for decoder-only LLMs:

In this wiki, keep it as the bridge between GPT-2, modern decoder-only architecture recipes like LLaMA, and agent/tool-use systems that treat language-model context as a working interface.