thinking-partner
A deterministic thinking partner that challenges assumptions and applies mental models to sharpen decisions, solve problems, and think more clearly. Use this…
Systematic debugging with hypothesis testing. Persistent across sessions.
$ npx -y skills add SienkLogic/plan-build-run --skill debug --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/debugContext preview
The summary Claude sees to decide when to auto-load this skill.
Systematic debugging with hypothesis testing. Persistent across sessions.
name: debug description: "Systematic debugging with hypothesis testing. Persistent across sessions." allowed-tools: Read, Write, Edit, Bash, Glob, Grep, Task, AskUserQuestion argument-hint: "[issue description]"
**STOP — DO NOT READ THIS FILE. You are already reading it. This prompt was injected into your context by Claude Code's plugin system. Using the Read tool on this SKILL.md file wastes ~7,600 tokens. Begin executing Step 1 immediately.**
**Before ANY tool calls**, display this banner:
╔══════════════════════════════════════════════════════════════╗ ║ PLAN-BUILD-RUN ► DEBUGGING ║ ╚══════════════════════════════════════════════════════════════╝
Then proceed to Step 1.
You are running the **debug** skill. Your job is to run a structured, hypothesis-driven debugging session that persists across conversations. You track every hypothesis, test, and finding in a debug file so work is never lost.
This skill **spawns Task(subagent_type: "pbr:debugger")** for investigation work.
---
---
Reference: `skills/shared/context-budget.md` for the universal orchestrator rules. Reference: `skills/shared/agent-type-resolution.md` for agent type fallback when spawning Task() subagents.
Additionally for this skill:
---
**Debug systematically, not randomly.** Every investigation step must have a hypothesis, a test, and a recorded result. No "let me just try this" — every action has a reason and is documented.
---
**CRITICAL (no hook) -- DO NOT SKIP: Create debug directory before any file writes.**
Before any file operations, ensure both directories exist by running:
mkdir -p .planning/debug
This handles the case where neither `.planning/` nor `.planning/debug/` exist yet (debug can be run before other skills that create `.planning/`). Do NOT skip this step — writing files to a non-existent directory will fail.
**Load depth profile:** Run `pbr-tools config resolve-depth` to get `debug.max_hypothesis_rounds`. If the command fails (no config.json or CLI error), default to 5 rounds. Initialize a round counter at 0. This counter increments each time a continuation debugger is spawned.
Scan `.planning/debug/` for existing debug files:
.planning/debug/
{NNN}-{slug}.md # Each debug session is a fileRead each file's frontmatter to check status:
**If active sessions found:**
**CRITICAL -- DO NOT SKIP**: Present the following choice to the user via AskUserQuestion before proceeding: Use the **debug-session-select** pattern from `skills/shared/gate-prompts.md`: question: "Found active debug sessions. Which would you like?"
Generate options dynamically from active sessions:
Handle responses:
**If no active sessions found:**
**Trigger:** If `$ARGUMENTS` contains `--from-uat`, OR if no arguments provided and UAT.md gaps exist for the current phase.
When triggered:
1. Read the current phase's VERIFICATION.md (or UAT.md if it exists):
2. For each gap entry, extract:
3. Pre-fill the debug session with UAT context:
4. Skip the symptom-gathering questions in Step 3a (symptoms are already populated from UAT gaps) 5. Proceed directly to **Generate Session ID** and **Create Debug File** with the pre-filled data
**If `--from-uat` is specified but no gaps exist:**
If `$ARGUMENTS` is provided and descriptive:
If `$ARGUMENTS` is empty or minimal:
**Symptom gathering questions** (ask as plain text — these are freeform, do NOT use AskUserQuestion):
1. **Expected behavior**: "What should happen?" 2. **Actual behavior**: "What actually happens? Include error messages if any." 3. **Reprodu
Plan it. Build it. Run it. A Claude Code plugin for structured development with context-engineered agents.
Repo: SienkLogic/plan-build-run
A deterministic thinking partner that challenges assumptions and applies mental models to sharpen decisions, solve problems, and think more clearly. Use this…
Run audit, prioritize findings, auto-fix via quick tasks, test, and commit.
Review past Claude Code sessions for PBR workflow compliance and UX quality.
Run multiple phases hands-free. Chains discuss, plan, build, and verify automatically.
Manage backlog items — ideas not ready for active planning. Add, review, promote, or remove.
Start a new project. Deep questioning, research, requirements, and roadmap.