Manuscript Offprint
arXiv:2610.18085Same Function, Different Trajectory: No Standard Optimizer Is Equivariant to Transformer Reparameterization
Abstract
We show that two Transformers representing the same function can follow different training trajectories. For example, doubling a query matrix and halving its key matrix preserves the model's function but changes the gradient scales seen by the optimizer. Our theoretical analysis establishes that standard block-local first-order optimizers fail to scale updates with parameters under a shared learning rate. For AdamW, transforming the first-and second-moment estimates alone does not correct the mismatch between parameter and update scales. To make runs restarted from equivalent checkpoints follow the same trajectory, we balance matrix pairs and transform their moment estimates together, bringing distinct but equivalent training states to the same starting point. To correct scale imbalance between paired Transformer matrices without changing predictions, we propose Symmetry-Aware Gradient Geometry Stabilization (SAGGS), which periodically equalizes the Frobenius norms of exact symmetry pairs, and its damped variant, Soft SAGGS. SAGGS reduces perplexity (PPL) by at 101M parameters on WikiText-103, and Soft SAGGS reduces PPL by in a 31M modern-architecture replication, both under scale imbalance. In a 123.8M checkpoint-resume experiment, reciprocally rescaling matrix pairs barely changes validation loss at restart but increases final PPL by ; hard and soft rebalancing recover to within 0.02 PPL of the control.
1 INTRODUCTION
Transformers (Vaswani et al., 2017) serve as the standard architecture for large language models (Radford et al., 2019; Touvron et al., 2023). Each Transformer layer consists of a multi-head self-attention block and a multi-layer perceptron (MLP). The attention block is built from query, key, value, and output projections, and the MLP is based on rectified linear units (ReLU) or Swish-gated linear units (SwiGLU) (Shazeer, 2020).
Several of these weight matrices form pairs whose scales can be traded against each other without changing the output. For example, attention compares queries and keys through the product of the query and key matrices, so replacing with for any leaves every attention score, and hence every prediction, unchanged. We call a pair of matrices an exact symmetry pair when replacing the pair with preserves the model's function for every . Rescaling the exact symmetry pairs of a model in this way yields a whole set of parameterizations that all compute the same function, which we call a symmetry orbit.
These parameterizations represent the same function but lead to different training trajectories. The reason is that the gradients scale inversely to the weights: Multiplying A by c multiplies its gradient by , and multiplying B by multiplies its gradient by c. A gradient-descent step moves the enlarged matrix times less, relative to its size, than in the original model and its shrunken partner times more, so the two models no longer compute the same function after the step. Figure 1 illustrates this effect.
Concretely, symmetry orbits in a Transformer arise from attention query-key (Q-K) and value-output (V-O) pairs, ReLU up-down projections, and the linear value-output path of SwiGLU (Sec. 2). This inverse gradient-scaling law holds for all of these pairs and follows from the chain rule (Dinh et al., 2017, Theorem 3). We use this law to determine how a rescaling distorts
Corresponding author

