The Hidden Ratio in Adam: Stable Structure, Compression, and Sign Dynamics

Yihe Zhou, Tongtian Zhu, Yingxiao Huo, Satya Prakash Dash, Can Wang, Samuel Kaski, Mingfei SunNeurIPS 2026

TL;DR

Adam is the undisputed workhorse of modern deep learning, yet the tangled dance between its moving averages makes it notoriously hard to interpret—and expensive to store in memory. By looking at Adam when its two decay rates are equal, the authors uncover a "hidden ratio" tucked inside its math that obeys a surprisingly universal, unchanging statistical law across models and training stages. Exploiting this invariant shape lets us crush Adam’s second-moment memory footprint down to a static 4-bit lookup table with virtually zero loss in performance, while neatly unifying Adam with sign-based optimizers.

What Problem Does This Paper Address?

If you are training a neural network tonight, you are probably using Adam. Under the hood, Adam tracks two exponential moving averages (EMAs) for every parameter: the gradient's mean ($m_t$, controlled by decay rate $\beta_1$) and its squared magnitude ($v_t$, controlled by $\beta_2$). Dividing the first by the square root of the second gives each parameter a custom step size.

Here is the catch: the raw values of $m_t$ and $v_t$ swing wildly across layers, tasks, and training steps, making Adam’s inner workings difficult to characterize cleanly and forcing engineers to burn precious GPU memory storing high-precision optimizer states (or complex per-block scaling metadata to quantize them). Recently, large-scale LLM recipes have drifted toward setting $\beta_1$ and $\beta_2$ very close together. The authors ask: if we go all the way to the tied-$\beta$ regime ($\beta_1 = \beta_2 = \beta$), does the mathematical fog clear up?

Methods

In standard Adam, you store $(m_t, v_t)$. When $\beta_1 = \beta_2 = \beta$, the quantity $v_t - m_t^2$ acts cleanly like an online variance. The authors factor out the deterministic $\beta$-scaling and define a transformed ratio:

$$y_t = \frac{1-\beta}{\beta}\left(\frac{v_t - m_t^2}{m_t^2}\right)$$

With this substitution, Adam’s parameter update splits cleanly in two: the direction is purely $\text{sign}(m_t)$, and the step size is attenuated by $(1 + \frac{\beta}{1-\beta}y_t)^{-1/2}$.

Instead of computing $v_t$ at all, the authors derive an exact scalar recursion to update $y_t$ directly from its previous value and the ratio $x_t = m_{t-1}/m_t$. This reparameterizes Adam's state from $(m_t, v_t)$ to $(m_t, y_t)$—which they call TR-Adam. Because $y_t$ turns out to live in a predictable numerical range, they throw away dynamic quantization scales altogether and snap $y_t$ to the nearest neighbor in a fixed 4-bit codebook (16 hard-coded numbers ranging from $0.25$ to $64$). Finally, they show that replacing the fluctuating $y_t$ with a single constant ($y_{\text{const}}$) reduces Adam to Signum (momentum-based SignSGD) with an explicit, pre-calibrated learning rate.

Datasets

Specific training and evaluation dataset names are not discussed in the main text of the paper (though standard LLM pre-training, supervised fine-tuning [SFT], and RLHF/ReMax pipelines are evaluated on Llama-20M, Pythia-160M, Pythia-1B, and Llama-3.2-1B-Instruct models; references point toward UltraFeedback and UltraChat, with exact setups deferred to the appendices). No new benchmarks are introduced.

Key Insights and Ideas

  • A Universal Statistical Fingerprint: While raw gradients vary by orders of magnitude, $y_t$ settles into a remarkably stable, scale-free distribution: a tight single-digit bulk with a heavy right tail, closely matching an inverse-square Gaussian law $2/Z^2$ where $Z \sim \mathcal{N}(0,1)$. It looks nearly identical whether you are pre-training from scratch or running RLHF.
