/project-toolkit:autoplanfrom project-toolkit
Routes any request to the appropriate skill, command, or agent chain when no specific skill is named. Acts as a front-door orchestrator for the full skill catalog.
Ships in project-toolkit. 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.
Read when SKILL.md points to them; scripts run unread.
One lazy entry point for the whole catalog. Classify the request, route it, apply defaults, and only stop for decisions that are genuinely the user's.
This router's stable identity is project-toolkit:autoplan. /autoplan
stays the local alias inside this repository; nothing is renamed
(REQ-039 criterion 10, DESIGN-037).
| Context | Name the model sees | Contract selected |
|---|---|---|
This repository, .claude/skills | autoplan | this router |
| Packaged plugin | project-toolkit:autoplan | this router |
| Mixed catalog with gstack | project-toolkit:autoplan and gstack:autoplan | router by qualified name; gstack's own review pipeline only by its qualified name |
gstack ships an unrelated skill also named autoplan (a four-phase
CEO/design/engineering/DX review pipeline). Never invoke a bare autoplan in
a mixed catalog expecting this router; use the qualified name. This router
never selects the gstack pipeline by an unqualified request, because that
skill carries no intents for this router's long-tail resolver to match.
| Trigger Phrase | Operation |
|---|---|
/autoplan followed by the request text | Classify and route the request |
do it | Classify and route the current request |
handle it | Classify and route the current request |
figure this out | Classify, then report the route before running |
your call | Classify, then report the route before running |
The router also fires implicitly. Any concrete request that names no skill routes through the table below instead of defaulting to a bare answer, for example "why is CI failing", "investigate the flaky test", or "redo the login fix properly".
The phrases come from this repo's session history: continue, proceed, investigate, fix the X, do it, handle it. Continue and proceed are not hard triggers: they resume the in-flight work, so they route to whatever is already running instead of re-classifying.
Apply in this order (REQ-039):
Delegation on each host. "Delegate to the X agent" means the host's subagent tool: Claude Code Task with subagent_type="X"; Copilot CLI task with agent_type="project-toolkit:X"; Codex spawn_agent with agent_type="X", plus fork_turns="none" when the agent reviews or judges work (the default hands it your whole history); Muse Code subagent_spawn with role="X" and an objective, plus worktree_isolation: true for an agent that writes files. If the host has no subagent tool, or no X agent is installed, run the step yourself in this session.
Before you classify, establish the target repository's stack. Do not assume the stack of the repo this skill ships from (Python-first). The target may be C#, TypeScript, Go, Rust, or anything else.
Read the target's own signals: CONTRIBUTING*, AGENTS.md/CLAUDE.md,
README*, build manifests (*.csproj/*.sln, pyproject.toml,
package.json, go.mod, Cargo.toml, pom.xml, build.gradle,
build.gradle.kts, settings.gradle, settings.gradle.kts), and the
src/, lib/, test//tests/ layout. Derive language, build command, test
command, and conventions; carry them into every route. A plan, path, or test
command that does not match the detected stack is a recon failure. For large
governed repos (SDK, runtime, framework), detect contribution gates (API
review, ref-assembly updates, changelog, breaking-change policy) and route
public-API work through those gates: land an API proposal and maintainer
review before writing the implementation.
Issue already has an in-flight blocking PR. Run check_existing_pr_for_issue.py --owner <O> --repo <R> --issue <N>
(github skill; args from URL; gh_unusable: MCP PR search)
before routing an autoplan <issue-url> request into new work;
exit 1: an open PR claims it; 2-4: stop, report; only 0 clears. If an open PR
already carries a closing keyword for the issue, do not treat "avoid
duplicating that work" and "resolve the issue" as the same goal; they diverge
whenever the PR bundles the requested scope with unrelated scope that has not
cleared review. Do not infer that divergence from an advisory scope- or
size-related label alone (a needs-split-style tag): such a label is
routinely assigned purely from commit count or file count, unrelated to
whether the PR's content is actually separable, and a long, cohesive PR can
carry it too. Before trusting one, check what actually assigns it in the
target repository (its CI workflow or label-automation config), not what its
name suggests. Forking a PR on the label's presence alone risks creating a
duplicate implementation instead of extracting anything, so treat any such
label only as a prompt to open the diff and review state, never as evidence
on its own. Confirm from the actual diff and review comments that the
issue's scope sits in its own reviewed, extractable commits before acting;
when it does, extract that slice into its own minimal, mergeable PR rather
than filing a follow-up issue and reporting the parent issue as handled
while it stays open with no merged artifact. (Learned from the
rjmurillo/ai-agents repository, where
needs-split was assigned purely from commit count and proves nothing about
scope. Also from the same issue: two independently-extracted
slices of the same blocking PR can race each other and one PR merging first
does not retroactively make the other's extraction wrong, only redundant
for the scope both cover; check what the winner actually shipped before
re-deriving or discarding the loser's independent findings.)
Answer two questions before you route. The Phase 0 recon reads come first; this step selects the pipeline, it does not forbid those reads.
Intent family. Match the request against the routing table below. When two
families match, prefer the more specific row (a failing CI check on a PR is
Session-protocol CI failure, not PR ops).
Size. Pick the smallest honest tier:
| Tier | Signal | Pipeline depth |
|---|---|---|
| Trivial | One known file, no new capability, no contract change | Fix, test, commit |
| Standard | Bounded change, existing capability surface | /build then /test then /review then /ship |
| Feature | New capability, new module, or ambiguous requirements | /spec then /plan then the Standard chain |
When unsure between tiers, start one tier down and escalate on contact with evidence (failing tests, widening diff), not on speculation.
| Intent | Route |
|---|---|
| Build a feature, "add X" | Lifecycle chain per size tier above |
| Execute, review, or resume a plan file the planner workflow wrote | Skill: planner (milestone decomposition stays with /plan) |
| New capability (Context, module, scanner, validator, pipeline component) | Skill: programming-advisor prior-art discovery BEFORE /spec; add buy-vs-build-framework only for a strategic build, buy, partner, or defer decision, then the Feature chain |
| Bug, error, "why is this broken" | Skill: analyze, then /build for the fix |
| PR, issue, label, milestone ops | Skill: github |
| Respond to PR review threads | Skill: pr-comment-responder |
| Merge conflicts | Agent: merge-resolver |
| Push, ship, "open a PR" | /ship (or /push-pr for push-only) |
| "what do we know about X" | Skill: memory-search |
| Research an unfamiliar topic | Skill: context-gather, then Skill: research (its claim gate composes ai-agents-external-claims before any durable write) |
| Ask about Claude Code or Copilot CLI hook contracts | Skill: agent-harness-reference |
| Port, implement, or change cross-harness hooks | Skill: agent-harness-reference, then /build (in the ai-agents repository: ai-agents-portability-campaign) |
| Software design depth, architecture boundaries, domain modeling, refactoring, legacy code, low coverage, old files, external APIs, queues, retries, transactions, event ordering, schema evolution, resilience | Skill: software-engineering-library, then the routed reference |
| Code quality, health check | Skill: quality-grades (repo-wide) or review (pre-merge) |
| "Did I touch security-critical files?" | Skill: security-detection |
| Review a diff or snippet for vulnerabilities | Skill: security-review; injection scan via security-scan |
| Correction received, lesson learned | Skill: reflect |
| Document a decision | Skill: adr-generator |
| New skill wanted | Skill: skillforge |
| Multi-domain, cross-cutting, or requires multiple agents | Agent: orchestrator |
The user naming a skill or command bypasses this table entirely. User Sovereignty wins over any row.
Model tier. Task shape picks the model tier; the orchestrator agent's Model, Effort, and Cost Routing section owns those rules and the measured exceptions. Fixture results only nominate a cheaper tier for a bounded leaf whose output a real downstream verifier checks. A passing eval fixture is not that verifier. Judgment and end-to-end work keep task-shape routing. Escalate on a failed acceptance check.
Router boundary (ADR-078). Autoplan is the outer front-door router at the
skill layer. It classifies any request that names no skill and routes it to one
destination: a skill, a lifecycle command, or an agent chain. When a request is
multi-domain or multi-agent execution, autoplan hands off to orchestrator
(last row above). Orchestrator is one of the destinations autoplan routes to,
not a peer: it owns multi-agent coordination, handoff management, and synthesis,
and it never routes back to autoplan. Rule: autoplan routes; orchestrator
coordinates specialists.
When the request names no skill or command, matches no row above, and is not multi-domain (Precedence step 3), run the resolver before falling back to the orchestrator. Resolve the script from the plugin root, so it works from an installed plugin and from a repository checkout:
RESOLVER="${COPILOT_PLUGIN_ROOT:-${CLAUDE_PLUGIN_ROOT:-$(git rev-parse --show-toplevel)/.claude}}/skills/autoplan/scripts/resolve_route.py"
Then run:
python3 "$RESOLVER" --request "<the user's request text>"
Read kind from the JSON result and act:
kind | Action |
|---|---|
explicit | Invoke route directly; the request already named it. |
orchestrator | Delegate to the orchestrator agent; a multi-domain marker fired. |
specialist | Invoke route, the one eligible skill whose intents matched. |
ambiguous | Ask the user to pick from candidates (Sovereignty; do not guess). |
none | No specialist matched. Fall through to the lifecycle chain by size tier, or delegate to the orchestrator agent when nothing else fits. |
A missing PyYAML module or a missing skills root exits 2 with a named
reason on stderr; when that happens, read skill descriptions directly
instead of retrying the resolver. The resolver never returns this router
itself (Precedence step 6): a request naming /autoplan drops that
self-reference and resolves the rest of the request instead.
Example specialists this step reaches that carry no table row above:
business-strategy (a founder problem, a business model, or a competitive
strategy question), world-model-diagnostic (why an agent's assumptions or
model are failing), and dx-review (audit a CLI, API, or onboarding workflow
for developer friction).
When you cannot invoke a subprocess (a constrained sandbox, no python3),
fall back to reading each candidate skill's description frontmatter field
directly and picking the closest match. Report which path you took
(resolver output vs. description fallback) in the Phase 4 final gate.
Apply these without asking. Log each application for the final gate.
Classify every decision the run surfaces; never promote silently.
| Class | Definition | Handling |
|---|---|---|
| Mechanical | One defensible answer (run tests, fix lint, sync a mirror) | Decide silently |
| Taste | Viable trade-offs, low reversal cost (naming, small refactor shape) | Decide, surface at the final gate |
| Sovereignty | Architecture, new ADRs, breaking changes, security posture, anything external or irreversible | Stop and ask. Never auto-decide |
The Sovereignty row is the AGENTS.md Ask First list plus the Autonomy
Guardrail. When a Sovereignty decision blocks the whole run, present 2 to 3
options with trade-offs per the Confusion Protocol and wait. See
references/writing-style-and-confusion-protocol.md for the full protocol,
completeness scoring, and writing-style mechanics. Read
references/decision-procedure.md before Phase 1: it is the six-step walk
(scope constraint, search, lake or ocean, build, present and ask, stop at
terminal) that used to live in the always-on builder-ethos rule.
references/golden-age.md holds the task-compression table behind Boil the
Lake; read it when sizing a build-vs-skip call.
The five references/orchestrator-*.md files serve the orchestrator agent, not this
router: analyst handoff, anti-patterns, resume and drift, hook feedback,
and routing evidence.
Every /autoplan run ends with one summary block, not a narration stream:
resolve_route.py is the deterministic long-tail resolver Phase 2b runs on
a single-domain table miss (DESIGN-037). It reads local SKILL.md
frontmatter and prints one JSON line to stdout; it opens no network
connection and runs no subprocess. Resolve its path the same way Phase 2b
does ($RESOLVER below), never as a bare relative invocation:
RESOLVER="${COPILOT_PLUGIN_ROOT:-${CLAUDE_PLUGIN_ROOT:-$(git rev-parse --show-toplevel)/.claude}}/skills/autoplan/scripts/resolve_route.py"
python3 "$RESOLVER" --request "audit our CLI for developer friction"
Exit codes: 0 on any resolution, including kind: "none". 2 for a
missing skills root, a missing PyYAML module (named on stderr), or a bad
argument. See Phase 2b above for the kind values and how to act on each.
A routed run is complete when every box checks:
orchestrator agent with the failure context rather than
retrying the same route blind. Two consecutive routing misses on one
request: stop, ask which route the user wanted, and log the miss with the
reflect skill.references/decision-procedure.md (opens in a new tab)references/golden-age.md (opens in a new tab)references/orchestrator-analyst-handoff.md (opens in a new tab)references/orchestrator-anti-patterns.md (opens in a new tab)references/orchestrator-hook-feedback.md (opens in a new tab)references/orchestrator-resume-and-drift.md (opens in a new tab)references/orchestrator-routing-evidence.md (opens in a new tab)references/writing-style-and-confusion-protocol.md (opens in a new tab)scripts/resolve_route.py (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
Generated from the plugin's indexed repository (rjmurillo/ai-agents) — no native marketplace selected
npx claudepluginhub p/rjmurillo-copilot-cli-agents-src-copilot-cli104 skills in this plugin
/adr-generatorCreate comprehensive Architectural Decision Records (ADRs). Researches the destination directory to detect existing template conventions, gathers context, determines next ADR number, generates the ADR, validates completeness, and saves. Supports multiple ADR formats (MADR, Nygard, Alexandrian, project canonical). Use when documenting technical decisions, creating new ADR files, or capturing rationale so future readers can revisit a choice. Use when you say "write an ADR", "document this decision", "document these design choices", "record why we chose this", "capture the rationale", or "for future maintainers", or when creating an ADR-like markdown file under docs/decisions/, docs/adr/, docs/architecture/, architecture/decisions/, or .project-toolkit/architecture/. Do NOT use to debate or review an existing ADR (use adr-review)./adr-reviewMulti-agent debate orchestration for Architecture Decision Records. Automatically triggers on ADR create/edit/delete. Coordinates architect, critic, independent-thinker, security, analyst, and high-level-advisor agents in structured debate rounds until consensus. Use when you say "review this ADR", when an ADR is created/edited/deleted, or when reviewing, accepting, or updating a decision file under .project-toolkit/architecture/, docs/architecture/, docs/decisions/, docs/adr/, or architecture/decisions/, including intent like "review this decision record" or "check this rationale for future maintainers". Do NOT use to author a new ADR (use adr-generator).Other plugins' skills for the same job