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

舍入位置的重要性:舍入位置对齐可稳定大语言模型的强化学习

Where Rounding Happens Matters: Rounding-Location Alignment Stabilizes LLM Reinforcement Learning

Peking University(北京大学)

Yijing Ke, Tianle Cai, Ruosong Wang

AI总结:

该研究针对大语言模型强化学习中因舍入位置差异导致的训练不稳定问题,通过对齐RoPE等三个区域的舍入位置,在保留原有推理与训练核心组件不变的情况下,稳定了BF16强化学习训练,避免了模型崩溃。

摘要:

大语言模型的强化学习常采用独立的推理与训练系统,即便权重与BF16张量完全相同,实现差异也可能使预期的在线策略更新变为离线策略,导致训练不稳定。现有解决方案需对齐整个推理与训练栈、修改全局精度或调整学习算法。本文探究在其他实现差异存在的情况下,对齐执行栈的选定部分是否可稳定BF16强化学习。我们通过在RoPE、SwiGLU、残差RMSNorm三个区域中保留选定中间结果为FP32,直至其输出BF16值,使训练侧的舍入位置与推理对齐。在四款Qwen系列模型上的实验表明,对齐全部三个区域可避免默认BF16基线下出现的训练崩溃;尽管仍存在数值差异,仅对齐RoPE路径在研究的运行中也足够有效。这些干预措施保留了推理引擎、矩阵乘法与注意力核函数以及学习目标不变。

英文摘要:

Reinforcement learning for large language models often uses separate systems for inference and training. Even with identical weights and BF16 tensors, implementation differences can make an intended on-policy update off-policy and destabilize training. Existing remedies align the entire inference and training stacks, change global precision, or modify the learning algorithm. We ask whether aligning selected parts of the execution stack can stabilize BF16 RL while other implementation differences remain. We align training-side rounding locations with inference in three regions---RoPE, SwiGLU, and residual RMSNorm---by retaining selected intermediates in FP32 until their BF16 outputs. Across four Qwen-family models, aligning all three regions prevents the collapse observed under the default BF16 baseline; RoPE-path alignment alone also suffices in the studied runs, despite remaining numerical discrepancies. The interventions keep the inference engine, matrix-multiplication and attention kernels, and learning objective unchanged.

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

↑