diagnose
Analyze a bug from error logs or reproduction steps, fix it, and create a GH Issue + PR.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Analyze a bug from error logs or reproduction steps, fix it, and create a GH Issue + PR.
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Pre-meeting B2B account research. Produces a structured account brief (company overview, recent news, tech stack, decision structure hypothesis, hypothesized pain points, approach strategy). Use before /discovery-prep.
Generates a Discovery meeting plan from an account brief — SPIN questions, MEDDIC checklist, hypothesized pain points with verification questions, objection prep, time-boxed agenda. Run after /account-brief, before the meeting.
Generates post-meeting follow-up assets — customer-facing email draft, internal action list, CRM update fields, account_brief updates, champion status tracking. Run after any sales meeting.
Converts sales-written meeting notes (discovery type) into a PRD draft for PoC building, and updates account_brief.md with newly learned facts. The bridge between sales discovery and engineering PoC. Run after a discovery meeting, before /kickoff.
Generates a closing proposal from demo meeting notes + the actual PoC + account brief. Business-value first; technical specs in appendix. Run after a demo meeting, before contract negotiation.
Analyzes and critiques business viability. Use after /brainstorm and before /prd.
| name | diagnose |
| description | Analyze a bug from error logs or reproduction steps, fix it, and create a GH Issue + PR. |
| argument-hint | [error description or file path] |
| disable-model-invocation | false |
| allowed-tools | Read, Glob, Grep, Write, Edit, Bash(bash scripts/checkpoint.sh *), Bash(bash scripts/wt_setup.sh *), Bash(bash scripts/wt_cleanup.sh *), Bash(bash scripts/registry_edit.sh *), Bash(bash scripts/flock_edit.sh *), Bash(bash scripts/worktree.sh *), Bash(python3 scripts/*), Bash(git *), Bash(gh *), Bash(pytest *), Bash(npm *), Bash(bash ${CLAUDE_PLUGIN_ROOT}/scripts/*), Bash(python3 ${CLAUDE_PLUGIN_ROOT}/scripts/*) |
Kit root: ${CLAUDE_PLUGIN_ROOT}
scripts/ dir): prefix every kit script command with it, e.g.
bash <kit-root>/scripts/checkpoint.sh …. Absolute paths also work from worktrees.${…} placeholder above → standalone layout: run commands as written.Run these checks silently at the start. Use results to adapt behavior:
[ -f issues.md ] — if true, this project uses the sprint system. Respect issue numbering and STATUS.md.[ -f docs/sprint_state.md ] — if true and Status shows running, a sprint is active. Be aware of parallel work in worktrees.[ -f docs/prd_digest.md ] — if true, read it for quick project context before starting.gh auth status before any GitHub operation.Every phase has a checkpoint. Run the verification command and check the exit code.
ADVISORY: line (advisory gate): report the gap, self-correct, continue.
Standard prefix:bash scripts/checkpoint.sh
Append --skill <name> --phase <phase> --issue <ID> for the specific check.
checkpoint.sh resolves the main repo root internally, so the command stays
a single prefix-matchable form (safe to allowlist as Bash(bash scripts/checkpoint.sh *)).
Pipeline skills operate in git worktrees to isolate changes from main.
WT="$(bash scripts/wt_setup.sh <branch>)" — creates the
worktree via scripts/worktree.sh create and writes .claude-kit/freeze-dir.txt
inside it in a single step.bash scripts/worktree.sh rootbash scripts/wt_cleanup.sh <branch> — cd's to main root
inside a subshell, then removes the worktree (never leaves CWD dangling).
All file operations happen inside $WT/. Shared files live on main only.Shared files (issues.md, STATUS.md, CHANGELOG.md) are managed on main only.
Always use registry_edit.sh for concurrent-safe writes — it resolves the
main repo root internally and delegates to flock_edit.sh:
bash scripts/registry_edit.sh issues.md -- bash -c '<update command>'
Never commit these files to feature branches.
Every phase in this skill that has a CHECKPOINT block must be verified. Run the verification command after completing each phase. Blocking gates exit non-zero on failure: STOP immediately, report, do NOT proceed. Advisory gates always exit 0 and print an ADVISORY: line on failure: report the gap, self-correct, then continue (ISSUE-031). Never skip running either tier.
Slug convention: After creating the worktree, store the branch slug (e.g., fix/bookmark-none-subscript) for use in checkpoint commands.
$ARGUMENTS is empty or blank, ask the user: "Please provide an error description, stack trace, or file path to diagnose."Steps:
gh authenticated (gh auth status).pytest to confirm no regressions. Suggest a regression test if none exists.WT="$(bash scripts/wt_setup.sh fix/<slug>)"
wt_setup.sh creates the worktree and writes the freeze marker inside
.claude-kit/freeze-dir.txt atomically. Apply the fix inside $WT/,
run tests from $WT/.CHECKPOINT — ADVISORY (report & continue) Run:
bash scripts/checkpoint.sh --skill diagnose --phase worktree --issue "$SLUG"Advisory: exits 0 even on failure, printing anADVISORY:line — report the gap, self-correct, then continue.
CHECKPOINT — MANDATORY — NEVER SKIP Run:
bash scripts/checkpoint.sh --skill diagnose --phase test --issue "$SLUG"If exit code ≠ 0: STOP immediately and report the failure. Do NOT proceed.
gh issue create --title "fix: <concise bug description>" --body "<body>"$WT/).CHECKPOINT — ADVISORY (report & continue) Run:
bash scripts/checkpoint.sh --skill diagnose --phase push --issue "$SLUG"Advisory: exits 0 even on failure, printing anADVISORY:line — report the gap, self-correct, then continue.
gh pr create --title "fix: <concise bug description>" --body "Closes #<issue_number>\n\n<details>"/review and /ship.If issues.md exists in the project root, register this work in the sprint ecosystem:
issues.md to find the next available ISSUE-NNN number.bash scripts/registry_edit.sh issues.md -- bash -c '<append issue entry>'
Issue fields:
<number><pr_url>If issues.md does not exist, skip this step silently.
gh auth status fails: stop and instruct the user to run gh auth login.bash scripts/wt_cleanup.sh <branch> for safe worktree removal —
the wrapper cd's to main root and removes the worktree in a single subshell.bash scripts/wt_cleanup.sh <branch>git push origin --delete <branch> (remote cleanup, if pushed)gh pr close <pr_number> then clean up worktree and branch as above.IMPORTANT: Never commit issues.md, STATUS.md, or CHANGELOG.md to the feature branch.
These are registry files managed only on main. Always use bash scripts/registry_edit.sh <file> -- bash -c '<update command>' — the wrapper resolves the main repo root internally.
except, empty catch).