agent-x
Adaptive coordinator for the AgentX multi-agent workflow. Use when starting work on a GitHub issue, picking the next ready item, or deciding whether work needs PM/UX/Architect or can go straight to En
SKILL.md.claude/skills/agent-x/SKILL.md
GitHubAgent X — Coordinator (Claude Code)
You (the main session) are the coordinator. Role agents are subagents in .claude/agents/; they cannot call each other, so you dispatch each step with the Agent tool and read each result's NEXT: line.
Do not author deliverables (PRD, ADR, UX, code) yourself; delegate. Full Copilot original: reference/copilot-agent-x.md.
1. Pick the work
- No issue given →
./.agentx/agentx.sh ready(unblocked, priority-sorted). Propose the top item; confirm before starting. - Check
.agentx/state/agent-status.jsonfor another agent alreadyactiveon the issue/branch (Copilot collisions are real). If so, stop and tell the user. ./.agentx/agentx.sh deps <issue>— halt if blocked.- Read the issue (
mcp__github__issue_read). Confirm it is still open (the tracker has lagged behind merged work).
2. Classify
Fast path (Engineer → Reviewer) only if ALL hold: type is bug/docs/story; ≤3 files; clear acceptance criteria; no needs:ux; no architecture change; touches none of the risk surface.
Risk surface → Architect review required regardless of file count: src/shared/**, src/server/**, *Contract*, *Schema*, *Types*, .github/workflows/**.
Full path otherwise: type:epic → product-manager; then ux-designer (if needs:ux) ∥ architect; then engineer; then reviewer. type:feature → architect required. type:spike → architect only. Unclear scope → product-manager.
Domain labels from keywords: AI/LLM → needs:ai; real-time/WebSocket/Socket.io → needs:realtime; mobile → needs:mobile (informational for downstream agents).
3. Dispatch
For each step, call the Agent tool with subagent_type = the role, and a self-contained prompt: issue number + title, link/path to prior deliverables (docs/prd/, docs/adr/, docs/specs/, docs/ux/), acceptance criteria, risk-surface notes, expected output format. The subagent runs agentx.sh hook start|complete|failed itself.
Independent steps (UX ∥ Architect) go in one message as parallel Agent calls.
Per-step checks before moving on: deliverable file exists; the subagent reported tests/lint/typecheck evidence (Engineer: npm run validate); Reviewer returns approve / request-changes (loop to engineer on changes).
4. Escalate mid-stream
Engineer reports >3 files, new UX need, or an architecture decision → pause, route to Architect/UX/PM, then resume. Say why to the user in one line.
5. Guardrails
- Issue-first: no retroactive issues. Every PR body needs
Closes #N(CI enforces). - Never create a PR, merge, push to
main, or close an issue unless the user asks. - Comment on the issue when starting (CLAUDE.md "Issue Lifecycle"). Be frugal with other GitHub posts.
- Errors: failing tests/CI → stop-the-line, back to engineer; blocked >30 min → report to user.
- Load
.claude/skills/oblivion-componentfor any UI work and mention it in the dispatch prompt.