Inference Scaling › Over-Training for Deployment Efficiency

Michael BrenndoerferOctober 27, 20259 min read
Language AI HandbookAll chapters
Part 23 of 67Scaling Laws
Chapter 167Inference Scaling › Over-Training for Deployment Efficiency
Reading section 4 of 11 · Over-Training for Deployment Efficiency · 9 minSection 4 of 11 · 9 min

Book contents

Section 4 of 11 · 9 min read

Inference Scaling › Over-Training for Deployment EfficiencyOne section · Sections in this chapter4 / 11 ↓

"Over-training" refers to training a model on more tokens than Chinchilla optimality would suggest. The term is slightly misleading, as it's only "over" training relative to compute-optimal. It's exactly the right amount of training for inference-optimal deployment. Think of it not as excessive training but as investing additional training compute to reduce inference costs later.

The LLaMA Philosophy

The LLaMA model family explicitly adopted this philosophy. The LLaMA paper states: "We only consider the performance of the resulting model, not the training compute budget." They trained 7B, 13B, 33B, and 65B parameter models on up to 1.4 trillion tokens. This is far more than Chinchilla ratios would suggest for the smaller models.

This statement is a philosophical break from the Chinchilla paradigm. Rather than asking how to minimize training compute, Meta's researchers asked how to maximize the value delivered per inference FLOP. This reframing led to models that were "inefficient" to train but were much more efficient to deploy.

For the 7B model, Chinchilla optimality would suggest around 140B tokens. Training on 1.4T tokens is 10× "over-training." This extra training compute is an investment that pays dividends at inference time through reduced per-token cost. Every additional training token helps the smaller model close the capability gap with larger alternatives, which makes it suitable for tasks that would otherwise require a more expensive model.

The Over-Training Ratio

We can quantify over-training with a simple ratio that captures how far a model departs from Chinchilla-optimal training:

Over-training ratio=DactualDoptimal=Dactual20N\text{Over-training ratio} = \frac{D_{actual}}{D_{optimal}} = \frac{D_{actual}}{20N}

where:

  • DactualD_{actual}: the number of tokens used to train the model
  • DoptimalD_{optimal}: the Chinchilla-optimal number of tokens for a model of size NN
  • NN: the number of model parameters
  • 20N20N: the Chinchilla approximation that optimal training uses roughly 20 tokens per parameter

This ratio gives a simple metric for characterizing how inference-optimized a model's training regime is. A ratio of 1 means the model was trained according to Chinchilla-optimal principles. Ratios greater than 1 indicate over-training for inference efficiency, with higher values representing more aggressive investment in training compute to reduce inference costs.

The table below shows typical over-training ratios for inference-optimized models:

Over-training ratios for inference-optimized models compared to Chinchilla-optimal training.
ModelParametersTokensChinchilla OptimalOver-training Ratio
LLaMA-7B7B1.4T140B10×
LLaMA-13B13B1.4T260B5.4×
Mistral-7B7B~8T140B~57×
Phi-22.7B1.4T54B26×

Modern inference-optimized models routinely use over-training ratios of 10× to 50× or more. The trend toward higher ratios shows growing recognition that inference costs dominate for production systems. Mistral's 57× over-training ratio on their 7B model shows how far this philosophy has been pushed. They invested roughly 57 times more training compute than Chinchilla would recommend. They bet that the resulting inference efficiency would more than compensate.

Out[5]:
Visualization
Grouped bar chart comparing actual training tokens versus Chinchilla-optimal tokens for LLaMA-7B, LLaMA-13B, Phi-2, and Mistral-7B, with red over-training ratio annotations showing values ranging from 5x to 57x above optimal.
Over-training ratios for inference-optimized models. Chinchilla-optimal corresponds to a ratio of 1 (dashed line). Modern models routinely train on 10-50× more data than Chinchilla prescribes, investing in training compute to reduce inference costs.

When Over-Training Pays Off

Over-training makes economic sense when total inference compute exceeds the extra training compute required. Let's formalize this break-even analysis.

Suppose you have two options:

  • Option 1: Train a large model N1N_1 on D1D_1 tokens (Chinchilla-optimal)
  • Option 2: Train a smaller model N2<N1N_2 < N_1 on D2>D1D_2 > D_1 tokens to match Option 1's loss

The additional training cost for Option 2 is:

ΔCtrain=6N2D2−6N1D1\Delta C_{train} = 6N_2D_2 - 6N_1D_1

