Abstract
Scaling laws are fundamental to understanding and predicting the performance of Large Language Models (LLMs) as a function of compute, data, and parameters. However, as model architectures grow in complexity, manually deriving these laws has become increasingly difficult. We introduce SLDAgent, an evolutionary system that automates the discovery of neural scaling laws. By co-optimizing mathematical expressions alongside their numerical fitting routines, SLDAgent explores a vast space of potential laws. Our evaluation on SLDBench, a new benchmark of over 5,000 scaling experiments, shows that SLDAgent significantly outperforms human experts and existing automated methods in predictive accuracy.
Introduction
In the development of LLMs, scaling laws provide the roadmap for efficient training. Classic examples like the Chinchilla Law allow researchers to extrapolate the performance of massive models from small-scale pilot studies. Yet, the manual process of proposing formulas and fitting parameters is labor-intensive and often relies on human intuition that may not capture the nuances of modern architectures like Mixture-of-Experts (MoE). This paper addresses whether an AI agent can autonomously discover the mathematical principles governing its own scaling behavior.
Methodology: The SLDAgent Framework
The core of our approach is SLDAgent, which treats scaling law discovery as a program evolution task. Unlike simple prompting methods, SLDAgent employs a co-optimization strategy that evolves two distinct Python subroutines:
- Expression Subroutine: Defines the symbolic mathematical model (e.g., variants of power laws).
- Optimization Subroutine: Defines the numerical algorithm used to fit the model's parameters to experimental data.
By evolving the fitting code in tandem with the formula, the agent can discover specialized optimization strategies tailored to specific mathematical structures. The system utilizes a multi-island evolutionary strategy and MAP-Elites to maintain a diverse population of candidate laws, ensuring robust exploration of the search space.
Experimental Setup: SLDBench
To evaluate discovery agents, we curated SLDBench, a comprehensive benchmark comprising 5,000+ experiments across eight diverse scenarios, including vocabulary size effects, supervised fine-tuning (SFT), and Mixture-of-Experts (MoE) scaling. The primary metric is the agent's ability to extrapolate: predicting performance for models and datasets significantly larger than those seen during the discovery phase.
Results and Discussion
SLDAgent demonstrates superhuman performance across the SLDBench suite. When powered by GPT-5, the agent achieved an average $R^2$ score of 0.748, compared to the human expert baseline of 0.517.
Key Insights
- Co-Optimization Efficacy: Ablation studies confirm that evolving the optimizer is as crucial as evolving the formula. Agents using fixed, off-the-shelf optimizers performed significantly worse.
- Dimensional Consistency: Discovered laws often exhibited "principled" mathematical properties, such as dimensionless ratios, which improved robustness in long-range extrapolation.
- Practical Application: The discovered laws were successfully applied to zero-shot hyperparameter optimization. For a 1B-parameter model, the agent-derived law predicted an optimal training configuration that resulted in a validation loss within 0.067% of the true experimental optimum.
Conclusion and Future Work
SLDAgent represents a significant step toward automated scientific discovery in AI. While current results are promising, future work will focus on expanding the benchmark to multimodal scaling and enabling the agent to propose entirely new variables for measurement. This "AI for Science" approach suggests that LLMs can indeed uncover the fundamental laws governing their own growth and evolution.
Summary updated