Figure 1: Same function, different trajectory. (1) Multiplying A by c and dividing its partner B by c leaves every prediction unchanged. The rectangle's sides are the Frobenius norms of A and B, so the rectangle changes shape but keeps its area. (2) The same numerical update causes unequal relative changes in the two blocks. (3) Resuming training from the rescaled checkpoint, whose pair norms are imbalanced but whose function is unchanged, ends with much worse perplexity (PPL) than resuming from the original. (4) Hard and Soft SAGGS rebalance the pairs without changing the current function and recover from this degradation.
the optimizer’s updates and what is needed for rescaled models to train identically.
Standard optimizers already include mechanisms such as adaptive gradient normalization, but these mechanisms still do not remove this dependence on the parameterization. Adam normalizes gradients using moving averages of gradients and squared gradients (Kingma and Ba, 2015), which cancels constant-factor scaling of the gradients: Both models receive the same numerical update (Figure 1(2)). To keep the two models equivalent, however, the update of the enlarged matrix would have to be c times larger and the update of its shrunken partner c times smaller. The same update is too small for the enlarged matrix and too large for its shrunken partner. Transforming Adam's moment estimates along with the weights does not fix this mismatch, because both models still use the same learning rate (Sec. 3). Appendix A discusses in detail how this work relates to and differs from prior studies of rescaling-aware optimization, weight balancing, and symmetry-induced learning dynamics (Neyshabur et al., 2015; Stock et al., 2019; Kunin et al., 2021).
To remove the scale imbalance between paired matrices without changing the function, we introduce Symmetry-Aware Gradient Geometry Stabilization (SAGGS), which periodically rescales each exact symmetry pair so that its two matrices have equal Frobenius norms (Sec. 4). To avoid disrupting optimizer state that has adapted to imbalanced scales, Soft SAGGS applies only a fraction of this correction at each rebalancing step. Both operations leave the current function unchanged and only rebalance the weights from which training continues. SAGGS also gives an exact restart procedure: Applied together with a matching transformation of the moment estimates, SAGGS moves any two checkpoints on the same symmetry orbit to the same balanced state, from which training follows the same trajectory (Corollary 4). We evaluate both variants in deliberate rescaling tests, which rescale the pairs of layer by to impose pair-scale imbalance without changing the function, as well as in checkpoint-resume workflows and in training without such rescaling (Sec. 5). In our seven-seed comparisons, rebalancing restores near-baseline PPL after an imposed rescaling, including a checkpoint edit, and leaves PPL nearly unchanged when no imbalance is imposed.
Our contributions are fourfold.
• We identify exact symmetry orbits in Transformer architectures (Sec. 2) and show their effect on training.
• Our theoretical analysis proves that, under a shared learning rate, no standard optimizer, including gradient descent, AdamW, and Lion, keeps two equivalent models equivalent during training (Theorem 5). Even with correctly transformed moment estimates, AdamW does so only if its learning rate, , and weight decay are also rescaled coordinate by coordinate (Theorem 2 and Example 3). We further prove that canonicalizing both weights and moments at restart makes the training resumed from any two checkpoints on the same symmetry orbit identical (Corollary 4).
-
We propose SAGGS, which periodically moves each exact symmetry pair to the unique point on its orbit where the two matrices have equal Frobenius norms, regardless of where on the orbit the pair starts (Proposition 1). Its damped variant, Soft SAGGS, moves each pair only part of the way there, shrinking the log ratio of the two norms by a constant factor at each rebalancing step (Sec. 4.2).
-
Under deliberate rescaling, seven-seed paired comparisons show consistent PPL reductions from rebalancing, of for a 101M WikiText-103 model and of for a 31M modern-architecture replication, and also for training with Lion (Sec. 5.2). In a 123.8M checkpoint-resume workflow, an edit that barely changes validation loss at restart increases final PPL by , and both rebalancing variants recover to within 0.02 PPL of the control (Sec. 5.3).
2.1 Exact Reparameterization Symmetries
Consider an -layer Transformer (Vaswani et al., 2017). At layer , the self-attention uses projections , , , and , and the MLP uses and . Let denote the data loss evaluated at parameters . The equations omit biases.
Table 1 records the scalar pair symmetries used in the optimizer analysis. The Q–K and V–O rows are scalar instances of the multi-head attention symmetries characterized by Tran et al. (2025); the ReLU up–down row uses standard positive homogeneity (Dinh et al., 2017; Neyshabur et al., 2015). The Gaussian error linear unit (GELU) (Hendrycks and Gimpel, 2016) is not positively homogeneous, so rescaling its up–down pair changes the function, and SAGGS excludes this pair. The SwiGLU MLP (Shazeer, 2020) is defined as
where denotes element-wise multiplication. For a fixed gate, the output is linear in the value path , so rescaling by and by leaves the output unchanged; the gate is not rescaled.
Table 1: Scalar pair rescalings , . Rows marked Yes preserve the forward pass exactly and are used by SAGGS.
| Sub-layer | Mechanism | Exact | ||
|---|---|---|---|---|
| Self-attention | Bilinear in logits | ✓ Yes | ||
| Linear composition | ✓ Yes | |||
| MLP (ReLU) | Positive homogeneity | ✓ Yes | ||
| MLP (GELU) | Non-homogeneous | ✕ No | ||
| SwiGLU | Linear in value path | ✓ Yes |
The same pairs remain exact in the modern architecture that we use for the 31M replication and the checkpoint-resume experiments (Sec. 5). This architecture combines SwiGLU with grouped-query attention (GQA), root mean square layer normalization (RMSNorm), and rotary position embeddings (RoPE); under GQA, the Q–K and V–O rescalings use one factor per group (Appendix B.2).
2.2 Gradient Covariance Identity
For an exact scalar symmetry pair, the standard chain-rule identity for reciprocal rescaling (Dinh et al., 2017, Theorem 3) gives, at differentiable points,
where and each gradient of the same data loss is evaluated at its own parameterization. The two parameterizations compute the same function yet give the optimizer different gradients. In Sec. 3, we show that, under a shared learning rate, no standard optimizer scales its updates with the weights, so two equivalent models stop computing the same function after an update. We also show that canonicalizing both weights and moments at restart makes two such models train identically.
Appendix B gives the matrix shapes, the single-head attention and MLP equations, the bias co-transforms, and the argument that layer normalization leaves the pairs exact; the same appendix also discusses cross-attention, mixture-of-experts, and state-space blocks, which our experiments do not use. Lemma 7 in Appendix C.1 states the general diagonal-map form of Eq. 2 used in the proofs.
3 EQUIVARIANCE AND RESTARTS
Two models on the same orbit compute the same function but give the optimizer different gradients (Eq. 2). This section asks whether an optimizer can compensate for this difference and keep the two models equivalent after every update. If the optimizer cannot, the position of a model on its orbit affects training, which motivates rebalancing (Sec. 4). We fix one balanced representative of each orbit (Sec. 3.1), derive what AdamW needs to keep two runs equivalent (Sec. 3.2), show that restarting both runs from the same balanced state makes the resumed runs identical (Sec. 3.3), and prove that no standard optimizer keeps two runs equivalent under a shared learning rate (Sec. 3.4).
3.1 Scalar Orbit Canonicalization
All points on an orbit compute the same function, so any one of these points can represent the orbit. We use the point at which the two matrices of each exact pair have equal Frobenius norms. The exact restart (Sec. 3.3) and SAGGS (Sec. 4.1) both move a model to this point.
Proposition 1 (Unique balanced representative of a scalar orbit). For an exact symmetry pair with positive Frobenius norms, let and with . These matrices form the unique Frobenius-balanced point on the orbit, with . The balancing map is independent of the starting orbit representative, idempotent, and forward-preserving.
Balancing sends every point of an orbit to the same point, so two checkpoints that differ only by an orbit move end up with identical weights after balancing.
3.2 AdamW Trajectory Equivariance
The gradient normalization built into Adam cannot make parameter updates equivariant. With covariantly transformed moments, Adam's normalized direction cancels the gradient scale when ; a common positive generally prevents exact cancellation. Even when this cancellation is exact, two runs that start on the same orbit do not stay equivalent. Adam then applies the same update to both runs, whereas staying on the same orbit requires each parameter to move in proportion to its own scale, that is, c times more for the enlarged block and c times less for the shrunken block.
AdamW setup. Let , , act on disjoint exact symmetry pairs as and as the identity elsewhere. Every sampled data loss is assumed differentiable at the iterates and satisfies . Consider AdamW, with common and bias-correction counters. Let and denote its moving averages of the data gradients and their elementwise squares, respectively. These averages estimate the first moment and second raw moment of the gradient; hats denote bias-corrected estimates. We refer to these estimates simply as moments. After updating the moments, the parameter update is
Here , , all denominators are positive, and the gradients entering the moments are the data gradients, without clipping (Pascanu et al., 2013) or an additional parameter penalty. The following theorem gives the exact conditions under which AdamW, including its moments, keeps two runs on the same orbit.
Theorem 2 (AdamW trajectory equivariance). Under the AdamW setup above and the state transformation , the parameter-update formula commutes with S for every state with positive denominators if and only if, at every step and coordinate,
Consequently, with these rules and a shared sequence of sampled losses, orbit-related initial states remain orbit-related at every step.
In words, when a coordinate is multiplied by , its learning rate must be multiplied by as well, while its and weight decay must be divided by . A learning rate shared by the two runs violates this rule for every nontrivial move . The following example shows how large the resulting error can be.
Example 3 (Moment covariance alone is insufficient). If the two runs keep the same hyperparameters, the trajectory equivariance of Theorem 2 fails in general even when and . In particular, let and . One Adam step from zero moments, with common learning rate , starting at and , respectively, gives
The primed loss after that step is unbounded as , although both initial losses equal 1/2 and their moments transform correctly.
Both runs move each weight by , whereas equivalence would require the primed run to move by and by : The step is too small for the enlarged weight and too large for the shrunken one. The failure arises even without moment lag, clipping, weight decay, or an floor. With set by the depth schedule of our deliberate rescaling tests (Sec. 5), the discrepancy is and grows exponentially with the layer index .
3.3 Exact Canonical Restart
With shared hyperparameters, AdamW cannot keep two equivalent runs equivalent (Theorem 2). A restart avoids this problem: If two runs resume from the same numerical state, both runs follow the same trajectory. For the weights, balancing already provides this common state, because the balancing map sends every point of an orbit to the same point (Proposition 1); the map below extends this canonicalization to the moments.
Canonical state map. Let and the disjoint exact pairs be as in Theorem 2. Assume each paired matrix has positive Frobenius norm. Let multiply each block by and each block by , where , and leave other coordinates unchanged. Define the state canonicalizer
Corollary 4 (Exact canonical restart). For the state canonicalizer C and exact-pair map S defined above, with positive norms on every pair,
Thus canonicalizing both orbit-related checkpoints and their moments before the first resumed update, and then using common hyperparameters, counters, and randomness, gives identical subsequent training trajectories. The same conclusion holds when both sets of moments are reset to zero before canonicalization.
In other words, if the weights and moments of both checkpoints are canonicalized before training resumes, the two runs are identical from the first resumed update onward. The restart needs no equivariant optimizer, because canonicalization removes the difference between the two runs before the optimizer sees either run. The checkpoint-resume experiments of Sec. 5.3 test a practical version of this idea: These experiments rebalance an edited branch periodically and compare its final PPL with the final PPL of a control.
3.4 Limits of Block-Local Updates
AdamW becomes trajectory-equivariant only after its hyperparameters are transformed coordinate by coordinate (Theorem 2). We now show that no standard first-order optimizer keeps two equivalent runs equivalent under a shared learning rate. The obstruction comes from block locality: Standard optimizers update each block using only the gradient history of that block. Write for the disjoint exact pairs together with the remaining parameters, and let be the group of orbit moves . For the exact pairs in Table 1, every sampled loss satisfies for all .
A first-order method is a sequence of maps with and ; hyperparameters, step counters, and optimizer state with a fixed initialization are absorbed into . The method is orbit-equivariant if
for all and all , wherever both sides are defined. Here is exactly the gradient history produced at orbit-related iterates (Lemma 7). For a pair , we write and for the gradient histories of its two blocks.
Theorem 5 (Block-local obstruction to orbit equivariance). Fix a pair p and suppose that the increment of has the form
with , , and a function of the gradient history of the block alone. If is orbit-equivariant, then
for all and all histories . Consequently whenever is positively homogeneous of some degree , or is bounded on a neighborhood of the zero history. The same holds for .
By Eq. 10, an equivariant block-local rule must turn gradients that are c times smaller into an update that is c times larger, since the block itself is c times larger. Standard optimizers never meet this requirement: When the gradients get smaller, their updates get smaller or stay the same. Gradient descent and heavy-ball momentum have degree 1 and scale their updates with the gradients. Degree-zero rules ignore the gradient scale: AdaGrad, RMSProp, Adam, and AdamW with a zero stabilizer ; the sign-based rules signSGD and Lion; and the zero-stabilizer limit of Shampoo. Adam and AdamW with keep their updates bounded as the gradients vanish. None of these optimizers is orbit-equivariant under a shared learning rate. Block locality and the homogeneity or boundedness assumption are both needed: A block-local rule of degree -1, or a rule that couples the two blocks of a pair, can be equivariant; Appendix C.7 gives these examples and the precise conditions for each optimizer above.
Relative-update scaling. Theorem 5 shows that equivalence breaks; the next result measures by how much, in terms of how far each block moves relative to its own size. The gradient covariance in Eq. 2, combined with homogeneity of the block-local direction, gives the following scaling law.
Corollary 6 (Relative-update scaling for homogeneous rules). Let both blocks of pair follow Eq. 9 with and with positively homogeneous of degree . Assume both current block norms are positive. For the orbit-related histories and , where acts on pair with factor , the increments satisfy and , so that
(11)
For gradient descent with , the relative update of the enlarged block shrinks by and the relative update of the shrunken block grows by ; degree-zero rules such as Lion or Adam with reduce both factors to . Under the depth schedule , the B-to-A log-ratio of relative updates shifts by : for gradient descent and for degree-zero rules. Gradient normalization at best halves this shift, from to , and does not remove the shift. SAGGS instead removes this shift at each rebalance: Measured from the balanced point of Proposition 1, each rebalance resets to 1 for every pair (Sec. 4).
Proofs for this section are in Appendix C.
4 SAGGS REBALANCING
No standard optimizer keeps two equivalent models equivalent under a shared learning rate (Theorem 5); thus, the position of a model on its orbit affects training. SAGGS leaves the optimizer unchanged and instead periodically moves the model along its orbit to the balanced point, where the two matrices of each exact pair have equal Frobenius norms (Proposition 1). The current function stays the same, and training continues from balanced pairs. Hard SAGGS makes this move at once (Sec. 4.1); its damped variant, Soft SAGGS, makes only part of the move at each rebalance so as not to disrupt optimizer state that has adapted to the imbalance (Sec. 4.2).
4.1 Hard SAGGS
Hard SAGGS applies the balancing map of Proposition 1 to every exact pair once every optimization steps (Algorithm 1). Each application shrinks the larger matrix of a pair and enlarges the smaller one by the same factor, so that both norms become the geometric mean of the two; in Figure 1(4), the rectangle becomes a square of the same area. Because each application is an exact orbit move, the forward map and the current data loss are unchanged at each rebalance.
Algorithm 1 Symmetry-Aware Rebalancing
Require: Parameters , interval , disjoint exact symmetry pairs
1: for each optimization step do 2: Perform standard optimizer update on 3: if then 4: for each pair do 5: if or then 6: Skip this pair, since no positive norm ratio is defined 7: else 8: 9: 10: 11: end if 12: end for 13: end if 14: end for
4.2 Soft SAGGS
Hard SAGGS moves each pair to its balanced point in a single step but leaves the optimizer state, which was built from gradients at the old scales, unchanged. Lion, for example, takes the sign of a combination of the current gradient and a momentum buffer, an exponential moving average (EMA) of past gradients (Chen et al., 2023). After a hard rebalance, the gradient of the shrunken block grows and the gradient of the enlarged block shrinks (Eq. 2), while the buffer keeps the old scales, so the sign of the combination, and hence the update, can change abruptly. In a Lion ablation without imposed rescaling, hard SAGGS was less consistent across seeds, whereas state-covariant SAGGS, which also rescales the buffer by the same factors as the gradients, removed most of this variation (Appendix F.5).
To avoid abrupt changes in the update without modifying the optimizer state, Soft SAGGS makes each correction smaller: At each rebalance, Soft SAGGS moves each pair only part of the way to its balanced point, so the gradient scales change in several smaller steps rather than in one jump. Concretely, Soft SAGGS keeps the schedule and the norm ratio of Algorithm 1 but replaces its full correction with the damped rebalancing map
where and controls how much of the full correction is applied. Forward equivalence is preserved exactly for any , because this map is an exact orbit move with factor on a pair from Table 1. Setting recovers hard SAGGS, and as the map approaches the identity. We refer to Eq. 12 with as Soft SAGGS, and we adopt as the default whenever a single value is required.
Soft and hard SAGGS. Each Soft SAGGS rebalance multiplies the log-norm ratio of a pair by , so repeated rebalances shrink the imbalance geometrically instead of removing the imbalance at once. For , however, the rebalanced weights still depend on where on the orbit the pair starts, and applying the map again moves the weights further; only hard SAGGS sends every point of an orbit to the same point, as the exact restart of Corollary 4 requires.
Appendix C.8 derives these properties, Appendix D.5 discusses optimizer-state handling and defines state-covariant SAGGS, Appendix B.1 gives the bias co-transforms for affine projections, Appendix D.3 provides a reference implementation of hard and Soft SAGGS, and Appendix D.6 covers computational cost, the interaction with weight decay, and numerical guards.
5 EXPERIMENTS
All points on an orbit compute the same function, yet the analysis of Sec. 3 predicts that the position of a model on its orbit affects training. The experiments below measure how much an imbalanced position degrades language-model training and how much of this degradation rebalancing recovers. We create such a position with an orbit edit, a deliberate rescaling of exact pairs, at initialization (Sec. 5.2) and in a checkpoint before training resumes (Sec. 5.3), and we also train without an edit to check whether rebalancing costs anything when no imbalance is imposed. Case studies on released checkpoints show imbalance arising in ordinary training and test exact canonical restart (Appendix I).
5.1 Experimental Setup and Statistics
Unless otherwise stated, we train a GPT-2-style decoder-only Transformer with pre-layer normalization (Pre-LN) on WikiText-103 using AdamW (Loshchilov and Hutter, 2019) with weight decay and gradient clipping. The primary 101M model uses ReLU. The 31M replication and the checkpoint experiments of Sec. 5.3 use a modern architecture with RMSNorm, RoPE, SwiGLU, and GQA, together with T5 SentencePiece tokenization.
The orbit edit rescales exact pairs of layer by , which leaves the function unchanged but imbalances deeper pairs more strongly. We compare training with- out an edit, at , with training after a deliberate edit at . The experiments index layers as , so the largest scale is , about 100 for a 24-layer model at . Vanilla uses the same optimizer and hyperparameters without rebalancing.
Table 2: 101M WikiText-103 comparison with . Method columns report mean PPL; reports the mean sample SD of paired Vanilla-minus-SAGGS differences. is paired Cohen's and is the one-sided sign-flip -value.
| λ | Vanilla | SAGGS | d | ||
|---|---|---|---|---|---|
| 0.0 | 22.881 | 22.906 | -0.025 ± 0.034 | -0.75 | 0.9453 |
| 0.2 | 23.277 | 22.904 | +0.374 ± 0.026 | 14.21 | 0.0078 |
We report the mean paired PPL difference over seven paired seeds. Unless stated otherwise, a difference is Vanilla minus the method, so a positive value favors the method, and denotes a sample standard deviation (SD). The one-sided sign-flip -value takes its smallest possible value, 0.0078, exactly when all seven differences are positive.
5.2 Paired Language-Model Comparisons
5.2.1 101M WikiText-103 Comparison
In our main comparison, we train the 101M ReLU Transformer with for 30K AdamW steps, starting either without an edit or after a Q-K edit at . Hard SAGGS rebalances all exact pairs every 100 steps.
At , SAGGS reduces PPL by across seven paired seeds, with (Table 2). At , the difference is PPL. With SAGGS, the edit no longer matters: PPL is 22.904 with the edit and 22.906 without the edit. Without an edit, Vanilla ends with a Q-K log-norm ratio of only about 0.15, compared with about 3 after the edit, and removing this small imbalance barely changes PPL.
5.2.2 Architecture and Tokenizer Replication
To test whether these results depend on the GPT-2 architecture or the GPT-2 tokenizer, we repeat the comparison on a 31M model with the modern architecture and T5 SentencePiece tokenization. Over seven paired seeds, Soft SAGGS reduces PPL by at , with , while the difference without an edit is PPL (Table 7). As in the 101M comparison, rebalancing helps after the edit and barely changes PPL without one, so its benefit is not specific to the GPT-2 architecture or the GPT-2 tokenizer.
Table 3: 123.8M checkpoint-surgery resume with . Values are final PPL, reported as mean sample SD across seeds. Paired contrasts appear in Table 11.
| Resume condition | Final PPL |
|---|---|
| Control resume | 20.84 ± 0.25 |
| Surgery resume, no SAGGS | 24.62 ± 0.58 |
| Surgery + SAGGS | 20.85 ± 0.25 |
| Surgery + Soft SAGGS | 20.85 ± 0.25 |
5.2.3 Lion Comparisons
Lion (Chen et al., 2023) uses only the sign of each update coordinate and therefore ignores the gradient scale, but, like Adam, Lion is still not orbit-equivariant (Theorem 5). We train the 101M ReLU model for 15K Lion steps with an all-pairs edit and seven paired seeds. We rebalance with Soft SAGGS, using every 100 steps, because a hard rebalance can abruptly change Lion's updates (Sec. 4.2). At , all seven seeds favor Soft SAGGS: PPL and (Table 9). At , the difference is PPL. Without rebalancing, the edit more than doubles the mean PPL of Lion, from 24.15 to 58.32, whereas the edited runs with Soft SAGGS reach 23.86.
5.3 Checkpoint Recovery and Diagnostics
Training often resumes from a checkpoint with a fresh optimizer, for example when the checkpoint is imported without its optimizer state. To measure how much an imbalanced checkpoint degrades training in this setting, we train the 123.8M model for 10K steps with each of seven seeds, reset its optimizer, and clone the checkpoint into four 5K-step continuations: control, edited, edited with SAGGS, and edited with Soft SAGGS. The three edited branches receive the same exact all-pairs edit at , and SAGGS and Soft SAGGS rebalance at the restart and every 50 steps thereafter.
At restart, the edited checkpoints are indistinguishable from the original by their loss: The edit and any first rebalance change the validation loss by less than . Nevertheless, the edited run without rebalancing finishes PPL worse than the control, with (Table 11). Hard and Soft SAGGS finish within 0.02 PPL of the control (Table 3), so rebalancing recovers almost all of the degradation caused by the edit.
Instead of being reset, the AdamW moments can be kept and transformed along with the weights. On the 31M model, keeping and transforming the moments leaves a nonzero gap of PPL relative to a control that also keeps its optimizer state (Table 12), consistent with Theorem 2: Under a shared learning rate, transformed moments alone do not keep the two runs equivalent.
Case studies on public checkpoints (Appendix I) show that pair imbalance also arises in ordinary training: In Pythia 410M, the query and key norms drift apart during pre-training by a factor of up to about 6 in deep layers. The case studies also test canonical restart on GPT-2 774M, fine-tuned from the released checkpoint and from an exact Q-K edit of this checkpoint: Canonicalizing both checkpoints at restart makes the two runs identical, whereas without canonicalization the edited run predicts a different top-1 token than the canonicalized runs at of held-out positions after 200 updates.
Appendix D gives the training configurations, hardware, and seed protocol, and Appendix E defines the paired statistics, states their test assumptions, and separates primary from supporting comparisons. Appendix F gives the full protocols, tables, and paired contrasts for Secs. 5.2 and 5.3, together with optimizer-state diagnostics for reset and stale moments. Appendix G verifies the predicted gradient-norm scaling, measures natural drift, and reports stress tests and replications across corpora, architectures, and model sizes; some of these experiments use SAGGS+P, which adds to SAGGS an auxiliary penalty on pair imbalance (Appendix D.1).
6 CONCLUSION
Even two Transformers that represent the same function can train differently. Our analysis characterizes exact AdamW equivariance, identifies the obstruction for standard block-local updates, and establishes exact restart equivalence through canonicalization of weights and moments. SAGGS and Soft SAGGS provide simple function-preserving corrections for pair-scale imbalance. The normalization layers of a Transformer, weight decay, and gradient clipping do not restore pair balance (Appendix H). A rebalance rescales each pair only as much as the pair is imbalanced, so rebalancing can be kept on throughout training. Across paired language-model experiments and checkpoint-resume workflows, these corrections recover the performance lost to this imbalance, in particular after an exact orbit edit. These findings show that the pair-scale imbalance introduced by a parameterization strongly affects training, whether training starts from initialization or resumes from a checkpoint.
AI USE STATEMENT
Generative AI tools were used as assistive tools for writing and editing, mathematical proofreading and consistency checking, and code development and debugging. Any AI-assisted outputs incorporated into this work were reviewed and validated by the authors as appropriate. The authors take full responsibility for the final content of this work, including any text, claims, or artifacts produced with the assistance of generative AI.
References
Ainslie, J., Lee-Thorp, J., de Jong, M., Zemlyanskiy, Y., Lebrón, F., and Sanghai, S. (2023). GQA: Training Generalized Multi-Query Transformer Models from Multi-Head Checkpoints. In EMNLP, pages 4895–4901.
Ainsworth, S. K., Hayase, J., and Srinivasa, S. S. (2023). Git Re-Basin: Merging Models modulo Permutation Symmetries. In ICLR.
Bernstein, J., Wang, Y., Azizzadenesheli, K., and Anandkumar, A. (2018). SIGNSGD: Compressed Optimisation for Non-Convex Problems. In ICML, volume 80, pages 559–568.
Chen, X., Liang, C., Huang, D., Real, E., Wang, K., Pham, H., Dong, X., Luong, T., Hsieh, C., Lu, Y., and Le, Q. V. (2023). Symbolic Discovery of Optimization Algorithms. In NeurIPS.
Cohen, J. (2013). Statistical power analysis for the behavioral sciences.
Dinh, L., Pascanu, R., Bengio, S., and Bengio, Y. (2017). Sharp Minima Can Generalize For Deep Nets. In ICML, volume 70, pages 1019–1028.
Du, S. S., Hu, W., and Lee, J. D. (2018). Algorithmic Regularization in Learning Deep Homogeneous Models: Layers are Automatically Balanced. In NeurIPS, pages 382–393.
Entezari, R., Sedghi, H., Saukh, O., and Neyshabur, B. (2022). The Role of Permutation Invariance in Linear Mode Connectivity of Neural Networks. In ICLR.
Fedus, W., Zoph, B., and Shazeer, N. (2022). Switch Transformers: Scaling to Trillion Parameter Models with Simple and Efficient Sparsity. J. Mach. Learn. Res., 23:120:1–120:39.
Glorot, X. and Bengio, Y. (2010). Understanding the difficulty of training deep feedforward neural networks. In AISTATS, volume 9, pages 249–256.
Gokaslan, A. and Cohen, V. (2019). OpenWebText Corpus. http://Skylion007.github.io/OpenWebTextCorpus.
Gu, A. and Dao, T. (2023). Mamba: Linear-Time Sequence Modeling with Selective State Spaces. CoRR, abs/2312.00752.
Gupta, V., Koren, T., and Singer, Y. (2018). Shampoo: Preconditioned Stochastic Tensor Optimization. In ICML, volume 80, pages 1837–1845.
He, K., Zhang, X., Ren, S., and Sun, J. (2015). Delving Deep into Rectifiers: Surpassing Human-Level Performance on ImageNet Classification. In ICCV, pages 1026–1034.
Hendrycks, D. and Gimpel, K. (2016). Bridging Non-linearities and Stochastic Regularizers with Gaussian Error Linear Units. CoRR, abs/1606.08415.
Henry, A., Dachapally, P. R., Pawar, S. S., and Chen, Y. (2020). Query-Key Normalization for Transformers. In EMNLP (Findings), volume EMNLP 2020, pages 4246–4253.
Huang, X. S., Pérez, F., Ba, J., and Volkovs, M. (2020). Improving Transformer Optimization Through Better Initialization. In ICML, volume 119, pages 4475–4483.
Kingma, D. P. and Ba, J. (2015). Adam: A Method for Stochastic Optimization. In ICLR.
Kunin, D., Sagastuy-Breña, J., Ganguli, S., Yamins, D. L. K., and Tanaka, H. (2021). Neural Mechanics: Symmetry and Broken Conservation Laws in Deep Learning Dynamics. In ICLR.
Lakens, D. (2013). Calculating and reporting effect sizes to facilitate cumulative science: a practical primer for t-tests and ANOVAs. Frontiers in psychology, 4:863.
Liu, L., Liu, X., Gao, J., Chen, W., and Han, J. (2020). Understanding the Difficulty of Training Transformers. In EMNLP (1), pages 5747–5763.
Loshchilov, I. and Hutter, F. (2019). Decoupled Weight Decay Regularization. In ICLR.
Merity, S., Xiong, C., Bradbury, J., and Socher, R. (2017). Pointer Sentinel Mixture Models. In ICLR.
Neyshabur, B., Salakhutdinov, R., and Srebro, N. (2015). Path-SGD: Path-Normalized Optimization in Deep Neural Networks. In NIPS, pages 2422–2430.
Pascanu, R., Mikolov, T., and Bengio, Y. (2013). On the difficulty of training recurrent neural networks. In ICML (3), volume 28, pages 1310–1318.
Radford, A., Wu, J., Child, R., Luan, D., Amodei, D., Sutskever, I., et al. (2019). Language models are unsupervised multitask learners. OpenAI blog, 1(8):9.
Salimans, T. and Kingma, D. P. (2016). Weight Normalization: A Simple Reparameterization to Accelerate
Training of Deep Neural Networks. In NIPS, page 901.
Shazeer, N. (2020). GLU Variants Improve Transformer. CoRR, abs/2002.05202.
Shazeer, N., Mirhoseini, A., Maziarz, K., Davis, A., Le, Q. V., Hinton, G. E., and Dean, J. (2017). Outrageously Large Neural Networks: The Sparsely-Gated Mixture-of-Experts Layer. In ICLR.
Stock, P., Graham, B., Gribonval, R., and Jégou, H. (2019). Equi-normalization of Neural Networks. In ICLR.
Su, J., Ahmed, M. H. M., Lu, Y., Pan, S., Bo, W., and Liu, Y. (2024). RoFormer: Enhanced transformer with Rotary Position Embedding. Neurocomputing, 568:127063.
Tanaka, H. and Kunin, D. (2021). Noether's Learning Dynamics: Role of Symmetry Breaking in Neural Networks. In NeurIPS, pages 25646–25660.
Touvron, H., Lavril, T., Izacard, G., Martinet, X., Lachaux, M., Lacroix, T., Rozière, B., Goyal, N., Hambro, E., Azhar, F., Rodriguez, A., Joulin, A., Grave, E., and Lample, G. (2023). LLaMA: Open and Efficient Foundation Language Models. CoRR, abs/2302.13971.
Tran, H. V., Vo, T., The, A. N., Huu, T. T., Nguyen-Nhat, M., Tran, T., Pham, D., and Nguyen, T. M. (2025). Equivariant Neural Functional Networks for Transformers. In ICLR.
Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, L., and Polosukhin, I. (2017). Attention is All you Need. In NIPS, pages 5998–6008.
Xiong, R., Yang, Y., He, D., Zheng, K., Zheng, S., Xing, C., Zhang, H., Lan, Y., Wang, L., and Liu, T. (2020). On Layer Normalization in the Transformer Architecture. In ICML, volume 119, pages 10524–10533.
Yang, G., Hu, E. J., Babuschkin, I., Sidor, S., Liu, X., Farhi, D., Ryder, N., Pachocki, J., Chen, W., and Gao, J. (2021). Tuning Large Neural Networks via Zero-Shot Hyperparameter Transfer. In NeurIPS, pages 17084–17097.
Zhai, S., Likhomanenko, T., Littwin, E., Busbridge, D., Ramapuram, J., Zhang, Y., Gu, J., and Susskind, J. M. (2023). Stabilizing Transformer Training by Preventing Attention Entropy Collapse. In ICML, volume 202, pages 40770–40803.
Zhang, B. and Sennrich, R. (2019). Root Mean Square Layer Normalization. In NeurIPS, pages 12360–12371.
Zhang, G., Wang, C., Xu, B., and Grosse, R. B. (2019). Three Mechanisms of Weight Decay Regularization. In ICLR.
Zhao, B., Dehmamy, N., Walters, R., and Yu, R. (2022). Symmetry Teleportation for Accelerated Optimization. In NeurIPS.
CHECKLIST
- For all models and algorithms presented, check if you include:
(a) A clear description of the mathematical setting, assumptions, algorithm, and/or model. [Yes] See Secs. 2, 3, and 4.
(b) An analysis of the properties and complexity (time, space, sample size) of any algorithm. [Yes] See Sec. 3 and Appendix D.6.
(c) (Optional) Anonymized source code, with specification of all dependencies, including external libraries. [Yes] See Appendix D.3.
- For any theoretical claim, check if you include:
(a) Statements of the full set of assumptions of all theoretical results. [Yes] See Sec. 3 and Appendix C.
(b) Complete proofs of all theoretical results. [Yes] See Appendix C.
(c) Clear explanations of any assumptions. [Yes] See Secs. 2 and 3.
- For all figures and tables that present empirical results, check if you include:
(a) The code, data, and instructions needed to reproduce the main experimental results (either in the supplemental material or as a URL). [Yes] See Appendix D.3.
(b) All the training details (e.g., data splits, hyperparameters, how they were chosen). [Yes] See Appendices D, F, G, and I.6.
(c) A clear definition of the specific measure or statistics and error bars (e.g., with respect to the random seed after running experiments multiple times). [Yes] See Appendix E.2.
(d) A description of the computing infrastructure used. (e.g., type of GPUs, internal cluster, or cloud provider). [Yes] See Appendix D.2.
- If you are using existing assets (e.g., code, data, models) or curating/releasing new assets, check if you include:
(a) Citations of the creator If your work uses existing assets. [Yes] See Appendices D and I.6.
(b) The license information of the assets, if applicable. [No] Asset licenses are not listed.
(c) New assets either in the supplemental material or as a URL, if applicable. [Not Applicable] No new datasets or model checkpoints are released.
(d) Information about consent from data providers/curators. [Not Applicable] No new participant data are collected.
(e) Discussion of sensible content if applicable, e.g., personally identifiable information or offensive content. [No] Sensitive corpus content is not analyzed.
- If you used crowdsourcing or conducted research with human subjects, check if you include:
(a) The full text of instructions given to participants and screenshots. [Not Applicable] No crowdsourcing or human-subject research.
(b) Descriptions of potential participant risks, with links to Institutional Review Board (IRB) approvals if applicable. [Not Applicable] No human-subject research.
(c) The estimated hourly wage paid to participants and the total amount spent on participant compensation. [Not Applicable] No human participants.
Same Function, Different Trajectory: No Standard Optimizer Is Equivariant to Transformer Reparameterization Supplementary Materials
APPENDIX TABLE OF CONTENTS
A Related Work 14
B Notation and Architectural Details 15
B.1 Attention, MLPs, and Affine Projections 15
B.2 Grouped-Query Attention and Rotary Embeddings 15
B.3 Interaction with Layer Normalization 16
B.4 Other Architectural Variants 16
C Proofs and Optimizer Analysis 16
C.1 Gradient Covariance from Forward Invariance 16
C.2 Unique Balanced Representative 17
C.3 Recovery of a Balanced Checkpoint 17
C.4 AdamW Moment Covariance at Corresponding Orbit Points 18
C.5 AdamW Equivariance and Canonical Restart 18
C.6 Orbit-Equivariant First-Order Updates 19
C.7 Normalized Directions and the Scope of the Obstruction 20
C.8 Soft Rebalancing: Contraction and Orbit Dependence 21
C.9 Pair-Norm Dynamics 21
C.10 Derivations for Pair-Norm Dynamics 22
D Experimental and Implementation Details 23
D.1 Models and Training Protocols 23
D.2 Seeds and Computing Infrastructure 24
D.3 Implementation 24
D.4 Model Configurations 25
D.5 Optimizer-State Co-Transformation 26
D.6 Cost, Weight Decay, and Numerical Guards 26
D.7 Code Availability and Reproducibility 27
E Statistical Methodology and Summary of Results 27
E.1 Paired Comparisons ..... 27
E.2 Statistics and Sign-Flip Tests ..... 27
E.3 Summary of Primary and Supporting Comparisons ..... 28
F Primary Comparisons and Optimizer-State Ablations ..... 29
F.1 101M WikiText-103 Comparisons ..... 29
F.2 Architecture and Tokenizer Replication ..... 29
F.3 Hard Rebalancing with Lion ..... 30
F.4 Soft Rebalancing with Lion ..... 31
F.5 Optimizer-State Co-Transformation with Lion ..... 31
F.6 Branched Checkpoint-Surgery Resume ..... 32
F.7 Optimizer-State Diagnostics ..... 33
F.8 State-Preserved Checkpoint-Surgery Diagnostic ..... 33
F.9 Stale Optimizer-State Checkpoint Edit ..... 34
F.10 Partial Optimizer-State Checkpoint Edit ..... 34
G Additional Experiments ..... 35
G.1 Gradient Law and Orbit Imbalance ..... 35
G.2 Supporting Ablations and Replications ..... 36
G.3 FP32 Gradient-Law Verification ..... 36
G.4 Naturally Occurring Pair Imbalance ..... 37
G.5 Pair Imbalance in a Pre-Trained Model ..... 38
G.6 Deep-Model Sensitivity to Rescaling ..... 38
G.7 Rescaling a 354M-Parameter Model ..... 39
G.8 SwiGLU Sensitivity to Rescaling ..... 40
G.9 1.2B-Parameter Gradient Law Verification ..... 41
G.10 Rescaling Strength at 101M Parameters ..... 42
G.11 Multi-Seed Comparisons Across Scales ..... 42
G.12 1.2B-Parameter Training ..... 43
G.13 Exact Contraction and Synthetic Optimizer Diagnostics ..... 44
G.14 Cross-Corpus Replication on OpenWebText ..... 45
G.15 123.8M Modern-Architecture Scale Replication ..... 45
G.16 296.7M Modern-Architecture Scale Replication ..... 46
H Further Discussion ..... 46
H.1 Adaptive Normalization and Trajectory Equivariance ..... 47
H.2 Sign-Based Optimizers and Soft Rebalancing ..... 47
H.3 Natural Drift and Weight Decay ..... 47
H.4 Implications for Initialization ..... 47
H.5 Training Stability ..... 48
I Released-Checkpoint Case Studies ..... 49
I.1 Pair Scales in Public Checkpoints ..... 49
I.2 Fine-Tuning from Equivalent Checkpoints ..... 50
I.3 Depth-Resolved Evolution under Lion ..... 51
I.4 Token-Level Differences after Restart ..... 52
I.5 Summary ..... 53
I.6 Protocols ..... 53
J List of Notation ..... 55
K Limitations ..... 55
A RELATED WORK
Parameterization and initialization. Variance-preserving initialization (Glorot and Bengio, 2010; He et al., 2015) fixes a single scale at the start of training. The Maximal Update Parametrization ( P) of Yang et al. (2021) provides a principled framework for hyperparameter transfer across widths. T-Fixup (Huang et al., 2020) instead rescales residual branches so that deep Transformers can be trained more stably at a fixed width. Our work is complementary: P governs how to scale across widths, and T-Fixup chooses a particular residual scale, while reparameterization symmetry reveals a continuous family of forward-equivalent configurations at fixed width and depth.
Weight normalization and reparameterization. Weight normalization (WeightNorm) (Salimans and Kingma, 2016) decouples the direction and magnitude of weight vectors, implicitly addressing some scale ambiguities. Dinh et al. (2017) explicitly derive the inverse gradient-coordinate law under function-preserving reciprocal rescaling. We use that law as background for the full-state optimizer analysis. Neyshabur et al. (2015) introduced path-regularization to account for rescaling invariances in ReLU networks. Transformer-NFN (Tran et al., 2025) characterizes more general matrix symmetries of multi-head attention; the scalar Q-K and V-O rescalings used here are special cases. Our focus is the response of first-order optimizer states and resumed trajectories to these edits. SAGGS instead selects the Frobenius-balanced representative of an exact scalar pair orbit. Standard WeightNorm has a trainable magnitude and does not impose this pairwise canonicalization.
Depth-dependent techniques. Pre-LN (Xiong et al., 2020) places the normalization before the attention and MLP sub-layers, improving gradient flow relative to post-layer normalization (Post-LN). Admin (Liu et al., 2020) diagnoses unbalanced residual-branch magnitudes in Transformers and rescales those magnitudes at initialization. Reparam (Zhai et al., 2023) constrains Q-K spectral scales to prevent attention entropy collapse, a failure mode adjacent to unconstrained motion along the Q-K orbit. Query-Key Normalization (Henry et al., 2020) removes that free Q-K scale by unit-normalizing the two factors. These techniques act on initialization, the residual stream, or spectral constraints, whereas our analysis concerns reciprocal rescalings inside attention and MLP blocks. The existence of an internal symmetry alone does not determine a training recipe's stability or final PPL.
Weight balancing and equivariance. Du et al. (2018) proved conservation of differences of squared layer norms under gradient flow in homogeneous networks and established discrete-time balancing results for matrix factorization. Conservation alone does not drive an arbitrary initial imbalance to zero. Equi-normalization (Stock et al., 2019) uses the same ReLU scale freedom to iteratively rebalance hidden units toward a minimum-norm representative; the procedure does not canonicalize first-order optimizer state. Symmetry Teleportation (Zhao et al., 2022) moves along a function-preserving orbit to change the local descent geometry. SAGGS uses a fixed orbit-selection criterion: the Frobenius-balanced representative of an exact scalar pair.
Symmetry and optimization dynamics. Kunin et al. (2021) and Tanaka and Kunin (2021) analyze how continuous network symmetries constrain learning dynamics and how finite-step and adaptive updates break associated conservation laws. Discrete permutation symmetries, whose role in linear mode connectivity was isolated by Entezari et al. (2022) and later used for model merging (Ainsworth et al., 2023), identify a different orbit: Those methods rearrange hidden units rather than rescaling a bilinear pair. Our focus is on complete discrete optimizer states and canonicalized restarts along the scalar rescaling orbit. The moment-scaling identities follow from the Adam recursions (Kingma and Ba, 2015). Theorem 2 and Corollary 4 give the corresponding discrete-time AdamW and restart rules, complementing the continuous-time analysis of Kunin et al. (2021).
B NOTATION AND ARCHITECTURAL DETAILS
B.1 Attention, MLPs, and Affine Projections
Consider an L-layer Transformer (Vaswani et al., 2017) with hidden dimension , attention head dimension , and MLP intermediate dimension . At layer , the self-attention sub-layer computes:
where , and . The equation is for a single head; multi-head attention concatenates the per-head matrices.
The MLP sub-layer with ReLU activation is:
where , , and denotes the activation function.
Let denote the data loss evaluated at parameters . The equations omit biases.
For affine projections, scale the Q–K biases with their respective matrices, the V bias with V, and the ReLU up-projection or SwiGLU value bias with its up matrix; leave output biases and the SwiGLU gate unchanged. These co-transforms preserve the forward and gradient-coordinate identities. Without these co-transforms, matrix-only rescaling need not be a symmetry of a biased layer.
B.2 Grouped-Query Attention and Rotary Embeddings
Modern variants. The pairs of Table 1 remain exact in the modern architecture that we use for the 31M replication and the checkpoint-resume experiments (Sec. 5). This architecture combines SwiGLU with GQA, RMSNorm, and RoPE. RMSNorm acts on the residual stream rather than on the paired matrices, and RoPE only rotates queries and keys, so the factors c and still cancel. GQA shares each key and value head across a group of query heads, so the Q–K and V–O rescalings use one factor per group.
Grouped-query attention. GQA (Ainslie et al., 2023) shares one and one across query heads, where is the group count. The Q–K orbit becomes group-tied: Any rescaling for the query heads in a group must be paired with a single for the group's shared key. The dimension of the orbit is reduced from scalars per layer in the multi-head case to scalars per layer; the gradient covariance in Eq. 2 applies to each group-pair independently. The per-pair Frobenius rebalance of SAGGS extends by treating each group's Q heads and shared K head as one balancing unit: The Q-side norm is . For V–O, scale the shared V head by and all corresponding output-projection blocks by , using their joint Frobenius norm on the output side.
Residual-stream normalization and rotary embeddings. RMSNorm (Zhang and Sennrich, 2019) pre-normalization acts on the residual stream and therefore leaves the internal pair identities unchanged. RoPE (Su et al., 2024) applies a position-dependent linear orthogonal map to queries and keys, so is invariant before and after the rotary map. The LLaMA-style block combining RMSNorm, RoPE, and SwiGLU (Touvron et al., 2023) with GQA (Ainslie et al., 2023) remains inside the catalog for the Q–K, V–O, and SwiGLU value–output pairs used by SAGGS.
B.3 Interaction with Layer Normalization
Layer-normalization interaction. Pre-LN normalizes the input to each sub-layer, which might seem to eliminate the effect of weight norm imbalance. However, layer normalization acts on the residual stream, i.e., the sub-layer input, not on the internal weight matrices. The gradient transformation law operates on the internal bilinear structure, and layer normalization does not interact with this symmetry. Specifically, the layer-normalization output is a fixed function of the residual stream regardless of the internal parameterization of the sub-layer, so the reparameterization preserves SubLayer and hence the gradient transformation law continues to hold.
To make the layer-normalization argument precise, write for the sub-layer map with all other sub-layer parameters fixed. Every exact pair in Table 1 satisfies
The form describes a ReLU MLP, but does not represent a Q-K attention pair: Both Q and K enter the logits, with . In Pre-LN, the residual-block map is ; in Post-LN, the residual-block map is . Substituting the same sub-layer identity into either expression proves forward invariance of the whole block. Lemma 7 then gives the same inverse gradient-coordinate factors in both cases.
B.4 Other Architectural Variants
The following extensions and boundaries complete the catalog in Sec. 2.1. Cross-attention, mixture-of-experts, and state-space blocks are not used in the primary training comparisons.
Cross-attention in encoder and decoder models. The attention pairs in Table 1 also apply when queries, keys, and values come from different sources: Their bilinear and linear compositions do not require the two input sequences to coincide.
Mixture-of-experts models. Each expert in a sparse mixture-of-experts MLP (Shazeer et al., 2017; Fedus et al., 2022) with ReLU experts contains an independent pair. Conditional routing means a given token is processed by only experts, but the symmetry , is per-expert and forward-equivalent regardless of the routing decision: The routing gate is shared across experts and unaffected. The catalog adds independent scalar orbits per layer, where is the expert count. For SwiGLU experts, the exact pair is V–O with the gate fixed. GELU up–down rescaling is not an exact symmetry.
State-space models. Mamba’s selective state-space block (Gu and Dao, 2023) contains an input projection and an output projection around a state-space recurrence. The input-dependent discretization step enters nonlinearly, so the recurrence is not generally homogeneous in its input. Reciprocal rescaling of the input and output projections need not preserve the function, and state-space blocks are excluded from Table 1. Any sub-block that has the form with g positively homogeneous inherits the corresponding pair. ReLU has this property; in SwiGLU, the same pair inheritance holds for the value path with the gate fixed, not for joint scaling of the gate and value projections.
C PROOFS AND OPTIMIZER ANALYSIS
C.1 Gradient Covariance from Forward Invariance
We record the general chain-rule identity underlying Eq. 2 and the optimizer-state proofs. The reciprocal-scaling instance is standard (Dinh et al., 2017, Theorem 3).
Lemma 7 (Forward invariance implies the gradient law). Let and let with all . Suppose that for every . Then is differentiable at if and only if is differentiable at , and at every such point
Proof. Let , i.e., . By hypothesis, as functions on . Since is an invertible linear map, is differentiable at if and only if is differentiable at ; for the converse write . In that case, the chain rule gives . Because , is differentiable at exactly when is, with . Combining the two statements, is differentiable at if and only if is differentiable at , and then ; multiplying by yields Eq. 15.
For a symmetry pair, take and leave all other coordinates unchanged. Forward invariance supplies the hypothesis, and the two blocks of Eq. 15 give Eq. 2. This hypothesis holds for the data loss but not for a loss that also includes penalties on the weights, such as L2 regularization, because rescaling a pair changes such penalties. Disjoint exact pairs can be transformed simultaneously by the same argument with a diagonal map containing their respective scales.
C.2 Unique Balanced Representative
Proof of Proposition 1. Throughout, and , so that and are well defined, and denotes the orbit move with factor .
Balance. and , so .
Uniqueness and independence of the orbit representative. The orbit of is , and is injective because with forces . The point is Frobenius-balanced if and only if , i.e., if and only if , whose unique positive solution is . Hence is the unique balanced point of . The balanced point depends only on the orbit and not on the point from which the representative is computed: If , then , so and . In particular, the step is idempotent: At one has and , so a second application is the identity.
Forward pass. Since , the exact-pair assumption ensures that the step leaves the forward map unchanged.
C.3 Recovery of a Balanced Checkpoint
Recovery after an orbit edit of a balanced checkpoint. If the imbalance was created from a balanced pair by an exact orbit move , this step applies the inverse orbit move and removes the associated diagonal coordinate factor. Suppose for some balanced pair with and some . Then , so the rebalancing step is and returns exactly. By Eq. 2, returning to the original balanced point also restores its gradient coordinates.
One-shot canonicalization. Algorithm 1 applies exactly and , which is . By Proposition 1, a single application reaches the unique balanced representative of the orbit without changing the forward pass, and any further application is the identity; this fact is the one-shot canonicalizer property for pair-norm imbalance on the symmetry orbit.
Canonicalization preserves the current function and data loss. At a fixed checkpoint, every point of its exact symmetry orbit has the same validation PPL. Proposition 1 selects the balanced representative; subsequent training from that point is evaluated empirically.
C.4 AdamW Moment Covariance at Corresponding Orbit Points
For a fixed sequence of corresponding orbit points, the Adam moment recursions determine the moments in the transformed coordinates. The following lemma supplies the identities used in Theorem 2; the lemma does not assume that common hyperparameters preserve the correspondence during training.
Corresponding-history setup. Let denote the data-loss gradient at step and let be the bias-corrected first- and second-moment estimates of AdamW with and . Under the reparameterization with diagonal Jacobian , where on , on , and elsewhere, let the primed quantities be computed from the gradients in the new coordinates at the corresponding orbit points , , with the same hyperparameters and zero-initialized moment buffers.
Lemma 8 (Adam moment covariance). Under the corresponding-history setup above, the new-coordinate gradients satisfy for every and every , so and .
Proof of Lemma 8. With all parameters outside the pair held fixed, the data loss satisfies by the exact-pair assumption, and is the linear map . Lemma 7 therefore gives, at every pair of corresponding points, , i.e., for all and all . The moment recursions and with are, coordinate-wise, linear in the sequence and in , respectively. By induction on : , and if then ; likewise . The bias corrections and are positive scalars that do not depend on the coordinate, so and . Decoupled weight decay acts separately on the parameters and does not enter the moments.
C.5 AdamW Equivariance and Canonical Restart
We prove the coordinate criterion, the functional counterexample, and the canonical restart identity separately. All calculations are in exact arithmetic.
Proof of Theorem 2. For the moment recursions and the coordinate criterion, suppose at step that , , and . Since the sampled loss is the same in the two runs and , differentiating this identity gives . The diagonal matrix is symmetric, so , where . The Adam moment recursions therefore give
Here denotes componentwise squaring. Shared bias-correction counters multiply each moment by the same scalar in both runs, so the same identities hold for and . This argument is inductive: The induction assumes corresponding parameters only at the current step, not at future iterates.
Fix a coordinate and a step, suppress their indices, and put , , . Because , the primed adaptive term is . Thus universal commutation of the parameter-update formula is precisely the identity
for every and every positive , and by continuity where and the denominators remain positive. First set and vary . This substitution yields . With these decay terms equal, take and cancel to obtain
Equality of the coefficients of gives . Equality of the constant coefficients, together with , then gives . Substituting the learning-rate identity into the decay identity gives . This calculation proves necessity for the update formula on its full state domain; two particular trajectories may still agree by accident without these identities. Conversely these three identities make both sides of Eq. 16 equal, proving sufficiency. Combined with the moment calculation above, sufficiency completes an induction from the initial state and proves trajectory equivariance. The reasoning also permits a deterministic time-dependent schedule: The three identities must hold at each step of that schedule.
Verification of Example 3. For , the gradients are and . The gradients are at and at . With zero initial moments, the first bias-corrected moments are and , for any . Every gradient component is positive, so all four denominators are positive and the normalized updates with are exactly 1. With no weight decay, this update rule gives
Hence
The inequality proves Eq. 5. For fixed , as , so . The initial product is 1 in both runs. The first and second moments satisfy exactly the relations in the proof of Theorem 2, so the discrepancy cannot be attributed to stale moments. Finally, implies , giving the stated depth-schedule consequence.
Proof of Corollary 4. For one pair, the norm ratio at is . Consequently its A-side balancing multiplier is , and its B-side multiplier is . The pairs are disjoint and all other coordinates are unchanged, so
All matrices here are positive diagonal matrices and commute. These commutation relations imply that
These three identities are exactly the three components of Eq. 7. The transformations are well-defined because both norms in every pair are positive. Each parameter balancing step is an exact symmetry and hence preserves the forward map.
After the two canonicalizations, the numerical parameters and moments are identical. With equal counters, common hyperparameters, and the same next minibatch and random choices, the next gradients, moments, and parameter updates are identical. Induction proves equality at every subsequent step. This implication also holds for common deterministic clipping applied after canonicalization, because the two gradients are then identical; clipping need not commute with an arbitrary S for this conclusion. If moments are reset, the same proof applies since . No identity with an uncanonicalized reference or an arbitrary stale state is used or implied.
C.6 Orbit-Equivariant First-Order Updates
Throughout, denotes the element of that acts on the fixed pair with factor and as the identity on every other block; that is, multiplies the -coordinates by and the -coordinates by , while multiplies those coordinates by and , respectively.
Proof of Theorem 5. For the degree -1 condition and the stated obstructions, fix , a step , and an admissible history , and write . The -coordinates of form the history , and the -block of is . By Eq. 9, the -block of the left-hand side of Eq. 8 equals , whereas the -block of the right-hand side equals . Equating the two, canceling the decay terms, and dividing by yields Eq. 10. The history was arbitrary in the domain of .
Homogeneous case. Suppose for all with . Applying Eq. 10 with and homogeneity with gives , so . Because we have , hence .
Bounded case. Suppose whenever . Given any , choose ; then and Eq. 10 gives . Letting shows .
For the -block, multiplies the gradient history by and multiplies the parameters by , so the same computation yields , which is Eq. 10 with replaced by ; the two consequences follow verbatim.
Coverage. Gradient descent, , and heavy-ball momentum, , are homogeneous of degree 1. AdaGrad, RMSProp, and Adam with divide a linear function of the history by the square root of a quadratic one and are homogeneous of degree 0, as are signSGD and Lion, since for . For Shampoo, put and . These Gram factors can be singular, including at the first step for a rectangular gradient. The zero-stabilizer limiting direction is
where denotes the Moore–Penrose pseudoinverse; equivalently, the inverse fourth root is zero on each nullspace. This pseudoinverse formula agrees with when both factors are positive definite. This pseudoinverse direction is the limit of the regularized direction because and : No component of lies in the divergent nullspace factors. Scaling the history by scales each Gram factor by , so the limiting direction scales as . For Adam or AdamW with , the bias-corrected first moment is a convex combination of the past gradients of the coordinate, so , which tends to 0 with the history; thus is bounded near the zero history. Decoupled weight decay is already included in Eq. 9, and Lion's decay term has the same form. None of these rules is identically zero, so none is orbit-equivariant.
Proof of Corollary 6. For the orbit-related histories, the -history is and the -history is . By homogeneity, and . Since and , Eq. 11 follows.
Depth-schedule specialization. For the nonzero increments in Corollary 6, taking logarithms of the ratio of the two nonzero relative increments gives a shift of , which equals for ; the same difference is for and for . For , the shift is zero only for ; an identity orbit move gives zero for every .
Full increments with decoupled decay. When , the corresponding full increments instead satisfy
The data and decay terms carry different powers of for , so their sum has no single scaling exponent in general. For example, at the scalar pair with loss , a first zero- AdamW step has data directions . With , , and a common , the multipliers of the full relative increments are on and on , instead of the data-only values and . The B-to-A multiplier is , whereas the data-only law gives .
C.7 Normalized Directions and the Scope of the Obstruction
Adam normalized direction. For corresponding gradient histories under , , and covariantly transformed initial moments, including zero initialization, Adam's moment recursions give and
. With a common additive stabilizer , its normalized data direction is
Thus the gradient-scale cancellation (Kingma and Ba, 2015) is exact when and the denominators are positive; the cancellation generally fails for a common positive . Even when , preserving an orbit-related training trajectory requires the parameter displacement to scale with the parameters.
Block-locality examples. Block locality and the stated regularity alternatives are essential. For example, the unbounded block-local rule that sets for and at has degree -1 and satisfies the required scaling. Moreover, the parameter-free, pair-coupled directions and are polynomial and equivariant: These directions transform by and , respectively. Thus the obstruction does not cover all parameter-free first-order methods.
Standard optimizer instances. Theorem 5 applies to gradient descent with or without heavy-ball momentum, both homogeneous of degree 1. The degree-zero class includes AdaGrad and RMSProp with zero additive stabilizers, Adam with , signSGD (Bernstein et al., 2018), and Lion. This class also includes per-tensor preconditioned updates such as the zero-stabilizer limit of Shampoo (Gupta et al., 2018), with inverse roots taken on the ranges of the Gram factors. Adam and AdamW with are bounded near the zero history and also fall within the theorem's scope. These rules are not orbit-equivariant under a common learning rate, with or without decoupled weight decay.
C.8 Soft Rebalancing: Contraction and Orbit Dependence
Contraction of the log-ratio. The residual log-imbalance after a single damped event contracts geometrically:
so K events with no intervening optimizer updates multiply the log-imbalance by . During training, optimizer updates can introduce new imbalance between events.
Dependence on the starting representative. The soft map is not itself an orbit canonicalizer for . Writing for the damped rebalancing map of Eq. 12 and , direct substitution of gives
Thus one soft event retains dependence on the starting representative; away from balance the soft map is also not idempotent, since a second event changes to . Hard rebalancing with has both canonicalizer properties. Corollary 4 uses that hard map. The seven-seed Lion comparison in Sec. 5.2 evaluates the damped variant on Lion training.
C.9 Pair-Norm Dynamics
For one matrix pair, let denote the optimizer direction: the data gradient for gradient descent, the normalized moment direction for AdamW, or a sign vector for Lion. With and , write
Let be the balance defect, and let be the log-ratio underlying the experimental diagnostics wherever both norms are positive. The numerical stabilizer used for measurements is specified in Appendix G.4. For the optimizer direction in Eq. 21, define the radial forcing and squared-direction norm difference by and .
Exact defect recursion. For any direction in Eq. 21, expanding the squared norms gives
This algebraic recursion does not require a symmetry assumption.
From the balance defect to the log-ratio. For positive norms, decay alone leaves unchanged. The balance defect bounds the log-ratio as . Appendix C.10 derives this bound and the exact recursion.
Radial parameter and update components. Balancing equalizes the weight norms of a pair, not the norms of its data gradients. Even at Frobenius balance, whether at initialization or right after a SAGGS rebalance, the matrices and in a symmetry pair can receive gradients with different magnitudes due to their positions in the computation graph. For instance, receives gradients that depend on through the attention logit Jacobian, and vice versa. Gradient magnitudes alone do not determine norm drift. Under Eq. 21, the expansion at a fixed iterate, with fixed directions and decay coefficient, is
The common decay contribution cancels from this first-order log-ratio increment.
Appendix C.10 gives the exact logarithmic recursion. At Frobenius balance, with both squared norms equal to , the first-order term is . The corresponding exact balance-defect recursion is Eq. 22. Interpreting a measured drift requires the radial components of the actual optimizer directions.
Common weight decay preserves the pair ratio. AdamW applies weight decay as uniformly to all parameters. This uniform decay multiplies both matrices of a pair by the same factor, so a decay step leaves the pair ratio unchanged and cannot restore balance by itself. The exact one-step defect recursion in Eq. 22 records the decay factor and data-update terms. The log-ratio increment depends on the radial components of the actual optimizer directions, as in Eq. 23.
C.10 Derivations for Pair-Norm Dynamics
All inner products and norms are Frobenius; we suppress the step index when no confusion can arise.
Derivation of the exact defect recursion. Expanding the squared norms of Eq. 21,
and subtracting gives Eq. 22.
Decay and log-ratio diagnostics. For the positive block norms of Appendix C.9, multiplying both matrices by the same positive scalar leaves the ratio of their norms, hence , unchanged. For the bound on , put , so that . If then and . If then and , using . In both cases, .
Exact log-ratio increments. For positive block norms before and after the update, define and , with the analogous definitions for , and set . Dividing the squared-norm expansions above by the respective old squared norms gives
At a fixed iterate with fixed directions and decay coefficient, the two arguments have expansions and . Using proves Eq. 23. The terms involving cancel, and at balance .
Numerical verification of the optimizer identities. A standalone numerical suite checks the AdamW state identities over 80 updates of a matrix regression with two coupled symmetry pairs, counterexamples obtained by omitting each required hyperparameter transformation, canonicalized restarts with common gradient clipping, and the zero- scalar counterexample. The numerical suite also checks the relative-increment exponents of Corollary 6 and the exact defect recursion in Eq. 22. These checks complement the proofs above.
D EXPERIMENTAL AND IMPLEMENTATION DETAILS
D.1 Models and Training Protocols
Architecture. The original small GPT-style experiments use Pre-LN, with normalization before each sub-layer, learned positional embeddings, tied input and output embeddings, bias-free linear projections, and context length 256. Later experiments specify their architecture and context-length changes. The vocabulary size is 50,257, as determined by the GPT-2 byte-pair encoding (BPE) tokenizer. Linear and embedding weights in the GPT-style model use ; normalization gains retain their default initialization. These GPT-style runs apply no additional factor to residual-output projections.
The four original GPT-style configurations range from 22M to 354M parameters. Table 4 lists their widths, depths, head counts, and peak learning rates under the names small, medium, deep, and xlarge.
Training. We use AdamW (Loshchilov and Hutter, 2019) with , , , weight decay 0.1, and a cosine learning rate schedule with linear warmup over the first 2,000 steps and a minimum learning-rate ratio of 0.1. Gradient clipping is applied with max norm 1.0. The default batch size is 64 for small and deep models and 32 for medium models. The xlarge configuration uses batches of 16 with gradient accumulation over 4 micro-batches, giving an effective batch size of 64. Training uses bfloat16 (BF16) mixed precision for efficiency.
Datasets. WikiText-103 (Merity et al., 2017) is the primary dataset, with approximately 103M training words; GPT-2 BPE token counts and processed training-token budgets differ. OpenWebText (Gokaslan and Cohen, 2019) is used for multi-dataset validation. OpenWebText contains approximately 8B tokens, and we use a subset for training.
SAGGS hyperparameters. Hard SAGGS rebalances all symmetry pairs every 100 steps. Soft SAGGS uses the reported interval and unless a sweep specifies otherwise. SAGGS+P, used only in some supplementary experiments, adds to SAGGS an auxiliary penalty on the training loss: the mean of over the rebalanced pairs, with , weighted by 0.01 unless a protocol specifies otherwise. The penalty is not part of SAGGS or Soft SAGGS. We rebalance Q-K, V-O, and MLP pairs in ReLU and SwiGLU models. GELU models use only Q-K and V-O pairs, since GELU up-down rescaling is not an exact symmetry.
Reparameterization procedure. The exponential reparameterization is applied after standard initialization by multiplying and for each symmetry pair. For exact pairs, this rescaling preserves the initial forward pass in exact arithmetic across all values. GELU MLP rescaling in the approximation diagnostic is excluded from this identity.
The mathematical sections index layers from 1 to ; the training code uses , so its largest applied scale is . Numerical examples use the code convention. Small and deep models use 30K steps, medium models 25K to 30K steps, and 354M models 15K to 20K steps unless their protocols specify otherwise. The logged gradients in SAGGS+P experiments include the auxiliary penalty; the exact gradient-coordinate law concerns the data loss alone.
Evaluation. Validation PPL is computed on the WikiText-103 validation set or the corresponding OpenWebText validation set, using non-overlapping windows at the experiment's configured sequence length, usually 256 or 512. Standard evaluation traverses the validation loader; any experiment-specific evaluation limits are specified in the corresponding protocol. Most experiments report mean SD over the paired seeds stated in each protocol; Appendix D.2 lists the number of seeds in every experiment.
D.2 Seeds and Computing Infrastructure
Random seeds. Paired comparisons use the same optimization seed for both arms, so the two arms share initialization, data order, and dropout masks. All seed pools were fixed before the corresponding experiments, and no seed was selected retrospectively from a larger pool.
A three-seed core pool was fixed before the multi-seed cross-scale comparisons and the three-seed 101M comparison. Three-seed experiments use this pool: the three-seed 101M comparison, the hard-rebalancing Lion comparison, the Lion state ablation, the OpenWebText replication, the 123.8M and 296.7M scale replications, the 354M stress test at , the 22M multi-seed cross-scale comparison, and the 101M one at . Four additional seeds, fixed before the primary seven-seed comparisons, extend the core pool to seven seeds for the seven-seed 101M comparison, the 31M architecture and tokenizer replication, and the soft-rebalancing Lion comparison. The branched checkpoint-surgery resume and the optimizer-state diagnostics use a separate seven-seed pool, which also contains the core pool and was fixed before those experiments. Two seeds from the core pool are used in the natural-drift experiment, the deep-model stress test, the 101M multi-seed cross-scale comparison at , and the 354M one. A single seed from the core pool is used in the 354M stress test at , the SwiGLU stress test, the 101M rescaling-strength sweep, and the 1.2B training comparison.
Compute. The main experimental suite was run on NVIDIA H100 80GB GPUs, using 4×H100 single-node runs with distributed data parallel (DDP) training for the largest configurations. The implementation also supports Intel Data Center GPU Max devices through the PyTorch XPU backend; DDP runs use NCCL on CUDA devices and XCCL on XPU devices. The 31M architecture and tokenizer replication, the 123.8M scale replication and branched checkpoint-surgery resume, the 31M optimizer-state diagnostics, and the 296.7M scale replication were executed on Aurora Intel Data Center GPU Max 1550 XPU tiles. Runtime depends on the recipe and hardware. For example, the 1.2B training comparison records 2,494 to 2,518 seconds per configuration on four H100s, equivalent to 41.6 to 42.0 minutes or approximately 2.8 H100-hours per configuration. These values are training timers, including periodic evaluation, rather than end-to-end times including data and model setup; these timers should not be extrapolated from parameter count alone.
D.3 Implementation
Implementation checks. We verify the implementation on CPU and replay the same suite on Aurora using an XPU device. The checks confirm exact forward preservation, the closed-form gradient law, and SAGGS forward preservation for Q–K, V–O, and MLP pairs on both the GPT-style model and the RMSNorm, RoPE, SwiGLU, and GQA model of the architecture and tokenizer replication. The checks also verify the optimizer-state co-transform used in the Lion state ablation by confirming that Adam-family first- and second-moment buffers receive the chain-rule scale factors after a hard SAGGS orbit move and after an explicit exact reparameterization surgery. Both runs pass all checks: The largest relative gradient-law error is below , and the optimizer-state relative error is zero.
Reference implementation. Listing 1 reproduces the rebalancing operator of our implementation, trimmed to the bias-free projections used in the primary training experiments. The pair map follows Table 1: For SwiGLU the MLP pair is the value and output matrices and the gate is untouched, and GELU models use only the Q–K and V–O pair types. For each pair the function computes and applies the damped rebalancing map of Eq. 12 with ; gives the hard rebalancing of Algorithm 1. Pairs with a norm below are skipped, as analyzed in Eq. 25. The optional moment co-transform is the state-covariant variant of Appendix D.5, used only in the Lion state ablation and the optimizer-state diagnostics; default hard and Soft SAGGS leave the buffers unchanged. For affine projections the full implementation additionally applies the bias co-transforms of Appendix B.1. The training loop calls the operator on the 32-bit floating-point (FP32) parameters, outside the BF16 autocast region, immediately after the optimizer update whenever .
Listing 1: Hard SAGGS with alpha=1 and Soft SAGGS with alpha<1 for bias-free projections, with optional optimizer-state co-transformation.
import torch
def get_pair_modules(block, pair_type): """Modules (A, B) of one exact pair in a block (Table 1).""" if pair_type == 'qk': return block.attn.W_Q, block.attn.W_K if pair_type == 'vo': return block.attn.W_V, block.attn.W_O if pair_type == 'mlp': if hasattr(block.mlp, 'W1'): # ReLU up and down return block.mlp.W1, block.mlp.W2 if hasattr(block.mlp, 'W_value'): # SwiGLU value and output; gate kept return block.mlp.W_value, block.mlp.W_out return None, None
def rescale_optimizer_state(optimizer, param, grad_scale): """Buffer co-transform for param ← s * param, grad_scale = 1 / s: gradient averages scale linearly, squared-gradient averages quadratically.""" state = optimizer.state.get(param) if not state: return for key, buf in state.items(): if not torch.is_tensor(buf) or buf.shape != param.shape: continue if key == 'exp_avg': # Adam and AdamW first moment; Lion momentum buf.mul_(grad_scale) elif key == 'exp_avg_sq': # Adam and AdamW second-moment estimate buf.mul_(grad_scale * grad_scale)
@torch.no_grad()
def saggs_rebalance_soft(model, pair_types='qk', 'vo', 'mlp'), alpha=0.5, optimizer=None, transform_optimizer_state=False): """Soft SAGGS with alpha in (0, 1]; alpha = 1 is Algorithm 1.""" for block in model.blocks: for pt in pair_types: A_mod, B_mod = get_pair_modules(block, pt) if A_mod is None: continue A, B = A_mod.weight, B_mod.weight norm_A, norm_B = A.norm(), B.norm() # Frobenius norms if norm_A < 1e-12 or norm_B < 1e-12: # delta_skip guard continue c_eff = (norm_A / norm_B).pow(alpha * 0.5) # rho^(alpha/2) A.div(c_eff) # A ← A / c_eff B.mul_(c_eff) # B ← c_eff * B if transform_optimizer_state: # state-covariant only rescale_optimizer_state(optimizer, A, c_eff) rescale_optimizer_state(optimizer, B, c_eff.reciprocal())
def saggs_rebalance(model, pair_types='qk', 'vo', 'mlp'): """Hard SAGGS (Algorithm 1): balanced orbit representative.""" saggs_rebalance_soft(model, pair_types, alpha=1.0)
D.4 Model Configurations
Table 4 summarizes the architectures and peak learning rates. Experiment-specific protocols specify any departures from these defaults.
The GPT-2-style models use context length 256 unless otherwise stated; the xlarge, 1B, and later 101M replication recipes use 512. At the same widths, the SwiGLU stress test uses three-projection variants with 25.5M parameters
Table 4: Model configurations. LR is the peak learning rate; modern-architecture head counts are pairs of query heads and key-value (KV) heads. The first four parameter counts assume two-projection ReLU or GELU MLPs. Context lengths and SwiGLU variants are specified in the text.
| Name | Heads | Params | LR | |||
|---|---|---|---|---|---|---|
| GPT-2-style | ||||||
| Small | 256 | 1024 | 12 | 4 | 22M | |
| Medium | 512 | 2048 | 24 | 8 | 101M | |
| Deep | 256 | 1024 | 48 | 4 | 51M | |
| Xlarge | 1024 | 4096 | 24 | 16 | 354M | |
| 1B (SwiGLU) | 2048 | 5504 | 22 | 16 | 1.22B | |
| Modern architecture | ||||||
| Modern-small | 384 | 1024 | 12 | 31M | ||
| Modern-medium-plus | 640 | 1728 | 24 | 123.8M | ||
| Modern-large | 896 | 2432 | 32 | 296.7M | ||
| Pre-trained | ||||||
| GPT-2 (pre-trained) | 768 | 3072 | 12 | 12 | 124M | |
at and 63.3M at . Modern-architecture models use RMSNorm, RoPE, SwiGLU, GQA, and T5 SentencePiece tokenization. Their context length is 256 for the 31M model in the architecture and tokenizer replication and the optimizer-state diagnostics, and 512 for the larger models.
D.5 Optimizer-State Co-Transformation
Optimizer-state co-transform ablation. SAGGS is a coordinate change on the symmetry orbit, whereas practical optimizers also maintain state variables. To separate the effect of the orbit move from the possible perturbation of optimizer state, we also evaluate a state-covariant variant. If a rebalance applies and , then the data-gradient coordinates transform as and . Accordingly, for an Adam-family first-moment buffer or a Lion momentum buffer we map and , and for Adam-family second-moment estimates we map and . By default, both hard and Soft SAGGS leave the optimizer buffers unchanged, so neither method needs access to the internal state of the optimizer. We use the state-covariant variant only as a diagnostic: In the Lion state ablation (Appendix F.5), this variant measures how leaving Lion's momentum buffer in the old coordinates affects the cost of hard rebalancing.
D.6 Cost, Weight Decay, and Numerical Guards
Computational cost. Each rebalance computes two Frobenius norms and rescales all entries, costing per pair with tensor operations. At interval , this rebalancing adds amortized work of per pair per optimization step. With full-layer Q-K, V-O, and MLP pairs there are 3L pairs; independent headwise Q-K and V-O pairs give for standard -head attention.
Interaction with weight decay. A common decoupled decay factor multiplies both matrices equally and leaves their norm ratio unchanged (Zhang et al., 2019). The one-step balance-defect recursion in Eq. 22 records the contribution of this decay factor; we discuss the measured drift in Appendix H.3.
Numerical skip guard. The implementation skips a pair when either norm is below , whereas Algorithm 1 states the ideal positive-norm map. For a scheduled soft event with positive norms, let before the event and let be the log-ratio afterward. The implemented correction obeys, in exact arithmetic,
A skipped positive-norm pair has , so the hard canonicalizer and fixed- contraction identities apply to executed corrections.
D.7 Code Availability and Reproducibility
Appendix C gives self-contained proofs under the stated assumptions. The experimental protocols and table captions specify model configurations, datasets, optimizers, training budgets, schedules, and hardware. Appendix D.2 describes the seed protocol and seed counts, and Appendix E.2 defines the paired statistics and multiple-comparison conventions.
Appendix D.3 gives a reference implementation of the rebalancing operator (Listing 1) and the checks used to verify this implementation. WikiText-103 and OpenWebText are public datasets.
Reproduction uses fixed seeds and the documented hardware and backend. Because torch.nn.functional.scaled_dot_product_attention can introduce backend non-determinism, reruns can differ from the reported values within numerical tolerance.
E STATISTICAL METHODOLOGY AND SUMMARY OF RESULTS
The primary comparisons and checkpoint-resume experiments use seven paired seeds; OpenWebText and the larger modern architectures use three. We report the mean paired PPL difference , its sample SD , paired Cohen's , and exact sign-flip -values. Unless stated otherwise, a difference is Vanilla minus the method, so a positive value favors the method, and denotes a sample SD. With seven seeds, the one-sided sign-flip -value takes its smallest possible value, 0.0078, exactly when all seven differences are positive; with three seeds, its smallest value is 0.125.
E.1 Paired Comparisons
For every paired comparison of Vanilla with a method at fixed and fixed model size, we use the same optimization seed for both arms, covering data ordering, weight initialization, and dropout mask, so the paired difference controls these stochastic factors. Checkpoint-branch diagnostics share the base checkpoint and use the continuation protocol specified in the corresponding experiment. The within-seed design reduces variation due to these shared stochastic factors. The primary 101M WikiText-103, 31M architecture replication, and Lion comparisons use seven paired seeds (Appendix D.2).
E.2 Statistics and Sign-Flip Tests
Reported statistics. The paired summaries use the mean , the paired SD , and paired Cohen's . Tables report the subset of these statistics relevant to each comparison. Unless explicitly labeled otherwise, primary values are sample SDs, not standard errors. Earlier small-n tables use a different dispersion convention: Those summaries use population SDs, while the later paired analyses use the denominator. We do not pool these summaries. Differences are computed before rounding; subtracting two rounded means can differ by one last rounded digit from the reported paired difference. Later table captions state only experiment-specific details. Unless a caption specifies otherwise, a positive paired is the left-minus-right or Vanilla-minus-method contrast on validation PPL, and is the one-sided sign-flip -value for a positive mean.
Sign-flip tests. For finite-sample significance, we use exact paired sign-flip randomization tests as the primary p-value whenever the claim is a paired contrast. Their finite-sample validity requires invariance of the joint null distribution under independent sign flips of the paired differences. For example, the condition holds for independent differences symmetric about zero. Pairing seeds or assuming only a zero mean does not establish this invariance. At , the smallest one-sided sign-flip is ; at the p-value floor is only 0.125, so three-seed comparisons can establish effect direction and scale but not a sign-flip claim. We also report the paired statistic as a supplementary descriptive summary; significance claims use the sign-flip test.
For paired differences , we enumerate all sign assignments and compute the one-sided value
The two-sided zero-effect test compares the absolute permuted mean against . These tests do not establish equivalence against a prespecified practical margin.
Effect-size thresholds. We use the conventional Cohen thresholds adapted to the paired design (Cohen, 2013; Lakens, 2013): negligible, small, medium, large, very large. The PPL effect at , on the 101M medium model is in the primary comparison (Sec. 5.2 and Table 2), with all seven paired differences positive. We interpret paired effect sizes together with absolute metric changes and sample size, rather than relying on the p-value alone.
Multiple-comparison handling. The primary hypothesis that SAGGS protects the language-model objective under a forward-equivalent orbit imbalance is tested by the 101M WikiText-103 paired seven-seed contrast in Sec. 5.2. The 31M modern-architecture seven-seed replication and the Lion and Soft SAGGS seven-seed comparison are primary replications of the architecture, tokenizer, and optimizer variants. Secondary contrasts, including other values, scale variants, and workflow diagnostics, provide supporting evidence. Reported p-values are unadjusted unless labeled otherwise; the unadjusted p-values must not be interpreted as family-wise significance claims. The single pre-declared core PPL contrast is separate from these secondary families.
Single-seed 1.2B comparison. The 1.2B comparison in Appendix G.12 uses a single seed because of compute constraints. Its training timers are 2,494 to 2,518 seconds per configuration on four H100s, or approximately 2.8 H100-hours per configuration, excluding data and model setup. We report this comparison's observed differences without an inferred p-value or Cohen's d (Table 23). The seven-seed 101M, modern-architecture, Lion, and checkpoint-resume comparisons are the primary statistical evidence; the three-seed 123.8M and 296.7M comparisons test transfer across scales.
Pre-specification of and seed choices. Throughout the paper, pre-specified means fixed in our experiment plan before inspecting the corresponding held-out result; the phrase does not imply external public registration. The stress-test setting was selected from the empirical sensitivity observed in initial single-seed exploratory runs and then fixed in advance for all subsequent paired confirmation experiments with . The paired seed pools were likewise fixed before the corresponding experiments were executed (Appendix D.2). The primary paired tables include all seeds of the corresponding pools and the values fixed in those configurations.
E.3 Summary of Primary and Supporting Comparisons
Role of each comparison. The main protection result is at , , with paired Cohen's (Table 2), measured under deliberate reparameterization. At , mean differences are small in the core AdamW and selected Soft and Lion comparisons; the three-seed Lion state ablation (Appendix F.5) is the main adverse unperturbed case.
SAGGS and Soft SAGGS are orbit-rebalancing steps for exact bilinear symmetries, complementary to the optimizer: Hard SAGGS selects the balanced representative, and Soft SAGGS contracts the distance to that representative in log-ratio coordinates. Deliberate rescaling tests measure sensitivity to orbit position; checkpoint-surgery and stale-state branches test recovery after an edit. Table 5 records the statistical support of each comparison. Paired n = 7 comparisons are the primary evidence; the n = 3 modern-architecture comparisons have a sign-flip floor of 0.125, and the 1.2B run is a single-seed scale check.
Table 5: Primary PPL comparisons and checkpoint-resume diagnostics. is the paired left-minus-right difference, reported as mean sample SD. Rows marked use three paired seeds; all others use seven. Soft denotes Soft SAGGS, WT-103 denotes WikiText-103, and V denotes Vanilla.
| Setting | Contrast | Purpose | |||
|---|---|---|---|---|---|
| Primary | |||||
| 101M WT-103 | V – SAGGS | Core language-model protection | |||
| 31M modern | V – Soft | Architecture and tokenizer | |||
| 101M Lion | V – Soft | Optimizer transfer | |||
| Workflow | |||||
| 123.8M surgery | No-SAGGS – control | State-reset resume | |||
| Mechanism | |||||
| 31M reset | Reset – reset ctrl | Reset penalty isolated | |||
| 31M reset | Soft – reset ctrl | Residual after Soft | |||
| 31M stale | Stale – Soft | Stale-state recovery | |||
| 31M partial | Deep-stale – Soft | Partial-state recovery | |||
| Scale transfer | |||||
| V – Soft | Larger modern architecture | ||||
| V – Soft | -class modern | ||||
Table 6: Three-seed 101M WikiText-103 comparison. Table 2 gives the seven-seed extension. Method columns report PPL as mean sample SD; reports paired Vanilla-minus-SAGGS differences in the same format.
| Vanilla | SAGGS | ||
|---|---|---|---|
F PRIMARY COMPARISONS AND OPTIMIZER-STATE ABLATIONS
The subsections below group related comparisons by purpose.
F.1 101M WikiText-103 Comparisons
The three-seed comparison uses a paired design on WikiText-103: , Vanilla or SAGGS, and three paired seeds. The medium ReLU Transformer has , , 8 heads, about 101M parameters, and context length 512. Each run uses 30K AdamW steps, learning rate , , weight decay 0.1, 2K-step warmup, cosine decay to 10% of peak, gradient clipping at 1.0, BF16 mixed precision, and batch size 32. At , Q-K pairs receive the depth-exponential edit at initialization. SAGGS rebalances Q-K, V-O, and ReLU up-down pairs every 100 steps. Data sampling and initialization are shared within seed. The primary comparison in Table 2 extends this protocol to seven paired seeds.
Table 6 reports paired differences . At , the mean is PPL: a small observed cost on a base near 22.9 PPL. At , the mean is PPL and all three seeds favor SAGGS. The paired effect sizes are and , respectively. With , the one-sided exact sign-flip -value floor is 0.125.
Pair-norm measurements in the seven-seed comparison. SAGGS keeps the final pair log-ratio imbalance below in these comparisons, whereas Vanilla Q-K imbalance is about 0.15 at and about 3 at . Rebalancing controls pair norms in both conditions; the PPL benefit appears under deliberate rescaling.
F.2 Architecture and Tokenizer Replication
This experiment tests transfer across architecture and tokenizer choices. The experiment replaces the GPT-style layer normalization, learned absolute positions, and standard multi-head attention with RMSNorm, RoPE, SwiGLU, and GQA, and replaces GPT-2 BPE with T5 SentencePiece tokenization. We evaluate the resulting
Table 7: Seven-seed modern architecture and cross-tokenizer replication. The paired block is Vanilla minus Soft SAGGS with .
| Mean PPL | Paired difference | ||||||
|---|---|---|---|---|---|---|---|
| Vanilla | Soft, | ||||||
| 0.0 | |||||||
| 0.2 | |||||||
31M model over seven paired seeds.
We train a 12-layer causal language model with , six query heads, two KV heads, SwiGLU hidden width 1024, tied input and output embeddings, no biases, RMSNorm pre-normalization, RoPE, and T5 SentencePiece vocabulary. We re-tokenize WikiText-103 with the T5 tokenizer.
The optimizer is AdamW with , weight decay 0.1, cosine decay, warmup, gradient clipping at 1.0, BF16 XPU autocast, batch size 48, sequence length 256, and 12K steps. The paired design compares Vanilla with Soft SAGGS at , crossed with and , over seven paired seeds. The reparameterization acts on Q-K, V-O, and SwiGLU value-output pairs, and Soft SAGGS rebalances those same pairs every 100 steps. A pre-training verification on a WikiText-103 batch confirms exact forward equivalence, with loss difference 0 and maximum logit difference below , and gradient-law relative errors below for Q-K, V-O, and SwiGLU value-output pairs.
The results reproduce both patterns observed in the 101M comparison (Table 7). First, the unperturbed comparison has a small observed difference: Vanilla and Soft SAGGS differ by only PPL, taking Vanilla minus Soft, relative to a baseline near 20.8 PPL. Second, the reparameterization creates a consistent degradation in Vanilla on all seven seeds, while Soft SAGGS remains near its unperturbed baseline: Vanilla is PPL and Soft SAGGS is PPL, with paired , , Cohen , and exact one-sided sign-flip .
The final pair-norm statistics show corresponding balance control: At , Vanilla ends with Q-K max absolute log-ratio about 2.65, V-O about 1.21, and MLP about 1.81, while Soft SAGGS keeps all three below . The scale replications in Appendices G.15 and G.16 extend the same architecture to 123.8M and 296.7M parameters. PPL depends on the tokenizer, so these values are not comparable with the values of the GPT-2-tokenized models; all performance comparisons here use the same tokenizer and paired seeds.
F.3 Hard Rebalancing with Lion
Lion (Chen et al., 2023) uses sign-based updates. Positive-scale invariance of its sign direction does not imply orbit equivariance of its parameter trajectory (Theorem 5). We test whether hard SAGGS protects Lion training under an exact orbit tilt.
Design. The protocol uses the medium ReLU Transformer with , , 8 heads, and 101M parameters, WikiText-103 with GPT-2 BPE, context length 512, and three paired seeds. We compare Vanilla and SAGGS at , applied to Q-K, V-O, and ReLU up-down pairs at initialization. Training uses 15K Lion steps with learning rate , , weight decay 0.1, batch size 32, gradient clipping at 1.0, and BF16 mixed precision. The cosine schedule uses 1.5K warmup steps and decays to of peak learning rate. SAGGS rebalances all three pair types every 100 steps.
Results. All three pairs favor SAGGS, with PPL, paired Cohen's , and paired (Table 8). With , the one-sided exact sign-flip -value floor is 0.125. The soft-rebalancing comparison in Appendix F.4 evaluates Soft SAGGS with seven paired seeds under both unperturbed and deliberately tilted starts. The Lion state ablation in Appendix F.5 compares hard, soft, and state-covariant rebalancing under matched Lion controls.
Table 8 records the Lion validation PPL of each paired seed in this comparison.
Table 8: Three-seed hard-rebalancing Lion comparison at : 101M parameters, , and 15K steps. Rows index the paired seeds. V denotes Vanilla, S denotes SAGGS, and .
| Seed | |||
|---|---|---|---|
| 1 | 55.992 | 23.954 | +32.038 |
| 2 | 113.248 | 24.065 | +89.183 |
| 3 | 61.429 | 23.963 | +37.466 |
Table 9: Seven-seed Lion comparison on the 101M WikiText-103 model. PPL is reported as mean sample SD; the paired block reports Vanilla-minus-Soft SAGGS differences.
| Mean PPL | Paired difference | ||||||
|---|---|---|---|---|---|---|---|
| Vanilla | Soft SAGGS | ||||||
| 0.0 | |||||||
| 0.2 | |||||||
F.4 Soft Rebalancing with Lion
Design. We use the 101M ReLU Transformer and 15K-step Lion recipe of the hard-rebalancing comparison: learning rate , , weight decay 0.1, 1.5K-step warmup, cosine decay to 10% of peak learning rate, batch size 32, context length 512, gradient clipping at 1.0, and BF16 mixed precision on WikiText-103. The paired design compares Vanilla and Soft SAGGS at , with all-pairs reparameterization and Soft every 100 steps. The hard and state-covariant comparisons in the Lion state ablation use three paired seeds.
Table 9 provides the seven-seed summaries. At , every one of the seven paired seeds favors Soft SAGGS, giving PPL and exact one-sided sign-flip . At , the paired mean is PPL, including one seed where Soft is 0.51 PPL worse than Vanilla. The results support protection under the deliberate tilt, with a small observed unperturbed mean cost.
F.5 Optimizer-State Co-Transformation with Lion
A hard rebalance changes gradient coordinates while Lion retains a momentum buffer storing an EMA of past gradients. To measure the effect of this state mismatch, we compare Vanilla, hard SAGGS, Soft SAGGS, and the state-covariant variant of Appendix D.5 under matched medium-scale Lion protocols.
Design. The state-covariant experiment comprises six runs: , three paired seeds, 101M parameters and , WikiText-103, Lion , , weight decay 0.1, batch 32, 15K steps, all-pairs reparameterization, and . The only changed variable relative to hard SAGGS is that the Lion momentum buffer () is multiplied by the same chain-rule factor as the gradient coordinate after every rebalance. The Vanilla, hard SAGGS, and Soft SAGGS baselines use the matched three-seed Lion baselines from the hard-rebalancing comparison. Their means and sample SDs are reported alongside the state-covariant variant in Table 10.
Interpretation. At , state-covariant SAGGS has a lower mean and less seed variation than hard SAGGS: PPL compared with PPL in Table 10. State-covariant SAGGS still has an observed mean cost of 0.225 PPL relative to Vanilla, with PPL and . These results support an optimizer-state contribution to the cost of hard rebalancing, while showing that co-transforming the momentum buffer does not eliminate the measured unperturbed mean cost.
At , the state-covariant variant retains the full protective effect: Vanilla minus state-covariant SAGGS is PPL, with (Table 10), matching the direction and order of magnitude of the matched Vanilla-minus-hard and Vanilla-minus-Soft contrasts in Table 10. State-covariant SAGGS and hard SAGGS differ by only PPL on average at , while Soft SAGGS is slightly lower than state-covariant SAGGS by 0.117 PPL on average. These results motivate Soft SAGGS as the default when optimizer buffers are
Table 10: Lion state-covariant ablation on the 101M model with . The upper block reports PPL as mean sample SD, and the lower block reports paired Vanilla-minus-State differences. Soft denotes Soft SAGGS; State denotes hard SAGGS with covariantly transformed momentum buffers.
| Vanilla | SAGGS | Soft | State | |
|---|---|---|---|---|
| 0.0 | ||||
| 0.2 |
| 0.0 | |||||
| 0.2 |
Table 11: Branched checkpoint-surgery full paired contrasts on the 123.8M modern architecture with .
| Contrast | |||||
|---|---|---|---|---|---|
| Surgery no SAGGS – control | |||||
| Surgery no SAGGS – SAGGS | |||||
| Surgery no SAGGS – Soft | |||||
| Control – SAGGS | |||||
| Control – Soft |
left unchanged. State-covariant hard rebalancing provides a complementary diagnostic when momentum-buffer transformations are available.
F.6 Branched Checkpoint-Surgery Resume
Motivation. The 123.8M scale replication in Appendix G.15 measures sensitivity to orbit imbalance at initialization. We now test a checkpoint-resume setting in which weights are edited and training continues with a fresh optimizer. For each seed, one shared phase-1 checkpoint is cloned into four continuation branches, isolating the effect of the edit and subsequent rebalancing.
Design. For each of the seven paired seeds, we train the same RMSNorm, RoPE, SwiGLU, and GQA T5 SentencePiece model used in the 123.8M scale replication for 10K normal WikiText-103 AdamW steps. We then reset the optimizer and branch into four 5K-step resumes: control, surgery without SAGGS, surgery with hard SAGGS, and surgery with Soft SAGGS. The non-control branches receive an exact all-pairs orbit surgery at the handoff; the SAGGS branches then rebalance Q-K, V-O, and SwiGLU value-output pairs every 50 steps. Hard SAGGS applies an initial exact rebalance at the handoff; Soft SAGGS applies at the handoff and during the resume. The optimizer state is deliberately not carried across the handoff. Each phase uses a fresh cosine schedule with warmup: 1K steps in phase 1 and 500 steps in phase 2. The base learning rate, weight decay, batch size, context length, and precision match the 123.8M scale replication.
The handoff uses an exact symmetry edit: Across all edited branches, the absolute validation-loss change after surgery and any initial rebalance is below . These changes are floating-point residuals of the full handoff operation.
The optimizer-state-reset resume exposes a large coordinate effect. Surgery with no SAGGS reaches PPL, while the control resume reaches PPL, a paired degradation of PPL with all seven seeds in the same direction, with . Hard SAGGS and Soft SAGGS recover the final validation PPL closely: Their final PPLs are and , only 0.010 and 0.009 PPL above the control resume, respectively. The final Q-K log-ratio makes the mechanism visible: No-SAGGS surgery ends near 6.14, whereas both SAGGS variants end below .
The experiment demonstrates protection in a controlled checkpoint-resume workflow with a deliberately introduced symmetry-orbit displacement and an optimizer-state reset. The comparison measures recovery of the final PPL; identical resumed trajectories require canonicalizing both checkpoints (Corollary 4).
Table 12: State-preserved checkpoint-surgery diagnostic on the 31M modern-architecture WikiText-103 model with . The lower block reports paired contrasts.
| Resume condition | Final PPL |
|---|---|
| Control, optimizer reset | |
| Surgery, optimizer reset | |
| Surgery reset + Soft SAGGS | |
| Control, optimizer preserved | |
| Surgery, state-covariant optimizer |
| Contrast | |||||
|---|---|---|---|---|---|
| Surgery reset – control reset | +0.277 | 0.015 | +50.21 | +18.98 | 0.0078 |
| Surgery reset – Soft | +0.270 | 0.013 | +56.23 | +21.25 | 0.0078 |
| Soft – control reset | +0.007 | 0.006 | +2.98 | +1.13 | 0.0156 |
| State-covariant – state control | +0.058 | 0.017 | +8.83 | +3.34 | 0.0078 |
| Reset control – state control | -0.650 | 0.019 | -88.91 | -33.60 | 1.0000 |
F.7 Optimizer-State Diagnostics
Instead of being reset, the AdamW moments can be kept and transformed along with the weights, or loaded unchanged, which leaves the moments stale. Seven-seed experiments on the 31M model compare these cases, including moments that are stale only in the deeper half of the layers. With reset moments, the edit adds PPL relative to the matched control (Table 12). Keeping and transforming the moments leaves a smaller but nonzero gap of PPL relative to a control that also keeps its optimizer state, consistent with Theorem 2: Under a shared learning rate, transformed moments alone do not keep the two runs equivalent. Fully stale and half-stale moments yield penalties of and PPL, respectively (Tables 13 and 14). In the reset and stale cases, Soft SAGGS returns PPL to approximately the PPL of the control, with a residual of at most PPL.
F.8 State-Preserved Checkpoint-Surgery Diagnostic
The branched checkpoint-surgery resume deliberately resets optimizer state at the handoff, matching the common workflow of importing a checkpoint without its AdamW moments. We now measure the residual penalty when optimizer moments are preserved and transformed covariantly with the exact orbit edit.
Design. For each of the seven paired seeds, we train the 31M modern RMSNorm, RoPE, SwiGLU, and GQA T5 SentencePiece model for 5K WikiText-103 AdamW steps. We then clone the same checkpoint into five 2.5K-step branches: control reset, surgery reset, surgery reset + Soft SAGGS, control state, and surgery state-covariant. The model uses context length 256, batch size 48, and peak learning rate . Phase 1 follows a 7.5K-step cosine schedule with 750-step warmup. The reset branches create a fresh AdamW optimizer and a 2.5K-step cosine schedule with 250-step warmup; the state branches load the phase-1 AdamW and scheduler state. In the state-covariant surgery branch, the exact all-pairs orbit move also maps AdamW first moments by the chain-rule factor and second moments by its square. This branch applies the covariant moment map without periodic rebalancing during phase 2.
Table 12 reports the seven-seed summaries. The reset branch reproduces the checkpoint-surgery mechanism at a smaller model size. Surgery with optimizer reset is PPL worse than the reset control over seven paired seeds, with exact sign-flip . Soft SAGGS recovers the penalty almost entirely, leaving only PPL relative to the reset control. The largest immediate absolute validation-loss change after the edit, including the initial Soft rebalance where used, is below .
When optimizer state is preserved and co-transformed, the surgery gap falls to PPL relative to the state-preserved control. Moment co-transformation alone does not enforce trajectory equivariance: The shared learning rates already violate the coordinate rule in Theorem 2, even if . Global clipping, finite precision, and state history can introduce further discrepancies. The residual is about one fifth of the reset-surgery gap. This comparison changes both moment history and the learning-rate continuation, so the roughly reduction
Table 13: Stale AdamW-state diagnostic on the 31M model with : final PPL as mean sample SD and paired contrasts after an exact edit. Stale branches retain the pre-edit moments.
| Resume condition | Final PPL |
|---|---|
| Control, preserved state | |
| Surgery + stale AdamW state | |
| Surgery + covariant AdamW state | |
| Surgery + stale state + Soft SAGGS |
| Contrast | |||||
|---|---|---|---|---|---|
| Stale – control | +0.056 | 0.015 | +9.86 | +3.73 | 0.0078 |
| Stale – covariant | +0.002 | 0.001 | +6.42 | +2.42 | 0.0078 |
| Stale – Soft | +0.062 | 0.016 | +10.52 | +3.98 | 0.0078 |
| Covariant – control | +0.054 | 0.015 | +9.21 | +3.48 | 0.0078 |
| Soft – control | -0.005 | 0.003 | -5.45 | -2.06 | 1.0000 |
cannot be attributed to moment preservation alone or used to partition the 123.8M checkpoint-surgery penalty at a different model scale. The small measured handoff loss change separately supports forward preservation. The state-preserved control itself is worse than the reset control in this short-horizon diagnostic. The experiment characterizes the residual penalty under the state-preserved continuation.
F.9 Stale Optimizer-State Checkpoint Edit
The state-preserved diagnostic compares optimizer reset against a carefully co-transformed AdamW state. A second checkpoint-resume condition arises when a checkpoint is edited by an exact symmetry transform, but its AdamW moments are loaded unchanged. This mismatch can occur whenever model weights are imported, rescaled, or surgically modified while optimizer internals are treated as opaque checkpoint metadata.
Design. We reuse the 31M modern RMSNorm, RoPE, SwiGLU, and GQA T5 SentencePiece WikiText-103 setting of the state-preserved diagnostic. For each of the seven paired seeds, we train the model for 5K phase-1 steps, then clone the resulting checkpoint's model, AdamW, and scheduler states into four 2.5K-step branches: control state, surgery state stale, surgery state-covariant, and surgery state stale + Soft SAGGS. All surgery branches receive the exact all-pairs orbit edit. The stale branch leaves AdamW first and second moments in the old coordinates; the covariant branch maps first moments by the chain-rule factor and second moments by its square; the Soft branch uses the same stale optimizer state but applies Soft SAGGS at the handoff and every 50 steps.
Table 13 reports the seven-seed summaries. The stale-state edit creates a small but highly consistent penalty: PPL relative to the state-preserved control over seven paired seeds, with , despite an immediate handoff validation-loss change below . Co-transforming AdamW moments is slightly better than stale reuse by only PPL, and still remains PPL worse than control. This residual is consistent with Theorem 2: Keeping common learning rates while co-transforming moments is already insufficient for trajectory equivariance. Clipping, finite precision, and the floor can add to this effect; the contrast does not isolate their shares.
Soft SAGGS removes the stale-state penalty. The stale-minus-Soft contrast is PPL over all seven seeds, with , while Soft itself is PPL relative to the state-preserved control. The effect size is much smaller than in the optimizer-reset workflow of the branched checkpoint-surgery resume, but the exact checkpoint edit still changes subsequent training when moments are stale. Periodic Soft SAGGS recovers the control PPL in these runs.
F.10 Partial Optimizer-State Checkpoint Edit
The stale-state diagnostic treats the AdamW state as either fully stale or fully co-transformed. Real checkpoint workflows can fail in a more granular way: Optimizer-state shards may be missing or stale only for a subset of layers. This experiment tests that intermediate failure mode while keeping the forward edit exact.
Table 14: Partial AdamW-state diagnostic on the 31M model with : final PPL as mean sample SD and paired contrasts. In deep-half-stale branches, only shallow-layer moments are co-transformed.
| Resume condition | Final PPL |
|---|---|
| Control state preserved | |
| Exact edit, covariant state | |
| Exact edit, all state stale | |
| Exact edit, deep-half stale | |
| Deep-half stale + Soft SAGGS |
| Contrast | |||||
|---|---|---|---|---|---|
| All stale – control | +0.056 | 0.008 | +19.19 | +7.25 | 0.0078 |
| Deep stale – control | +0.056 | 0.007 | +19.86 | +7.51 | 0.0078 |
| Deep stale – covariant | +0.003 | 0.002 | +4.45 | +1.68 | 0.0078 |
| All stale – deep stale | +0.000 | 0.001 | +0.71 | +0.27 | 0.2500 |
| Deep stale – Soft | +0.062 | 0.008 | +19.92 | +7.53 | 0.0078 |
| Soft – control | -0.005 | 0.002 | -8.05 | -3.04 | 1.0000 |
Design. We again use the 31M modern RMSNorm, RoPE, SwiGLU, and GQA T5 SentencePiece WikiText-103 setting of the state-preserved and stale-state diagnostics. For each of the seven paired seeds, one 5K-step phase-1 checkpoint is cloned into five 2.5K-step branches: control state, surgery covariant, surgery all-stale, surgery deep-stale, and surgery deep-stale + Soft SAGGS. All surgery branches receive the exact all-pairs orbit edit. The covariant branch maps every AdamW first and second moment into the new coordinates. The all-stale branch leaves every moment in the old coordinates. The deep-stale branch maps only the shallow half of layers and leaves layers 6 through 11 stale, mimicking a partially missing optimizer-state shard. The Soft branch starts from this same partial-state condition and uses Soft SAGGS at handoff and every 50 steps.
Table 14 reports the seven-seed summaries. The partial-state condition changes subsequent training despite preserving the current function: The immediate handoff validation-loss change, including the initial Soft rebalance where used, is below , but the deep-stale branch is PPL worse than the state-preserved control over seven paired seeds, with . This partial-state penalty is essentially the same penalty as leaving all moments stale, PPL. Leaving the additional shallow-half moments stale changes mean PPL by only 0.00027; this difference measures the incremental cost of stale moments, not the entire surgery penalty. Relative to the fully covariant branch, the deep-stale condition is still PPL worse, so the partial shard mismatch is measurable but much smaller than the orbit edit itself under the practical protocol.
Soft SAGGS again removes the penalty. The deep-stale-minus-Soft contrast is PPL, with all seven paired seeds in the same direction, and Soft is PPL relative to the control. Together with the reset and stale-state comparisons, these results show that periodic rebalancing recovers control-level PPL across the tested optimizer-state conditions.
G ADDITIONAL EXPERIMENTS
These experiments evaluate numerical identities, naturally occurring imbalance, and transfer across architectures, corpora, and model sizes. Seed counts and method variants are stated for each protocol.
G.1 Gradient Law and Orbit Imbalance
G.1.1 Gradient-Law Verification
We evaluate the gradient-norm scaling implied by Eq. 2 on the same batch at orbit-related points, using FP32, or BF16 at 1.2B parameters. The exact pairs agree with the predicted scaling within floating-point error, whereas GELU MLP pairs show substantially larger deviations. Appendix G.3 defines the residual and slope measurements. Table 15 reports their maxima.
Table 15: Maximum relative gradient-norm residual (Eq. 26) in FP32, by depth, tilt, and pair type. GELU MLPs are included as a non-exact comparison.
| Pair | ||||
|---|---|---|---|---|
| Q-K (ReLU) | 12 | |||
| 24 | ||||
| 48 | ||||
| V-O (ReLU) | 12 | |||
| 24 | ||||
| 48 | ||||
| MLP (ReLU) | 12 | |||
| 24 | ||||
| 48 | ||||
| MLP (GELU) | 12 | |||
| 24 | ||||
| 48 | ||||
| MLP (SwiGLU) | 12 | |||
| 24 | ||||
| 48 |
G.1.2 Natural Drift
We test whether pair-scale imbalance also develops without a deliberate edit. We train three ReLU models at for 30K steps with two seeds: a small model with 22M parameters and , a medium model with 101M parameters and , and a deep model with 51M parameters and . We track the maximum absolute log-ratio across layers and measure its growth from initialization to the last logged step. Every reported seed shows positive growth. Q-K pairs have the largest mean increases, ranging from 0.14 to 0.20 (Table 16). Appendix G.4 defines the measurement and its numerical stabilizer. These results establish naturally occurring imbalance; its effect on PPL is assessed by the paired training comparisons in Sec. 5.2.
G.1.3 Additional Stress and Scale Checks
Supplementary experiments examine deeper models, SwiGLU, 354M models, and a single-seed 1.2B training run. These experiments generally show larger PPL effects under imposed rescaling than during unperturbed training, with exceptions documented in the experiments below. These comparisons complement the primary seven-seed results.
G.2 Supporting Ablations and Replications
Three-seed replications give Vanilla-minus-Soft PPL differences of +18.278 on OpenWebText, +21.156 at 123.8M parameters, and +85.813±4.730 at 296.7M under . Appendices G.14, G.15, and G.16 give the results. Their smaller seed counts support comparisons of direction and magnitude. Synthetic contraction and optimizer-state ablations provide separate diagnostics of the rebalancing operation, as reported in Appendices G.13 and F.5.
G.3 FP32 Gradient-Law Verification
We verify the gradient transformation law of Eq. 2 by computing gradients at the original parameterization and the reparameterized configuration for the same batch. Table 15 uses FP32; the 1.2B check uses BF16 mixed precision. The verification compares gradient norms. Writing and , its relative residual is
The reported is the maximum over tested blocks and layers. This residual verifies the norm consequence of the law; small norm residuals alone do not verify gradient directions.
Table 16: Increase in maximum absolute symmetry-pair log-ratio during standard ReLU training at . The reported uses as in Appendix G.4. Values are mean population SD over two seeds.
| Model | Params | Q-K | V-O | MLP | |
|---|---|---|---|---|---|
| Small | 22M | 12 | |||
| Medium | 101M | 24 | |||
| Deep | 51M | 48 |
The reported gradient-ratio depth slopes fit against layer index, with . The exact shift under an orbit move applies to the unstabilized log-ratio; a fixed additive can change this shift when a gradient norm is near the floor. We test across depths , tilt parameters , and all symmetry pairs Q-K, V-O, and MLP.
For the exact symmetries, i.e., Q-K and V-O across all activations, ReLU MLP, and SwiGLU value-output, the reported relative errors range from approximately to across the reported FP32 configurations. In particular, the ReLU MLP row reaches at ; the largest Q-K residual is at . These residuals are consistent with floating-point error in an exact symmetry. GELU MLP shows substantially larger errors with a non-monotone dependence on in the deepest row, up to , confirming that the deviation is dominated by GELU's lack of exact homogeneity rather than numerical precision. In the 1.2B gradient-law verification (Table 20), the law continues to hold with relative error below under BF16 mixed precision. The SwiGLU value-output rows have norm residuals near .
G.4 Naturally Occurring Pair Imbalance
At each logging step, before the optimizer update, we track the maximum stabilized log-ratio imbalance across all layers:
We record this statistic for each symmetry pair type Q-K, V-O, and MLP. This statistic is the absolute imbalance at step . Table 16 instead reports its increase between the first and last logged states:
The reported is a difference of maxima. The growth statistic is distinct from both the endpoint and the maximum layerwise change .
For positive norms and , the ideal log-ratio used in the theory satisfies . Thus the stabilized measurement approximates when both norms are large relative to , but the stabilized measurement does not obey the exact orbit-shift or contraction identities near the floor. Experimental references to measured log-ratios use this numerical convention. Since initialization is not exactly balanced, a nonzero endpoint alone does not establish growth from initialization; positive does establish an increase in the maximum absolute imbalance. We train for 30,000 steps with two seeds, context length 256, 2K-step warmup, and logging every 500 steps. Peak learning rate is for the small and deep models and for the medium model. The last logged drift state is at step 29.5K, before the final 500 updates.
The log-ratio increment depends on parameter and update inner products, as in Eq. 23; different gradient magnitudes alone do not determine the direction or persistence of drift.

