Skip to content

Language models scale reliably with over-training and on downstream tasks

Skip →Merging in practice: LLMs & retrievers
LLM stage 2 #14Pretraining stage 2 #2extendedfrontierpaperrubric 8/122024 · ~30 min

Samir Yitzhak Gadre, Georgios Smyrnis, Vaishaal Shankar, …, Ludwig Schmidt

Status

TL;DR. Chinchilla-style laws describe compute-optimal training, but deployed models are usually over-trained: smaller models trained on many more tokens, because they are cheaper to serve. Gadre et al. train 104 models (0.011B–6.9B) on C4, RedPajama and RefinedWeb with token multipliers M=D/NM = D/N from 20 to 640. The loss-vs-compute curves for different MM are parallel, so a small grid predicts large over-trained runs. A second law links loss to average downstream error.

Assume α=β\alpha = \beta in the Chinchilla form and substitute N=C/(6M)N = \sqrt{C/(6M)}, D=CM/6D = \sqrt{CM/6}:

L(C,M)=E+(aMη+bM−η)C−η,η=α/2.L(C, M) = E + \left(a M^{\eta} + b M^{-\eta}\right) C^{-\eta},\qquad \eta = \alpha/2 .

The exponent η\eta is the same for every MM; over-training only raises the constant in front. Downstream error is then predicted from loss with Err(L)=ϵ−kexp⁡(−γL)\text{Err}(L) = \epsilon - k\exp(-\gamma L), averaged over 17 tasks where a small model is already at least 10 points above chance.

Results. With 2.4×10¹⁹ FLOPs of small runs, the paper extrapolates the C4 validation loss of a 1.4B, 900B-token RedPajama model (32× over-trained), which costs 300× more to train. With 2.7×10²⁰ FLOPs it predicts the average top-1 error of a 6.9B compute-optimal model to within 1 percentage point, using 20× less compute. Fits are reported separately for each training set; for RedPajama the law is L=1.84+(212M0.136+367M−0.136)C−0.136L = 1.84 + (212M^{0.136} + 367M^{-0.136})C^{-0.136}. Individual task errors remain much harder to predict than the average.

  • Chinchilla — the compute-optimal law this reparameterises.
  • Data-constrained scaling — what happens when the extra tokens must be repeated.
  • Emergence as a mirage — why averaging tasks and using smooth links makes downstream prediction possible.
  • DCLM — same group; uses small-scale runs to make data decisions.

Questions to think through

These questions have no single right answer. Write or say your answer before you open the hints. Mark a question once you could defend your answer in a reading group.

  1. Derive / compute

    Starting from L = E + A·N^(−α) + B·D^(−β) with α = β, C = 6ND and token multiplier M = D/N, derive L(C, M) = E + (a·M^η + b·M^(−η))·C^(−η) with η = α/2. Use the RedPajama fit a = 212, b = 367, η = 0.136 to find the optimal M, and estimate how much more compute an M = 640 model needs to match an M = 20 model's loss.

    What a strong answer covers
    • N = √(C/(6M)) and D = √(CM/6). Then A·N^(−α) = A·6^η·M^η·C^(−η) and B·D^(−α) = B·6^η·M^(−η)·C^(−η), so a = A·6^η and b = B·6^η.
    • The exponent η does not depend on M, so curves for different M are parallel lines in log-log space; M only sets the offset.
    • The offset aM^η + bM^(−η) is smallest at M* = (b/a)^(1/(2η)) = (367/212)^(3.68) ≈ 7.5 for this fit, which conflicts with the paper's observation that M = 20 is near-optimal, so the fitted constants should not be read too literally.
    • Offsets: M = 20 gives about 563 and M = 640 about 663, a ratio of about 1.18. Matching the loss needs C to grow by 1.18^(1/0.136) ≈ 3.3×.
  2. Mechanism

    The paper predicts downstream error from loss with Err(L) = ε − k·exp(−γL) and averages over 17 tasks selected because a small model already beats chance by 10 points. Explain why this two-step chain (compute → loss → error) is more predictable than fitting error to compute directly, and why the task selection matters.

    What a strong answer covers
    • Loss is a smooth, low-noise function of compute; per-task accuracy is noisy and can sit at chance for a long time, then jump.
    • The exponential maps loss to an error that saturates at ε (random or ceiling), which fits the flat-then-falling shape of averaged accuracy.
    • Averaging many tasks reduces noise. Selecting tasks above chance at small scale avoids tasks where the small models give no signal at all, the regime where "emergence" appears.
    • The cost is that the prediction only covers tasks that are already learnable at small scale; it says nothing about tasks that start at chance.
  3. Design

    You must pick model size and tokens for an embedding model that will serve billions of queries. Using this paper, design a small-scale study that tells you how far past 20 tokens per parameter you can go and how much quality you lose.

    What a strong answer covers
    • Train a grid of small models (for example 10M–400M) at several M from 20 to 640, as the paper did, on the target data.
    • Fit L(C, M), check that the exponents are parallel across M, and extrapolate to the planned size; validate with one larger hold-out run.
    • Add serving cost (FLOPs per query × expected queries) to training compute to choose M that minimises total cost at a target quality.
    • Check that the downstream metric (retrieval nDCG) tracks the LM loss; if not, fit a separate loss-to-metric link as the paper does for error.

Done with this page?

Status