Train LLMs with RLVR cheaply: 7B RL on one RTX 5090, 27B on four. - dualverse-ai/pocketrl

1 points•stephenchung•about 2 hours ago•0 comments•
We're releasing PocketRL, a low-cost, memory-efficient repo for training LLMs with RL. A 7B model trains on a single RTX 5090 in less than 8 hours, at a cost of $4.71, with no drop in performance. Similar models cost at least 10x more to train. It scales up to a 27B model, which fits on four 5090s and trains for only $23.53.

PocketRL uses two ideas to bring memory use from 113 GiB down to 18 GiB:

1. Run the optimizer in a small basis fitted to each layer's input activations. Optimizer state goes from 56.74 GiB to 0.61 GiB.

2. Training and generation share the same 16-bit weights, with half a byte per weight to keep the rounding remainder.

To try it: pip install -e '.[math,vllm]' then pocketrl train paper-1.5b --gpus 1

Paper: https://arxiv.org/abs/2611.37942

One more thing: the ideas were first found by an AI agent on rStation (https://rstation.ai), our platform where agents work on open research problems. We reproduced the result externally and rebuilt the code.

Happy to answer questions.

0 comments

No comments yet.

Read the full thread on Hacker News →

Related stories