Predicting Model Performance › From Loss to Capabilities
Language AI HandbookAll chapters Predicting Model Performance › From Loss to CapabilitiesOne section · Sections in this chapter3 / 10 ↓
Reading tools Definitions & inline links
Choose your expertise level to adjust how many terms are explained. Beginners see more tooltips, experts see fewer to maintain reading flow. Hover over underlined terms for instant definitions.
Article links
Make inline references clickable
Predicting loss is useful for comparing training efficiency, but practitioners care about what models can do. Can a 70B model solve math problems? Will a 7B model follow complex instructions? Connecting loss predictions to capability predictions introduces significant challenges that go beyond the mathematical smoothness of loss curves.
The basic difficulty is that loss and capabilities measure different things. Loss is a continuous quantity that summarizes average prediction quality across millions of tokens. Capabilities are often binary or threshold-based: either the model can do the task or it can't. Bridging this gap requires understanding the relationship between average performance and specific task success, a relationship that can be highly nonlinear.
The Loss-Capability Disconnect
Test loss measures how well a model predicts the next token on average. Capabilities measure whether a model can perform specific tasks. These tasks often require chains of correct predictions or reasoning steps that loss doesn't directly capture. This distinction matters because a model could have excellent loss while failing at tasks that require sustained accuracy. Conversely, it could succeed at tasks despite mediocre average loss if it excels in the right places.
Mathematically, test loss is the cross-entropy averaged over all tokens:
Let's unpack what each symbol means and why this formula captures prediction quality:
- : the average loss across all tokens
- : the total number of tokens in the test set
- : the -th token in the sequence
- : all tokens preceding position (the context)
- : the model's predicted probability for the correct token given the context
The negative sign and logarithm work together in a specific way: when the model assigns high probability to the correct token, is close to zero (a small negative number, so the negative of it is a small positive number, a small penalty). When probability is low, becomes a large negative number, so the negative gives a large positive penalty. The logarithm is needed here because it makes the loss additive across independent predictions and penalizes confident wrong predictions more severely than uncertain ones.
Averaging over all tokens gives the mean prediction quality across the entire test set. This averaging is both a strength and weakness of loss as a metric. It's a strength because it provides a stable, complete measure that doesn't depend on which specific tokens we choose to examine. It's a weakness because the averaging obscures capability-relevant structure: a model might predict common words perfectly (low contribution to loss) while struggling with the rare but necessary tokens that determine task success.
Consider two hypothetical scenarios for a math problem where the final answer is a specific token:
- Model A predicts the correct answer token with 20% probability (wrong most of the time when sampling, adding to higher loss)
- Model B predicts it with 52% probability (right most of the time if we take the argmax)
The loss difference between these scenarios is modest, both models are far from certain. For Model A, the loss contribution from this token is . For Model B, it's . The difference of about 1 nat seems significant but represents just one token among thousands. Yet the capability difference is binary: Model A usually gets the answer wrong, Model B usually gets it right. This nonlinear relationship between loss and task success creates prediction challenges that no amount of loss extrapolation can fully address.
Emergent Capabilities and Phase Transitions
As we'll discuss in Part XXX on emergence, some capabilities appear suddenly as models scale rather than improving gradually with loss. This creates a limitation for extrapolation. If a capability is absent at all scales we've tested, we can't reliably predict when it will appear. The capability might emerge at the next doubling of scale, or it might require ten more doublings. Loss trends alone don't tell us.
Emergence often follows a sigmoid pattern rather than a power law. While loss decreases smoothly following , capabilities can transition from near-zero to near-perfect over a relatively narrow range of scales. Understanding this sigmoid pattern helps us recognize why capability prediction is fundamentally harder than loss prediction.
import numpy as np
from scipy.optimize import curve_fit
def sigmoid_emergence(x, threshold, steepness):
"""
Model sudden capability emergence with a sigmoid.
The sigmoid function captures how capabilities often emerge suddenly
rather than gradually. The formula is:
$$\sigma(x) = \frac{1}{1 + e^{-k(x - t)}}$$
where:
- $x$: the log-scale of the model ($\log_{10}$ of parameter count)
- $t$ (threshold): the scale at which capability reaches 50%
- $k$ (steepness): how sharply the transition occurs
The exponential in the denominator creates the characteristic S-shape:
- When $x \ll t$: the exponential dominates, output $\approx 0$
- When $x \gg t$: the exponential vanishes, output $\approx 1$
- When $x = t$: output $= 0.5$ exactly
"""
return 1 / (1 + np.exp(-steepness * (x - threshold)))
# Simulated capability scores at different scales
scales = np.array(
[10, 50, 100, 300, 500, 1000, 3000, 7000]
) # Millions of params
capability_scores = np.array([0.02, 0.05, 0.08, 0.15, 0.25, 0.72, 0.91, 0.96])
# Fit emergence curve
emergence_params, _ = curve_fit(
lambda x, t, s: sigmoid_emergence(np.log10(x), t, s),
scales,
capability_scores,
p0=[2.5, 3],
)The sigmoid function's mathematical properties explain why emergence feels sudden. The steepness parameter controls how rapidly the transition occurs: when is large, the function jumps quickly from near-zero to near-one. In log-scale (which is how we typically view model sizes), a steep sigmoid means that capability jumps from negligible to saturated over perhaps a single order of magnitude in scale. If our training runs span models from 10M to 300M parameters, and the transition happens around 1B, we see nothing but flat near-zero performance, giving no warning of the imminent jump.


