AI agents trained through reinforcement learning often use a harness, a scaffold controlling what the agent reads and what guidance it gets. Most harnesses are hand-written and fixed during training, even as the agent changes. This limits learning and requires manual tuning.
ModHarness-RL treats the harness as learnable programs. Interaction is recorded as typed blocks (reasoning, tool calls). Two programs are learned: Compression (organizes history into limited context) and Steering (adds guidance when off track). Programs are proposed, tested, and updated automatically during training.
Across three domains, the learned harness improved performance over fixed harnesses by 14 percent to 24 percent. This shows harnesses can be automatically optimized, saving effort and improving agent learning.
