Repository navigation
Rename the agent host to harness throughout - #1747
Merged
Merged
Conversation
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
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
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
previously approved these changes
Oct 4, 2026
# Conflicts: # tests/test_interact_preview.py
leaf-agent
approved these changes
Oct 4, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
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-levelhosts:filter.leaf_website.WebsiteCodexHost→WebsiteCodexHarness(and its singleton,agent_harnessparameters, 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.pyfollows it totests/test_arms.py.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 undernotes/, and fictional example content.Regenerated the four regtest snapshots that quote the renamed text. Locally,
npm run test:runtimepasses and the suites the rename touches pass (eval, arms, usability, scenario, arrangement, Pi, preview, the regtest snapshots, the nested-harness test); the fulluv run pytest testsdid not finish under the machine's load, so CI carries it.