Hyperparameter Transfer with Mixture-of-Expert Layers
Tianze Jiang, Blake Bordelon, Cengiz Pehlevan, Boris Hanin
TL;DR
This paper tackles the costly problem of hyperparameter tuning in large Mixture-of-Experts (MoE) transformers by developing a DMFT-grounded parameterization that enables HP transfer across width, depth, and MoE dimensions while preserving sparsity. Building on the max-update ($\mu$P) and CompleteP scaling framework, the authors extend these principles to MoE layers, deriving explicit initialization and learning-rate rules for router weights, expert projections, and biases, and proving scale-invariant dynamics in the dynamical mean-field theory (DMFT) limit. Empirically, HPs identified from small models transfer robustly to larger models and longer training horizons, with uniform expert load, and MoE models achieving competitive performance relative to dense baselines under fixed token budgets. The work provides both theoretical and practical foundations for MoE scaling laws and offers concrete guidance for stable, scalable MoE training, opening avenues for longer horizons and broader HP exploration in sparse transformers.
Abstract
Mixture-of-Experts (MoE) layers have emerged as an important tool in scaling up modern neural networks by decoupling total trainable parameters from activated parameters in the forward pass for each token. However, sparse MoEs add complexity to training due to (i) new trainable parameters (router weights) that, like all other parameter groups, require hyperparameter (HP) tuning; (ii) new architecture scale dimensions (number of and size of experts) that must be chosen and potentially taken large. To make HP selection cheap and reliable, we propose a new parameterization for transformer models with MoE layers when scaling model width, depth, number of experts, and expert (hidden) size. Our parameterization is justified by a novel dynamical mean-field theory (DMFT) analysis. When varying different model dimensions trained at a fixed token budget, we find empirically that our parameterization enables reliable HP transfer across models from 51M to over 2B total parameters. We further take HPs identified from sweeping small models on a short token horizon to train larger models on longer horizons and report performant model behaviors.