Figure 2: Growth G in maximum absolute pair log-ratio from step 0 to 29.5K during standard ReLU training. Q–K pairs show the largest mean growth. The ordering of MLP and V–O differs across model configurations. Error bars show population SD over two seeds.
G.5 Pair Imbalance in a Pre-Trained Model
Motivation. The natural-drift experiment measures changes in pair imbalance during training from scratch. Here we inspect a released GPT-2 checkpoint to determine whether its learned attention pairs have unequal norms.
Checkpoint measurement. We load GPT-2 small (Radford et al., 2019), with 124M parameters, , , and GELU, from Hugging Face and measure the symmetry pair-norm balance. The recorded maximum absolute log-ratios are 0.221 for Q-K and 0.931 for V-O, so V-O has the larger imbalance in this checkpoint. These pre-fine-tuning measurements use stabilizer . Without the corresponding initial norms, these endpoint measurements do not determine how much imbalance accumulated during pre-training. We report the attention-pair maxima; GELU up-down rescaling is not an exact symmetry. Exact attention-pair edits of this biased model also require the bias co-transforms stated in Appendix B.1. These observations motivate studying attention-pair canonicalization during fine-tuning.
G.6 Deep-Model Sensitivity to Rescaling
Motivation. We test whether rebalancing protects deep Transformer training from deliberate exact Q–K orbit tilts. The deepest layer’s scale factor is ; the gradient-coordinate identity alone does not predict the resulting PPL or a critical value of .
Table 17: Deep ReLU model with under Q-K rescaling over 30K steps. Values are best validation PPL, reported as mean population SD over two seeds; denotes Vanilla minus SAGGS+P.
| Vanilla | SAGGS+P | |||
|---|---|---|---|---|
Table 18: 354M GELU model with Q-K rescaling over 15K steps. Values are best validation PPL, with denoting Vanilla minus SAGGS+P; gradient slopes are seed means at the last logged state, step 14.5K. The row marked uses three seeds, with PPL as mean sample SD; the other rows use a single seed.
| PPL | Gradient slope | |||||
|---|---|---|---|---|---|---|
| Vanilla | SAGGS+P | Vanilla | SAGGS+P | |||
Setup. We train the deep ReLU model with and on WikiText-103 for 30,000 AdamW steps with two seeds, applying Q-K rescaling at . The recipe uses peak learning rate , batch size 64, context length 256, and 2K-step warmup. We compare Vanilla against SAGGS+P, with rebalancing every 100 steps and auxiliary-penalty weight 0.01.
Results. Table 17 shows the results. At , where , Vanilla PPL approximately doubles from 30.34 to 61.46, while SAGGS+P maintains near-baseline PPL of 30.31. At , where , Vanilla reaches PPL 150.58, while SAGGS+P achieves 30.35, close to the unperturbed baseline in this two-seed stress test. The PPL gap of at is a stress-test result: Orbit rebalancing removes the injected symmetry-coordinate distortion.
G.7 Rescaling a 354M-Parameter Model
Motivation. We test whether the protection observed in the deep-model stress experiment also occurs at 354M parameters. The experiment compares unperturbed training with exact Q-K reparameterization at under the same training recipe.
Setup. We train the xlarge GELU model with and for 15,000 AdamW steps on a single NVIDIA H100 GPU, applying Q-K rescaling at . The sequence length is 512, and batch size 8 with gradient accumulation gives an effective batch size of 32. SAGGS+P applies only to Q-K and V-O pairs, where the bilinear symmetry is exact regardless of activation, with interval 200 and auxiliary penalty weight 0.005. Warmup is 1.5K steps. The reported PPL is the best validation value; gradient slopes use the last logged state at 14.5K.
Results. Table 18 reports one seed at and 0.1, and three seeds at . At , the PPL values are 23.53 and 23.59, a 0.06 increase for SAGGS+P in this single-seed comparison.
At , where , Vanilla achieves 23.89 while SAGGS+P maintains 23.56, giving a PPL gap at this scale factor. At , where , Vanilla PPL degrades to over 3 seeds, a increase over the 23.53 Vanilla baseline, while SAGGS+P maintains , essentially unchanged from the unperturbed case. All three seed-paired differences favor SAGGS+P, with small dispersion in these observed runs. The final logged gradient slope is 0.187 for Vanilla at and 0.017 for SAGGS+P.
Table 19: Single-seed SwiGLU MLP rescaling: best validation PPL over 30K steps, with MLP pair imbalance and gradient-ratio depth slope measured at the last logged state, step 29.5K.
| λ | Method | PPL | MLP imbalance | Gradient slope |
|---|---|---|---|---|
| Deep, | ||||
| 0.0 | Vanilla (baseline) | 28.48 | ||
| SAGGS+P | 28.42 | |||
| 0.2 | Vanilla | 63.24 | ||
| SAGGS+P | 28.46 | |||
| Small, | ||||
| 0.0 | Vanilla | 31.79 | ||
| SAGGS+P | 31.88 | |||
| 0.1 | Vanilla | 31.98 | ||
| SAGGS+P | 31.80 | |||
| 0.2 | Vanilla | 32.48 | ||
| SAGGS+P | 31.77 | |||
| 0.3 | Vanilla | 33.37 | ||
| SAGGS+P | 31.85 | |||
G.8 SwiGLU Sensitivity to Rescaling
Motivation. The gradient-law verification in Appendix G.3 confirmed SwiGLU's exact V-O symmetry with the nonlinear gate held fixed. SwiGLU is used in modern Transformer architectures, motivating a test of this activation. We vary the rescaling strength for SwiGLU, following the ReLU comparison in the deep-model stress test.
Setup. We compare two SwiGLU models with and : a 12-layer model with 25.5M parameters and a 48-layer model with 63.3M parameters. Rescaling acts on the MLP value–output pair, with for the smaller model and for the deeper model. Each configuration uses 30,000 WikiText-103 training steps and a single seed. The MLP-only runs use learning rate at and at , context 256, batch 64, and 2K-step warmup. The table reports best validation PPL; pair imbalance and gradient slope use the last logged state at step 29.5K.
Results. Table 19 reports the results.
Deep model, . At , where , Vanilla PPL degrades severely to 63.24 with an MLP log-ratio imbalance of 8.70 and gradient slope 0.212, while SAGGS+P maintains 28.46 PPL with pair imbalance below and slope 0.0002. Its PPL is close to the baseline of 28.48, recovering nearly all of the degradation caused by the imposed rescaling. SAGGS+P at achieves 28.42, compared with the Vanilla baseline of 28.48, a 0.06 PPL difference in this single-seed protocol.
Small model, . The lambda sweep reveals a smooth degradation curve: Vanilla PPL increases from 31.79 at to 31.98 at to 32.48 at to 33.37 at , with final logged MLP imbalance growing from 0.061 to 0.193 to 0.718 to 1.694 across the four tilts. SAGGS+P consistently maintains baseline performance across all values: 31.80 at , 31.77 at , and 31.85 at , all with pair imbalance below . At , the increase above the unperturbed Vanilla baseline of 31.79 is +1.58 PPL for Vanilla, which reaches 33.37, and +0.06 for SAGGS+P.
The +34.78 PPL gap between Vanilla and SAGGS+P at in the deep model shows substantial sensitivity to the exact SwiGLU value–output reparameterization in this training recipe. Figure 3 plots the corresponding validation-PPL curves at both depths.

