All /swarm subcommands available in the current OpenCode Swarm source tree. The authoritative source is src/commands/registry.ts; this page is generated from that registry, so the reference below cannot drift from the shipped commands. Edit the registry, then regenerate with bun run scripts/generate-commands-docs.ts --write.
Commands are grouped by function (core, agent, config, diagnostics, utility). Compound commands (e.g., /swarm config doctor) resolve the two-word form first, then fall back to the first token. Additional deprecated compatibility aliases (dash-form TUI shortcuts and legacy names) still resolve to their canonical command with a deprecation warning but are intentionally not documented individually.
First-class MODE commands are repo-agnostic. The npm package ships the built-in OpenCode mode skills and materializes private runtime copies under .swarm/bundled-skills/ before emitting a MODE signal. Native project skill roots (.opencode/skills/, .claude/skills/, and .agents/skills/) remain project-owned and are never overwritten.
- Inside an OpenCode session: type
/swarm <subcommand>in the chat. Session-scoped commands (turbo,full-auto) require an active session and only work here. - Standalone CLI:
opencode-swarm run <subcommand>(e.g.opencode-swarm run status,opencode-swarm run show-plan 2). Both routes share the same registry; seesrc/cli/index.tsfor the standalone dispatcher.
Several swarm subcommands share exact names with Claude Code built-in slash commands. This is a known source of model confusion — AI agents trained on Claude Code may try to invoke the CC built-in instead of the swarm subcommand. All swarm commands must use the full /swarm <subcommand> form; never reference a conflicting swarm subcommand by its bare name inside a swarm agent context.
| Swarm Command | Conflicts With | Severity | CC Behavior |
|---|---|---|---|
/swarm show-plan |
/plan |
CRITICAL | Enters Claude Code plan mode — Claude proposes all actions before executing them |
/swarm reset |
/reset |
CRITICAL | Alias for /clear — wipes the entire conversation context window |
/swarm checkpoint |
/checkpoint |
CRITICAL | Alias for /rewind — restores conversation and code to a prior state |
/swarm status |
/status |
HIGH | Shows Claude Code version, active model, account, and API connectivity |
/swarm agents |
/agents |
HIGH | Manages Claude Code subagent configurations and teams |
/swarm config |
/config |
HIGH | Opens Claude Code settings interface (alias: /settings) |
/swarm export |
/export |
HIGH | Exports the current Claude Code conversation as plain text to a file |
/swarm doctor |
/doctor |
HIGH | Diagnoses the Claude Code installation (version, auth, permissions) |
/swarm history |
/history |
MEDIUM | Shows Claude Code session history |
For contributors: adding a new swarm command that matches a CC built-in requires updating src/commands/conflict-registry.ts with an explicit severity and disambiguation note; the CI gate test in src/commands/conflict-registry.test.ts fails until this is done.
Two human-only restricted commands exist as escape hatches for wedged mechanical gates. They are documented here — not buried in a category group — because you need them exactly when a workflow is stuck. Both append an audit event to .swarm/events.jsonl.
Clear a stuck PR_REVIEW/PR_FEEDBACK mechanical gate and stop the auto-resume loop [mode] [reason] or PR_FEEDBACK --cancel-publication <reason...> (cancelled_without_publication)
Args: [PR_REVIEW|PR_FEEDBACK] [reason...] | PR_FEEDBACK --cancel-publication <reason...>
Human-only restricted command. An agent cannot run this command itself through swarm_command (toolPolicy: 'restricted'); when the situation above applies, the agent asks you to run it in chat (or uses its dedicated tool path).
Human-only escape hatch for an unrecoverable PR_REVIEW or PR_FEEDBACK mechanical gate. When the architect cannot reach complete_pr_workflow — for example a compound git fetch && git checkout was rejected as read-only shell syntax, the PR head cannot be fetched, or the working tree is on the wrong branch — running this clears the durable gate state for the current session and stops the auto-resume loop without depending on the trapped model. The agent itself cannot run this command; it must call the abort_pr_workflow tool (or ask you to run this command). Both paths funnel into the same fail-closed abortPrWorkflow hook, which refuses while the workflow is armed for publication or while PR workflow lanes are still in flight. To cancel an armed PR_FEEDBACK publication without publishing, use the exact human syntax PR_FEEDBACK --cancel-publication <reason...>; it requires a non-empty reason, records the terminal cancelled_without_publication status with the observed remote head, and never grants push authority. A plain recovery or force abort never clears an armed window. This human-only force path has exactly one exception to the lane refusal (issue #2251): when the ONLY lanes still blocking are ones past the 30-minute staleness horizon that the liveness probe reports as still running — a lane nothing will ever settle on a schedule — it clears the gate anyway, names exactly which lanes it overrode, and finalizes their delegation records so the session can start a new PR workflow. Those sessions are NOT stopped and their output is NOT collected. A lane with a fresh updatedAt still blocks even under force, and any delegation record that still keeps the session blocked is named in the warning. When checkout preparation preserved a stash, the result instructs the caller to run prepare_pr_workflow_checkout operation=restore after the clear. An audit event is appended to .swarm/events.jsonl.
Record a MANUAL plan-critic approval to unblock the critic_pre_plan execution gate [reason...]
Args: [reason...]
Human-only restricted command. An agent cannot run this command itself through swarm_command (toolPolicy: 'restricted'); when the situation above applies, the agent asks you to run it in chat (or uses its dedicated tool path).
Human-only escape hatch for the ratchet-tighter critic_pre_plan execution gate (issue #2012). When the critic already returned APPROVED but the mechanical snapshot recorder failed to persist it (verdict-format mismatch, dispatch-signal miss, or a plan.json read race), an enabled critic_pre_plan gate blocks coder delegation. Running this records a manual plan_critic_gate approval snapshot so the gate unblocks, with a distinct method: "manual_override" audit marker. The agent itself cannot run this command; it must call the approve_plan_critic tool (or ask you to run this command). Both paths funnel into the same forceRecordPlanCriticApproval hook, which requires an active architect session. An audit event is appended to .swarm/events.jsonl. Prefer re-running MODE: CRITIC-GATE first; use this only as an escape hatch when a legitimate APPROVED was lost.
Show current swarm state (plus background-work health when hooks.background_subagents is enabled)
Claude Code conflict: name clash with /status — always use the full /swarm status form.
Show current plan (optionally filter by phase number)
Args: [phase-number]
List registered agents
Claude Code conflict: name clash with /agents — always use the full /swarm agents form.
Show help for swarm commands
Args: [command]
Without argument, shows full command listing. With argument, shows detailed help for a specific command.
Use /swarm finalize to finalize the swarm project and archive evidence
Args: --prune-branches, --skill-review, --dry-run
Idempotent 4-stage terminal finalization: (1) finalize writes retrospectives for in-progress phases, (2) archive creates timestamped bundle of swarm artifacts and evidence, (3) clean removes active-state files for a clean slate, (4) align performs aggressive git reset --hard to the default remote branch, discarding uncommitted changes and gitignored build artifacts (user-created untracked files are preserved); falls back to a cautious reset that preserves uncommitted changes when the aggressive path cannot proceed. Alignment re-verifies the tracked tree immediately before its destructive reset and aborts fail-closed (leaving alignment undone) when tracked files changed after the close gate was verified or the status cannot be re-read (#2953). WARNING: alignment discards local changes and gitignored files. Resets agent sessions, delegation chains, and active-agent mappings. Reads .swarm/close-lessons.md for explicit lessons and runs curation. Cleanup: knowledge.jsonl is preserved; plan.json, plan.md, events.jsonl, handoff.*, run-memory.jsonl, and summaries/ are removed. An open epic (Epic Mode) is first closed as abandoned-by-swarm-close (it never lands; its close report is archived); .swarm/epic/ is cleaned, while .swarm/epic-prior/ (learning prior and past epic reports) is preserved. Use --skill-review to run the quota-bounded skill_improver in proposal mode. Use --dry-run to preview what finalize would archive, clean, and align without taking the lock or changing anything.
Run the post-mortem agent: project-end synthesis, queue triage, and final curation pass
Args: --force, --scope session|project
Reads .swarm/ evidence (knowledge entries, events, curator digests, proposals, retrospectives, drift reports) and produces a post-mortem report at .swarm/post-mortem-{planId}.md. Idempotent: re-runs skip if report exists unless --force is passed. Use --scope session to limit knowledge event aggregation to the current session; project scope is the default.
Prepare state for clean model switch (new session)
Generates handoff.md with full session state snapshot, including plan progress, recent decisions, and agent delegation history. Prepended to the next session prompt for seamless model switches.
Analyze spec.md vs plan.md for requirement coverage gaps
Clarify and refine an existing feature specification
Args: [description-text]
Generate or import a feature specification [description]
Args: [description-text]
Enter architect MODE: BRAINSTORM — structured seven-phase planning workflow [topic]
Args: [topic-text]
Triggers the architect to run the brainstorm workflow: CONTEXT SCAN, single-question DIALOGUE, APPROACHES, DESIGN SECTIONS, SPEC WRITE + SELF-REVIEW, QA GATE SELECTION, TRANSITION. Use for new plans where requirements need to be drawn out before writing spec.md / plan.md.
Enter architect MODE: LOOP — compound-engineering loop: brainstorm → plan → build → review → improve, iterating until done [objective]
Args: <objective> [--max-cycles 1..5] [--autonomy checkpoint|auto] [--depth standard|exhaustive] [--resume]
Triggers the architect to run the compound-engineering loop defined in .swarm/bundled-skills/loop/SKILL.md: BRAINSTORM (requirements) → PLAN (+ critic gate) → BUILD (execute) → REVIEW (independent reviewer + critic on the diff, report-only) → IMPROVE (phase-wrap retrospective + compounding learning capture), then evaluate stop conditions and loop for another improvement cycle if the objective is unmet and budget remains. Generator and reviewer/critic run in separate contexts; failing assertions must be fixed at the root cause, never weakened, mocked, or skipped. Defense-in-depth stop conditions: objective met, --max-cycles budget (default 3), no-progress/plateau, oscillation, unrecoverable error, or explicit user stop. --autonomy auto (default) runs unattended with hard stops still enforced; --autonomy checkpoint pauses at phase gates for user approval. --depth exhaustive widens exploration. --resume continues an existing loop run from durable .swarm/loop/ state. Distinct from full-auto (a critic gate that intercepts phase completions and high-risk actions for review — it never plans, delegates, or executes; the architect retains all delegation duty) and turbo (parallel lanes within a phase): loop is a user-initiated, gated, compounding workflow.
Enter architect MODE: COUNCIL — multi-model deliberation [question] [--spec-review]
Args: <question> [--spec-review]
Triggers the architect to convene a three-agent General Council: Generalist (reviewer model), Skeptic (critic model), and Domain Expert (SME model). The architect first runs 1–3 targeted web searches and passes a compiled RESEARCH CONTEXT to all three agents before dispatching them in parallel. Agents deliberate using the NSED peer-review protocol (Round 1 independent analysis, Round 2 MAINTAIN/CONCEDE/NUANCE for disagreements). The architect synthesizes the final answer directly from convene_general_council output. --spec-review switches to single-pass advisory mode for spec review. Requires council.general.enabled: true and a search key (Keenable: none; SpecStream: SPECSTREAM_API_KEY only) in the resolved config: global ~/.config/opencode/opencode-swarm.json, then project .opencode/opencode-swarm.json overrides.
Launch deep PR review with multi-lane analysis [url] [--council]
Args: <pr-url|owner/repo#N|N> [--council] | <GitHub PR URL> --release-head <full SHA>
Launches a structured PR review: preserves dirty state, verifies and binds an exact detached PR head, reconstructs PR intent via obligation extraction cascade, computes a depth tier (S/M/L) from the bound merge-base diff, launches the base explorer wave through dispatch_lanes_async (all 6 review dimensions covered on every PR — six singleton lanes at tier L, consolidated owned_workflow_lanes partitions at tiers S/M) while the architect keeps doing non-dependent work, and polls collect_lane_results incrementally. It evaluates an exact 11-row repository-agnostic risk-family ledger, records applicable rows as MATCHED and concretely inapplicable rows as provenance-free NOT_TRIGGERED, always keeps unclassified-risk MATCHED, and dispatches micro work only for MATCHED families (dedicated lanes at tier L, consolidated sweeps at S/M). It then validates findings through independent reviewer confirmation, applies critic challenge to HIGH/CRITICAL findings, and synthesizes only after matched coverage is closed. Failed obligations retry through the same structured async mode and exact PR head; blocking or direct-Task dispatch is not provenance-equivalent, so unclosed matched coverage leaves the review BLOCKED rather than degraded. --council variant fires adversarial multi-model review. Supports full GitHub URL, owner/repo#N shorthand, or bare PR number (resolves against origin remote). For release admission, the architect uses the full GitHub PR URL and exact head SHA.
Ingest and close known PR feedback (review comments, CI failures, conflicts) [pr] [instructions]
Args: [url|owner/repo#N|N] [instructions...]
Triggers MODE: PR_FEEDBACK — ingests existing pull-request feedback (review threads, requested changes, CI/check failures, merge conflicts, stale branch state, pasted notes), verifies every claim against source, clusters related problems, fixes confirmed items, validates the branch, and reports closure status for every ledger item. Distinct from /swarm pr-review, which discovers new findings. On a PR the default run continues to green CI and a monitored merge, then a session retrospective and the memory closeout. It merges only when your own words ask for the merge (for example "/swarm pr-feedback 123 and merge"; a question or mention never counts) or you answer yes to its merge question. "Fixes only" skips CI and the merge; "no merge" skips only the merge. The PR reference is optional: with none, the architect builds the ledger from the current PR/branch; text after the reference is forwarded as extra instructions. Supports full GitHub URL, owner/repo#N shorthand, or bare PR number (resolved against origin).
Drive an already-reviewed, approved PR to green and merged (monitor CI, fix, merge) [pr]
Args: <pr-url|owner/repo#N|N>
Triggers MODE: CI_MONITOR — takes an already human-reviewed, approved PR, exhaustively researches every CI failure, fixes it end-to-end, iterates until all required checks are green (max 5 fix cycles), then merges via gh pr merge (no strategy flag on a merge-queue base; the allowed method on a direct base). Invoke only after human review is complete; the skill re-verifies reviewDecision: APPROVED and mergeable state before doing anything destructive. Distinct from /swarm pr-subscribe, which passively watches a PR without a merge terminal. Supports full GitHub URL, owner/repo#N shorthand, or bare PR number (resolved against origin).
Subscribe the current session to PR state-change notifications
Args: <pr-url|owner/repo#N|N>
Subscribes the current session to PR state-change events for the specified PR. When pr_monitor.enabled is true, the background polling worker detects CI failures, new comments, review state changes (changes requested / approved), merge conflicts and conflict resolutions, and merge/close events — each gated by its pr_monitor notify_* config flag (notify_ci_success defaults to false). Delivery follows pr_monitor.event_delivery: "prompt" (default) wakes the subscribed session with a structured message; "advisory" queues session-scoped advisories with dedup tokens for the next turn. Subscriptions are idempotent, capped by pr_monitor.max_subscriptions, and agent-callable. Supports full GitHub URL, owner/repo#N shorthand, or bare PR number (resolved against origin). Requires pr_monitor.enabled: true in config.
Unsubscribe the current session from PR state-change notifications
Args: <pr-url|owner/repo#N|N>
Unsubscribes the current session from PR state-change events for the specified PR. Removes the active subscription record (idempotent; agent-callable). Supports full GitHub URL, owner/repo#N shorthand, or bare PR number (resolved against origin).
Show PR monitor subscription status for the current session
Displays all active PR subscriptions for the current session. Shows PR URL, last checked time, watching status, and error count per subscription. Also shows total active subscriptions across all sessions.
Create a temporary merge-result worktree and run CI before merge queue entry
Args: [pr-ref] [--base <ref>]
Creates a detached temporary worktree under the OS temp dir (swarm-ci-simulate) from the base — an explicit validated --base when given (stacked/release-branch PRs), otherwise the detected default remote branch (origin/HEAD, init.defaultBranch, origin/main, origin/master, verified to exist) — merges the given PR ref (or the current ref), runs fixed local CI gates (typecheck, lint, build, test), then removes the worktree non-force and prunes metadata. Worktree removal is fail-closed: a blocked or dirty worktree is surfaced, never force-deleted. Intended as a pre-queue merge_group simulation helper.
Launch deep codebase audit with parallel explorer waves, dual reviewers, and critic challenge [scope]
Args: <scope> [--profile standard|security|ux|architecture|full] [--max-explorers 1..8] [--json] [--skip-update] [--allow-dirty]
Runs a read-only deep audit of the specified scope using parallel explorer waves (8-file cap per mission, ~3500 line guardrail), always 2 parallel reviewers for verification, and sequential critic challenge on HIGH/CRITICAL findings. Profiles select explorer lanes: standard (5 lanes), security, ux, architecture, full (all 8 lanes). Emits a structured findings report without mutating source code.
Launch a multi-source, fact-checked deep research pass and synthesize a cited report [question]
Args: <question> [--depth standard|exhaustive] [--max-researchers 1..6] [--rounds 1..4] [--brief]
Runs the orchestrator-worker deep-research protocol: the architect decomposes the question into subtopics, gathers evidence with web_search and web_fetch across up to N iterative rounds, dispatches parallel sme synthesis workers, verifies every claim against cited sources with dual reviewers, challenges high-stakes claims with the critic, and presents a cited report in chat. Read-only — does not mutate source code, delegate to coder, or call declare_scope. Requires council.general.enabled and a search key (Keenable: none; SpecStream: SPECSTREAM_API_KEY only).
Launch codebase-review-swarm for a quote-grounded full-repo or large-subsystem audit
Args: [scope] [--mode phase0|complete|defect|security|correctness|testing|ui|performance|ai-slop|enhancements|custom] [--tracks <list>] [--continue <run-id>] [--json] [--skip-update] [--allow-dirty]
Runs the codebase-review-swarm workflow: Phase 0 inventory, selected-track depth planning, non-diluting review passes, coverage closure, reviewer validation, critic challenge, and .swarm/review-v8 artifacts. Materializes the bundled skill package if missing, then emits a MODE signal; the architect workflow must not mutate source files.
Generate or sync language-agnostic design docs (domain, technical-spec, behavior-spec, reference/) for the project under build [description]
Args: <description> [--out <dir>] [--lang <name>] [--update]
Triggers the architect to enter MODE: DESIGN_DOCS — delegates to the docs_design agent to author/sync docs/domain.md, docs/technical-spec.md, docs/behavior-spec.md, and docs/reference/* (plus reference/traceability.json and design-changelog.md). Normative docs are 100% language-agnostic; all framework-specific material is quarantined under reference/. --update syncs existing docs to current code/spec instead of generating fresh. Requires design_docs.enabled: true.
Ingest a GitHub issue into the swarm workflow [url] [--plan] [--trace] [--no-repro]
Args: <issue-url|owner/repo#N|N> [--plan] [--trace] [--no-repro]
Triggers the architect to enter MODE: ISSUE_INGEST — ingests a GitHub issue, restructures it into a normalized intake note, localizes root cause through hypothesis-driven tracing, and outputs a resolution spec. --plan transitions to plan creation after spec generation. --trace runs the fix workflow end-to-end (implies --plan); compose commit-pr to publish. --no-repro skips the reproduction step. Supports full GitHub URL, owner/repo#N shorthand, or bare issue number (resolves against origin remote).
Show current resolved configuration
Claude Code conflict: name clash with /config — always use the full /swarm config form.
Run config doctor checks
Ensure plan.json and plan.md are synced
View or modify QA gate profile for the current plan [enable|override ...]
Args: [show|enable|override] <gate>...
show: display spec-level, session-override, and effective QA gates for the current plan. enable: persist gate(s) into the locked-once profile (architect; rejected after critic approval lock). override: session-only ratchet-tighter enable. Valid gates: reviewer, test_engineer, council_mode, sme_enabled, critic_pre_plan, hallucination_guard, sast_enabled, mutation_test, phase_council, drift_check, final_council.
Toggle or set auto-proceed override for the active session
Args: [on|off]
Without argument, toggles auto-proceed mode. With "on" or "off", sets the state explicitly.
Acknowledge that the spec has drifted from the plan and suppress further warnings
Show aggregated context-capsule telemetry stats
Run tool registration coherence check
Run health check on swarm state
Dry-run: show what the guardrails would do to a command or write target (executes nothing)
Reset one exact active invocation/action circuit after repair
Read the guardrail decision log (use --blocks-only for blocks)
Run preflight automation checks
List active, awaiting-merge, and conflicted worktree lanes
Show performance metrics [--cumulative] [--ci-gate] [--max-cost-usd ] [--gate-audit-run ]
Args: --cumulative, --ci-gate, --max-cost-usd <n>, --gate-audit-run <id>
Exit codes (#2493 review F-14): with --ci-gate, the process exits 0 only when every quality check passes and 1 on any failure, budget breach, or missing evidence — CI-safe by construction. Without --ci-gate the command is informational and always exits 0.
Run the bounded Tier-1 reviewer/test/SAST/mutation/quality gate matrix
Args: --model <id>, --swarm <id>, --gates <csv>, --tasks <csv>, --runs <n>, --max-concurrency <n>, --max-retries <n>, --max-time-ms <n>, --max-cost-usd <n>, --seed <value>, --run-id <id>, --json
Runs immutable curated defects only in disposable copies, records unavailable data honestly, and writes versioned results below .swarm/evidence/gate-audit/. Container tasks are unsupported until a safe array-form runner exists.
Show offline per-model gate catch, false-reject, retry, cost, and reviewer fallback statistics
Args: --json, --min-samples <n>
Run the independent review model against a selected Git diff
Args: --base <ref>, --range <from..to|from...to>, --working-tree, --json
Collects one bounded canonical diff, dispatches the configured reviewer in a fresh read-only session, optionally validates eligible HIGH/CRITICAL findings when configured or required by gate mode, and persists the receipt and evidence. With no selector, reviews the default merge-base plus working-tree scope.
Show per-agent and per-task token/cost telemetry [--json]
Args: --json
Report swarm observability events from the SQLite query authority [--task ] [--session ] [--trace ] [--run ] [--since ] [--json]
Args: --task <id>, --session <id>, --trace <id>, --run <batchId>, --since <ISO-8601>, --json
Bounded, deterministic query over the observability events store in .swarm/swarm.db (the first run performs a bounded, idempotent legacy-import into the local sink). --run filters the lane/dispatch batch axis (workflow.batchId). Unmatched delegation begins are disclosed, never fabricated into ends. Includes a Task attempts (cohort) section (issue #2676): execution-attempt records folded through a snapshot-qualified cohort with per-class counts, known/unavailable cost split, uncertainty, and an explicit causal-rate qualification line. --json emits a schemaVersion-tagged block (schema v2 adds the taskAttempts cohort field).
Show the opt-in local mission-control dashboard URL and status (issue #2509)
Read-only status for the opt-in loopback dashboard over durable swarm state (gates & circuits, delegation age bands, lane liveness, task board, activity timeline). Disabled by default; enable with dashboard.port > 0 in opencode-swarm.json. Never starts or stops the listener — lifecycle belongs to plugin init; the dashboard itself performs no mutations.
Show learning metrics and violation trends
Args: --json, --phase <N>
Computes aggregate learning metrics from knowledge events: violation-rate trends, directive application rates, escalation frequency, per-entry ROI, and never-applied entries. Surfaces a learning summary for the curator digest.
Measure plan coupling (p) and rank modules driving conflicts (Epic mode preview)
Args: --phase <n>, --threshold <-1..1>, --min-co-changes <n>, --format markdown|json, --persist, --suggest
Computes the coupling coefficient p = (conflicting task pairs) / (total task pairs) over the current plan, using Epic mode's combined path + co-change conflict signal. Surfaces per-module contention and a ranked decoupling roadmap. Declared scopes come from live declare_scope bindings (falling back to plan files_touched). Read-only and usable without Epic Mode on, but the co-change signal is included only when epic.cochange.enabled is true — otherwise p reflects path conflicts only and the report says the signal is disabled by config. --suggest adds Epic plan shaping for the whole plan (the advisory save_plan returns as epic_shaping when Epic is on): the plan's epic sizing and up to 5 suggestions — scope advice (declare-scope, narrow-scope) first, then by their effective-speedup gain: extract-prerequisite, isolate-hot-file, split-task, merge-tasks, each with a concrete save_plan patch. Read-only; bounded by a work budget (skipped-budget beyond it).
Open, inspect, and close a plan-scoped epic (coupling-aware parallel execution of the current plan)
Args: start [--force] | close [--abandon] [--land squash|merge|none] | status [--repair-refs] | report [<key>|last] [--format json] | learning | prior [show|reset [--confirm=<token>]] | clear-merge-failure <taskId> [--confirm]
An epic is bound to ONE plan: start opens it for the current plan, close ends it. Requires epic.mode.enabled: true in config (top-level epic block; no turbo block needed — the legacy turbo.epic path is still accepted and migrated). start [--force] refuses, in order: epic-disabled-by-config, host-unsupported (the host gives the plugin no OpenCode SDK client; on OpenCode 2 the v2 adapter ships one, so this refusal does not fire there — Epic is startable on OpenCode 2 via the native v2 /swarm command dispatch, #3169 Phase 4), no-plan / plan-ledger-unreadable, epic-already-open (idempotent for the same plan) / epic-open-for-other-plan, turbo-active (config turbo_mode, a session with Turbo on, or a running Lean run — Epic enables neither Lean nor Turbo and never waives per-task QA), dirty-baseline (git: uncommitted changes outside .swarm/), detached-head / epic-branch-exists (epic-branch policy), in-flight-coders (any coder dispatch, background delegation, unsettled settlement, or preserved/recovery lane), not-epic-sized (too few pending tasks, insufficient scope coverage, or insufficient effective speedup — run it in Balanced, or reshape it with the plan-shaping suggestions shown; --force overrides and is recorded). Non-git projects run an epic serially (one task per wave). Git epics default to epic.commit_policy: "epic-branch": start checks out swarm/epic/<epicKey> and every Epic commit goes there (epic_next_wave blocks with epic-branch-mismatch, and no landing or residue is committed, while HEAD is elsewhere); current-branch keeps commits on the starting branch. In a git epic every coder runs in an isolated worktree (refused EPIC_ISOLATION_DEGRADED when isolation is unavailable) and lands as a swarm(task <id>): … merge commit; main-tree files a non-coder writer (test_engineer, docs) wrote for a task are committed as residue of that task; update_task_status writes nothing to git; wave close records the commit of each task as refs/swarm/epics/<epicKey>/tasks/<id> (deleted at close unless epic.retain_refs; never pushed by default). While open, the architect calls epic_next_wave and does what its status says: it issues one wave at a time (tasks with non-conflicting declared scopes — exclusive tasks alone, at most one task per densely coupled component; phases strictly in order), the architect dispatches one Task per taskId in ONE message and runs per-task QA (pre_check_batch → reviewer + test_engineer → update_task_status(completed)), and the next epic_next_wave closes the wave (recording outcomes and declared-vs-actual divergence) and issues the next; when a phase is done it returns phase-ready-for-review → epic_phase_review → phase_complete. close [--abandon] [--land squash|merge|none] refuses while tasks are pending (or the epic is orphaned / unreadable) unless --abandon, refuses a dirty tree before landing, writes a close report (epic-report-v2, embedding the epic scorecard) to .swarm/epic/reports/ and .swarm/epic-prior/reports/ (newest 50 kept), and lands the epic branch onto the original branch: squash (default — staged, uncommitted changes for you to review and commit), merge (a --no-ff merge commit), or none (switch back only). The epic branch is kept (remove it with git branch -D once committed). A landing conflict is rolled back (the attempted squash or merge is undone) and the epic stays closing — rerun close to resume. --abandon never lands; it switches back to the original branch when the tree is clean. status [--repair-refs] (also bare /swarm epic) shows the epic, its waves, phases, the task components recorded with the latest wave and recorded divergence, orphan detection (plan renamed or replaced), sentinel/row repair, recorded worktree merge failures, and retires legacy Epic v1 session state once; --repair-refs re-adopts task commits a rebase or amend made unreachable from HEAD. report [<key>|last] [--format json] shows the epic scorecard: live for the open epic (bare report), else from the close report of a past epic in .swarm/epic-prior/reports/ (last = newest; <key> = a report or epic key) — tasks completed in the epic, waves (count, width), time over closed waves (wave span, task issue→resolve time, and their ratio, a concurrency factor that is NOT a speedup: it includes queueing behind serialized QA), conflicts (merge-back failures, undeclared writes), rework (extra generations, reopens), first-pass gate rates (upper bounds: the failure history is bounded), forced/sizing at start and learned hot files. Epics learn from their outcomes: undeclared writes teach learned co-writes (a task declaring D that also wrote f makes later tasks declaring D conflict with tasks on f — planner analysis only, never write authorization) and incidents (undeclared writes, merge conflicts, Stage B failures, rework, reopens) in excess of clean exposures make a file hot (a task declaring it runs alone) — undeclared writes its strongest learned co-writer explains are discounted (expansion already separates them), so one declarer writing a file is not heat; an empty history learns nothing (neutral start). Each wave close updates the posterior of the epic; close merges it into the project prior .swarm/epic-prior/learning.json (decayed per epic and by age; kept across /swarm close; epic.learning.*). learning shows what the planner learned and uses now; prior [show] shows the project prior; prior reset previews and prints a single-use confirm token (15 minutes); prior reset --confirm=<token> clears it. Also: clear-merge-failure [--confirm]. The former on / off toggles, the decide / last subcommands and calibration (renamed learning) were removed.
Detect hidden file couplings via co-change NPMI analysis
Args: --threshold <number>, --min-commits <number>
Dry-run hidden coupling analysis with configurable thresholds
Args: --threshold <number>, --min-commits <number>
Advisory headless CI: evaluate the repo gate/evidence state read-only with machine exit codes [--timeout-ms ] [--json]
Args: --timeout-ms <n>, --json
Host-decoupled, read-only evaluation of the checked-out repo (#2497): per-task required gates (tri-state evidence), plan-critic approval, and evidence-quality thresholds, composed from the authoritative readers. Exits 0 only when every evaluated gate passes; 1 on any violation, no-data, corrupt evidence, or a missing plan; 2 on cancellation (SIGINT/SIGTERM); 3 on deadline/internal error. Emits a Markdown report plus a [SWARM_CI_JSON] machine block. Never writes to .swarm and cannot satisfy or bypass any gate; runs with no TTY and no OpenCode host.
Validate a declarative harness blueprint or atomic blueprint patch
Args: <project-relative-json>
Show the ledger-derived current harness blueprint projection
Show bounded hash-verified harness version history
Args: [--limit <1..100>]
Compare two stored harness blueprint versions
Args: <from-version> <to-version>
Export a canonical stored harness blueprint
Args: [version]
Validate an inert harness candidate manifest
Args: <project-relative-json>
Show bounded harness candidate metadata without raw patch content
Args: <candidate-id>
Show candidate file and blueprint-change metadata without raw patch content
Args: <candidate-id>
Issue a one-shot session/action/candidate/hash-bound write approval
Args: <target-session-id> skill_improve <candidate-id> <candidate-content-hash> [--generation <n>] [--allowed-path-digest <sha256>]
Show completed phases summary
Claude Code conflict: name clash with /history — always use the full /swarm history form.
Governed single-skill optimizer (issue #1822). Proposes, validates, and activates one allowlisted SKILL.md candidate at a time with durable lifecycle, serial control, and manual approval.
Args: plan|run|status|diff|approve|reject|rollback|history <slug> [candidateId] [--json] [--confirm] [--expected-content-hash <hash>] [--models <csv>] [--dry-run]
Disabled/proposal-only by default. run requires skill_opt.enabled=true AND --confirm (consumes a held-out test set). approve/activate/reject/rollback are human-only and require --expected-content-hash to refuse a stale base. Stores append-only lifecycle under .swarm/evolution/skills///.
Propose an optimization round (dry-run; no mutation, no validation)
Args: <slug> [--json] [--models <csv>]
Execute the optimization loop (draft→smoke→validate; held-out set is single-use so at most one validation per run). Requires skill_opt.enabled=true and --confirm.
Args: <slug> --confirm [--json] [--models <csv>]
Show the current candidate lifecycle state
Args: <slug> <candidateId> [--json]
Show baseline-vs-candidate diff summary for a candidate
Args: <slug> <candidateId> [--json]
Activate a pending candidate (human-only; requires --expected-content-hash)
Args: <slug> <candidateId> --expected-content-hash <hash> [--json]
Record a rejection for a candidate (no active-skill mutation)
Args: <slug> <candidateId> [--json]
Restore the pre-activation snapshot (appends a rolled_back event)
Args: <slug> <candidateId> [--json]
Show the append-only lifecycle event log for a candidate
Args: <slug> <candidateId> [--json]
Governed HarnessOpt capstone (issue #2503). Freezes the comparative task set and drives isolated, approved, reversible optimization rounds through the evaluation substrate.
Args: plan|run|status|stop|history [--tasks <json>] [--split train|validation|test] [--seed <s>] [--confirm] [--json] [--reason <text>]
Disabled by default. run requires harness_opt.enabled=true AND --confirm, executes one governed round in a disposable worktree (a test split consumes the held-out set exactly once, substrate-enforced), and records durable lineage with task-cost accounting (unknown-not-zero). Activation/rollback stay on /swarm approve-write + the harness store; the controller never mutates the live harness.
Freeze the comparative task set and report loop status (dry-run)
Args: --tasks <json> [--split train|validation|test] [--seed <s>] [--json]
Execute ONE governed optimization round in a disposable worktree. Requires harness_opt.enabled=true and --confirm; a test split consumes the held-out set exactly once.
Args: --tasks <json> --confirm [--split train|validation|test] [--seed <s>] [--json]
Show loop status and the latest round lineage summary
Args: [--json]
Human-only operator stop: halt governed rounds with a recorded reason
Args: [--reason <text>] [--json]
Separately executable comparative evaluation (issue #2503): baseline, ablation, and simple-agent arms on one frozen task population with an independently validated manifest, the independent oracle verdict, and a retained pilot-graduation record.
Args: --tasks <json> --confirm [--manifest <json>] [--seed <s>] [--lower-ci <n>] [--json]
List durable round lineage records (bounded to the last 20)
Args: [--json]
Export plan and context as JSON
Exports the current plan and context as JSON to stdout. Useful for piping to external tools or debugging swarm state.
Claude Code conflict: name clash with /export — always use the full /swarm export form.
Human-only grant/revoke of the training-content consent record (two-step confirm token)
Args: [--confirm=<token>] [--revoke] [--max-bytes N] [--max-records N] [--retention-days N]
Issue #2486 (D7). Training-content capture is OFF by default and cannot be enabled by config, env, agents, or tools — only by this durable, project-bound consent record under .swarm/training/v1/consent.json. Bare invocation prints the consent terms (purpose, content classes, redaction, hard quota ceilings) and issues a 15-minute confirmation token; --confirm= writes the grant (quotas clamp to the ceilings, never above); --revoke stops capture immediately (physical deletion is /swarm dataset withdraw). Since #3840 the redaction version is informational redactor provenance, not a consent-terms boundary: the consent terms (purpose, content classes, quotas, retention, expiry) are the authorization surface, so a consent granted under an older redactor stays valid and capture continues — the running redactor only removes more content before storage. The preview prints the running version. Remediation for already-stored pre-v2 content: docs/training-vault-remediation.md.
Human-only destructive withdrawal: purge vault content, tombstone, revoke exports
Args: [--confirm=<token>]
Issue #2486 (D7). Preview-first: the bare command shows exactly what would be deleted (records, bytes, exports to revoke) and issues a 15-minute confirmation token. --confirm= physically empties the vault records file, appends a durable withdrawal tombstone (never deleted by any later operation), writes REVOKED.json revocation manifests into every export still under plugin control, and marks the consent withdrawn.
Human-only governed dataset export (deterministic bundle + manifest, two-step confirm token)
Args: [--kind <k>[,<k>]] [--session <id>] [--task <id>] [--since <ISO>] [--validation-ratio <0..0.5>] [--confirm=<token>]
Issue #2486 (D7). Side-effect-free preview by default: export id, record counts (train/validation split, quarantined excluded), estimated size, destination, and a 15-minute confirmation token. --confirm= writes the deterministic bundle (records.jsonl, train.jsonl, validation.jsonl, manifest.json with sha256 checksums, schema version, echoed filters, and a session-coherent split) under .swarm/training/v1/exports//; identical re-exports are idempotent. Since #3840 every exported record is re-redacted by the running redactor, so the manifest reports the source redaction versions represented separately from the verified floor, and an export that cannot safely redact a record publishes nothing. The existing /swarm export (plan+context JSON) is unchanged.
Show evidence bundles [taskId]
Args: <taskId>
Displays review results, test verdicts, and other evidence bundles for the given task ID (e.g., "2.1").
Generate evidence summary with completion ratio and blockers
Generates a summary showing completion ratio across all tasks, lists blockers, and identifies missing evidence.
Emit or verify verification receipts <task|phase> [--export] | --verify
Args: <task|phase> <id> [--export] | --verify <bundle>
Emits a portable, hash-backed record of the durably recorded gate outcomes for a task or phase (JSON + Markdown under .swarm/evidence/receipts/; --export writes a PR-attachable bundle under .swarm/plan-export/, reaped at close). --verify re-checks every recorded hash in a bundle on any machine (including a fresh clone) and exits nonzero on any mismatch with a typed failure (corrupt_json, unsupported_format_version, schema_mismatch, receipt_hash_mismatch, missing_artifact, digest_mismatch, path_escape).
Archive old evidence bundles [--dry-run]
Args: --dry-run
Archives evidence bundles older than max_age_days (config, default 90) or beyond max_bundles cap (config, default 1000). --dry-run previews which bundles would be archived without deleting them. Applies two-tier retention: age-based first, then count-based on oldest remaining.
Run knowledge curation and hive promotion review
Run quota-bounded skill-improver consolidation and stage skill proposals
Args: --force, --respect-interval, --evaluate
Runs the same consolidation pass used by scheduled skill_improver trigger points: queue hardening, skill-improver proposal writing, and optional draft-skill generation. It never auto-activates skills. Use --respect-interval to obey the configured cadence instead of forcing a run.
Manage runtime concurrency override for plan execution [set|status|reset]
Args: set <N|preset>, status, reset
Sets, queries, or clears a session-scoped concurrency override for max_concurrent_tasks during plan execution. When set, the override takes precedence over the plan's locked execution_profile.max_concurrent_tasks. The override is session-scoped — it does not modify the plan and is cleared on session reset. While an epic is open (Epic Mode), the override is not consulted: the epic wave width (turbo.lean.max_parallel_coders, default 4) governs.
Subcommands: concurrency set — Set session concurrency to N (1-64) concurrency set — Set to preset: min (1), medium (3), max (8) concurrency status — Show effective concurrency (override, plan baseline, operational effective) concurrency reset — Clear the session concurrency override
Session-scoped — resets on new session.
Manage OpenSpec-compatible SDD artifacts and effective spec projection
Args: status|validate|project [--json] [--change <id>] [--dry-run] [--source <provider>] [--feature <id>|all] [--overwrite]
Parent command for spec-driven development artifacts. Use sdd status to inspect .swarm/spec.md plus openspec/ artifacts, sdd validate to validate OpenSpec-compatible deltas, and sdd project to materialize the effective spec into .swarm/spec.md for planning. Spec-Kit: sdd project projects ALL features with feature-scoped ids (featureId/FR-nnn) when several exist; --feature selects one (v1 bare-id output); --feature all is the explicit multi-feature alias (project only). Provider selection precedence: --source beats SWARM_SDD_SOURCE, which beats sdd.source in the config (.opencode/opencode-swarm.json or the user config), which beats auto-detection; a selection from any non-flag source is final and /swarm sdd status reports where it came from.
Show OpenSpec-compatible SDD status and effective spec source
Args: [--json]
Validate OpenSpec-compatible artifacts and effective spec projection
Args: [--json] [--change <id>]
Materialize the OpenSpec-compatible effective spec into .swarm/spec.md
Args: [--dry-run] [--overwrite] [--json] [--change <id>]
Stop the autonomous PR babysitting settling loop for this session [stop] [reason...]
Args: stop <reason...>
Human-only stop for the #2502 settling loop (triple opt-in: pr_monitor.enabled + pr_monitor.auto_pr_feedback + pr_feedback_loop.enabled). stop cancels any armed publication generation via the audited #2584 no-publish route (fail-open when nothing is armed), records a terminal cancelled state with the operator-visible reason, clears claimed-but-unsettled monitor events from the session queue via the sanctioned queue-clear primitive, and writes an atomic cleanup receipt under .swarm/pr-feedback-loop-cleanups/. Idempotent: re-running returns the same terminal without duplicating effects. Never issues new wakes; a wake already in flight may still surface in the session, but the workflow gate refuses pushes against a cancelled generation. The reason is mandatory.
Tie this worktree to a shared swarm knowledge store [name]
Args: [<name> | status]
Links the current worktree to a shared knowledge store so multiple swarms working on the same project (e.g. separate git worktrees) pool their lessons instead of each keeping an isolated .swarm/knowledge.jsonl. With no name, ties all worktrees of the same repo via the project hash; with a name, ties any worktrees/repos that use the same name. Existing local lessons are merged (deduped) into the shared store. Use /swarm link status to inspect.
Show whether this worktree shares knowledge via a link
Stop sharing swarm knowledge for this worktree [--no-copy]
Args: [--no-copy]
Unlinks the current worktree from its shared knowledge store and returns it to a local .swarm/knowledge.jsonl. By default the shared lessons are copied back into the local store (deduped) so nothing is lost; pass --no-copy to skip the copy-back.
Manually promote lesson to hive knowledge (policy-gated; --force --reason overrides with audit)
Args: --category <category>, --from-swarm <lesson-id>, --applies-to-tools <a,b>, --applies-to-agents <a,b>, --required-actions <a,b>, --forbidden-actions <a,b>, --verification-checks <a,b>, --force --reason <why>, <lesson-text>
Promotes a lesson to hive knowledge directly (--category) or via an existing swarm lesson (--from-swarm), in one cross-process policy transaction (#1847). A policy failure blocks promotion unless --force --reason "" is given (audited); an entry id alone is not authorization. Requires direct text or --from-swarm. An actionability floor (#1821) needs at least one predicate flag and one scope flag (see args), unless knowledge.promotion_require_actionable=false.
Clear swarm state files [--confirm]
Args: --confirm (required)
DELETES plan.md, plan.json, context.md, events.jsonl, run-memory.jsonl, and summaries/ from .swarm/. Stops background automation and clears in-memory queues. SAFETY: requires --confirm flag — without it, displays a warning and tips to export first. Before deleting, auto-backs up the state it removes to .swarm/reset-backups// (newest 5 kept) so it can be restored by copying the files back.
Claude Code conflict: name clash with /reset — always use the full /swarm reset form.
Clear session state while preserving plan, evidence, and knowledge
Args: --confirm=<token> (purge dirty/live lanes)
Deletes .swarm/session/state.json plus other session files; clears in-memory sessions, chains, and active-agent maps. Preserves plan, evidence, and knowledge; releases this session's pending knowledge-gate obligations (#2398); recovers coder settlements wedged on CODER_DISPATCH_IN_PROGRESS (#2268); backs up to .swarm/reset-backups/ (newest 5 kept). If a cleanup step fails, the closing guard stays closed by design, writes pause (an advisory says why), and a reset re-run or restart recovers.
Verify a git-external deliverable with pinned anchors <task_id>
Args: <task_id>
Runs the task's pinned read-only git evidence_anchors (issue #3422) inside the project root and records the durable external-evidence bundle that admits completion — the in-machine exit for tasks whose deliverable (commit/push, gh ops) can never produce a coder settlement. Fail-closed: the plan task must declare evidence_class external_git with 1..16 anchors (expect exact / expect_prefix non-empty), every anchor runs as a bounded no-shell argv spawn (stdin ignored, 10s per anchor, 30s total; output over the 4096-char evidence bound refuses the anchor rather than truncating it), and only positively-known read-only git subcommands/flags (rev-list, log, rev-parse, show, diff) are admitted. Undeclared tasks, mismatched anchors, and non-read-only commands refuse exactly as the completion gate does. Declaration changes revoke stale proofs (a fresh attest is then required). See docs/commands.md and docs/plan-durability.md.
Recover wedged coder settlements [task_id] [--force]
Args: [task_id] [--force]
Settles stale coder-settlement WALs in .swarm/coder-settlements/ — the CODER_DISPATCH_IN_PROGRESS wedge where a dispatch's completion never fired (issue #2268). Safe mode recovers settlements whose owner process is gone. --force also releases ownership keys held by this process: use only when no dispatch is genuinely running (a late completion then reports CODER_SETTLEMENT_IDEMPOTENCY_CONFLICT, safe to ignore). Never interrupts another live OpenCode process. Also repairs tasks wedged at coder_delegated with unattributed green pre_check evidence — the post-reset TASK_WORKFLOW_STAGE_A_REQUIRED wedge — and the settlement-wedge class (issue #2828): a task whose workflow drifted to idle or blocked while a COMMITTED accepted coder settlement and green post-settlement pre-check evidence still justify Stage A gets the missing stage_a_passed written directly, with a settlementRecovery marker and a stage_a_repair audit event in .swarm/events.jsonl; the architect-side audited escape hatch for the same receipts is the recover_stage_a_task tool. Both recovery surfaces also refresh the invoking session's in-memory task workflow view, so a blocked-start wedge does not survive the recovery in the session that ran it (#3043). Note that --force affects only in-process settlement-WAL ownership and does not override Stage A wedge-classification refusals. Pass [task_id] to scope both phases to one task. Diagnose and repair emit per-category status explanations (missing/stale/ambiguous/corrupt/live_wedge/settlement_wedge) with shell-correct invocation guidance per host — see docs/troubleshooting/recovery-runbook.md (#2665). Human-only.
Restore swarm state or project files to a checkpoint
Args: <phase-number|label|list-number> [--confirm <token>] [--yes]
Restores legacy .swarm/ phase checkpoints from checkpoints/phase- when present; otherwise named git checkpoints from .swarm/checkpoints.json. SAFETY (#2946): a restore that would DESTROY uncommitted work previews first and issues a 15-minute --confirm token; re-run with that token (or --yes) to execute. Every executing restore backs up the destroyed bytes to .swarm/rollback-backups/ (newest 5). Clean trees stay single-call. Bare invocation lists checkpoints.
Retrieve full output from a summary
Args: <summary-id>
Loads the full tool output that was previously summarized (referenced by IDs like S1, S2). Use when you need the complete output instead of the truncated summary.
Toggle Turbo Mode strategy for the active session [on|off|lean|standard|status]
Args: on, off, lean, standard, status
Toggles Turbo Mode for the current session. Supports two strategies:
Standard turbo — Bypassed: phase_complete Gates 1-5 (completion-verify, drift-verifier, hallucination-guard, mutation-gate, phase-council). Still enforced: Stage A (lint, imports, pre_check_batch); Stage B (reviewer + test_engineer), exactly as without Turbo; the planned-tasks refusal (phase_complete refuses while planned tasks are unfinished, including under Turbo, #3770); Gate 5b (architecture-supervisor); Gate 6 (final-council); Gate 7 (full-auto). Lean turbo — parallel lane execution with per-lane reviewer gates and file-lock conflict detection. Bypassed: phase_complete Gates 1-5 (completion-verify, drift-verifier, hallucination-guard, mutation-gate, phase-council). Still enforced: Stage A (lint, imports, pre_check_batch); Stage B (reviewer + test_engineer), exactly as without Turbo; the planned-tasks refusal (phase_complete refuses while planned tasks are unfinished, including under Turbo, #3770); Gate 5b (architecture-supervisor); Gate 6 (final-council); Gate 7 (full-auto).
Subcommands: turbo on — enable turbo (uses lean when config turbo.strategy is "lean", otherwise standard) turbo off — disable all turbo modes turbo lean on — enable Lean Turbo explicitly turbo lean off — disable Lean Turbo turbo lean — toggle Lean Turbo on/off turbo standard on — force standard turbo (disables lean even if config says lean) turbo standard off — disable all turbo modes (standard + lean) turbo status — show detailed status including active strategy and lanes
Epic Mode is not a Turbo strategy: start it with /swarm epic start (it enables neither Lean nor Turbo, and per-task QA is never waived). turbo epic [on|off] replies with that redirect and changes nothing. While an epic is open, every Turbo-enabling subcommand is refused (epic-open) until /swarm epic close; turning Turbo off always works.
Session-scoped — resets on new session.
Control Full-Auto Mode for the active session [on [mode]|off|exit|status|retry-oversight|resume|abort]
Args: on [assisted|supervised|strict], off|exit, status, retry-oversight, resume, abort
First-class toggle for Full-Auto Mode — a critic gate reviewing escalations on your behalf (the architect still plans and delegates; it never executes tasks itself). No config-level enablement is required: "on" activates immediately (unless full_auto.locked is true in config), "off" disarms the run (back to interactive operation), "status" reports the durable run state. An optional mode after "on" overrides full_auto.mode for this run (the override holds until the run pauses or ends; resume re-derives from live config, so on strict resumes supervised under default config): assisted (critic on policy escalations only), supervised (default — risky/high-impact actions reviewed), strict (ALL plan mutations reviewed). While active, the critic answers architect questions and reviews phase boundaries, delegations, and risky actions; only ESCALATE_TO_HUMAN verdicts halt for your input. retry-oversight performs a transport-only health probe for an infrastructure/deadline pause; it never replays the denied action. resume runs the same on preflight (readable config; full_auto.locked refuses), then requires a recent matching probe and no active recovery blockers. abort terminates the durable run immediately. Run state is durable (.swarm/full-auto-state.json) and survives restarts; a bare toggle flips the current state. Composes with an open epic (Epic Mode): both the Full-Auto phase approval and the epic_phase_readiness gate apply at phase_complete.
Write a retrospective evidence bundle for a completed phase
Args: <json: {phase, summary, task_count, task_complexity, ...}>
Writes retrospective evidence bundle to .swarm/evidence/retro-{phase}/evidence.json. Required JSON: phase, summary, task_count, task_complexity, total_tool_calls, coder_revisions, reviewer_rejections, test_failures, security_findings, integration_issues. Optional: lessons_learned (max 5), top_rejection_reasons, task_id, metadata.
List knowledge entries
Migrate knowledge entries to the current format
Args: <directory>
One-time migration from .swarm/context.md SME cache to .swarm/knowledge.jsonl. Skips if sentinel file .swarm/.knowledge-migrated exists, if context.md is absent, or if context.md is empty. Reports entries migrated, dropped (validation/dedup), and total processed.
Move a knowledge entry to quarantine [reason]
Args: <entry-id> [reason]
Moves a knowledge entry to quarantine with optional reason string (defaults to "Quarantined via /swarm knowledge quarantine command"). Validates entry ID format (1-64 alphanumeric/hyphen/underscore). Quarantined entries are excluded from knowledge queries.
Restore a quarantined or archived knowledge entry
Args: <entry-id>
Restores a quarantined or archived knowledge entry back to the active knowledge store by ID. Dispatches by current status: an 'archived' entry is restored to its pre-archive status; a 'quarantined' entry is restored from the quarantine sidecar. Validates entry ID format (1-64 alphanumeric/hyphen/underscore).
Human-only exact-ID quarantine of hive-store entries with backup and rollback
Args: <preview|commit|rollback|status> ...
Issue #2033 operator maintenance for the machine-global hive knowledge store. preview <id>[,<id>...] shows exact candidate IDs with per-line hashes, provenance, status, and a store fingerprint, and issues a short-lived confirmation token. commit --token <t> [--reason <text>] writes and hash-verifies a complete backup plus manifest BEFORE any mutation (outside the hive lock), then re-verifies the live store against that backup inside one fast transaction (any drift — concurrent append, entry change, version bump, or duplicate-id ambiguity — aborts with no mutation and cleans up the orphaned backup), moving EXACTLY the selected entries to shared-learnings-quarantined.jsonl, with counts verified afterwards and an honestly-reported automatic restore on failure. rollback --token <token12> | --latest restores the exact original bytes idempotently. Selection is exact-ID only — never by text, substring, cohort, age, or blacklist, and never in bulk. Human-only: refused for agents via swarm_command, chat fallback, and the shell guardrail.
List unactionable knowledge entries pending hardening
Lists entries from .swarm/knowledge-unactionable.jsonl that failed the actionability gate. Shows pending entries (awaiting next hardening pass) and retire candidates (hardening failed). Use /swarm knowledge retry-hardening to reset retire candidates.
Reset retire candidates for re-hardening [id]
Args: [entry-id]
Resets the retire_candidate flag on unactionable entries so the next scheduled hardening pass re-attempts LLM enrichment. Without arguments, resets all retire candidates. With an ID prefix, resets only the matching entry.
Show Swarm memory commands
Show Swarm memory provider, JSONL, and migration status
Show pending Swarm memory proposals and rejection reasons
Args: --limit <n>
Summarize Swarm memory recall usage
Args: --limit <n>
Show Swarm memory Q-value and reward updates
Args: --limit <n>
Compact deleted, superseded, and expired scratch memories
Args: --confirm
List stale and low-utility Swarm memories
Args: --limit <n>
Export current Swarm memory to JSONL files
Run golden Swarm memory recall evaluation fixtures
Args: --json, --instruction-pairing, --fixtures <directory>, --profiles <list>, --manifest <file>
Verify the memory audit-log hash chain (tamper detection)
Args: --json
Import legacy JSONL memory into SQLite
Run the one-time legacy JSONL to SQLite migration
Summarize recent memory consolidation passes and metrics
Args: --limit <n>
Share this worktree memory across linked sibling worktrees via the cohort identity (requires memory.link.enabled). Independently opt-in from /swarm link.
Args: [name]
Show whether this worktree shares memory via a cohort link
Stop sharing memory; copies the cohort memory family back to local .swarm/memory/. The cohort store is never deleted.
Args: [--no-copy]
Manage project checkpoints [save|restore|delete|list]
Args: <save|restore|delete|list> <label> [--confirm <token>] [--yes]
save: creates named git checkpoint. restore: hard-resets tracked files to the checkpoint; when uncommitted tracked work would be destroyed it previews first and requires the --confirm token from that preview (or --yes to confirm in one step); destroyed bytes are backed up to .swarm/rollback-backups/ (#2946). delete: removes checkpoint metadata. list: shows all checkpoints with timestamps. All subcommands require a label except list.
Claude Code conflict: name clash with /checkpoint — always use the full /swarm checkpoint form.