一键导入
diagnose
Root-cause analysis for reproducible bugs. Builds a hypothesis tree, runs evidence-gathering steps, narrows to the actual cause before fixing.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Root-cause analysis for reproducible bugs. Builds a hypothesis tree, runs evidence-gathering steps, narrows to the actual cause before fixing.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
Dispatch a multi-wave plan to specialist agents with audit + risk-area abort. Supports --auto-push, --auto-merge, --goal-mode for budgeted runs. NOT for writing the plan itself (that is /spec), and NOT for a single small edit with no waves — just make the edit.
Independently re-verify a completion claim in a separate context — mechanical evidence (files/tests/assertions) plus a refute-by-default semantic judge — before a wave or task is allowed to be called "done". Emits the shared verdict schema. NOT for code-style review (that is a reviewer's lane) and NOT for verifying work you authored in the same context — the verifier must be a fresh spawn.
Router over the harness skills — which skill fits your situation, and the main flow through them. NOT for performing the routed work itself — it only points; invoke the skill it names.
Upstream planning-discipline — brainstorm a feature into spec.md + plan.md under .agent/plans/<slug>/, then route to plan approval. Enforced by the spec-gate tool boundary, not prompt coercion. NOT for trivial/test/doc-only edits (the gate scopes those out), and NOT for executing an already-approved plan (that is /supervise).
Commits staged changes and opens a PR. Runs gitleaks + risk-area guards before committing. Push is user-confirmed by default; --auto-push and --auto-merge are opt-in. NOT for review or verification (run those before wrapping), and NOT when nothing has changed yet — there is nothing to commit.
Agent-driven, read-only self-audit of the harness — run the machine integrity layer once as a dry-run, present a per-check pass/fail table, cite the P1-1 doc-reality result, and for any failure give root-cause + fix + backlog follow-up. Consumes the machine gates; it does not reimplement them. NOT for auditing a consumer project's own codebase (use that project's test suite), and NOT for applying fixes — this skill observes and reports only.
基于 SOC 职业分类
| name | diagnose |
| description | Root-cause analysis for reproducible bugs. Builds a hypothesis tree, runs evidence-gathering steps, narrows to the actual cause before fixing. |
| when_to_use | User reports a bug that's reproducible but cause is unclear. NOT for fast stack-trace fixes (use a debugger instead). |
| tools | Read, Bash, Grep, Glob, Edit |
Find the root cause of a bug — the deepest thing you can change so the symptom doesn't recur. Don't fix until you've confirmed the cause.
List 2-5 candidate causes. For each:
Write the list down (in your working memory or a scratch file). Don't hold it in conversation context only — that gets lost.
Run one targeted probe per hypothesis:
// DIAGNOSE — remove before commit).After each probe: which hypotheses are still standing? Cross off the rest.
When one hypothesis stands:
Now write the fix:
Bug: <one-line>
Repro: <command / test that fails>
Hypotheses:
H1: <…> — RULED OUT (evidence: <…>)
H2: <…> — RULED OUT
H3: <…> — CONFIRMED (evidence: <…>)
Root cause: <…>
Fix: <files touched, smallest diff>
Regression test: <path>:<test-name>
Verification: <repro now> / <test> / <suite>
DIAGNOSE
marker before committing.