Figure 3: Single-seed SwiGLU MLP rescaling at (a) and (b) : best validation PPL for Vanilla and SAGGS+P (Table 19). The deeper model uses only . Vanilla markers shift left and SAGGS+P markers shift right by 0.007 for visibility; the bracket in (b) gives Vanilla minus SAGGS+P at .
Table 20: 1.2B-parameter gradient law verification in BF16 mixed precision. Values are the maximum relative error across all 22 layers for each symmetry pair type and . All errors are below 0.16%.
| Pair type | Maximum relative error (%) | |||
|---|---|---|---|---|
| Q-K | 0.152 | 0.118 | 0.129 | 0.146 |
| V-O | 0.110 | 0.107 | 0.110 | 0.156 |
| MLP (SwiGLU) | 0.030 | 0.042 | 0.038 | 0.054 |
G.9 1.2B-Parameter Gradient Law Verification
Motivation. We measure gradient-law residuals at billion-parameter scale under BF16 mixed precision.
Setup. We construct a 1.22B-parameter SwiGLU Transformer with , , , and , with gradient checkpointing, and measure gradient norms at a single minibatch under BF16 mixed precision. For each of the symmetry pair types Q-K, V-O, and MLP, and , we reparameterize from a common baseline state and compare the measured gradient norms against the theoretical predictions and .
Results. Table 20 reports the maximum relative error across all layers for each pair type and value. Across all 12 configurations, the maximum relative error remains below 0.16%, with the MLP SwiGLU value–output pair achieving particularly precise agreement below 0.055%. At , the deepest layer's scale factor is . The extreme coordinate multiplier ratio is ; the actual gradient-norm spread also depends on the baseline gradients. These measurements show that the norm-scaling identity remains numerically accurate in this billion-parameter BF16 configuration.
Table 21: Single-seed rescaling-strength sweep at 101M parameters and over 30K steps. Here is SAGGS+P minus Vanilla. The difference is before rounding.
| Vanilla PPL | SAGGS+P PPL | ||
|---|---|---|---|
| 0.1 | 22.91 | 22.90 | |
| 0.2 | 23.24 | 22.89 | |
| 0.3 | 25.91 | 22.92 |
G.10 Rescaling Strength at 101M Parameters
Motivation. We test whether the advantage of SAGGS+P on the medium model with , , and 101M parameters grows at higher values where the scale factor becomes large.
Setup. We compare Vanilla and SAGGS+P on the medium ReLU model with Q-K rescaling at . Training uses a single seed, 30,000 WikiText-103 steps, learning rate , context length 512, batch size 32, and a 2K-step warmup. SAGGS+P uses rebalancing every 100 steps and auxiliary-penalty weight 0.01.
Results. Table 21 reports the results. At , where , SAGGS+P and Vanilla differ by 0.01 PPL, reaching 22.90 and 22.91, respectively. At , where , SAGGS+P begins to show benefit: SAGGS+P reaches 22.89 and Vanilla reaches 23.24, so . At , where , the gap widens substantially: SAGGS+P reaches 22.92 and Vanilla reaches 25.91, so . SAGGS+P at remains within 0.01 PPL of the Vanilla reference of 22.91, despite the roughly thousand-fold rescaling of the deepest pair.
G.11 Multi-Seed Comparisons Across Scales
Motivation. We assess consistency across random seeds at 22M, 101M, and 354M parameters, using two or three paired seeds at and .
Setup. We compare Vanilla and SAGGS+P at in three configurations. The 22M ReLU model uses , context length 256, and 3 seeds. The 101M ReLU model uses , context length 512, 3 seeds at , and 2 seeds at . The 354M GELU model uses , context length 512, 2 seeds, and gradient accumulation over 4 micro-batches for an effective batch size of 32. The 22M and 101M models train for 30K steps; the 354M model trains for 20K steps. The medium and 354M comparisons use Q-K-only tilts, learning rate , 2K-step warmup, rebalancing every 100 steps, and auxiliary-penalty weight 0.01. In particular, this 354M recipe uses a higher learning rate and more frequent rebalancing than the 354M stress test in Appendix G.7.
Results. Table 22 reports the multi-seed validation. At , SAGGS+P shows negligible difference from Vanilla across these scales, with absolute mean differences below 0.05 PPL.
At , SAGGS+P protects the medium and 354M models, while the small-model comparison favors Vanilla. The medium-scale gap of is consistent with the 101M rescaling-strength sweep (Table 21), and the 354M gap of has a large paired effect size in this protocol. This 20K-step cross-scale protocol is distinct from the 15K-step 354M stress experiment (Table 18), where the same mechanism yields a larger PPL gap; the comparisons agree in sign and differ in horizon and recipe.
Table 22: Multi-seed validation across scales. Rows marked use two seeds; the others use three. is SAGGS+P minus Vanilla; paired SD uses within-seed differences. Values are mean SD: Medium and 354M entries use sample SD over the complete specified seed sets, while small-model entries retain their original recorded summaries.
| Scale | Vanilla PPL | SAGGS+P PPL | ||
|---|---|---|---|---|
| Small, 22M | 0 | |||
| 0.2 | ||||
| Medium, 101M | ||||
| 0.2 | ||||
| 354M | ||||
Table 23: Single-seed 1.2B-parameter SwiGLU training over 10K steps with DDP on 4×H100 GPUs. Gradient norms are measured before clipping at 1.0.
| Metric | |||
|---|---|---|---|
| Vanilla | Vanilla | SAGGS | |
| Final validation PPL | 23.81 | 221.24 | |
| Best validation PPL | 23.81 | 221.24 | |
| Mean gradient norm | 0.68 | 27.79 | |
| Q-K max-abs log-ratio | 0.032 | 4.222 | |
| V-O max-abs log-ratio | 0.033 | 4.117 | |
| MLP max-abs log-ratio | 0.037 | 4.138 | |
G.12 1.2B-Parameter Training
Motivation. The 1.2B gradient-law verification in Appendix G.9 confirmed the gradient transformation law via a single forward-backward pass. A separate empirical issue is whether the sensitivity seen in smaller-scale training persists at billion-parameter scale. To test this persistence, we train a 1.22B-parameter SwiGLU model for 10,000 optimizer steps using DDP across 4×H100 GPUs.
Setup. The SwiGLU Transformer has , , , and , with gradient checkpointing and BF16 mixed precision. We train on WikiText-103 using AdamW with , , weight decay 0.1, a cosine schedule with 1,000-step warmup, and gradient clipping at 1.0. A per-GPU batch size of 4 on 4 GPUs with 2 accumulation steps gives an effective batch size of 32. We compare three configurations: unperturbed Vanilla at , Vanilla with all-pairs rescaling at , and SAGGS with the same rescaling and rebalancing every 100 steps.
Results. Table 23 reports the results. The 1.2B baseline achieves PPL = 23.81 after the specified 10K-step training budget. At , where and the all-pairs reparameterization affects Q-K, V-O, and MLP simultaneously, Vanilla PPL severely degrades to 221.24, a increase. The training loss plateaus above 2.7, compared with a baseline of 1.5, and does not recover within the 10K-step budget. Before clipping at 1.0, the mean gradient norm reaches 27.8, compared with a baseline of 0.68, with a peak of about 4,700. The final maximum absolute log-ratios are 4.22 for Q-K, 4.12 for V-O, and 4.14 for MLP.
In this single-seed 10K-step run, SAGGS protects against this degradation, achieving PPL = 23.70, slightly better than the baseline, while keeping the final maximum absolute log-ratio below for every pair type. V-O is largest at . Figure 4 shows how Q-K and MLP imbalance evolve during this run. This single-seed comparison extends the observed sensitivity to rescaling to billion-parameter training.
Interpretation. Together with the 1.2B gradient-law verification (Appendix G.9), this run shows that both the structural symmetry and the associated optimizer sensitivity appear at billion-parameter size.
(a) Q-K pairs

