arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2601.09719cs.CLcs.AI
收藏

有界双曲正切:大型语言模型中预层归一化的稳定高效替代方案

Bounded Hyperbolic Tangent: A Stable and Efficient Alternative to Pre-Layer Normalization in Large Language Models

Yonsei University(延世大学);Upstage AI

Hoyoon Byun, Youngjun Choi, Taero Kim, Sungrae Park, Kyungwoo Song

AI总结:

提出BHyT,通过有界双曲正切和数据驱动的输入约束替代Pre-LN,在保持稳定性的同时提升训练和推理效率。

摘要:

预层归一化(Pre-LN)是大型语言模型(LLM)的事实标准,对于稳定预训练和有效迁移学习至关重要。然而,Pre-LN会带来重复的统计计算开销,并且仍然容易受到深度诅咒的影响,即随着层数增加,隐藏状态幅度和方差增大,破坏训练稳定性。面向效率的无归一化方法(如Dynamic Tanh (DyT))提高了吞吐量,但在深度下仍然脆弱。为了同时解决稳定性和效率问题,我们提出了有界双曲正切(BHyT),作为Pre-LN的直接替代方案。BHyT将tanh非线性与显式的、数据驱动的输入边界相结合,使激活值保持在非饱和范围内。它防止了激活幅度和方差随深度增长,并提供了理论稳定性保证。在效率方面,BHyT每个块仅计算一次精确统计量,并用轻量级方差近似替代第二次归一化。实验表明,BHyT在预训练期间表现出更好的稳定性和效率,与RMSNorm相比,平均训练速度提升1.6%,平均token生成吞吐量提升1.77%,同时在语言理解和推理基准上保持强大的预训练-only和SFT后性能。代码见:https://github.com/MLAI-Yonsei/BHyT

英文摘要:

Pre-Layer Normalization (Pre-LN) is the de facto choice for large language models (LLMs) and is crucial for stable pretraining and effective transfer learning. However, Pre-LN incurs repeated statistical-computation overhead and remains vulnerable to the curse of depth, where hidden-state magnitudes and variances grow as the number of layers increases, destabilizing training. Efficiency-oriented normalization-free methods such as Dynamic Tanh (DyT) improve throughput but remain fragile at depth. To jointly address stability and efficiency, we propose Bounded Hyperbolic Tanh (BHyT), a drop-in replacement for Pre-LN. BHyT combines a tanh nonlinearity with explicit, data-driven input bounding to keep activations within a non-saturating range. It prevents depth-wise growth in activation magnitude and variance and provides a theoretical stability guarantee. For efficiency, BHyT computes exact statistics once per block and replaces a second normalization with a lightweight variance approximation. Empirically, BHyT demonstrates improved stability and efficiency during pretraining, achieving an average of 1.6\% faster training and an average of 1.77\% higher token generation throughput compared to RMSNorm, while maintaining strong pretraining-only and post-SFT performance across language understanding and reasoning benchmarks\footnote{Code is available at: https://github.com/MLAI-Yonsei/BHyT}.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