arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2509.16591cs.CL
收藏

异质自适应策略优化:针对每个token的性质进行定制化优化

Heterogeneous Adaptive Policy Optimization: Tailoring Optimization to Every Token's Nature

Peking University Shanghai AI Laboratory(北京大学上海人工智能实验室);Beihang University(北京航空航天大学);Shanghai AI Laboratory(上海人工智能实验室);Peking University Zhongguancun Academy, 5 Beijing Key Laboratory of Software and Hardware Cooperative Artificial Intelligence Systems(北京大学中关村学院,5北京软件硬件协同人工智能系统重点实验室)

Zheng Liu, Mengjie Liu, Siwei Wen, Mengzhang Cai, Bin Cui, Conghui He, Wentao Zhang

AI总结:

本文提出HAPO算法,通过熵度量异质性指导优化,实现细粒度调节。算法包含四个核心组件,通过token级处理提升LLM在数学推理、代码和逻辑任务中的性能。

摘要:

使用熵作为异质性的度量来指导优化已成为强化学习中大语言模型的关键研究方向。然而,现有方法通常将其视为离散过滤器或事后调节器,而非核心优化驱动因素。为充分挖掘熵的潜力并实现精细调节,我们引入异质自适应策略优化(HAPO),一种token感知算法,通过整个训练过程中基于token级熵持续调整优化动态。我们的算法包含四个关键组件:(1)自适应温度采样,实时调整采样温度,促进高熵token的探索。(2)token级组平均优势估计,估计token级优势,考虑序列长度效应的同时保持非偏处理。(3)差异优势再分配,利用熵和重要性比率调整具有明确信号的token的优势。(4)非对称自适应截断,根据token级熵动态调整截断边界。通过系统研究熵,我们将token级处理嵌入到每个阶段。在多个模型上的数学推理、代码和逻辑任务的广泛实验表明,HAPO在DAPO上表现一致优越。我们的代码可在https://github.com/starriver030515/HAPO找到。

英文摘要:

Using entropy as a measure of heterogeneity to guide optimization has emerged as a crucial research direction in Reinforcement Learning for LLMs. However, existing methods typically treat it as a discrete filter or post-hoc regulator rather than a core optimization driver. To fully leverage the potential of entropy and achieve fine-grained regulation, we introduce Heterogeneous Adaptive Policy Optimization (HAPO), a token-aware algorithm that continuously adapts optimization dynamics based on token-level entropy throughout the entire training process. Our algorithm includes four key components: (1) Adaptive Temperature Sampling that adjusts sampling temperature in real time, promoting exploration at high-entropy tokens. (2) Token-Level Group Average Advantage Estimation that estimates advantages at token level, accounting for sequence-length effects while preserving non-biased treatment.(3) Differential Advantage Redistribution that leverages entropy and importance ratios to adjust advantages for tokens with clear signals. (4) Asymmetric Adaptive Clipping that adynamically adjusts clipping boundaries based on token-level entropy. Through systematic investigation of entropy, we embed token-level treatment into every stage. Extensive experiments on mathematical reasoning, code, and logic tasks across multiple models demonstrate HAPO's consistent superiority over DAPO. Our code can be found in https://github.com/starriver030515/HAPO.

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

↑