(b) MLP pairs
---- Vanilla
Vanilla

SAGGS
Figure 4: Maximum absolute pair log-ratio across layers during 1.2B training: (a) Q–K and (b) MLP. The shared vertical scale is linear from 0 to and logarithmic above; the break marks the transition. Post-rebalance SAGGS samples are at most and appear at zero. Samples align with rebalancing events and end at 9.9K; Table 23 reports the final 10K-step measurements after the intervening updates.
G.13 Exact Contraction and Synthetic Optimizer Diagnostics
This synthetic study tests the exact disturbance-free contraction law and separately measures Lion sign changes after a soft orbit edit. The sign diagnostic concerns the sampled optimizer state.
Disturbance-free Soft SAGGS contraction. Starting from a random pair with controlled log-ratio , we apply the damped rebalancing map of Eq. 12 repeatedly without intervening optimizer updates. The contraction law in Eq. 19 predicts exactly. In double precision over and three initial imbalances, the reported worst scored single-step relative error is . This error is scored only when both and exceed ; tiny denominators can amplify rounding error. For , the predicted residual is zero, so this relative-error score has no eligible steps. The 200-event absolute residual is zero for all three starts at . The theoretical factor at is after 200 events and after 150 events. These factors describe repeated applications of the damped rebalancing map; training-time balance is measured separately in the language-model experiments.
Lion update-sign response to damping. After a 500-step warmup with initial reparameterization, we branch the optimizer state into six parallel runs, each applying Soft SAGGS with a different , and compare the immediate Lion sign update to the branch. The fraction of update components that flip sign relative to baseline is 0.65% at , 1.82% at , 3.91% at , 5.34% at , and 7.03% at . The measured relationship is monotone in and roughly linear. Hard rebalancing with flips about 11 times as many components as in this diagnostic; this pattern is an empirical observation about the sampled state.
Table 24: OpenWebText paired comparison with seeds. The paired block is Vanilla minus Soft SAGGS with and reports the two-sided sign-flip -value .
| Mean PPL | Paired difference | ||||||
|---|---|---|---|---|---|---|---|
| Vanilla | Soft, | ||||||
| 0.0 | |||||||
| 0.2 | |||||||
Table 25: 123.8M modern-architecture scale replication, 15K AdamW steps, . The paired block is Vanilla minus Soft SAGGS with .
| Mean PPL | Paired difference | ||||||
|---|---|---|---|---|---|---|---|
| Vanilla | Soft, | ||||||
| 0.0 | |||||||
| 0.2 | |||||||
G.14 Cross-Corpus Replication on OpenWebText
The medium-scale paired comparisons in the 101M WikiText-103, multi-seed cross-scale, and Lion experiments all run on a single corpus of about 103M words tokenized with the GPT-2 vocabulary. We repeat the paired comparison of Vanilla and Soft SAGGS with , crossed with and , on OpenWebText (Gokaslan and Cohen, 2019), using a 100M-token GPT-2-tokenized subset, with the same medium-scale architecture as the 101M WikiText-103 comparisons: , , , and 101M parameters, trained with AdamW at , , weight decay 0.1, a cosine schedule with 1.5K warmup, gradient clipping at 1.0, batch size 32, , and BF16 autocast, for 15K steps with all-pairs reparameterization. The learning rate, warmup, horizon, and use of all-pairs rather than Q-K-only tilts differ from the 30K-step recipe of the 101M WikiText-103 comparisons, and the optimizer differs from the optimizer of the Lion comparisons. The replication changes both corpus and training recipe. Each configuration uses three paired seeds.
Table 24 reports PPL for unperturbed Vanilla training and after rescaling. At , the paired Vanilla-minus-Soft difference is PPL; at , the difference is PPL. The protection has the same direction as the WikiText-103 comparison, but its magnitude is not directly attributable to the corpus change because the optimizer recipe, horizon, and edited pairs also differ. The two-sided sign-flip -value is 0.25 at for three seeds. This experiment provides supporting evidence on another corpus under a different training recipe.
This OpenWebText comparison keeps the GPT-2 BPE vocabulary and the same dense Transformer without GQA or RMSNorm. The architecture and tokenizer replication in Appendix F.2 instead tests a smaller but deliberately different LLaMA-like stack (Touvron et al., 2023; Ainslie et al., 2023): RMSNorm, RoPE, SwiGLU, GQA, and a T5 SentencePiece tokenizer.
G.15 123.8M Modern-Architecture Scale Replication
The 31M replication in Appendix F.2 changed the architecture and tokenizer at a scale that admits seven paired seeds. We next test the same mechanism in the 100M-parameter regime. We keep the RMSNorm, RoPE, SwiGLU, and GQA block and T5 SentencePiece tokenizer, but use a 24-layer model with , ten query heads, two KV heads, SwiGLU hidden width 1728, sequence length 512, and tied embeddings, for 123.8M trainable parameters.
We use the same paired design comparing Vanilla and Soft SAGGS with , crossed with and , over three paired seeds. The optimizer is AdamW with , weight decay 0.1, cosine decay, warmup, gradient clipping at 1.0, BF16 XPU autocast, batch size 12, sequence length 512, and 15K steps. The reparameterization and Soft SAGGS act on Q-K, V-O, and SwiGLU value-output pairs, with rebalancing every 100 steps. Training uses Intel Data Center GPU Max 1550 XPU tiles.
Table 25 reports the three-seed summaries. The 123.8M replication follows the same pattern as the 31M comparison. At , the mean Vanilla-minus-Soft difference is PPL.
Table 26: 296.7M modern-architecture scale replication, 12K AdamW steps, . The paired block is Vanilla minus Soft SAGGS with .
| Mean PPL | Paired difference | ||||||
|---|---|---|---|---|---|---|---|
| Vanilla | Soft, | ||||||
| 0.0 | |||||||
| 0.2 | |||||||
At , Vanilla ends at PPL , whereas Soft SAGGS ends at ; the paired contrast is PPL with all three seeds favoring Soft SAGGS. With , the one-sided exact sign-flip -value floor is 0.125.
G.16 296.7M Modern-Architecture Scale Replication
The modern-architecture replications at 31M and 123.8M parameters show sensitivity to rescaling. We next test the same paired design at 296.7M parameters, increasing both the width and depth of the RMSNorm, RoPE, SwiGLU, and GQA architecture.
Design. The model uses the same T5 SentencePiece tokenization and causal RMSNorm, RoPE, SwiGLU, and GQA block, with , 14 query heads, two KV heads, SwiGLU hidden width 2432, 32 layers, tied embeddings, sequence length 512, and 296.7M trainable parameters. We train the paired grid of Vanilla and Soft SAGGS with , crossed with and , over three paired seeds for 12K AdamW steps on WikiText-103 with learning rate , weight decay 0.1, 10% warmup, cosine decay, gradient clipping at 1.0, BF16 XPU autocast, batch size 8, and rebalancing every 100 steps. As in the 123.8M scale replication and checkpoint-surgery resume, the intervention acts on Q-K, V-O, and SwiGLU value-output pairs. The run uses all 12 Intel Data Center GPU Max 1550 XPU tiles.
Table 26 reports the three-seed summaries. At , Soft SAGGS achieves slightly lower PPL in all three paired seeds, with . Under the same exact all-pairs reparameterization, Vanilla ends at PPL, while Soft SAGGS ends at PPL; the paired protection is PPL with all three seeds favoring Soft SAGGS.
The final pair-norm statistics show balance control: Vanilla runs at retain large maximum absolute log-ratios, Q-K about 7.5, V-O about 5.4, and MLP about 6.4, whereas Soft SAGGS keeps all three below . Absolute PPL is tokenizer- and budget-dependent; the contrast is the within-tokenizer, seed-paired PPL recovery under deliberate rescaling at a 300M-class modern-architecture scale.
H FURTHER DISCUSSION
The results distinguish invariance of the current function from equivariance of an optimizer trajectory. Standard adaptive and sign-based rules can cancel gradient scales while retaining a dependence on parameter scales. Transforming moments alone does not correct the update-scaling mismatch under shared hyperparameters. Full-state canonicalization addresses this dependence at restart by bringing orbit-related checkpoints to the same numerical state.
Periodic rebalancing serves a different practical role: controlling pair-scale imbalance as training proceeds. Its strongest measured benefits occur after deliberately imposed rescaling, including the checkpoint-resume workflows. Imbalance also arises naturally, in both trained-from-scratch and public models, and rebalancing can be kept on throughout training to control this imbalance: A rebalance rescales each pair only as much as the pair is imbalanced, correcting a large imbalance and leaving pairs that are already close to balance almost untouched. Soft SAGGS brings the same control to Lion, whose update depends on a momentum buffer of past gradients: Soft SAGGS leaves the optimizer state unchanged and applies the correction in several smaller steps, so the update changes gradually, and training recovers from the degradation caused by an edit.
The normalization layers of a Transformer, either layer normalization or RMSNorm, do not remove the pair symmetries, because these layers act on the residual stream rather than on the paired matrices. Weight decay does not restore pair balance either, because the decay shrinks both matrices of a pair by the same factor. Global gradient clipping rescales all gradients by one common factor, set by their total norm, so the gradients enlarged by an orbit edit can shrink the gradients of all other blocks. The following subsections expand on this discussion, covering adaptive and sign-based optimizers, natural drift and weight decay, initialization, and training stability.
H.1 Adaptive Normalization and Trajectory Equivariance
Adam and AdamW normalize gradients using per-parameter moment estimates. With covariantly transformed moments and , their normalized directions are unchanged by reciprocal rescaling. Equivariance requires the parameter displacements to scale with the parameters, which a shared learning rate does not provide (Theorem 2). Theorem 5 extends this obstruction to the standard block-local rules considered here.
For ideal degree-zero rules on corresponding histories, Corollary 6 shows that the distortion in the log-ratio of relative data updates is half the distortion of gradient descent. This factor concerns the data-update term under the stated assumptions; full increments can also reflect weight decay, a fixed positive , and differences in clipping.
Theorem 2 supplies a mechanism for a residual surgery gap even with correctly transformed moments. The depth and sweeps measure the training response, while the state-preserved, stale-state, and partial-state experiments (Appendices F.8, F.9, and F.10) examine the additional role of moment history.
Adaptive-optimizer qualifications. Reset or stale moments and time-varying orbit moves can break the correspondence between current gradients and past statistics. A fixed positive must also be transformed according to Theorem 2 to preserve trajectory equivariance. Global gradient clipping generally changes its common clipping multiplier under a nonuniform diagonal rescaling of the gradient. Decoupled weight decay alone commutes with a fixed diagonal rescaling when is unchanged. If learning rates are transformed to restore update equivariance, the decay coefficients must also be transformed to keep this product fixed.
H.2 Sign-Based Optimizers and Soft Rebalancing
Lion computes its update sign from a weighted combination of the current gradient and its momentum buffer, an EMA of past gradients. A positive scalar rescaling of both the gradient and the buffer leaves this sign unchanged. As in Example 3, this sign invariance produces the same numerical displacement, while a rescaled parameter trajectory requires a rescaled displacement. Sign invariance does not imply immunity to a symmetry tilt, even before accounting for clipping or a stale momentum buffer. Theorem 5 covers Lion directly as a degree-zero rule. The hard- and soft-rebalancing Lion comparisons (Appendices F.3 and F.4) measure the resulting training sensitivity: The tilt degrades Vanilla Lion training, and rebalancing recovers PPL in those comparisons.
The Lion state ablation in Appendix F.5 reports a higher unperturbed mean PPL and greater seed variation for hard SAGGS than for Soft or state-covariant rebalancing. Soft SAGGS limits the correction at each event by applying only an fraction of the log-norm correction, as in Eq. 19. Optimizer updates can introduce new imbalance between events. The synthetic study in Appendix G.13 separately reports a sampled sign-response diagnostic. For sign-based optimizers, we use as the default, retain the protection, and assess the unperturbed cost with paired controls at .
H.3 Natural Drift and Weight Decay
Pair imbalance develops during ordinary training, but the direction of that drift depends on the radial components of the optimizer updates, not just their magnitudes. Appendix C.9 states the exact defect recursion and the first-order log-ratio identity. Appendix C.10 gives the derivations. Common weight decay scales both matrices equally and therefore leaves the ratio unchanged. Hard SAGGS restores balance at each executed event, while Soft SAGGS contracts the log-ratio. The effect on validation loss depends on the subsequent training trajectory. Layer normalization preserves the internal pair identities, as shown in Appendix B.3.
H.4 Implications for Initialization
Our analysis reveals that standard initialization schemes, e.g., Xavier and Kaiming, implicitly choose a specific point in the continuous family of forward-equivalent parameterizations. The gradient geometry at this point need not be the best one for a fixed optimizer, horizon, and regularization recipe. Specifically, if and are initialized with the same variance, as is standard, the squared Frobenius norms have the same expectation when their shapes match; independent samples are not exactly balanced. Training can then change the imbalance. Residual-output initialization and GQA also give systematic norm differences, so means no deliberate tilt, not exact balance of every pair.
SAGGS enforces balance at executed hard events. Soft SAGGS contracts the current log-ratio. Their effects on validation PPL are evaluated against the unperturbed training controls.
H.5 Training Stability
Gradient geometry distortion can also affect training stability. When the reparameterization amplifies gradients of by while attenuating the gradients of by , the spread of gradient norms can change in either direction, depending on the baseline gradients. The amplified gradients may dominate the global norm and cause clipping to scale the current gradients of every block. This clipping leaves every nonzero pair-gradient norm ratio unchanged. For gradient descent, the clipping scales the data-update direction by the same factor, but the effect on AdamW depends on both moment histories. Theorem 2 excludes clipping, whose multiplier can change under an orbit edit. Decoupled decay is separate from this gradient clipping.
We track gradient norm spikes, defined as steps where the total gradient norm exceeds , across our experiments. While the absolute number of spikes does not change substantially with moderate under AdamW in the reported runs, the distribution of gradient mass across parameter groups shifts systematically, which can be detrimental for training efficiency. SAGGS controls pair-norm imbalance; the resulting gradient-norm distribution still depends on the training trajectory.
(a) Shape-adjusted pair log-ratio in released checkpoints; all layers; zero = equal RMS entries

