Async GRPO with LoRA across HF Jobs: a bucket, a proxy, and no NCCL
By Jakub Antkiewicz
•2026-09-14T14:43:57Z
TRL Enables Distributed RL Training on HF Jobs Without NCCL
Hugging Face's Transformer Reinforcement Learning (TRL) library has introduced a significant update in version v1.14, enabling its `AsyncGRPOTrainer` to perform distributed training across separate Hugging Face Jobs using LoRA adapters. This development is notable as it provides a practical method for scaling out Reinforcement Learning (RL) workloads without relying on high-speed, direct node-to-node interconnects like NCCL. Instead, the system uses a shared cloud storage bucket for model synchronization, making distributed training more accessible on containerized platforms.
Technical Architecture: Buckets over Interconnects
The architecture separates the trainer from multiple vLLM inference replicas, each running in an independent HF Job. The key to this decoupled system is the use of a Hugging Face Storage Bucket, which is mounted as a local filesystem in every Job. Rather than transferring entire multi-gigabyte model weights after each update, the trainer only saves and synchronizes a lightweight LoRA adapter, which is typically only a few megabytes in size. This process is orchestrated by a small, essential proxy server.
- Decoupled Components: A trainer Job, two or more vLLM replica Jobs, a shared Storage Bucket, and a proxy server.
- Synchronization Method: The trainer writes new LoRA adapters to the mounted bucket; vLLM servers read them from the same path.
- Proxy Functions: Adds required authentication headers for HF Jobs and broadcasts adapter-loading commands to all vLLM replicas simultaneously to maintain state consistency.
- Efficiency: The system intelligently routes generation requests to the replica most likely to have the relevant KV prefix cached, minimizing re-computation.
This configuration provides a blueprint for leveraging standard cloud infrastructure to achieve distributed AI training. By abstracting away the need for a shared physical network fabric, it allows for more flexible and potentially cost-effective scaling of policy-gradient RL tasks. The case study demonstrated a significant performance gain, reducing a 500-step training run from over three hours to just 53 minutes, confirming the architecture's viability for production-level work.
By leveraging small, portable LoRA adapters with ubiquitous cloud storage, this architecture effectively decouples the training and inference processes in RL, offering a scalable and cost-effective alternative to monolithic, tightly-coupled distributed training systems.