SiameseNorm: Breaking the Barrier to Reconciling Pre/Post-Norm

Tianyu Li, Dongchen Han, Zixuan Cao, Haofeng Huang, Mengyu Zhou +5 more
2/8/2026
cs.LGcs.AIcs.CL

Official code: Qwen-Applications/SiameseNorm (14 stars, last commit 2026-02-27).

Abstract

Modern Transformers predominantly adopt the Pre-Norm paradigm for its optimization stability, foregoing the superior potential of the unstable Post-Norm architecture. Prior attempts to combine their strengths typically lead to a stability-performance trade-off. We attribute this phenomenon to a structural incompatibility within a single-stream design: Any application of the Post-Norm operation inevitably obstructs the clean identity gradient preserved by Pre-Norm. To fundamentally reconcile these paradigms, we propose SiameseNorm, a two-stream architecture that couples Pre-Norm-like and Post-Norm-like streams with shared parameters. This design decouples the optimization dynamics of the two streams, retaining the distinct characteristics of both Pre-Norm and Post-Norm by enabling all residual blocks to receive combined gradients inherited from both paradigms, where one stream secures stability while the other enhances expressivity. Extensive pre-training experiments on 1.3B-parameter models demonstrate that SiameseNorm exhibits exceptional optimization robustness and consistently outperforms strong baselines. Code is available at https://github.com/Qwen-Applications/SiameseNorm.

View on arXivView PDF

Code Implementations(1)

Code of the research paper "SiameseNorm: Breaking the Barrier to Reconciling Pre/Post-Norm"

140C, C++Feb 8, 20267 months ago

Similar Papers

Cite this paper

@article{li2026siamesenorm,
  title  = {SiameseNorm: Breaking the Barrier to Reconciling Pre/Post-Norm},
  author = {Tianyu Li and Dongchen Han and Zixuan Cao and Haofeng Huang and Mengyu Zhou and Ming Chen and Erchao Zhao and Xiaoxi Jiang and Guanjun Jiang and Gao Huang},
  year   = {2026},
  eprint = {2602.08064},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2602.08064v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2602.08064.svg)](https://codeofpaper.com/paper/2602.08064)

Discussion