skip to content

Search

← The Language Machines

Part II — The Transformer Era (2017–2020)

Scaling Laws

Power laws, compute-optimal training, the Chinchilla re-balance, and the emergence debate.

2020–2022 12 min read 8 papers

It is January 2020. The transformer is two and a half years old, GPT-2 has shown that bigger generative models write better text, and every lab is asking the same question with no principled way to answer it: given a fixed budget of compute, how large should the model be, and how much data should it see? A ten-author paper from OpenAI turns that question from folklore into a fitted curve — and two years later, DeepMind shows the curve was fitted wrong.

Where We Were

By late 2019 the field had strong evidence that scale helped and almost no theory of how much. The Transformer (Vaswani et al., June 2017) had made training larger sequence models practical; GPT-2 (February 2019) had demonstrated that a generatively pretrained decoder improved broadly as it grew; T5 and BART (both October 2019) had pushed transfer learning across every text task. But sizing decisions were made by intuition and budget, not by prediction.

The practical questions compounded. Depth or width? More parameters or more data? Train to convergence or stop early? How large a batch? Work on large-batch training and gradient noise had begun to give partial answers for optimization, but nobody could say in advance what the loss of a ten-times-larger model would be, so every scale-up was a leap of faith justified after the fact.

The stakes were rising with the hardware. Training runs were moving from single machines to clusters, and a mistake in allocation — a model too large for its data, or data wasted on a model too small — burned weeks of accelerator time that could not be refunded. What the field needed was an instrument: something that let you measure small models cheaply and predict large ones before paying for them.

From folklore to a fitted curve, then a correction Kaplan's power laws license an era of giants; Chinchilla shows the laws were fitted on the wrong hyperparameters. Grey monospace text is the model's scale or the paper's headline claim. 2017 Transformer makes scale practical Jan 2020 Kaplan laws fitted power laws May 2020 GPT-3 175B, the prescription applied Dec 2021 Gopher 280B on ~300B tokens Mar 2022 Chinchilla re-balances the recipe Apr 2022 PaLM 540B, last pre-Chinchilla giant Jun 2022 / Apr 2023 Emergence, then Mirage the metric-choice debate the era of giants the two fitted-curve papers the correction A smaller model, trained on the corrected recipe, beat every larger predecessor at identical compute cost.
A smaller model, trained on the corrected recipe, beat every larger predecessor at identical compute cost. PNG ↓

The Breakthrough

Act one: the power laws. “Scaling Laws for Neural Language Models” (Kaplan et al., 2020), submitted in January 2020, trained families of transformer language models across many sizes and measured how the cross-entropy loss (the quantity introduced in chapter 1) fell as three resources grew: non-embedding parameters, dataset tokens, and training compute. The result was startlingly clean. Loss followed smooth power laws in each variable, “with some trends spanning more than seven orders of magnitude.” Architecture details — depth versus width, number of heads — mattered far less than raw scale. For the first time, a lab could train a sweep of small models, fit three constants, and read off the expected loss of a model a thousand times larger.

The paper’s most consequential claim was about allocation. Larger models were found to be significantly more sample-efficient, so “optimally compute-efficient training involves training very large models on a relatively modest amount of data and stopping significantly before convergence.” Concretely, as the compute budget grew, parameters should grow much faster than data. The field listened. GPT-3 (Brown et al., 2020), submitted in May 2020, was a 175-billion-parameter model — in its authors’ words, “10x more than any previous non-sparse language model” — and its headline result, few-shot in-context learning, is the subject of chapter 7. Gopher (Rae et al., 2021), DeepMind’s 280-billion-parameter model of December 2021, trained on roughly 300 billion tokens. PaLM (Chowdhery et al., 2022), Google’s April 2022 system, trained a 540-billion-parameter dense transformer on 780 billion tokens. The era of giants was a direct application of the Kaplan prescription: enormous parameter counts, comparatively little data.

Act two: the correction. “Training Compute-Optimal Large Language Models” (Hoffmann et al., 2022), submitted in March 2022, re-ran the measurement with one methodological fix. The Kaplan sweep had used, in Hoffmann et al.’s words, “a fixed number of training tokens and learning rate schedule for all models; this prevents them from modelling the impact of these hyperparameters on the loss.” When the learning-rate schedule is matched to the actual token budget of each run, the picture changes. Training over 400 models from 70 million to over 16 billion parameters on 5 to 500 billion tokens, the DeepMind team found that “for every doubling of model size the number of training tokens should also be doubled” — parameters and data should scale equally with compute, not with parameters far ahead.

By that arithmetic, every headline model of the previous two years was substantially undertrained: too many parameters, too few tokens. The proof was empirical. Chinchilla, a 70-billion-parameter model trained on 1.4 trillion tokens — the same compute budget as Gopher, spent on a model a quarter the size seeing over four times the data — outperformed Gopher, GPT-3, and other larger models across a wide range of evaluations. On the MMLU benchmark it reached 67.5% average accuracy, more than 7 percentage points above Gopher. A smaller model, trained correctly, beat a bigger one at identical cost — and was cheaper to serve forever after.