(b) Frobenius log-ratio during Pythia pre-training; equal-size pairs have matching RMS and Frobenius ratios

Figure 5: Pair-scale variation in released checkpoints. (a) Eleven checkpoints, using the shape-adjusted log-ratio , where and count matrix entries. Red denotes larger root mean square (RMS) entry magnitudes in and blue denotes larger RMS entry magnitudes in ; zero means equal RMS, which differs from Frobenius balance for unequal-size GQA pairs. Blank SwiGLU rows denote GELU MLPs. (b) Four Pythia pre-training runs and layerwise Q–K log-ratios for 410M. Equal matrix sizes make RMS and Frobenius log-ratios coincide. Appendix I.6 gives the protocols.
I RELEASED-CHECKPOINT CASE STUDIES
The paired experiments establish protection and recovery in controlled training runs. We complement these experiments with four case studies on public checkpoints: naturally occurring pair-scale variation, coordinate-sensitive fine-tuning, the internal evolution of a Lion stress test, and token-level restart differences on real text. These measurements are independent of the primary training runs. Appendix I.5 summarizes the case studies, and Appendix I.6 gives the protocols.
I. 1 Pair Scales in Public Checkpoints
Figure 5 extends the GPT-2 endpoint measurement of Appendix G.5 with a cross-model survey and intermediate Pythia checkpoints. The intermediate checkpoints distinguish initialization offsets from changes accumulated during training: Q–K starts nearly balanced, but reaches a maximum absolute log-ratio of 1.86 in Pythia 410M, concentrated in deep layers. Pythia 1B remains within 0.04, and V–O initially moves toward balance. Drift is model- and pair-dependent. These observations show pair-scale variation during ordinary training, without measuring its effect on loss. Training also changes the function, so these checkpoints are not points on a single fixed symmetry orbit.
(a) Disagreement with the canonicalized trajectory

