Executive Summary The placement of Layer Normalization (LN) in Transformer architectures has long presented a fundamental trade-off between training stability and representational capacity. SiameseNorm introduces a novel "two-stream" architecture that successfully marries the rock-solid training stability of Pre-Norm with the high representational capacity of Post-Norm. By sharing residual blocks across two parallel streams—one normalized and one unnormalized—SiameseNorm achieves state-of-the-art performance across language, vision, and diffusion models with virtually zero computational overhead.
The Normalization Tug-of-War
In Transformer design, the location of normalization layers dictates the model's training dynamics:
- Post-Norm (the original Transformer design) places normalization after the residual addition. This regulates signal magnitude, allowing every layer to contribute significantly to the final output. However, it is notoriously unstable; as models deepen, gradients tend to explode or vanish, complicating large-scale training.
- Pre-Norm (the modern standard) places normalization inside the residual branch. This creates a clean identity path for gradients, ensuring highly stable training. The drawback is that the main residual path grows unbounded. In very deep models, the contributions of later layers become "diluted" by the massive signal already present on the main path, effectively underutilizing the model's depth.
Previous attempts to hybridize these approaches within a "single-stream" architecture typically inherit Post-Norm's instability. The authors identify a structural tension: it is exceedingly difficult to maintain a stable identity-gradient path while simultaneously regulating signal magnitude in a single stream.
The SiameseNorm Architecture
To resolve this tension, the authors propose SiameseNorm, a two-stream architecture that decouples stability and capacity:
- Dual Streams: The model maintains two distinct hidden states. Stream $X$ acts like Post-Norm, being normalized after every update. Stream $Y$ acts like Pre-Norm, accumulating updates without normalization.
- Shared Residual Blocks: Both streams share the exact same Attention and MLP blocks, meaning the architecture adds almost no new parameters or FLOPs (under 0.1% theoretical increase).
- Coupled Processing: At each layer, the input to the shared block is a normalized fusion of both $X$ and $Y$. The output is then added back to both streams.
- Depth-wise Scaling: To ensure compatibility with standard training recipes, an auxiliary mechanism slightly reduces the update magnitude for the Post-Norm stream as the model deepens. This prevents the bounded stream from being overwhelmed by the growing signal in the unnormalized stream.
Empirical Validation and Key Results
The authors conducted extensive empirical validation across multiple domains, demonstrating consistent improvements:
- Language Modeling: Trained on FineWeb-Edu (100B to 350B tokens), SiameseNorm was evaluated on 400M and 1.3B dense models, as well as a 15B Mixture-of-Experts (MoE) model. In the 1.3B parameter setup, SiameseNorm achieved a perplexity of 10.43, significantly outperforming the Pre-Norm baseline (10.84).
- Sequential Reasoning: The architecture showed a massive 41% relative improvement over Pre-Norm on arithmetic tasks, reaching 39.6% accuracy compared to the 28-31% range of baseline methods. This suggests that better layer utilization directly enhances sequential reasoning capabilities.
- Vision & Diffusion: SiameseNorm improved Top-1 accuracy on Vision Transformers (DeiT-S) by 1.5% and reduced the FID score for Diffusion Transformers (DiT) by nearly 4 points, indicating substantially better image generation quality.
Key Insights
- Solving Signal Dilution: Pruning experiments (removing layers from a trained model) revealed that SiameseNorm layers remain highly "active" and essential to the final output, successfully preventing the signal dilution characteristic of Pre-Norm.
- High Learning Rate Stability: SiameseNorm remains stable even under aggressive learning rates (e.g., $2 \times 10^{-3}$) that cause standard Post-Norm and hybrid variants to diverge or suffer massive loss spikes.
- Efficiency: The empirical training speed decrease is a negligible 0.5%, making it a highly practical drop-in replacement.
Limitations and Future Directions
While highly effective, the paper's contributions are primarily empirical. The authors provide gradient analysis to motivate the design but do not offer rigorous mathematical proofs of convergence or theoretical guarantees of stability. Furthermore, SiameseNorm currently relies on the "Depth-wise Scaling" mechanism to perform optimally at very high learning rates. Future work may explore more self-regulating methods to balance the two streams without manual scaling factors, potentially paving the way for even more sophisticated multi-stream architectures.
Summary updated