Agent Harnesses Need Their eBPF · Ron Yifeng Wang and Aditya Akella, The University of Texas at Austin · InfraAI & LDOS Blog, December 1, 2026
A verifier, not the agent, decides which harness policies load
The authors begin with two approaches that failed. Giving Claude Haiku 5.5 harness tools such as compact() and set_effort() plus a live context meter cut success on five long tasks from 92% to 52%; the model rushed to submit incomplete work. Letting agents edit harness code went wrong more quietly. In one case a Haiku-written controller rewrote the harness's own token counts, so in 5 of 400 simulated sessions neither it nor the fallback compaction caught a context overflow. In one, both counted 28.4K tokens while the rendered context was about 33.6K against a 32K budget. Crash rollback, regression tests and a Sonnet reviewer all approved it. When the authors asked agents to add a $0.50 spending guard to Exo, a self-editing harness from other researchers, all seven guards passed Exo's guardian and then failed enforcement tests. Their summary of the problem: "Poorly written policies and buggy implementations hurt the human operator, not just the agent."
Their system, ext, borrows from Linux eBPF. The harness keeps the mechanisms: token counting, cost reservation, context rendering, saving full tool outputs. Agents write policies for narrow typed hooks such as compaction, tool-output shaping, effort and stop, in a loop-free Python subset that cannot touch files, the network or harness state. Before any policy loads, the Z3 solver checks it against eleven default rules and any rules the operator adds, in about 24 ms per load, and returns a counterexample when one fails. It attaches to unmodified Claude Code through native hooks and a host-side HTTP proxy.
The authors report zero rule violations across more than 550 runs. Under a $0.30 cap the agent was never told about, all six ext runs stayed within budget and five answered every question, while Exo's agents, given the budget in the prompt, overspent in both Opus trials. On a 200K-window incident audit where vanilla Claude Code with Sonnet 4.6 hit compaction thrashing and scored 0/204 twice, ext runs scored 199/204 and 204/204. In one Mastodon-style build, vanilla Opus 5.5 compacted six times in 22 tool calls and passed 0 of 150 tests; with ext it passed 147. One reusable policy took Opus from 14/27 to 22/27 solves on nine coding tasks at about the same cost. These are the authors' own figures: the code is not released yet and there is a waitlist, so none of it can be reproduced outside their lab today.
Why it matters: If your agents can tune their own harness, the hard part is keeping the budget and the evidence the operator cares about intact while they do it. This work argues for a narrow policy surface with checked rules and a safe fallback, and its examples of a reviewer, a test suite and a crash check all approving a silently broken controller are worth reading before you let an agent edit harness code.