OPUS: Towards Efficient and Principled Data Selection in Large Language Model Pre-training in Every Iteration
Shaobo Wang (Shanghai Jiao Tong University), Xuan Ouyang, Tianyi Xu, Yuzheng Hu, Jialin Liu, Guo Chen, Tianyu Zhang, Junhao Zheng, Kexin Yang, Xingzhang Ren, Dayiheng Liu, Linfeng Zhang
Overview
In this talk, Shaobo Wang from Shanghai Jiao Tong University presents OPUS (Optimizer-induced Projected Utility Selection), a novel framework for dynamic data selection in large language model (LLM) pre-training developed in collaboration with Alibaba Qwen. As the machine learning community approaches the limits of publicly available human-generated text, brute-force scaling of token counts is becoming economically and physically unsustainable. While scaling laws dictate that data quality can shift the entire loss curve downward rather than merely moving along diminishing returns, existing data selection methods fall short. Static filters score documents only once before training begins, failing to adapt as the model learns, while dynamic gradient-based selectors rely on plain Stochastic Gradient Descent (SGD) geometry, ignoring the preconditioners used by modern optimizers like AdamW or Muon.

Key moments
- 0:00 Introduction and motivation for data selection in LLM pre-training
- 2:00 The data wall and limits of data repetition
- 4:00 Limitations of static filters and dynamic gradient-based selectors
- 5:30 Core principle: Optimizer-induced projected utility with OPUS
- 7:00 Bench-proxy: Constructing an in-distribution benchmark-directed validation set
- 8:00 Efficiency techniques: Ghost gradients and count-sketch at scale
- 10:00 Experimental results on GPT-2 and Muon/AdamW optimizers
- 11:30 Continued pre-training gains and toxicity filtering case study
OPUS: Towards Efficient and Principled Data Selection in Large Language Model Pre-training in Every Iteration
Speakers: Shaobo Wang (Shanghai Jiao Tong University); Xuan Ouyang; Tianyi Xu; Yuzheng Hu; Jialin Liu; Guo Chen; Tianyu Zhang; Junhao Zheng; Kexin Yang; Xingzhang Ren; Dayiheng Liu; Linfeng Zhang
Conference: ICML
YouTube: https://slideslive.com/39083534
Overview
In this talk, Shaobo Wang from Shanghai Jiao Tong University presents OPUS (Optimizer-induced Projected Utility Selection), a novel framework for dynamic data selection in large language model (LLM) pre-training developed in collaboration with Alibaba Qwen. As the machine learning community approaches the limits of publicly available human-generated text, brute-force scaling of token counts is becoming economically and physically unsustainable. While scaling laws dictate that data quality can shift the entire loss curve downward rather than merely moving along diminishing returns, existing data selection methods fall short. Static filters score documents only once before training begins, failing to adapt as the model learns, while dynamic gradient-based selectors rely on plain Stochastic Gradient Descent (SGD) geometry, ignoring the preconditioners used by modern optimizers like AdamW or Muon.
OPUS resolves these limitations by defining data utility with respect to the actual update applied by the optimizer, coupling it with a benchmark-directed validation signal (bench-proxy), and accelerating computation through ghost techniques and count-sketch projections. Operating at industrial pre-training scales with an overhead of only 4.7%, OPUS achieves massive data efficiency gains—such as matching the performance of models trained on double the token count—and consistently outperforms both static filters and existing dynamic selection baselines across multiple model scales.
Background
▶ Watch: Introduction and motivation for data selection in LLM pre-training (0:00)
The economic and computational realities of LLM pre-training are governed by scaling laws, most notably the Chinchilla scaling law. This law dictates that a model's loss decomposes into three components: an irreducible entropy term, a model size term, and a data term. In practical engineering settings, the model size ($N$) is fixed in advance by inference budgets, serving costs, and hardware constraints. Once $N$ is frozen, the model term becomes a constant, leaving the data term as the sole lever to drive loss downward. However, the data term decays as $D^{-\beta}$ with an exponent $\beta \approx 0.28$, a painfully flat trajectory where cutting the loss gap in half requires roughly a 10× increase in data volume.
This challenge is compounded by the data wall. Projections indicate that the total stock of human-generated public data—which remains essentially flat year-over-year—will intersect with frontier LLM training data consumption curves between 2026 and 2028. While practitioners might consider training on the same data for multiple epochs, repetition cannot substitute for fresh tokens; prior work shows that returns from repeated data decay exponentially, with repetition beyond roughly 16 epochs contributing almost nothing.
To break this bottleneck, the field must transition from accumulating more tokens to selecting better tokens. Existing approaches divide into two categories:
- Static filters (such as perplexity filters, deduplication methods, and quality classifiers like FineWeb-EDU): These score each document once offline before training starts. They are training-agnostic, treating a document identically whether the model is at step zero or step one million, despite the fact that easy patterns are exhausted early and useful data frontiers shift over time.
- Dynamic selectors: These select data on-the-fly using gradient-based influence functions, but their formulations assume plain SGD geometry. Because frontier models are trained using AdamW or Muon, raw gradient scoring misaligns with the actual weight updates applied during training.
Key Findings
▶ Watch: Limitations of static filters and dynamic gradient-based selectors (4:00)
OPUS addresses these foundational discrepancies by introducing an optimizer-aware selection mechanism that operates efficiently at pre-training scale. The key findings and performance outcomes include:
- Superior Downstream Performance: When pre-training GPT-2 Large and GPT-2 XL on the FineWeb dataset for 30 billion tokens under the Muon optimizer, OPUS achieved the highest average performance across 10 benchmarks covering knowledge, reasoning, and common sense, outperforming all static filters and dynamic selectors. Similar dominance was observed under the AdamW optimizer.
- Outperforming Superior Static Subsets: In a deliberately stacked comparison against FineWeb-EDU, OPUS selected strictly from the lower-quality mid-tier pool (score 3), while baseline models trained on the superior subsets (scores 4 and 5). Despite starting with lower-quality candidate text, OPUS surpassed the baselines.
- Drastic Convergence Acceleration: On GPT-2 XL, OPUS reached the validation loss of a randomly sampled model trained on 60 billion tokens using only 17 billion tokens, representing roughly a 3.5× acceleration in convergence speed.
- Domain Perplexity and Continued Pre-training: Evaluated on held-out sets across 10 domains, OPUS outperformed competing methods in domain perplexity. In continued pre-training experiments on Qwen2-8B-Base using the Science-Pythia dataset, OPUS improved domain knowledge and scientific reasoning, achieving peak performance using only 0.5 billion tokens—a 6× data efficiency gain over random baseline selection.
- Zero-Shot Toxicity Detection: A single OPUS scoring pass applied to a mixed corpus of clean and toxic documents successfully separated well-formed text from toxic content without requiring any dedicated training or classification labels.
Technical Design & Architecture
▶ Watch: Bench-proxy: Constructing an in-distribution benchmark-directed validation set (7:00)
The architecture of OPUS is built around three core requirements: being principled (aligned with the true optimizer update), reliable (guided by an in-distribution, benchmark-directed validation signal), and efficient (affordable at industrial pre-training scale).
Optimizer-Aware Utility Formulation
Every first-order optimization method can be expressed as an update step:
$$\Delta\theta = P_t \cdot g$$
where $P_t$ is the preconditioner applied to the gradient $g$.
- For SGD, $P_t$ is the identity matrix ($P_t = I$).
- For AdamW, $P_t$ is a diagonal preconditioner inversely proportional to the square root of the exponential moving average of squared gradients ($\frac{1}{\sqrt{v_t + \epsilon}}$), giving every coordinate its own adaptive step size.
- For Muon, $P_t$ is matrix-valued, orthogonalizing each weight matrix update via Newton-Schulz iterations to mix and rotate coordinates.
OPUS evaluates data utility not on the raw gradient, but on the effective update $P_t g$. Using a first-order Taylor expansion, the utility of a candidate sample is decomposed into two terms:
- Importance: Measures how well the sample’s effective update aligns with a validation direction (i.e., whether the sample moves the model parameters toward the desired optimization goal).
- Diversity: A penalty on redundancy within the selected batch to prevent the model from wasting capacity on near-duplicate samples.
Batches are subsequently selected using Boltzmann sampling over these computed scores.
Bench-Proxy Validation Set
Defining a proper validation set ($D_{\text{val}}$) presents a dilemma: raw benchmark data introduces severe distribution shifts from pre-training text alongside high gradient noise due to tiny sample sizes, whereas a random held-out split is stable but blind to downstream capabilities.
OPUS resolves this via bench-proxy. Using a frozen text encoder, the system embeds benchmark validation samples and the pre-training corpus, maximizing cosine similarity to retain top documents within a 30-million-token budget. This constructs a proxy pool that remains in-distribution (pre-training text) while being strictly benchmark-directed. At each step, mini-batches are drawn from this pool to establish the proxy gradient direction.
Scaling via Ghost Techniques and Count-Sketch
Calculating per-sample gradients naively requires one backpropagation pass per candidate, imposing a prohibitive 35× computational slowdown. OPUS overcomes this bottleneck using two systems optimizations:
- Ghost Technique: For linear layers, a per-sample gradient is a rank-one outer product of forward and backward activations. By decomposing inner products into separate terms, the computational complexity is dramatically reduced.
- Count-Sketch: The computation is projected into an 8,192-dimensional space, bounding the cost to be strictly linear in layer width for diagonal preconditioners.
Combined, these mechanisms limit the total overhead of OPUS to 4.7% over standard random data selection.
Experimental Setup & Results
▶ Watch: Efficiency techniques: Ghost gradients and count-sketch at scale (8:00)
- Models Evaluated: GPT-2 Large, GPT-2 XL, and Qwen2-8B-Base.
- Datasets: FineWeb, FineWeb-EDU, and Science-Pythia.
- Training Scale: Pre-training runs spanned 30 billion tokens (for GPT-2 variants) and 0.5 billion tokens (for continued pre-training on Qwen2-8B).
- Evaluation Metrics: Loss trajectory convergence speed, average downstream accuracy across 10 knowledge, reasoning, and common sense benchmarks, and domain perplexity across 10 distinct domains.
- Baseline Comparisons: Compared against static filters (perplexity filters, deduplication, FineWeb-EDU quality scores) and dynamic gradient-based selection methods relying on standard SGD geometry.
- Headline Results: OPUS achieved up to a 3.5× convergence speedup on GPT-2 XL (matching 60B token performance in 17B tokens) and a 6× data efficiency gain on Qwen2-8B, consistently outperforming superior static data subsets even when restricted to lower-tier (score 3) candidate pools.
Practical Implications
▶ Watch: Continued pre-training gains and toxicity filtering case study (11:30)
For infrastructure teams, model builders, and training deployers, OPUS establishes that optimizer geometry cannot be ignored when performing dynamic data selection. Treating optimizer states (such as AdamW's momentum denominators or Muon's orthogonalized matrix updates) as incidental implementation details leads to misaligned gradient utilities that degrade selection quality.
The practical overhead of 4.7% demonstrates that advanced, principled data selection is no longer restricted to offline filtering or academic simulations; it is viable at industrial pre-training scales. Practitioners operating under strict data scarcity or high compute costs can leverage OPUS to extract significantly higher intelligence per token, effectively extending the economic runway of pre-training corpora in the post-data-wall era. However, deployers must integrate the bench-proxy pipeline into their data-loading infrastructure, requiring a frozen text encoder and auxiliary storage for proxy pools alongside standard data loaders.
Key Takeaways
- The Era of More Tokens is Ending: Exhaustion of public human-generated text and diminishing returns from data repetition make intelligent data selection an absolute requirement for future LLM pre-training.
- Optimizer-Aware Geometry Matters: Data utility must be evaluated on the effective update applied by the optimizer ($P_t g$), accounting for preconditioners in AdamW and Muon rather than relying on plain SGD gradients.
- Bench-Proxy Bridges the Validation Gap: Combining pre-training text distribution with benchmark-directed embedding matching yields a stable, high-utility validation signal.
- Industrial Efficiency Achieved: Through ghost gradient decomposition and count-sketch projections, OPUS limits runtime overhead to just 4.7% over random selection.
- Substantial Efficiency Gains: OPUS delivers up to a 3.5× speedup in loss convergence and a 6× improvement in data efficiency on frontier model architectures.
About the Speaker(s)
- Shaobo Wang (Shanghai Jiao Tong University): Researcher from Shanghai Jiao Tong University who conducted work on pre-training data selection in collaboration with Alibaba.
Co-authors: Xuan Ouyang, Tianyi Xu, Yuzheng Hu, Jialin Liu, Guo Chen, Tianyu Zhang, Junhao Zheng, Kexin Yang, Xingzhang Ren, Dayiheng Liu, Linfeng Zhang.
Reviews
→ Top-rated talks at International Conference on Machine Learning 2026
All talks from International Conference on Machine Learning 2026