R495 · Agent principles and patterns › Workflows over agents

The harness that decides least: a shell, a memory file and a meter

Read the original

harness-design, context-management, benchmarks, cost, agent-autonomy

A Microsoft paper argues that the presets inside mainstream agent harnesses — prescribed prompts, wrapped tool suites, fixed command timeouts, threshold compaction — are decisions made before the model has seen the task, and that for frontier models those decisions now cost more than they buy. The harness it proposes, Freehand, replaces all of them with three primitives and reports better accuracy, roughly half the cost and the fastest average runtime across eleven model–benchmark settings. The same design loses to first-party harnesses on weaker models, by a similar margin, which is the finding worth designing against.

Source: Freehand: The Bitter Lesson Comes to Agent Harnesses, arXiv:2612.02442v1, 1 December 2026; code at github.com/microsoft/FreeHand. 31 pages, 7 figures, 15 tables.

The architecture, such as it is

Freehand adds no new component to the ReAct-style observe–reason–act loop. It changes who decides inside it, and gives the model the levers.

A shell, with time under the model's control. Instead of a vocabulary of wrapped tools, the model gets one general execution primitive in a language it already writes fluently, and sets the timeout of every command itself. It can build the abstraction a task needs, and it can wait for a long computation instead of polling it.

Memory as a file. The conversation history lives in the environment as an editable file in the provider's native message format. Curating context becomes one more shell action: prune a stale log, condense a region, re-insert a cropped screenshot. There is no compactor, no memory interface and no threshold.

A meter instead of rules. After every turn the harness reports context size, tokens, cost and elapsed time — where the model stands, never what to do about it. The prompt describes how the runtime works and prescribes no workflow.

One mechanism thus replaces file tools, image viewers, compactors, memory interfaces and GUI toolkits, and the same harness runs across terminal, scientific, knowledge-work, GUI and workflow tasks with no domain-specific tooling.

What the numbers say

Two frontier models (GPT-6-astra, Claude Opus 5.5) across five benchmarks, plus Gemini 4 Carbon on one — eleven settings, all at high reasoning effort. Terminal-Bench 4 (63 systems-security tasks), Terminal-Bench Science (70 scientific-computing), Agents' Last Exam (105 research-engineering), OSWorld 2.1 (108 Ubuntu GUI), AutomationBench (600 enterprise workflow). Baselines pinned to their latest defaults in identical containers with official verifiers: each model's own first-party harness (Codex, Claude Code, Gemini CLI), plus OpenCode, Pi, DeepSeek Harness, and a bash-only evaluation harness that still fixes its workflow and timeouts.

The reversal is the real claim. On three lower-tier models from three families, each first-party harness beats Freehand by 5.1–6.7 points: Codex by 5.7 on GPT-6 Sol (34.9 against 29.2), Claude Code by 6.7 on Claude Sonnet 5.5 (41.6 against 34.9), DeepSeek Harness by 5.1 on DeepSeek V4.1 Flash (28.9 against 23.8). The same DeepSeek Harness build that helps its own weak model by 5.1 points trails Freehand by 6.0 and 4.4 points on the two frontier models — so the flip tracks model capability, not harness quality. Presets are a crutch, then a cage.

Where the advantage actually comes from

Request-level logs separate three effects, and they are not the ones the framing suggests.

  1. Programmatic execution. Given bash, frontier models build probes, parsers and verification pipelines sized to the problem: 85.1% of calls on the research-engineering benchmark run multi-stage pipelines or bespoke scripts, against 51.5% for the first-party baseline.

  2. No polling, no reminders. The baseline averages 11.6 pseudo-terminal polls per task where Freehand has none; another injects 38–199 runtime reminders per task, roughly doubling model turns at the same command count.

  3. Horizon-adaptive curation. Context editing is rare on short tasks (0.2%), common on multi-hour scientific work (58.6–64.3%) and near-universal on GUI tasks (77.8–91.7%) — with no prompt rule about when to prune. On one long run, cumulative input falls from 24.54M to 8.92M tokens.

The ablation deserves more weight than the headline. Replacing model-side curation with 90%-threshold auto-compaction leaves accuracy statistically unchanged (67.7 ± 1.0 against 67.5 ± 0.4; 56.8 ± 2.1 against 57.1 ± 3.0) and only raises cost, by 19% and 7%. Self-managed memory is a cost mechanism. The accuracy comes from the shell and from the absence of injected machinery.

Tradeoffs and failure modes

Review checklist

Connections

See R495 on the knowledge map

Part of the Research notes on nowucca.com. Figures and claims are the source's own unless the summary says otherwise.