(b) Divergence from the canonicalized trajectory
(c) Relative movement: (solid), (dashed)
(d) Q–K imbalance persists; Soft contracts it

reciprocal edit
edit + Soft SAGGS ( , every 10 steps)
canonicalized at handoff (either start)
released coordinates
released, other training-window seed
Figure 6: Fine-tuning from forward-identical GPT-2 774M checkpoints: 200 AdamW updates with fresh moments and 16,384 held-out targets. (a) Top-1 disagreement and (b) mean absolute token-NLL difference, relative to the canonicalized branch. Canonicalizing either start gives the same trajectory, shown in green. The dashed reference uses different sampled training windows; the reference is not an uncertainty band. (c) Net Q–K movement relative to each branch’s starting norm, a cumulative rather than one-step measurement. (d) Q–K log-ratios: layer mean and min–max band. Soft SAGGS uses at handoff and every ten steps. Appendix I.6 gives the protocols.
I. 2 Fine-Tuning from Equivalent Checkpoints
We next branch from the released GPT-2 774M checkpoint with fresh AdamW moments (Figure 6). An exact reciprocal edit , preserves the current function but leads to 7.3% held-out top-1 disagreement with the canonicalized trajectory after 200 updates. Canonicalizing either starting representative gives identical subsequent predictions and token negative log-likelihoods (NLLs) at every evaluation. Soft SAGGS leaves 1.1% disagreement. Continuing from the released coordinates gives 0.65% disagreement with the same canonicalized reference. This comparison illustrates Corollary 4 with reset moments and distinguishes exact restart equivalence from the approximate recovery provided by Soft SAGGS. The reciprocal edit is imposed for this controlled comparison; trajectory differences do not establish a long-run loss advantage.
(a) Relative first step: (solid), (dashed)

