Fix the Sampling Before the Regressor: LinMix Turns Data Mixing Into Attribution
Choosing a data mix is really estimating how much each domain contributes to a target score; moving the sample points from near-duplicate random mixes to decorrelated vertices is what makes a linear fit stand up, and it removes the need to search over mixes at all.
On this page
Lin leads pretraining at a small lab, where a single billion-parameter run is all the GPU budget allows this quarter, and the machine time is already booked. The call he has to make has no undo: how much web text, code and mathematics to blend into the training corpus, because once it is mixed there is no money for a second run. The team's existing routine is to write down a few dozen ratios, train one small model on each to scout the terrain, and then work backwards to the ratio that looks best. Everyone assumes that training a few more scouts, or using a fancier formula to work backwards, will make the ratio more accurate. The trouble sits in the step nobody questions: those random ratios all huddle around the mix the corpus already has, they look far too much alike, and so nothing reveals which kind of material is actually doing the work. Paper [1] argues that what needs changing first is not the backwards formula but how those ratios are scattered.
The Mix Decision, and the Fix That Keeps Missing
Unpack the jargon first. The corpus is split along source, topic or style into blocks the paper calls domains; the small models trained cheaply to scout the terrain are proxy models; and fitting an equation that predicts the final score from a mix is regression. Popular data-mixing methods run exactly this chain: scatter a set of domain weights at random, train one proxy model per set, fit a regression to the outcomes, and use the fitted equation to pick the most promising mix [1]. That is what Lin's team does, and what everyone thinks will rescue it is more proxy models and a fancier regressor.
The paper renames this practice, and the rename exposes the flaw. It is really a domain attribution problem, meaning each coefficient in the regression is supposed to be read as how much that domain contributes to the target metric [1]. Once it is attribution, the right question is whether those random mixes are a good set of observations. They are not. The standard approach draws weights from a Dirichlet distribution, in plain words a common recipe for generating random mixes, and the points it produces cluster around the corpus's original ratio, with domain weights rising and falling together and therefore highly correlated. Fit on such points and the contribution of any single domain cannot be separated. The paper goes further and proves that Dirichlet sampling inflates the attribution error precisely when its mixes concentrate around the prior data mix [1]. Lin can add proxy runs indefinitely and still be measuring the same near-identical points over and over, never isolating what he actually wants to separate.
Mixing as Attribution: Reading Coefficients as Contributions
Change the lens and the goal sharpens. Starting from linear datamodels, the paper shows the expected outcome of a proxy run is linear in its domain mix, with coefficients that aggregate sample-level attribution scores [1]. Linear here means the final score can be written as each domain weight times its own coefficient, summed up, and that coefficient is what the domain is worth. So asking which mix is best stops being a black-box search and becomes an estimation problem: estimate each coefficient well. How well you can estimate depends entirely on where you place the observation points, which is exactly the concern of classical optimal experimental design [1].
The experimental substrate is documented in detail. The main runs use the 200B-token WebOrganizer corpus, built from CommonCrawl web data and cleaned for pretraining; each document gets one of 24 topic labels and one of 24 format labels, and is cut into 2048-token sequences each drawn from a single domain [1]. Two granularities follow: 24 coarse domains from topics alone, and 288 fine-grained domains formed by the larger half of the 24 by 24 topic-format pairs, covering 94% of the corpus [1]. Three targets are optimised: ARC for scientific question answering, HellaSwag for commonsense reasoning, and HellaSwag combined with PIQA as a two-benchmark target; in each case the mix is tuned against proxy-model bits-per-byte on the benchmark's training split, and the target model's accuracy is reported on a held-out set, the test split for ARC and validation for HellaSwag and PIQA whose test labels are withheld [1]. Bits-per-byte, in plain words, scores how tightly a model compresses text, lower being better. A further setup optimises validation loss on the Common Pile corpus so the design is not tested only one way [1].
Why Vertex Sampling Lets a Linear Fit Stand Up
LinMix's change is almost too small to look like a new method: instead of tossing points into the interior of the mix space, it samples only at the vertices of the capped simplex. All legal mixes form a polytope, capped meaning each domain has an allowed upper limit, and its vertices are the extreme points where every domain is either at its cap or entirely absent [1]. This removes every tunable hyperparameter, and it decorrelates the domain effects, in plain words it stops each domain's contribution from being tangled with the others, so a linear model can be fitted directly and its coefficients are the domain attributions [1]. The paper also establishes the optimality of vertex sampling in this design sense [1].
| Sampling scheme | What the mixes look like | Effect on a linear fit | Tuning needed |
|---|---|---|---|
| Dirichlet sampling | Mostly clustered near the original ratio | Domain coefficients stay tangled; fit fails at hundreds of domains | Yes, defaults do not converge at 288 domains |
| Vertex sampling (LinMix) | Each domain at its cap or absent | Contributions separate; coefficients read as attributions | No, hyperparameter-free by construction |
Two benefits follow immediately. First, the paper proves that the optimal mix given by LinMix keeps only domains with positive attribution values and requires no search over candidate mixes at all [1]: estimate the coefficients and the answer is simply written there. Second, once a linear model stands, there is no need to compensate with nonlinear surrogates and per-setup tuning. The authors report that vertex sampling puts the interpretable linear model on par with the best nonlinear alternative, documenting fit quality with the cross-validated Spearman rank correlation between predicted and observed benchmark bits-per-byte as proxy models accumulate, and with R-squared in an appendix figure [1]. The baseline tells the other half: at 288 fine-grained domains the Dirichlet-based algorithm does not converge with the default hyperparameters tau equal to 2, lower bound 0.1 and upper bound 5, nor even with the upper bound raised to 10 [1]. At a few hundred domains only vertex sampling supports a linear fit [1], which is both an experimental observation and the hardest selling point of the design.
What the Pretraining Runs Show: 46, 14, 11 and 288
Theory aside, what happened when models were actually trained? The paper pretrains 1B-parameter OLMo2 and 4B Qwen3.5 language models and reports that LinMix outperforms Dirichlet-based data mixing across reasoning, code and math benchmarks, naming two relative gains: 46% on MBPP and 14% on GSM8K [1]. At 288 fine-grained domains, LinMix improves benchmark accuracy by 11% on average over the best nonlinear baseline [1]. These figures are copied from the paper; the 11% is its own reported average conclusion, not a number I computed here. The main table also states that LinMix with a linear model significantly improves data mixing at 288 domains and is on par or better at 24 domains [1]. It does not claim a win everywhere, and the coarse setting is close to a tie by the paper's own wording.
| Setup | Reported result | Note |
|---|---|---|
| 1B OLMo2 and 4B Qwen3.5 pretraining | Relative gains: 46% on MBPP, 14% on GSM8K | Across reasoning, code and math, versus Dirichlet mixes |
| 288 fine-grained domains | Only vertex sampling supports a linear fit | Baseline does not converge at default tau = 2 |
| 288 fine-grained domains | 11% average over best nonlinear baseline | Figure is the paper's own, not recomputed here |
| 40 domains, 416B-token corpus | Transfer to held-out HumanEval and MATH | Mixes optimised per target benchmark |
A second set of runs widens the plate: the 24-topic WebOrganizer is extended with Nemotron-CC-Math and Stack-Edu split into 15 programming languages, yielding a 416B-token corpus spanning 40 domains; mixes are still optimised with 40 domains for each target and evaluated on that target's held-out set plus a held-out benchmark [1]. The paper reports strong performance across language, coding and math benchmarks, with transfer to held-out ones such as HumanEval and MATH [1]. Two appendix ablations are worth noting without overstating them: scaling the linear coefficients by their standard error could improve performance, and transforming the utility of the mix towards its logarithm relaxes the 24-domain support for HellaSwag and yields better results [1]. These are exploratory appendix observations, not the main claim, and I repeat them with that caveat.
Where LinMix Stops: What It Does Not Decide For You
State the boundary clearly, so a paper about sampling design is not read as a recipe that works by magic. What it proves is narrow: inside the frame that treats a mix as linear attribution to be estimated, vertex sampling is the optimal design and Dirichlet sampling inflates error near the prior mix. It does not prove that any particular set of weights is optimal for your project, and it does not promise that switching to vertices wins on every benchmark and at every scale [1]. The following limits are either stated by the paper or visible directly in its setup.
- Conclusions are tied to the panel: the main runs use 24 and 288 domains on a 200B-token WebOrganizer corpus, the scaled run 40 domains on 416B tokens, so a different corpus or a different domain split means re-estimating the coefficients;
- Linearity is a premise, not a free gift: the expected outcome being linear in the mix, with coefficients aggregating sample-level attributions, rests on the linear-datamodel assumptions, and the paper only gets a linear fit to stand under vertex sampling;
- Proxy to target transfer has conditions: the paper says transfer depends on proxy training hyperparameters, with lower learning rates improving agreement with larger models' dataset rankings, so proxy results are not target results;
- Hyperparameters are gone, judgement is not: hyperparameter-free refers to the sampling step, while how to define domains, where to set caps, which target benchmarks to choose and how to hold out data still need a human decision;
- The relative gains have context: 46% and 14% are relative gains, the 11% is an average over the best nonlinear baseline at 288 domains, and the 24-domain setting is on par or better, so outperforming Dirichlet mixing is not the same as beating every method everywhere.
In short, LinMix fits the case where you can cut the corpus into capped domains, are willing to estimate coefficients as linear attributions, and will write down the proxy-training hyperparameters and the held-out evaluation [1]. If what you really want to know is how much of a material that never entered the corpus should get, or the domains themselves are ill-defined and the caps cannot be set, this method cannot answer that. Getting the domain definitions and the evaluation policy straight first beats another optimisation pass over the vertices.
