Harness Scaling for Generalizable Agentic Reinforcement Learning
Organizations: Gaoling School of Artificial Intelligence, Renmin University of China · IQuest Research · Beihang University
Abstract
Agent harnesses have become a central component of modern agentic systems, shaping how models use tools, manage context, and coordinate long-horizon interaction. Realizing the benefits of these harnesses depends on how effectively the underlying model can make use of them, motivating reinforcement learning directly through the harness. While recent efforts have explored harness diversification to reduce specialization to particular execution settings, how to systematically construct and organize harness diversity for cross-harness generalization remains insufficiently understood. This work studies Harness Scaling as a distinct scaling dimension for agentic RL, focusing on structured variation in how policies execute and interact with the same underlying task and environment. Concretely, we construct a factorized harness space, select a compact training subset with balanced factorial coverage, and organize cross-harness training through locality-aware task assignment. Across multiple benchmarks, model scales, and RL algorithms, Harness Scaling consistently improves generalization to unseen harness combinations. Moreover, policies trained through structured white-box harness variation transfer effectively to unseen external black-box harnesses, outperforming policies trained through a single complex black-box harness. These results establish harness diversity as a meaningful scaling dimension for agentic RL and highlight the importance of how this diversity is organized for cross-harness generalization.
Figures & tables
| Method | Harness | ClawGym-Bench | JobBench-Easy | PinchBench | Avg. | |||
| In-Space | Claude Code | In-Space | Claude Code | In-Space | Claude Code | |||
| Qwen3-4B-Instruct | ||||||||
| Base | – | 18.08 | 33.90 | 7.16 | 6.78 | 32.69 | 32.74 | 21.89 |
| GRPO | Single | 37.33 | 38.96 | 10.24 | 5.79 | 45.60 | 40.95 | 29.81 |
| Scaling | 52.78 | 45.37 | 13.55 | 14.83 | 56.24 | 51.47 | 39.04 | |
| PPO | Single | 43.78 | 40.75 | 12.63 | 9.68 | 48.86 | 47.74 | 33.91 |
| Method | ClawGym-Bench | JobBench-Easy | PinchBench | Avg. |
| Qwen3-4B-Instruct | ||||
| Black-Box SFT | 44.48 | 11.10 | 49.66 | 35.08 |
| Black-Box RL | 44.10 | 9.42 | 46.61 | 33.38 |
| Harness Scaling | 45.37 | 14.83 | 51.47 | 37.22 |
| Qwen3-30B-A3B-Instruct | ||||
| Black-Box SFT | 49.55 | 13.16 | 51.52 | 38.08 |
| Setting | ClawGym-Bench | PinchBench |
| Random-18 | 47.90 / 42.78 | 51.28 / 48.74 |
| Random Assign. | 50.46 / 43.17 | 53.20 / 50.23 |
| Ours | 52.78 / 45.37 | 56.24 / 51.47 |
| Base Harness | In-Space | Claude Code | |
| Single | 59.82 | 48.12 | 46.02 |
| Scaling | 59.63 | 58.60 | 49.62 |
Appendix figures & tables7 assets
Supplementary material from the paper’s appendix.
Appendix
| Dim. | Aspect | Base | Variant I | Variant II |
| System prompt | Direct system instruction specifying the agent role and execution rules. | The same requirements are embedded in a simulated product context, with additional platform and UI descriptions. | The requirements are reframed through a narrative and role-based setting. | |
| Tool interface | Original tool names and schemas, such as execute_bash and file_editor , without distractors. | Functional tools are exposed through semantically related aliases, together with additional non-functional distractor tools. | Functional tools are exposed through opaque identifiers and augmented with distractor tools, largely removing lexical cues to tool functionality. | |
| Observation | Raw tool outputs without additional prefixes or suffixes. | Outputs are augmented with simulated infrastructure metadata, including pod names, namespaces, and scheduling information. | Outputs are augmented with structured XML-style metadata, including tool name, exit code, process ID, duration, and execution node. | |
| Context management | The complete interaction history remains available in the active context. | LLM-based compaction periodically summarizes earlier history while retaining the five most recent turns in context. | A more aggressive compaction policy retains the three most recent turns, with summarized history externalized to an auxiliary file. | |
| Workflow | Standard free-form execution without additional procedural constraints. | A plan-first workflow requires explicit planning before task execution. | Planning is combined with periodic progress verification every three steps. |
| S0T0O0C0W0 | S0T1O1C1W1 | S0T2O2C2W2 |
| S1T0O0C1W1 | S1T1O1C2W2 | S1T2O2C0W0 |
| S2T0O1C0W2 | S2T1O2C1W0 | S2T2O0C2W1 |
| S0T0O2C2W1 | S0T1O0C0W2 | S0T2O1C1W0 |
| S1T0O1C2W0 | S1T1O2C0W1 | S1T2O0C1W2 |
| S2T0O2C1W2 | S2T1O0C2W0 | S2T2O1C0W1 |
| Parameter | 4B GRPO | 4B PPO | 30B-A3B GRPO | 30B-A3B PPO |
| Prompt batch size | 16 | 128 | 16 | 128 |
| Rollouts per prompt | 8 | 1 | 8 | 1 |
| Actor mini-batch size | 16 | 128 | 16 | 128 |
| Actor learning rate | ||||
| Max. prompt length | 8K | 8K | 4K | 4K |
| Max. response length | 32K | 32K | 60K | 60K |
| S0T2O1C1W2 | S2T1O1C2W0 | S0T1O0C2W2 |
| S2T2O0C0W1 | S0T1O2C0W1 | S1T0O0C2W1 |
| S0T0O0C1W2 | S0T0O1C0W1 | S0T2O2C2W0 |
| S1T0O1C1W0 | S1T0O2C2W2 | S1T1O0C0W0 |
| S1T2O1C0W2 | S1T2O2C1W1 | S2T0O2C0W0 |
| S2T1O1C1W2 | S2T1O2C2W1 | S2T2O0C1W0 |
| Method | ClawGym-Bench | JobBench-Easy | PinchBench | Avg. |
| Qwen3-4B-Instruct | ||||
| Single-Harness RL | 43.18 | 7.67 | 45.20 | 32.02 |
| Harness Scaling | 46.84 | 11.25 | 50.11 | 36.07 |
| Qwen3-30B-A3B-Instruct | ||||
| Single-Harness RL | 45.31 | 11.90 | 52.78 | 36.66 |
| Harness Scaling | 50.16 | 14.81 | 58.62 | 41.20 |
| Setting | ClawGym-Bench | PinchBench |
| Single-Harness RL | 37.33 / 38.96 | 45.60 / 40.95 |
| Harness Scaling, | 48.21 / 43.17 | 54.23 / 49.26 |
| Repeat-2, Same Anchor | 49.76 / 43.60 | 50.34 / 48.64 |
| Harness Scaling, | 52.78 / 45.37 | 56.24 / 51.47 |
| Harness Scaling, | 49.56 / 41.99 | 53.90 / 50.04 |
| Setting | Harness | In-Space | Claude Code |
| Single-Harness RL | 31.06 | 28.57 | |
| Single-Harness RL | 35.79 | 36.11 | |
| Single-Harness RL | 33.52 | 33.11 | |
| Single-Harness RL | 35.15 | 32.72 | |
| Harness Scaling | 40.86 | 37.22 |
Agentic RL
Agentic reinforcement learning trains AI agents to plan, use tools, and adapt through feedback from multi-step interactions.
See all 228 papers