Mohaned178

Agent Handoff Protocol — AI skill for Claude Code

AI community

Agent Handoff Protocol: explicit, verifiable, measurable handoffs between AI coding agents (Claude Code, Codex CLI, Gemini CLI, OpenCode), with an evaluation engine.

How to install Agent Handoff Protocol

This entry records only its repository, not the path inside it, so there is no exact command to give. Open Mohaned178/agent-handoff-protocol and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What Agent Handoff Protocol does

Agent Handoff Protocol: explicit, verifiable, measurable handoffs between AI coding agents (Claude Code, Codex CLI, Gemini CLI, OpenCode), with an evaluation engine.

Alternatives in AI

  • Desktop Cc Gui — Multi-engine AI coding desktop client (Tauri) 4.4k ★
  • Botmux — Bridge Feishu/Lark to AI coding CLIs — Claude Code, Codex, Gemini, OpenCode… every DM, group or topic spawns i 1.2k ★
  • Claw Empire — Command Your AI Agent Empire from the CEO Desk — A local-first AI agent office simulator that orchestrates CLI 1.1k ★

README

AHP: Agent Handoff Protocol and LLM Evaluation

AHP makes handoffs between AI coding agents explicit, verifiable and measurable, and evaluates whether doing so improves real task outcomes.

Release 1 targets four coding-agent CLIs (Claude Code, Codex CLI, Gemini CLI, OpenCode), combinable in one workflow, each through a dedicated adapter. A step succeeds only when verification passes, never on an agent's own claim; every event is written to an append-only ledger so a crash never silently runs work twice; and an evaluation engine tests whether structured handoffs actually beat a single agent and a plain-text pipeline. A negative result is a legitimate outcome.

**Status: early development.** Linear multi-step workflows run end to end with the mock adapter, each step receiving a validated, versioned handoff, a run whose process stopped is recovered with `ahp recover`, and Ctrl+C cancels a run; no real coding-agent adapter exists yet.

Development

Requires Node.js 24 or newer and git. Developed on Windows; CI runs on Windows, macOS and Linux.

npm install
npm run typecheck   # tsc, no emit
npm test            # Vitest: the whole suite
npx vitest run test/run.test.ts   # one test file
npm run build       # compile to dist/
npm run schemas     # regenerate schemas/*.json after changing a protocol schema

Try it against any git repository with a commit (after `npm run build`):

node bin/ahp.mjs run workflow.ts --repo 
node bin/ahp.mjs inspect  --repo 
node bin/ahp.mjs recover  --repo                             # after the runtime died
node bin/ahp.mjs recover  --policy adopt|abort --repo    # decide an unknown attempt

`ahp run` and `ahp recover` exit 0 when the run succeeded, 1 when it failed (or ahp did), 2 on a usage error, 3 when the run stopped for a recovery decision and 130 when it was cancelled.

A workflow file (`.ts` or `.js`) default-exports a workflow definition. The package is not