/spec-autopilot:autopilot-docs-fixfrom spec-autopilot
Use 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.
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.
autopilot-docs-sync 产出的 .cache/spec-autopilot/drift-candidates.json<id>.patch):可直接 git apply 的 unified diff(确定性)<id>.<rule>.suggestion.md):人工评审模板(含推荐修改说明)<project>/.cache/spec-autopilot/docs-fix-patches/,需通过 apply-fix-patch.sh 在 git stash 保护下手动触发/autopilot-docs-fix scan — 扫描候选清单并生成 patches/autopilot-docs-fix apply --patch-id <id> — 应用单个 patch/autopilot-docs-fix apply --all — 批量应用所有 auto patch若 .cache/spec-autopilot/drift-candidates.json 不存在,提示先执行:
bash ${CLAUDE_PLUGIN_ROOT}/runtime/scripts/detect-doc-drift.sh \
--changed-files "<space-separated-files>"
或等待 autopilot 主流水线 Phase 7 自动触发 docs-sync。
| Rule | 类型 | 产物 | 说明 |
|---|---|---|---|
| R1 | manual | .suggestion.md | SKILL.md 改动摘要 + README 建议修改位置 |
| R2 | auto | .patch | 追加脚本名到 .dist-include 末尾(git apply --check 通过) |
| R3 | manual | .suggestion.md | CLAUDE.md 改动提醒检查版本标识 |
| R4 | manual | .suggestion.md | Phase 总览改动提醒刷新 docs/plans 流程图 |
| R5 | manual | .suggestion.md | 新 SKILL.md 提醒更新根 README 插件表格 |
bash ${CLAUDE_PLUGIN_ROOT}/runtime/scripts/generate-doc-fix-patch.sh \
--candidates-file .cache/spec-autopilot/drift-candidates.json \
--output-dir .cache/spec-autopilot/docs-fix-patches/
# 单个
bash ${CLAUDE_PLUGIN_ROOT}/runtime/scripts/apply-fix-patch.sh \
--index .cache/spec-autopilot/docs-fix-patches/INDEX.json \
--patch-id <id>
# 批量 auto
bash ${CLAUDE_PLUGIN_ROOT}/runtime/scripts/apply-fix-patch.sh \
--index .cache/spec-autopilot/docs-fix-patches/INDEX.json \
--all
# 演练
bash ${CLAUDE_PLUGIN_ROOT}/runtime/scripts/apply-fix-patch.sh \
--index .cache/spec-autopilot/docs-fix-patches/INDEX.json \
--patch-id <id> --dry-run
git stash push -u 保护 working treegit apply --check 预校验,失败立即 git stash pop 回滚type: manual patch;需 --force-manual 显式 acknowledge.cache/spec-autopilot/docs-fix-patches/INDEX.json:
{
"patches": [
{"id":"docfix-001-r2-abc12345", "type":"auto",
"target":"plugins/spec-autopilot/runtime/scripts/.dist-include",
"apply_cmd":"git apply docfix-001-r2-abc12345.patch"}
],
"source": ".cache/spec-autopilot/drift-candidates.json"
}
详见 references/patch-strategies.md。
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.Other plugins' skills for the same job