No slash command · from spec-autopilot
Use when the autopilot orchestrator dispatches an adversarial Critic sub-agent just before a phase gate and needs that sub-agent to score the phase artifacts against structured rubrics and emit risk-report-phase{N}.json into the change context for downstream gate prechecks. ONLY for autopilot orchestrator; not for direct user invocation.
Ships in spec-autopilot. 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.
前置条件自检:本 Skill 仅在 autopilot 编排主线程派发的独立 Critic Sub-Agent 中使用。 如果当前不是该上下文,请立即停止并忽略本 Skill。
借鉴 Devin Autofix Loop、Cursor Vuln Hunter、ASDLC Adversarial Review 的核心模式: 独立 Critic Agent + 结构化 Rubric + 闭环回灌。
check_id / severity / evidence_format,禁止自由发挥feedback-loop-inject.sh 注入后续 sub-agent 的 task envelope,形成防御纵深每个 phase gate 的 Step 0 (预检) 由 runtime/scripts/risk-scan-gate.sh 触发:
Phase N 完成 → autopilot-gate Step 0
├── 派发本 Skill 作为 Critic Sub-Agent (独立上下文)
├── 写入 openspec/changes/<change_name>/context/risk-report-phase{N}.json
├── risk-scan-gate.sh 读取报告,统计 blocking_count
└── 若 blocking_count > 0 → fail-closed,gate 拒绝放行
派发本 Skill 时,编排主线程应在 task envelope 中提供:
{
"phase": 5,
"requirement_type": "feat",
"rubric_path": "skills/autopilot-risk-scanner/references/rubrics/phase5-feat.yaml",
"artifacts_root": "openspec/changes/<change_name>/",
"report_output": "openspec/changes/<change_name>/context/risk-report-phase5.json",
"stance": "adversarial-critic"
}
Critic Agent 的工作流程:
check_idevidence_required 与 evidence_formatpassed=falseevidence 字段(精确到文件:行号)与 reasoning(最多 3 句话)参见 references/rubric-schema.md。必备字段:
{
"phase": 5,
"rubric_version": 1,
"requirement_type": "feat",
"scored_rubrics": [
{
"check_id": "P5-FEAT-001",
"severity": "block",
"passed": false,
"evidence": "tests/test_foo.sh:无对应测试",
"reasoning": "新增公共函数 foo() 在源码中存在但未被任何测试文件 import"
}
],
"blocking_count": 1,
"warning_count": 0,
"recommendation": "block_phase_advance"
}
recommendation 取值:block_phase_advance | proceed_with_warnings | proceed
| Skill | 关系 |
|---|---|
autopilot-gate | gate Step 0 调用本 Skill 作为预检;blocking_count>0 时拒绝放行 |
autopilot-dispatch | task envelope 应携带 prior_risks[],由 feedback-loop-inject.sh 从本 Skill 报告生成 |
autopilot-phase5-5-redteam | Phase 5.5 是更激进的对抗模式;本 Skill 是常规 phase 级 Critic |
| 脚本 | 用途 |
|---|---|
runtime/scripts/risk-scan-gate.sh | gate Step 0 预检入口,读取报告并决策放行/拦截 |
runtime/scripts/feedback-loop-inject.sh | 将 severity≥warn 条目注入下游 task envelope |
所有由本 Skill 拦截、最终被人工或 Phase 5.5 复现的真实事故,必须以条目形式收录至
docs/regression-vault/,命名规范见 docs/regression-vault/README.md。
references/rubric-schema.md (opens in a new tab)references/rubrics/phase1-bugfix.yaml (opens in a new tab)references/rubrics/phase1-feat.yaml (opens in a new tab)references/rubrics/phase3-feat.yaml (opens in a new tab)references/rubrics/phase5-bugfix.yaml (opens in a new tab)references/rubrics/phase5-feat.yaml (opens in a new tab)references/rubrics/phase6-feat.yaml (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub stoicatom/claude-autopilot --plugin spec-autopilot22 skills in this plugin
/autopilotUse when the user requests an end-to-end spec-driven delivery pipeline (requirements → OpenSpec → implementation → testing → archive); orchestrates Phase 0-7./autopilot-agentsUse when the user wants to discover, install, list, hot-swap, or get recommendations for phase-specific autopilot sub-agents sourced from community catalogs (OMC, Anthropic official, VoltAgent, etc.), or when the autopilot setup flow needs to resolve a missing agent for a given phase./autopilot-dispatchUse when the autopilot orchestrator main thread is about to dispatch a phase-specific sub-agent via the Task tool and needs the JSON envelope contract, explicit path injection, and parameterized prompt templates. Not for direct user invocation; skip when the current context is not the autopilot orchestrator./autopilot-docs-fixUse when the user runs /autopilot-docs-fix scan|apply or asks to convert documentation drift candidates into git-applicable patches or manual suggestion templates under human confirmation./autopilot-docs-syncUse when the autopilot orchestrator or pre-commit hook needs deterministic static detection of documentation drift between SKILL.md, runtime scripts, CLAUDE.md and their README / .dist-include / root plugin table targets./autopilot-gateUse when an autopilot phase boundary is reached and gate verification + checkpoint + event emission are required before advancing to the next phase.Other plugins' skills for the same job