AReaL让语言模型训练更快:异步生成与训练,效率提升2.77倍。
AReaL: A Large-Scale Asynchronous Reinforcement Learning System for Language Reasoning

- 异步解耦生成与训练,不再等待最长输出完成。
- 在相同GPU下比同步系统快2.77倍,数学和代码任务表现更优。
- 适合需要大规模高效训练的LLM研究者与工程师。
强化学习(RL)已成为训练大语言模型(LLMs)进行推理任务的主要范式。有效实现LLM的RL需要大规模并行,对高效训练系统提出迫切需求。现有大多数大规模LLM RL系统为同步模式,在批次设置下交替生成与训练,每批推演由同一模型生成。该方法虽稳定但存在严重系统效率问题:生成需等待批次中最长输出完成才可更新模型,导致GPU利用率低下。我们提出AReaL,一个全异步的强化学习系统,完全解耦生成与训练。在AReaL中,推演工作节点持续生成新输出,无需等待;训练工作节点在收集到一批数据后即可更新模型。AReaL还引入多项系统级优化,显著提升GPU利用率。为稳定训练,其通过平衡推演与训练工作负载控制数据过时,并采用增强过时处理的PPO变体以更好应对旧样本。在数学与代码推理基准上的大量实验表明,相较于同步系统,AReaL在相同GPU数量下实现了最高2.77倍的训练加速,且最终性能相当或更优。AReaL代码已开源:https://github.com/inclusionAI/AReaL/。
原文摘要 · Abstract (English)
Reinforcement learning (RL) has become a dominant paradigm for training large language models (LLMs), particularly for reasoning tasks. Effective RL for LLMs requires massive parallelization and poses an urgent need for efficient training systems. Most existing large-scale RL systems for LLMs are synchronous, alternating generation and training in a batch setting where rollouts in each training batch are generated by the same model. This approach stabilizes RL training but suffers from severe system-level inefficiency: generation must wait until the longest output in the batch is completed before model updates, resulting in GPU underutilization. We present AReaL, a fully asynchronous RL system that completely decouples generation from training. Rollout workers in AReaL continuously generate new outputs without waiting, while training workers update the model whenever a batch of data is collected. AReaL also incorporates a collection of system-level optimizations, leading to substantially higher GPU utilization. To stabilize RL training, AReaL balances the workload of rollout and training workers to control data staleness, and adopts a staleness-enhanced PPO variant to better handle outdated training samples. Extensive experiments on math and code reasoning benchmarks show that AReaL achieves up to 2.77$\times$ training speedup compared to synchronous systems with the same number of GPUs and matched or improved final performance. The code of AReaL is available at https://github.com/inclusionAI/AReaL/.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。