Evolution of LLM Training Optimizers: From Gradient Descent to Orthogonalized Momentum

    This article traces how neural network optimizers for large language model training have developed, from gradient descent and momentum to adaptive learning rate methods like Adam and newer matrix-based approaches that use momentum orthogonalization. It explains the problems each generation addresses, the memory and stability trade-offs involved, and practical guidance for choosing an optimizer at scale.

    1. Why the Optimizer Is the “Navigator” of LLM Training

    When people discuss the training of a new large model, attention usually goes to parameter count, context length, and data quality. The optimizer, however, is what largely determines whether training is efficient and converges stably.

    A classic analogy helps. Training a neural network is like placing a blindfolded person in a mountain range and asking them to reach the lowest valley. They have only two pieces of information:

    • Loss: the altitude of their current position.
    • Gradient: computed through backpropagation, it indicates which direction the ground slopes downhill.

    The optimizer is the decision strategy in their head. It determines which direction to step next and how large that step should be. An optimizer typically addresses three core problems:

    1. Step size control (learning rate scheduling): A step that is too large may jump over the valley floor and land on the opposite slope, causing the loss to oscillate without converging. A step that is too small makes training unacceptably slow. The ideal strategy moves quickly across flat terrain and slows down on steep slopes near the valley floor.
    2. Escaping local optima: Real loss surfaces contain many small pits along the mountainsides. Simply walking in the steepest direction can trap the optimizer in one of them, making it appear that the valley bottom has been reached.
    3. Handling ill-conditioned curvature: When the loss surface forms a long, narrow canyon, the gradient keeps pointing toward the canyon walls, and plain descent becomes very inefficient.

    In the era of large models, these three problems are amplified. Parameter counts reach hundreds of billions, and a full training run consumes compute measured in tens of thousands of GPU-days. Every gain in convergence efficiency translates into real cost savings.

    2. The Classical Starting Point: Gradient Descent and Its “Unphysical” Flaw

    The most basic method is stochastic gradient descent (SGD). Its underlying idea dates back to the steepest descent method proposed by Augustin-Louis Cauchy in 1847. At each step, parameters are updated along the negative gradient direction.

    1. # Vanilla SGD
    2. param = param - lr * grad

    This method is simple, stable, and has clear theoretical properties. It has a flaw that is often overlooked, however. It models a massless particle sliding over a surface, one that can start at full speed instantly and stop instantly. This contradicts physical intuition and causes practical problems:

    • In narrow canyon terrain, the gradient mainly points toward the canyon walls. The particle oscillates back and forth, wasting many steps sideways, while progress along the canyon is extremely slow.
    • It is highly sensitive to the learning rate, so tuning is costly.
    • With noisy mini-batch gradients, the update direction jitters significantly.

    3. Momentum: Giving the Particle Mass and Inertia

    Boris Polyak, a Soviet mathematician, challenged this model. In 1964, while studying optimization theory, he asked what would happen if the sliding particle were given mass and inertia.

    This idea led to the well-known Heavy Ball Method:

    1. # Momentum (Heavy Ball)
    2. velocity = beta * velocity + grad
    3. param = param - lr * velocity

    Inertia brings two direct benefits:

    • Damped oscillation: In canyon terrain, the gradient components perpendicular to the canyon alternate in sign, and the historical average in momentum cancels them out. Along the canyon, the gradients point consistently and accumulate, so the particle keeps moving toward the valley bottom.
    • Crossing shallow pits: When the particle reaches a shallow local optimum, inertia can carry it out of the pit and onward to lower ground.

    This idea later led to Nesterov accelerated gradient, which first looks ahead one step before computing the gradient. Momentum became a standard component of nearly all important early deep learning models.

    4. The Adaptive Era: Tuning Step Sizes per Parameter

    Momentum addresses the direction problem, but the step size problem remains. Adaptive learning rate methods were developed to handle it. They adjust each parameter’s learning rate based on the magnitude of its historical gradients. Parameters with consistently large gradients take smaller steps, and parameters with sparse gradients take larger steps. Representative methods, such as the Adam family, dominated deep learning training over the past decade for these reasons:

    • They are relatively robust to hyperparameters and work well out of the box.
    • They naturally suit sparse gradients and parameters at different scales.
    • They have been widely validated in large model pretraining, and their engineering ecosystem is mature.

    They also have costs. Each parameter needs extra storage for first- and second-moment states. For models with hundreds of billions of parameters, this means several times the memory overhead. The stability of second-order statistics at very large scale, and their sensitivity to hardware numerical formats, also remain ongoing engineering challenges.

    5. A New Trend: From Per-Parameter Updates to a Matrix Perspective

    Recently, optimizer research has taken a notable new direction. It treats parameters as structured matrices rather than as independent scalars, and it updates them with that structure in mind. Methods in this line, including the momentum orthogonalization-based optimizers widely discussed in the field, share the following core ideas:

    1. Apply an approximate orthogonalization to the gradient momentum matrix. For example, use an iterative method to approximate the matrix’s “sign direction,” so that the singular values of the update matrix become more uniform.
    2. The resulting update step is more balanced across the directional spectrum, which prevents a few dominant directions from monopolizing the update.
    3. In practice, these methods often bring more stable training dynamics, lower memory usage, and tolerance for larger learning rates.
    1. # Pseudocode: basic skeleton of matrix-based momentum updates
    2. momentum = mu * momentum + grad
    3. update = approximate_orthogonalize(momentum) # e.g., Newton-Schulz iteration
    4. param = param - lr * scale * update

    These methods are not a silver bullet. Orthogonalization adds computational overhead, and for layers such as embedding layers and normalization parameters, teams often need to combine them with traditional adaptive methods. Still, this direction matters because it lets the optimizer exploit the geometric structure of parameters, not only their statistical information.

    6. Practical Recommendations

    For teams training large models or running large-scale training, consider the following principles when choosing an optimizer:

    • Prioritize the memory budget: Optimizer state is a hidden memory cost. Fewer states allow larger batches or larger models.
    • Use a hybrid strategy: Try newer matrix-based methods for the main matrix parameters, and keep mature adaptive methods for scalar and vector parameters.
    • Watch late-stage stability: A faster start is not worthwhile if it comes at the cost of late-stage loss spikes.
    • Validate thoroughly with ablations: Optimizer gains are strongly tied to model scale and data distribution, so conclusions from small models may not extrapolate. Validate on small-scale proxy experiments before scaling up.

    7. Conclusion

    From Cauchy’s steepest descent, to Polyak giving the particle mass, to per-parameter adaptation and matrix-based orthogonalized updates, optimizer development has followed one goal across this century-long evolution: use gradient information more intelligently to reach the valley floor faster and more stably. In an era of expensive large-model compute, the optimizer is no longer just a hyperparameter in a training script. It is a key technical lever that shapes training economics and the ceiling of model capability, and it deserves continued attention from practitioners.