Coming from Claude Code
The first agent-harness-adapter install in a repository with a Claude Code
setup offers to move it into the standard places, where every agent can use
it. Claude Code keeps working: CLAUDE.md gets the line @AGENTS.md, skills
and subagents are copied back into .claude/, and its settings get one entry
per event that runs your hooks from .agents/hooks.json.
agent-harness-adapter install # asks (answer no to leave it)agent-harness-adapter install --migrate # moves without askingWithout a terminal (in CI, or from a script) it never asks: nothing moves,
and the moves it would make are listed with a note. Run install --migrate
at any time to move what is still in Claude Code’s places.
What moves
Section titled “What moves”| From | To | Claude Code then gets |
|---|---|---|
CLAUDE.md’s own text |
AGENTS.md (under ## From CLAUDE.md when AGENTS.md already has text) |
@AGENTS.md in CLAUDE.md |
.claude/skills/<name> |
.agents/skills/<name> |
a copy in .claude/skills |
hooks in .claude/settings.json |
.agents/hooks.json |
one entry per event that runs them (Hooks) |
.claude/agents/<name>.md |
.agents/agents/<name>.md |
a copy in .claude/agents |
The hooks that move are command hooks on the seven events the adapter knows
(SessionStart, SessionEnd, UserPromptSubmit, PreToolUse,
PostToolUse, Stop, PreCompact).
What stays
Section titled “What stays”- Text between a tool’s markers in
CLAUDE.md(<!-- mytool:harness -->…). - Hooks on other events, hooks of another type than
command, and hooks that already runagent-harness-adapter. - Permissions, slash commands (
.claude/commands),.claude/settings.local.jsonand every other setting. They have no standard place yet, so keep them in.claude/. .mcp.json: it is already the standard place.
Each is listed as not migrated: … before anything moves.
Safety
Section titled “Safety”- A file already in the standard place with the same content is left in both
places. One with different content stops the migration, naming both: the
first install notes it and installs without migrating;
--migraterefuses until you merge them. - At project scope, files with changes git has not committed stop the
migration (
--forcemoves them anyway), sogit diffshows exactly what moved. - At user scope (
--scope user), it moves~/.claude/CLAUDE.md,~/.claude/skills,~/.claude/settings.json’s hooks and~/.claude/agentsinto~/.agents/, after backing them up to~/.agents/backup-<time>/.
After migrating
Section titled “After migrating”uninstall takes out only what the adapter wrote: the @AGENTS.md line,
the copies and the hook entries. The moved text, skills, hooks and subagents
stay in AGENTS.md and .agents/.
Undo it
Section titled “Undo it”At project scope, git restore . brings back the files that moved; then
delete the new, untracked files that git status lists. At user scope, copy
the backup back.