English

ReaL: Efficient RLHF Training of Large Language Models with Parameter Reallocation

Distributed, Parallel, and Cluster Computing 2025-04-25 v2 Artificial Intelligence Computation and Language Machine Learning

Abstract

Reinforcement Learning from Human Feedback (RLHF) is a pivotal technique for empowering large language model (LLM) applications. Compared with the supervised training process of LLMs, the RLHF training process is much more sophisticated, requiring a diverse range of computation workloads with intricate dependencies between multiple LLM instances. Therefore, simply adopting the fixed parallelization strategies from supervised training for LLMs can be insufficient for RLHF and result in low training efficiency. To overcome this limitation, we propose a novel technique named parameter ReaLlocation, which dynamically adapts the parallelization strategies for different workloads during training by redistributing LLM parameters across the training cluster. Building upon this idea, we introduce ReaL, a pioneering system for efficient RLHF training. ReaL introduces the concept of an execution plan, which defines a fine-grained resource allocation and parallelization strategy particularly designed for RLHF training. Based on this concept, ReaL employs a tailored search algorithm with a lightweight run-time estimator to automatically discover an efficient execution plan for an instance of RLHF experiment. Subsequently, the runtime engine deploys the selected plan by effectively parallelizing computations and redistributing parameters. We evaluate ReaL on the LLaMA models with up to 70 billion parameters and 128 GPUs. The experimental results demonstrate that ReaL achieves speedups of up to 3.58×3.58\times compared to baseline methods. Furthermore, the execution plans generated by ReaL exhibit an average of 81%81\% performance improvement over heuristic approaches based on Megatron-LM in the long-context scenario. The source code of ReaL is publicly available at https://github.com/openpsi-project/ReaLHF .

Keywords

Cite

@article{arxiv.2406.14088,
  title  = {ReaL: Efficient RLHF Training of Large Language Models with Parameter Reallocation},
  author = {Zhiyu Mei and Wei Fu and Kaiwei Li and Guangju Wang and Huanchen Zhang and Yi Wu},
  journal= {arXiv preprint arXiv:2406.14088},
  year   = {2025}
}

Comments

11 pages (20 pages with references and the appendix), 17 figures. Accepted by MLSys 25

R2 v1 2026-06-28T17:13:05.208Z