@fig-capability-emergence illustrates the challenge: while loss (left) decreases smoothly and predictably with scale, capabilities (right) can exhibit sharp transitions. The left panel shows the gentle, monotonic curve that scaling laws capture well. Each doubling of scale yields a predictable improvement. The right panel shows a fundamentally different pattern: near-zero performance persists across multiple scale doublings, then capability rapidly emerges, then saturates near perfect. If we only have data from scales below 500M parameters, the capability curve appears nearly flat, giving no indication of the imminent jump. This is not a failure of our fitting procedure. It's a property of threshold-based capabilities.
Benchmark Score Prediction
For tasks that improve more gradually with scale, we can attempt direct prediction using transfer functions from loss to accuracy. The important observation is that accuracy often improves linearly with improvements in log-loss rather than raw loss. This makes intuitive sense. Reducing loss from 4.0 to 2.0 (a halving) is a much bigger deal than reducing from 2.0 to 1.5, even though the absolute reduction is smaller. The logarithmic relationship captures how capability gains become harder to achieve as performance improves.
import numpy as np
def loss_to_accuracy(loss, task_baseline, loss_ceiling, loss_floor):
"""
Map model loss to expected task accuracy using a log-linear transfer function.
The main idea is that accuracy improves linearly with log-loss improvements,
not with raw loss improvements. This reflects how each halving of loss
(a constant multiplicative improvement) yields roughly equal capability gains.
The formula computes:
$$\text{accuracy} = \text{baseline} + \text{progress} \times (1 - \text{baseline})$$
where:
$$
\text{progress} = \frac{\log(L_{\text{ceiling}}) - \log(L)}{\log(L_{\text{ceiling}}) - \log(L_{\text{floor}})}
$$
Args:
loss: Predicted model loss (L)
task_baseline: Random guess accuracy for the task (e.g., 0.25 for 4-way multiple choice)
loss_ceiling: Loss at which accuracy ≈ baseline (model performs at chance)
loss_floor: Loss at which accuracy approaches 1.0 (near-perfect performance)
The log-space interpolation means:
- A model at loss_ceiling has made 0% progress → accuracy = baseline
- A model at loss_floor has made 100% progress → accuracy ≈ 1.0
- Progress scales logarithmically between these bounds
"""
# Clip loss to valid range
loss_clipped = np.clip(loss, loss_floor, loss_ceiling)
# Linear interpolation in log-loss space
progress = (np.log(loss_ceiling) - np.log(loss_clipped)) / (
np.log(loss_ceiling) - np.log(loss_floor)
)
# Map to accuracy
return task_baseline + progress * (1.0 - task_baseline)
# Task-specific calibration (fit from existing model evaluations)
task_calibrations = {
"hellaswag": {"baseline": 0.25, "ceiling": 4.0, "floor": 1.2},
"mmlu": {"baseline": 0.25, "ceiling": 3.5, "floor": 1.5},
"arc_challenge": {"baseline": 0.25, "ceiling": 3.8, "floor": 1.4},
}The transfer function's structure encodes important assumptions about how capabilities emerge from improved language modeling. The baseline parameter captures the performance of a random guesser, for four-way multiple choice, this is 25%. The ceiling is the loss at which models perform no better than random. Below this loss, capability begins to emerge. The floor is the loss at which capability saturates near 100%. Between ceiling and floor, we interpolate linearly in log-loss space.
This parameterization requires calibration data: we need to have observed models across a range of losses on each specific task to fit the ceiling and floor values. Different tasks have different calibrations because they depend on loss in different ways. A task requiring rare factual knowledge might need very low loss before accuracy improves, while a task testing common patterns might show improvement at higher loss.

Predicted benchmark scores for extrapolated models: ------------------------------------------------------------ 1B model (predicted loss: 2.139): hellaswag : 64.0% mmlu : 68.6% arc_challenge : 68.2% 7B model (predicted loss: 1.920): hellaswag : 70.7% mmlu : 78.1% arc_challenge : 76.3% 70B model (predicted loss: 1.684): hellaswag : 78.9% mmlu : 89.8% arc_challenge : 86.1%
These capability predictions rely on task-specific calibration curves fit from previous evaluations. The accuracy improves only as quickly as the underlying calibration data allows. If we've never seen models with loss below 2.0 on a task, we're extrapolating the loss-accuracy relationship as well as the loss itself. This compounds the uncertainty: we're extrapolating one uncertain prediction through another uncertain function.