gate-build
Runs configured build and test commands in tiered order. Captures output as evidence per tier. Returns PASS, FAIL, WARN, or SKIP…
Investigation-first debugging workflow. Scopes the problem, delegates root cause analysis, produces a diagnosis report, and applies fix/log/defer autonomously.
Claude Code
$ npx -y skills add Obsidian-Owl/specwright --skill sw-debug --agent claude-code
Codex
$ npx skills add Obsidian-Owl/specwright --skill sw-debug -a codex -y
Cursor
$ npx skills add Obsidian-Owl/specwright --skill sw-debug -a cursor -y
Gemini CLI
$ npx skills add Obsidian-Owl/specwright --skill sw-debug -a gemini-cli -y
GitHub Copilot
$ npx skills add Obsidian-Owl/specwright --skill sw-debug -a github-copilot -y
OpenCode
$ npx skills add Obsidian-Owl/specwright --skill sw-debug -a opencode -y
Windsurf
$ npx skills add Obsidian-Owl/specwright --skill sw-debug -a windsurf -y
name: sw-debug description: >- Investigation-first debugging workflow. Scopes the problem, delegates root cause analysis, produces a diagnosis report, and applies fix/log/defer autonomously. argument-hint: "[problem description]" allowed-tools: - Read - Write - Bash - Glob - Grep - Task
First-class debugging path. Scope the problem, investigate concurrently, diagnose with evidence, then decide: fix it now, log it, or defer. Operates autonomously, applying `protocols/decision.md` for the fix/log/defer decision.
**Stage boundary (LOW freedom):** Follow `protocols/stage-boundary.md`. Investigate and diagnose. NEVER write code, run tests, branch, or commit. Fix path: produce spec.md, handoff to `/sw-build`.
**Scope (MEDIUM freedom):**
(last failed command, error output in conversation). If genuinely undetermined, apply DISAMBIGUATION: choose the most likely problem from available context.
**Investigate (HIGH freedom):** Delegate concurrently per `protocols/delegation.md`: `specwright-researcher` (code context, call paths) and `specwright-architect` (root cause, blast radius).
**Diagnose (MEDIUM freedom):** Write `diagnosis.md`: Problem (observed vs expected), Root Cause (confidence level, file:line evidence), Blast Radius (affected / not affected), Fix Approach (high-level), Alternatives Considered. If agents return insufficient evidence: produce low-confidence diagnosis and note the gap in decisions.md.
**Decision (MEDIUM freedom):** Apply `protocols/decision.md` DISAMBIGUATION + reversibility:
spec.md, handoff to `/sw-build`.
`/sw-design`** (Type 1 — structural scope).
Record the decision in decisions.md.
**State (LOW freedom):** Follow `protocols/state.md`. Work ID: `debug-{short-description}`.
| Condition | Action | |-----------|--------| | No problem description or context | Apply DISAMBIGUATION from conversation history. Record interpretation. | | Agents return no evidence | Low-confidence diagnosis. Apply fix/log/defer per reversibility. | | Fix is architectural (>3 files) | Halt. Recommend `/sw-design`. | | Compaction during investigation | Re-run investigation; diagnosis.md rebuilt from scratch |
Craft quality software with AI discipline. Spec-driven development plugin for Claude Code and Opencode — quality gates, adversarial testing, and evidence capture.
Runs configured build and test commands in tiered order. Captures output as evidence per tier. Returns PASS, FAIL, WARN, or SKIP…
Detects leaked secrets, injection patterns, and sensitive data exposure across changed files. Uses real tooling when configured,…
Tiered semantic analysis of changed code (rg → ast-grep → OpenGrep). Detects error-path bugs structural gates miss. Findings…
Maps every acceptance criterion from the spec to implementation evidence and test evidence. Criteria without evidence fail. The…
Audits test quality — assertion strength, boundary coverage, mock discipline, error path testing. Delegates to the tester agent…
Detects unused exports, orphaned files, architecture layer violations, and circular dependencies across changed files. Delegates…
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…
Ask which skill or flow fits your situation. A router over the skills in this repo.