Skip to content

Rename the agent host to harness throughout - #1747

Merged
max-sixty merged 5 commits into
mainfrom
harness-rename
Oct 4, 2026
Merged

max-sixty merged 5 commits into
mainfrom
harness-rename

Conversation

@max-sixty

@max-sixty max-sixty commented Oct 4, 2026 •

Copy link
Copy Markdown
Owner

Leaf modeled each agent program (Claude Code, Codex, Pi, leaf.page's embedded App Server driver) as a Harness, but named the same concept "host" everywhere else: the module (leaf/host.py), the per-agent references (host-claude-code.md, …), the eval flag (--host cc|codex), and the prose. This cuts every agent-sense "host" over to "harness", so the concept has one name.

Renamed:

  • leaf/host.py → leaf/harness.py; references/host-{claude-code,codex,codex-app-server,pi}.md → harness-*.md, with SKILL.md's routing and the eval cases that check those reads.
  • Harness.host_pid / host_runs → process_pid / process_runs (harness.harness_pid() would repeat itself).
  • leaf-dev eval --host → --harness, with the eval metadata key, HOSTS, and the case-level hosts: filter.
  • leaf_website.WebsiteCodexHost → WebsiteCodexHarness (and its singleton, agent_harness parameters, and the hosted turn's back-reference). The instructions the hosted agent reads now say "this harness".
  • leaf_dev.harness → leaf_dev.arms, so "harness" names only the agent harness. The module's own docstring already opened with "Arms"; tests/test_harness.py follows it to tests/test_arms.py.
  • Prose in the shipped skill, references, contracts, AGENTS.md, notes, docs and tests, and the test names built on it.

Left as "host", since each names a different concept: the network host (--host NAME, page_access, host_key, Host: headers), the machine (the host's browser, Codex login, uv cache), static and HTTP hosts serving revisions, DOM shadow hosts and :host, MCP hosts, "hosted" leaf.page agents, recorded eval results under notes/, and fictional example content.

Regenerated the four regtest snapshots that quote the renamed text. Locally, npm run test:runtime passes and the suites the rename touches pass (eval, arms, usability, scenario, arrangement, Pi, preview, the regtest snapshots, the nested-harness test); the full uv run pytest tests did not finish under the machine's load, so CI carries it.

This was written by Claude Code on behalf of max-sixty

Leaf modeled each agent program as a `Harness` but called the same concept
"host" everywhere else. Every agent-sense "host" is now "harness":

- `leaf/host.py` is `leaf/harness.py`, and the per-agent references are
  `references/harness-{claude-code,codex,codex-app-server}.md`.
- `Harness.host_pid`/`host_runs` are `process_pid`/`process_runs`.
- `leaf-dev eval --host` is `--harness`, with the eval metadata key and the
  case-level filter.
- `leaf_website.WebsiteCodexHost` is `WebsiteCodexHarness`, and the hosted
  agent's instructions say "this harness".
- `leaf_dev.harness` is `leaf_dev.arms`, so "harness" names only the agent
  harness; `tests/test_harness.py` follows it to `tests/test_arms.py`.

The network host (`--host NAME`, `host_key`), the machine, static and HTTP
hosts, DOM shadow hosts, MCP hosts and "hosted" leaf.page agents keep "host".

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
leaf-agent
leaf-agent previously approved these changes Oct 4, 2026
# Conflicts:
#	.claude/skills/developing-leaf/SKILL.md
#	AGENTS.md
#	dev/leaf_dev/arrangement_eval.py
#	dev/leaf_dev/delivery_eval.py
#	dev/leaf_dev/eval.py
#	dev/leaf_dev/eval_codex.py
#	dev/leaf_dev/promptfoo.py
#	dev/leaf_dev/reader_eval.py
#	dev/leaf_dev/scenario_provider.py
#	dev/leaf_dev/usability_eval.py
#	evals/README.md
#	notes/agent-usability-evals.md
#	skills/leaf/SKILL.md
#	skills/leaf/scripts/leaf/harness.py
#	skills/leaf/scripts/leaf/session-lifetime.md
#	skills/leaf/scripts/leaf/session.py
#	tests/test_eval.py
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
leaf-agent
leaf-agent previously approved these changes Oct 4, 2026
# Conflicts:
#	dev/leaf_dev/arms.py
#	dev/leaf_dev/arrangement_eval.py
#	dev/leaf_dev/eval.py
#	dev/leaf_dev/reader_eval.py
#	dev/leaf_dev/scenario_provider.py
#	evals/README.md
#	tests/test_arrangement_eval.py
#	tests/test_eval.py
leaf-agent
leaf-agent previously approved these changes Oct 4, 2026
# Conflicts:
#	tests/test_interact_preview.py
@max-sixty
max-sixty merged commit 09fda7d into main Oct 4, 2026
4 checks passed
@max-sixty
max-sixty deleted the harness-rename branch October 4, 2026 22:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants