/agent-toolkit-complete:swarm-handofffrom agent-toolkit-complete
Creates artifact and commit file handoffs between swarm roles using Git worktrees, branches, and the Agent Toolkit CLI. Useful when a swarm needs to move work from implementer to reviewer to integrator.
Ships in agent-toolkit-complete. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Create correct file handoffs between swarm roles so work moves via Git + filesystem, not chat copy. Every writer gets an isolated worktree/branch; the filesystem state.json is authoritative.
from -> to).swarm-observer diagnoses a stuck active handoff..agent-toolkit/swarm/runs/<run-id>/state.json.artifacts/). For commit type, commit/branch must exist locally.from and to roles from the recipe (pair: implementer→reviewer; team: implementer→reviewer→integrator).# Artifact — by convention in artifacts/
mkdir -p artifacts
cat > artifacts/<name>.md <<'EOF'
# Context for <to>
- What was implemented and why
- Files changed and how to verify
- Risks / open questions
EOF
git add artifacts/<name>.md # optional, but keeps history
# Commit handoff — use when work is already committed
git log --oneline -n 5
git branch --show-current
# Artifact handoff — triggers auto-provision of <to>'s worktree/tab + agent
agent-toolkit swarm handoff create --type artifact --from implementer --to reviewer --artifact artifacts/cna-ideas.md --run-id <run-id>
# Commit handoff
agent-toolkit swarm handoff create --type commit --from reviewer --to integrator --commit <sha> --branch <branch> --run-id <run-id>
# Auto behavior:
# - If an active handoff exists where to == from_role, it auto-completes (auto:true) and trace records handoff_completed.
# - Next role gets eager window (Waiting for handoff: <from> -> <to>) replaced by real prompt: export AGENT_TOOLKIT_SWARM_RUN_ID/RUN_DIR/REPO SWARMFORGE_ROLE + cd worktree && exec <runner> "$(cat prompt)"
Verify:
agent-toolkit swarm handoffs --run-id <run-id> --json | jq '.[] | {id,from,to,status,artifact,commit,auto}'
agent-toolkit swarm status --run-id <run-id> --json | jq '.trace | last'
# Expect: handoff create logs, worktree path, and runner exec with $(cat prompt)
git worktree add <path> <branch>). The prompt is export AGENT_TOOLKIT_SWARM_RUN_ID/... && cd <worktree> && <runner>.store.py + config.py resolve repo root via git rev-parse --git-common-dir (handles .git file in worktrees). Do not bypass with manual state.json edits.pane run / tmux exec uses _user_shell() ($SHELL//usr/bin/zsh fallback) as <shell> -lc.# After reviewer/integrator approves
agent-toolkit swarm promote --run-id <run-id> --handoff-id <id>
# or for the latest completed artifact:
agent-toolkit swarm promote --run-id <run-id>
# Then delegate push/PR
# (use github-cli-workflow skill for branch push + draft PR)
Same run can be reused for sequential requests — just create a new implementer -> reviewer artifact handoff on the same run-id. Eager windows stay; only the chain retriggers. Create a new run only for isolated branching.
echo — use the file path in --artifact.state.json directly; always via handoff create / task complete.commit type, always pass --commit and --branch; the store validates validate_commit_exists.artifacts/ in Git so herdr/tmux runners can read it from their worktree.| Need | Skill |
|---|---|
| Launch the swarm before handoffs | swarm |
| Diagnose stuck or orphaned handoffs | swarm-observer |
| Verify code before promotion | code-reviewer, security-reviewer, tdd-guide |
| Push branch and create PR | github-cli-workflow |
| Generate docs from handoff output | output-handshake, docs-generator |
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub ulises-jeremias/agent-toolkit --plugin agent-toolkit-complete118 skills in this plugin
/adrWHAT — Create and maintain Architecture Decision Records (ADRs) per the process. Covers when to write an ADR, required sections, review, and linking to epics/PRs. English for cross-team artifacts unless the user asks otherwise./agreementWHAT - Capture explicit agreements, terms, parties involved, dates, validity, and linked work items using the Agreement Document structure./architecture-diagramWHAT — Create architecture diagrams of real systems as one self-contained HTML page. Default mode is an interactive, Lucidchart-style explainer built from a JSON model: nested containers (cloud, cluster, namespaces), service boxes with brand icons, numbered flows the reader selects one at a time (user access, operator access over a VPN or tailnet, CI/GitOps deploy, secrets, observability, data), hover cards, an inventory and a "not there yet" list, validated by a build script. Poster mode keeps the static dark HTML+SVG template with a PNG/PDF export toolbar. Also exports Mermaid, D2, draw.io, SVG or PNG. Use for system, infrastructure, cloud, deployment, network, access-flow or security topology diagrams delivered as a shareable visual artifact rather than in-repo text.Other plugins' skills for the same job