Figure 2: Distribution of the transformed ratio yt across training regimes. Columns correspond to β = 0.90, 0.92, 0.95, while rows compare pretraining on Pythia-160M, supervised fine-tuning on Pythia-1B, and RLHF on Llama-3.2-1B-Instruct. Within each block, the top panel shows the CDF and the bottom panel shows the histogram; colors denote early, middle, and late training stages.
  • Pointwise Precision in the Denominator is Overrated: Chopping off $y_t$'s extreme tail above $64$ and rounding the rest to just 16 fixed values barely nudges the validation loss. Adam doesn't care about the exact variance at every step—only coarse local noise-to-signal attenuation.
  • Free Learning-Rate Transfer to Signum: Signum normally requires an annoying, separate hyperparameter sweep because its optimal learning rate shifts drastically as $\beta$ changes. Viewing Adam as "Signum + $y_t$ attenuation" predicts that $y_t$'s average effect equals a constant slightly above $3$ ($y_{\text{const}} \approx 3.1\text{–}3.4$). Plugging $y_{\text{const}} \in \{3, 5\}$ into the update lets a state-free Signum-style optimizer piggyback directly on standard Adam learning rates.

Key Results

  • Diagnostic Coarsening: Simply truncating $y_t$ at $64$ and applying 4-bit quantization changes final pre-training validation loss by at most $+0.0063$ (and at $\beta=0.95$, slightly improves it by $-0.0010$).
Figure 3: Comparison of the training performance of standard Adam and its modified variants based on the transformed ratio yt, including long-tail truncation and coarse 4-bit quantization. Even after truncating the right tail and representing the remaining bulk with only 16 quantization levels, the resulting optimizer still closely tracks the behavior and final performance of the standard Adam.
  • Full Pipeline Quantization (TR-Adam): Across Pythia-160M (4B tokens) and Pythia-1B (20B tokens) pre-training, SFT, and Llama-3.2-1B RLHF, recursive TR-Adam with a 4-bit $y_t$—even when paired with an FP8 first moment $m_t$ and zero per-block scaling metadata—overlays full-precision Adam's loss curves almost perfectly, and occasionally edges it out late in SFT/RLHF.
  • Learning-Rate Sweeps: On Llama-20M across $\beta \in \{0.90, 0.92, 0.95, 0.97\}$, TR-Adam preserves the exact optimal learning-rate basin of full-precision Adam, while constant-state proxies ($y_{\text{const}} \in \{3, 5\}$) successfully prevent the leftward learning-rate drift seen in vanilla Signum.

Limitations and Future Work

  • Tied-$\beta$ Only: The clean variance math and scale-free distribution rely strictly on $\beta_1 = \beta_2$. It does not claim to beat untied Adam ($\beta_1 < \beta_2$) everywhere.
  • Emulated Compression: The 4-bit and FP8 states were simulated inside FP32 tensors to test mathematical viability; writing custom GPU kernels to realize actual wall-clock speedups and VRAM savings is left for future work.
  • Scale and Architecture Scope: Main experiments focus on Transformer language models up to 1B parameters (with only brief MLP/ResNet and early-stage 8B checks in the appendix). Scaling full training runs beyond 1B parameters and across diverse architectures remains open.

Summary updated

Abstract

Adam is the default optimizer for training modern deep neural networks, yet its adaptive behavior remains poorly understood due to the complex interaction between its first- and second-moment exponential moving averages (EMAs). We study Adam in the tied-$\beta$ regime, where the two EMA decay rates are equal, and show that its adaptive dynamics can be expressed through a transformed ratio with approximately scale-stable behavior. Empirically, this transformed ratio exhibits a stable, heavy-tailed distribution across tasks, model scales, and training stages, in contrast to the variability of raw moment magnitudes. This empirical stability has both practical and conceptual consequences. First, we derive a recurrence for the transformed ratio, yielding a reparameterization of Adam that replaces the second moment with a compressible state. Leveraging its stable distribution, we show that a fixed 4-bit codebook is sufficient in our experiments to store this state without auxiliary scaling, achieving performance competitive with full-precision Adam. Second, the transformed ratio view clarifies Adam's connection to sign-based methods: Adam reduces to sign-based momentum modulated by the transformed ratio, and replacing it with a constant recovers Signum as a limiting case. This perspective further provides a simple rule for transferring learning rates between the two methods. Together, these results suggest that tied-$\beta$ Adam admits a simple and approximately stable ratio structure underlying its adaptive behavior and demonstrate its utility for both analysis and efficient implementation. Code is available at https://github.com/agent-lab/hidden-ratio-adam.
BibTeX
@inproceedings{zhou2026hidden,
  author = {Yihe Zhou and Tongtian Zhu and Yingxiao Huo and Satya Prakash Dash and Can Wang and Samuel Kaski and Mingfei Sun},
  title = {{The Hidden Ratio in Adam: Stable Structure, Compression, and Sign Dynamics}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=GZha6judfp},
}
Figure