Two recipes split from the same fixed compute budget Kaplan pours compute into parameters; Chinchilla splits it evenly, and the even split wins at identical cost. Grey monospace text is the resulting model or ratio. Fixed compute budget the same total FLOPs Kaplan recipe, 2020 params grow as C^0.73 Chinchilla recipe, 2022 params and tokens grow equally Very large model modest data, GPT-3, Gopher, PaLM Quarter the size, 4x the data Chinchilla 70B on 1.4T tokens Undertrained giants Lower loss, same compute the Kaplan branch the Chinchilla branch
Both branches spend the same compute; only the balanced branch reaches a lower loss, which is the entire content of the correction. PNG ↓

One caveat both papers share: the laws were fitted on dense transformers. Sparse mixture-of-experts models decouple parameter count from per-token compute and follow their own accounting.

The Mathematics

Kaplan et al. found that when only one resource binds, test loss follows a power law in that resource:

L(N)=(NcN)αN,αN≈0.076, Nc≈8.8×1013L(D)=(DcD)αD,αD≈0.095, Dc≈5.4×1013L(Cmin⁡)=(CcCmin⁡)αC,αC≈0.050, Cc≈3.1×108\begin{aligned} L(N) &= \left(\frac{N_c}{N}\right)^{\alpha_N}, \quad \alpha_N \approx 0.076,\ N_c \approx 8.8 \times 10^{13} \\ L(D) &= \left(\frac{D_c}{D}\right)^{\alpha_D}, \quad \alpha_D \approx 0.095,\ D_c \approx 5.4 \times 10^{13} \\ L(C_{\min}) &= \left(\frac{C_c}{C_{\min}}\right)^{\alpha_C}, \quad \alpha_C \approx 0.050,\ C_c \approx 3.1 \times 10^{8} \end{aligned}
SymbolMeaning
LLCross-entropy test loss in nats per token
NNNon-embedding parameter count
DDDataset size in tokens
Cmin⁡C_{\min}Minimum training compute in PF-days
Nc,Dc,CcN_c, D_c, C_cFitted scale constants for each law
αN,αD,αC\alpha_N, \alpha_D, \alpha_CFitted power-law exponents

From these laws Kaplan et al. derived how a growing compute budget should be split:

N∝Cmin⁡0.73,B∝Cmin⁡0.24,S∝Cmin⁡0.03N \propto C_{\min}^{0.73}, \qquad B \propto C_{\min}^{0.24}, \qquad S \propto C_{\min}^{0.03}
SymbolMeaning
NNModel parameters
BBBatch size
SSNumber of training steps
Cmin⁡C_{\min}Minimum training compute (same quantity as in the laws above)

Hoffmann et al. replaced the single-variable laws with a joint parametric fit over both parameters and data:

L(N,D)=E+ANα+BDβ,E≈1.69, A≈406.4, B≈410.7, α≈0.34, β≈0.28L(N, D) = E + \frac{A}{N^{\alpha}} + \frac{B}{D^{\beta}}, \quad E \approx 1.69,\ A \approx 406.4,\ B \approx 410.7,\ \alpha \approx 0.34,\ \beta \approx 0.28
SymbolMeaning
EEIrreducible loss floor, fitted at 1.69
A,BA, BFitted constants weighting each penalty term
α,β\alpha, \betaFitted exponents, 0.34 for parameters and 0.28 for data
NNModel parameters
DDTraining tokens

Minimizing this loss subject to a fixed compute budget gives the compute-optimal allocation:

Nopt∝Ca,Dopt∝Cb,a≈b≈0.5N_{\mathrm{opt}} \propto C^{a}, \qquad D_{\mathrm{opt}} \propto C^{b}, \qquad a \approx b \approx 0.5
SymbolMeaning
NoptN_{\mathrm{opt}}Compute-optimal model parameter count
DoptD_{\mathrm{opt}}Compute-optimal training token count
CCTotal training compute (FLOPs)
a,ba, bFitted exponents, both approximately 0.5

Hoffmann et al. estimated the exponents three independent ways, and all three agreed:

Approachaa (parameters)bb (tokens)
1 — Fix model sizes, vary training tokens0.500.50
2 — IsoFLOP profiles0.490.51
3 — Parametric loss fit0.460.54
Kaplan et al. (2020), for contrast0.730.27

What It Enabled

The most direct legacy of the two papers is that frontier training runs became engineered rather than gambled. Scaling-law sweeps — train dozens of small models, fit the curve, commit the budget — became a standard line item in every serious pretraining effort, a practice detailed in training runs in practice. The tokens-per-parameter ratio became the fastest way to read a model announcement:

