{"by":"Danau5tin","descendants":12,"id":44721791,"kids":[44722616,44723120,44722618,44722354,44729954,44722998,44722672,44722509,44734078,44722970,44721792],"score":125,"text":"After training calculator agent via RL, I really wanted to go bigger! So I built RL infrastructure for training long-horizon terminal&#x2F;coding agents that scales from 2x A100s to 32x H100s (~$1M worth of compute!) Without any training, my 32B agent hit #19 on Terminal-Bench leaderboard, beating Stanford&#x27;s Terminus-Qwen3-235B-A22! With training... well, too expensive, but I bet the results would be good!<p>*What I did*:<p>- Created a Claude Code-inspired agent (system msg + tools)<p>- Built Docker-isolated GRPO training where each rollout gets its own container<p>- Developed a multi-agent synthetic data pipeline to generate &amp; validate training data with Opus-4<p>- Implemented a hybrid reward signal of unit test verifiers &amp; a behavioural LLM judge.<p>*Key results*:<p>- My untrained Qwen3-32B agent achieved 13.75% on Terminal-Bench (#19, beats Stanford&#x27;s Qwen3-235B MoE)<p>- I tested training to work stably on 32x H100s distributed across 4 bare metal nodes<p>- I created a mini-eval framework for LLM-judge performance. Sonnet-4 won.<p>- ~£30-50k needed for full training run of 1000 epochs (I could only afford testing )<p>*Technical details*:<p>- The synthetic dataset ranges from easy to extremely hard tasks. An example hard task&#x27;s prompt:<p>&quot;I found this mystery program at `&#x2F;app&#x2F;program` and I&#x27;m completely stumped. It&#x27;s a stripped binary, so I have no idea what it does or how to run it properly. The program seems to expect some specific input and then produces an output, but I can&#x27;t figure out what kind of input it needs. Could you help me figure out what this program requires?&quot;<p>- Simple config presets allow training to run on multiple hardware setups with minimal effort.<p>- GRPO used with 16 rollouts per task, up to 32k tokens per rollout.<p>- Agent uses XML&#x2F;YAML format to structure tool calls<p>*More details*:<p>My Github repos open source it all (agent, data, code) and has way more technical details if you are interested!:<p>-  Terminal Agent RL repo<p>-  Multi-agent synthetic data pipeline repo<p>I thought I would share this because I believe long-horizon RL is going to change everybody&#x27;s lives, and so I feel it is important (and super fun!) for us all to share knowledge around this area, and also have enjoy exploring what is possible.<p>Thanks for reading!<p>Dan<p>(Built using rLLM RL framework which was brilliant to work with, and evaluated and inspired by the great Terminal Bench benchmark)","time":1753787523,"title":"Show HN: Terminal-Bench-RL: Training long-horizon terminal agents with RL","type":"story","url":"https://github.com/Danau5tin/terminal-bench-rl"}