(b)

(c) Attention entropy after 400 steps
(d) Early loss improvement reverses

tilt on Q-K and V-O)
tilt + hard, every 10 steps
sign-term prediction (tilt)
tilt + Soft, every 10 steps
tilt + Soft, every 100 steps
released coordinates
released + Soft, every 10 steps
Figure 7: Depth-resolved response to an exact attention-pair tilt in GPT-2 355M with during 400 Lion steps. (a) First-step relative Q–K movement and the sign-term prediction ; full updates also include decay. (b) Direction change for tilted and , and with tilt + Soft every ten steps. Columns are 15 evaluation steps on a nonlinear time axis. (c) Attention-entropy change from handoff after 400 steps, averaged over 16 fixed sequences, heads, and query positions. (d) Mean held-out NLL. Rebalancing includes handoff and leaves buffers unchanged; Soft uses . The figure shows a single-seed stress test; protocols are in Appendix I.6.
I. 3 Depth-Resolved Evolution under Lion
Figure 7 connects the degree-zero relative-update law to the time course of a public-model stress test. The deepest key block receives a relative first step of about 1% under the imposed tilt, compared with 0.01% in released coordinates. Its cosine similarity with the starting matrix falls to 0.46 after 400 steps, accompanied by a larger attention entropy decrease in deep layers and a reversal of the early loss advantage. The cosine diagnostic is invariant to positive scalar rescalings and therefore separates directional change from the balancing operation itself. Soft SAGGS limits these changes, and hard rebalancing also performs well in this setting. The preference for damping is supported by the unperturbed Lion state ablation in Appendix F.5. Here, attention entropy and loss are measured jointly, without isolating a causal relation between the two quantities.

Figure 8: Token-level restart differences in GPT-2 124M. (a), (b), and (c) Outcome-independent excerpts from three WikiText-103 validation articles. Columns are ground-truth BPE tokens conditioned on preceding text; a leading dot denotes a space and @-@ is the corpus hyphen. Rows show branch-minus-control token NLL at handoff or after 30 shared AdamW updates. Blue denotes increased and red denotes decreased target probability on a shared signed scale. The edit co-transforms moments; the canonical branch additionally balances weights and moments, while Soft SAGGS with leaves buffers unchanged at rebalancing. Appendix I.6 gives the protocols.
I. 4 Token-Level Differences after Restart
Figure 8 makes the full-state distinction visible at individual tokens. After a moment-covariant edit, the probability of Marshal rises from the control's 0.0582 to 0.0628, while commander falls from 0.0242 to 0.0215 after resuming. Full-state canonicalization restores both, within finite-precision residuals. The edited branch's mean NLL is 0.01136 nats lower on this evaluation set, illustrating that trajectory divergence can also improve predictions. Soft SAGGS leaves a small residual difference from the control; full-state canonicalization recovers the reference trajectory.
I. 5 Summary
Case studies on public checkpoints complement the paired training comparisons. The case studies show that pair imbalance also arises in ordinary training, to a degree that varies across models and pairs. In Pythia 410M, for example, the query and key matrices start with nearly equal norms, but during pre-training their norms drift apart by a factor of up to about 6 in deep layers, which corresponds to a log-norm ratio of 1.86.
The case studies also test canonical restart on a released model. We fine-tune GPT-2 774M with fresh AdamW moments, starting from the released checkpoint and from an exact Q–K edit of this checkpoint that maps and . Canonicalizing both checkpoints at restart makes the two runs identical, with the same predictions and token NLLs at every evaluation. Without canonicalization, the edited run predicts a different top-1 token than the canonicalized runs at 7.3% of held-out positions after 200 updates. Periodic Soft SAGGS reduces this fraction to 1.1% but not to zero. Canonical restart also works when the moments are kept rather than reset: In a GPT-2 124M case whose edit transforms the moments along with the weights, canonicalizing both weights and moments fully restores the trajectory of the unedited run.
I. 6 Protocols
The four figures in this appendix use supplementary measurements on public checkpoints, independently of the primary training runs. Training case studies use a single fixed seed, FP32, deterministic PyTorch operations, eager attention, and no dropout, TensorFloat-32, or gradient clipping. Within each comparison, all branches use the same fixed training batches, except for the explicitly marked alternative-sampling reference. The training runs use one GPU; the checkpoint-norm survey reads weight tensors on CPU. The case studies are descriptive, single-seed measurements, not additional multi-seed PPL comparisons. Evaluation subsets contain teacher-forced next-token targets, not sampled generations or full-validation PPL measurements.
Public checkpoint survey (Figure 5). Figure 5(a) includes GPT-2 124M, 355M, 774M and 1.5B; Pythia 6.9B; Qwen2.5 3B and 7B; Mistral 7B v0.1; Hermes-3-Llama-3.1-8B; a ViT-B/16 CIFAR-10 classifier; and the DistilBERT SST-2 classifier. All layers and available exact matrix pairs are retained, with biases excluded from norms. Fused GPT-2 and Pythia projections are split into Q, K, and V. Pythia stores these projections grouped by head. SwiGLU uses only its up-down value path. GELU MLPs are excluded. Figure 5(a) removes the shape offset (1/2) , and therefore measures equal-RMS rather than equal-Frobenius balance for GQA. The measured Qwen2.5-3B-Instruct row is omitted because its log-ratios differ from the base by at most .
Figure 5(b) uses public Pythia 160M, 410M, 1B and 1.4B checkpoints from step 0 through step 143000: 20 each for 160M and 410M and 11 each for 1B and 1.4B. Each training step represents 2,097,152 tokens. Pythia 2.8B was excluded because its early checkpoints contained the same already-trained weights as the endpoint, preventing an initialization comparison. Q–K starts within 0.003 of balance in all four plotted models. V–O starts near , consistent with the initialization offset. The model sizes differ in architecture dimensions; no monotone size trend or performance consequence is inferred from these observations.
Fine-tuning and Lion protocols. Figures 6 and 7 use the released GPT-2 774M (openai-community/gpt2-large) and 355M (openai-community/gpt2-medium) checkpoints, respectively. Both use batch size four, context length 128, and fixed random windows from a prefix of the WikiText-103 raw training split containing just over 600,000 tokens, with end-of-text separators. The evaluation set comprises the first 128 non-heading validation paragraphs with at least 129 GPT-2 tokens, truncated to 129 tokens each, yielding 16,384 targets.
The 774M run starts each branch with fresh AdamW moments, learning rate , , , decay 0.1, and 200 updates at constant learning rate without warmup. Q–K reciprocal edits co-transform their biases and leave the attention scaling operation unchanged. Canonicalization and Soft operate on Q–K and V–O. Q, K, and V biases follow their weight scales, while attention output biases are untouched. Soft uses at handoff and every ten steps without moment transformation. The alternative-sampling branch uses a different seed to draw new training windows. In Figure 6(a) and Figure 6(b), this branch is compared to the canonicalized branch, just like the other curves, and is a single reference, not a variability estimate. The measured handoff maximum logit difference is on the first 16 evaluation sequences, with zero top-1 disagreements over all evaluation targets. The two canonicalized branches have identical predictions and token NLLs at all 12 evaluation steps.
The canonicalized branch’s mean held-out NLL falls from 3.389 to 2.975 nats. At step 200, the reciprocal-edit, released, and Soft SAGGS branches exceed this NLL by , , and nats, respectively. Median Q-to-K relative net movement is about 58 for the edited branch and near one after canonicalization.
The 355M run uses Lion with a zero-initialized momentum buffer, constant learning rate , , decay 0.1 on matrices and no decay on vectors, and 400 updates without warmup. The tilt acts on Q-K and V-O in all 24 layers; biases follow the exact transformations above. Branches comprise released, released+Soft, tilt, tilt+Soft every ten or 100 steps, and tilt+hard every ten steps. Every rebalancing branch also corrects at handoff and leaves buffers unchanged. In particular, the interval-100 Soft branch already has a smaller initial imbalance than the uncorrected tilt branch. Relative steps are measured before each periodic rebalance, and cosine changes are measured against each branch's own post-handoff matrices. The handoff maximum logit residual is below 0.013 on the logit probe, with zero disagreements on all evaluation targets. For K and O, measured step norms agree with the sign-only prediction within 0.11% throughout the run; decay contributes more for the inflated Q blocks. The large imposed scale is a stress test, not an estimate of typical naturally occurring imbalance.
At layer 24, the relative first-step magnitude of divided by the relative first-step magnitude of is 7,166 under the tilt and 1.03 in released coordinates. Final NLL is 3.350 for the tilted branch, 3.151 for released, 3.153 for tilt + Soft, and 3.151 for tilt + hard.
Token-level restart protocol. Figure 8 uses the released GPT-2 124M model (openai-community/gpt2) and its tokenizer. We first perform 20 AdamW adaptation steps, then exactly balance attention pairs and co-transform moments to obtain a shared balanced starting state. This complete state is cloned into the control and the edited branches. The edit uses for and maps , . The full-state branch additionally canonicalizes both weights and moments before resuming. Soft applies at handoff and every five steps, leaving buffers unchanged at its own events. This design distinguishes full-state canonical restart from the default buffer-preserving periodic method.
All branches resume for 30 updates with batch four, context 128, constant learning rate , AdamW betas , , and decay 0.1. Fixed training windows are drawn from a prefix of the WikiText-103 raw training split containing just over 200,000 tokens. The evaluation set takes the first 64 non-heading validation paragraphs with at least 65 tokens and scores their first 64 next-token targets. Displayed cases are the first qualifying paragraphs of the first three distinct validation articles, located at source rows 3, 49, and 80, using their first 33 tokens; the initial token provides context. Selection does not depend on the branch outcomes. Original WikiText punctuation is retained. For the 96 displayed target positions, the maximum handoff logit discrepancy is ; after resuming, the discrepancy is 3.08 for the edited branch and for full-state canonicalization. The three passages are illustrative cases, not independent training replicates.
Across all 4,096 evaluation targets, the branches initially agree on top-1 predictions. Final disagreement with control is 3.32% with mapped moments alone, 0% with full-state canonicalization, and 0.20% with Soft SAGGS. These comparisons measure restoration of the reference trajectory, not a general quality advantage.
Table 27: Main mathematical notation used in the paper.
| Symbol | Meaning |
|---|---|
| Architecture and loss | |
| model parameters | |
| data loss | |
| depth and layer index | |
| hidden, head, and MLP widths | |
| attention projections | |
| ReLU MLP up and down projections | |
| SwiGLU value and gate | |
| Frobenius norm | |
| Symmetry and orbits | |
| exact scalar symmetry pair | |
| reciprocal scale factor | |
| orbit map | |
| coordinatewise orbit map | |
| depth-schedule tilt | |
| layerwise orbit scale | |
| pair-norm ratio | |
| balancing scale | |
| pair-balancing diagonal map | |
| full-state canonicalizer | |
| set and index of disjoint exact pairs | |
| Optimizer updates | |
| learning rate | |
| decoupled weight-decay coefficient | |
| Adam additive stabilizer | |
| Adam moment-estimate decay rates | |
| first-moment estimate and bias-corrected version | |
| second-raw-moment estimate and bias-corrected version | |
| pair optimizer directions | |
| block-local direction map | |
| homogeneity degree of | |
| parameter increments | |
| Diagnostics and SAGGS | |
| balance defect | |
| pair log-norm ratio | |
| radial forcing | |
| squared-direction-norm difference | |
| rebalancing interval | |
| Soft SAGGS damping | |
| damped orbit factor | |
| Experiments | |
| mean paired PPL difference | |
| paired SD | |
| paired Cohen's | |
| one-sided sign-flip -value | |
| number of paired seeds | |
J LIST OF NOTATION
Table 27 lists the main mathematical notation.
K LIMITATIONS
The experiments evaluate a selected collection of Transformer architectures, optimizers, and language-modeling datasets. The experiments do not cover every model family or every corpus, so the empirical findings should be interpreted within this experimental scope.