ModelDateParametersTraining tokensTokens per parameter
Gopher (Rae et al., 2021)Dec 2021280B~300B~1.1
Chinchilla (Hoffmann et al., 2022)Mar 202270B1.4T20
PaLM (Chowdhery et al., 2022)Apr 2022540B780B~1.4
Llama 3 405B (Grattafiori et al., 2024)Jul 2024405B15.6T~39

The second legacy was to move the bottleneck. If data must scale with parameters, then data — not hardware — becomes the binding constraint. Hoffmann et al.’s own projections made this explicit: a compute-optimal 1-trillion-parameter model would need roughly 21.2 trillion training tokens, and the paper noted that “the amount of training data that is projected to be needed is far beyond what is currently used to train large models, and underscores the importance of dataset collection.” That warning is the opening premise of chapter 11, the data question.

The third legacy came after Chinchilla, and partially superseded it: over-training. Chinchilla optimizes training compute alone, but a model is trained once and served millions of times. Llama 3 (Grattafiori et al., 2024) made the trade explicit — its flagship 405B model sat near its own compute-optimal point at 15.6 trillion tokens, but Meta deliberately chose to “train our smaller models for much longer than is compute-optimal. The resulting models perform better than compute-optimal models at the same inference budget.” Small, heavily over-trained models are the economic engine of the open-weights explosion and of cheap API tiers, and the successor question — whether to spend marginal compute at training time or at inference time — is taken up in the economics of test-time compute and reasoning models.

Chinchilla's correction opens two paths, not one Balancing parameters and tokens exposes data as the new bottleneck, and licenses deliberately over-training small models for cheap serving. Grey monospace text names where each path leads. Kaplan laws, 2020 the era of giants Chinchilla correction 2022 Data becomes the bottleneck 21T tokens for a 1T-param model Overtrained small models Llama 3, ~39 tokens per param Web-scale data curation Cheap inference, open weights
Balancing parameters and tokens does not settle the scaling question, it just relocates the constraint, first to data supply, then to inference economics. PNG ↓

The emergence debate. Scaling laws predict loss, not abilities — and the gap between the two produced the era’s sharpest scientific argument. “Emergent Abilities of Large Language Models” (Wei et al., 2022), submitted in June 2022, defined an ability as emergent if it is “not present in smaller models but is present in larger models,” and catalogued examples where task performance sat at random until a scale threshold, then jumped: three-digit arithmetic appearing in GPT-3 at roughly 2×10²² training FLOPs (about 13B parameters); MMLU performance surpassing random only at 3–5×10²³ FLOPs (70B–280B parameters); chain-of-thought prompting beating standard prompting only near 10²³ FLOPs (~100B parameters); instruction tuning hurting models of about 8B parameters or smaller while helping at ~100B. The unsettling implication was that smooth loss curves could hide discontinuous capability jumps — you could not know what the next scale-up would unlock, for good or ill.

The rebuttal arrived in April 2023. “Are Emergent Abilities of Large Language Models a Mirage?” (Schaeffer et al., 2023) argued that “emergent abilities appear due to the researcher’s choice of metric rather than due to fundamental changes in model behavior with scale.” Exact-match accuracy on a multi-digit arithmetic problem is all-or-nothing: a model whose per-digit accuracy improves smoothly will score zero until it crosses the threshold where every digit comes out right, then appear to leap. Swap the discontinuous metric for a continuous one — per-token error, edit distance — and, in the authors’ analysis of GPT-3 results and a meta-analysis of BIG-Bench claims, the sharp jumps flatten into the familiar smooth curves. The debate is not fully settled — some capability thresholds matter precisely because the real world grades with discontinuous metrics — but the Mirage paper permanently raised the evidentiary bar for claims that scale produces qualitative surprises.

Key Papers

PaperAuthorsYearLinkWhy it matters
Scaling Laws for Neural Language ModelsKaplan et al.2020arXiv:2001.08361First clean power laws for LM loss; made scale a predictable engineering variable
Language Models are Few-Shot LearnersBrown et al.2020arXiv:2005.14165GPT-3 at 175B — the Kaplan prescription executed at full size
Scaling Language Models: Methods, Analysis & Insights from Training GopherRae et al.2021arXiv:2112.11446280B model on ~300B tokens; the undertrained baseline Chinchilla beat
Training Compute-Optimal Large Language ModelsHoffmann et al.2022arXiv:2203.15556The Chinchilla re-balance: scale parameters and tokens equally
PaLM: Scaling Language Modeling with PathwaysChowdhery et al.2022arXiv:2204.02311540B dense model on 780B tokens; the last great pre-Chinchilla giant
Emergent Abilities of Large Language ModelsWei et al.2022arXiv:2206.07682Named and catalogued discontinuous capability jumps with scale
Are Emergent Abilities of Large Language Models a Mirage?Schaeffer et al.2023arXiv:2304.15004Showed metric choice can manufacture emergence; reframed the debate
The Llama 3 Herd of ModelsGrattafiori et al.2024arXiv:2407.21783Deliberate over-training past Chinchilla-optimal for inference economics

PM Lens

Papers referenced