where:

  • ΔCtrain\Delta C_{train}: the difference in training compute between the two options
  • N1,N2N_1, N_2: parameter counts for Option 1 (larger) and Option 2 (smaller) respectively
  • D1,D2D_1, D_2: training tokens for Option 1 and Option 2 respectively

This difference can be positive or negative depending on the specific model sizes and training durations. If the smaller model requires enough additional training to offset the reduced parameter count, ΔCtrain\Delta C_{train} will be positive, representing an upfront investment that must be recouped through inference savings.

The inference savings per token generated are:

ΔCinference=2(N1−N2)\Delta C_{inference} = 2(N_1 - N_2)

Here, ΔCinference\Delta C_{inference} is the FLOPs saved per output token by using the smaller model (since each forward pass requires 2N2N FLOPs per token).

This quantity is always positive when N1>N2N_1 > N_2, meaning smaller models always save inference compute regardless of how they were trained. The magnitude of these savings grows linearly with the difference in model sizes. A 63B parameter reduction saves 63 billion fewer multiply-add operations per token.

Over-training pays off when total inference tokens TinferenceT_{inference} satisfies:

Tinference×ΔCinference>ΔCtrainT_{inference} \times \Delta C_{inference} > \Delta C_{train} Tinference>6N2D2−6N1D12(N1−N2)T_{inference} > \frac{6N_2D_2 - 6N_1D_1}{2(N_1 - N_2)}

This break-even analysis determines whether the inference savings justify the training investment. The inequality has a clear interpretation: the left side is cumulative inference savings over the model's deployment, while the right side is the upfront training cost differential. When expected inference volume exceeds the break-even point, the smaller over-trained model becomes the economically rational choice.

Worked Example: Break-Even Analysis

Let's work through a concrete comparison between a 70B Chinchilla-optimal model and a 7B over-trained model, both achieving similar loss. This example illustrates the practical magnitude of the cost differences and helps build intuition for deployment decisions.

Option 1: 70B model, 1.4T tokens

  • Training: 6×70B×1.4T=5.9×10236 \times 70B \times 1.4T = 5.9 \times 10^{23} FLOPs
  • Inference: 2×70B=1.4×10112 \times 70B = 1.4 \times 10^{11} FLOPs/token

Option 2: 7B model, 4T tokens (assume this matches 70B model's loss)

  • Training: 6×7B×4T=1.68×10236 \times 7B \times 4T = 1.68 \times 10^{23} FLOPs
  • Inference: 2×7B=1.4×10102 \times 7B = 1.4 \times 10^{10} FLOPs/token

In this case, Option 2 costs less to train. This can happen when targeting a specific loss level rather than frontier performance. The inference savings are:

ΔC=1.4×1011−1.4×1010=1.26×1011 FLOPs/token\Delta C = 1.4 \times 10^{11} - 1.4 \times 10^{10} = 1.26 \times 10^{11} \text{ FLOPs/token}

Every inference token saves 1.26×10111.26 \times 10^{11} FLOPs, and there's no training penalty. This is a best-case scenario where the over-trained model wins on both training and inference efficiency. It highlights how the conventional wisdom about "larger models being better" can be misleading for deployment contexts.

Even when over-training does cost more, break-even typically occurs at modest inference volumes. If the 7B model required 102410^{24} FLOPs to train (an additional 8×10238 \times 10^{23} FLOPs over the 70B option), the break-even would be:

Tbreak-even=8×10231.26×1011≈6.3×1012 tokensT_{\text{break-even}} = \frac{8 \times 10^{23}}{1.26 \times 10^{11}} \approx 6.3 \times 10^{12} \text{ tokens}

At 500 tokens per request, that's about 12.6 billion inference requests, easily exceeded by any widely-deployed model. To put this in perspective, a popular API serving just 10,000 users, each making 10 requests per day, would reach this break-even point in roughly 3.4 years. For consumer-scale deployments with millions of users, break-even occurs within days or weeks of launch.

Out[6]:
Visualization
Line chart showing cumulative inference savings growing linearly against total inference tokens in trillions, with a horizontal dashed red line marking the additional training cost and a break-even point labeled at approximately 6.3 trillion tokens where savings surpass costs.
Break-even analysis for over-training investment. The cumulative inference savings (blue) grow linearly with tokens generated. Once savings exceed the additional training investment (red dashed line), the over-trained model becomes more economical.