Bug fix workflow: root cause analysis → user review → regression test + fix via TDD
npx skills add https://github.com/nWave-ai/nWave --skill nw-bugfix
Wave: CROSS_WAVE
Agents: Rex (nw-troubleshooter) → selected crafter (OOP or FP per project paradigm)
End-to-end bug fix pipeline: diagnose root cause, review findings with user, then deliver regression tests that fail with the bug and pass with the fix. Ensures every defect produces a test that prevents recurrence.
INPUT: "{bug-description}"
│
├─ Phase 1: Root Cause Analysis (@nw-troubleshooter)
│ └─ /nw-root-why "{bug-description}"
│ └─ Output: RCA document with root cause chain + fix proposal
│
├─ Phase 2: User Review (INTERACTIVE — STOP here)
│ └─ Present RCA findings to user
│ └─ User confirms root cause + approves fix direction
│ └─ If user rejects → refine RCA or stop
│
└─ Phase 3: Regression Test + Fix
└─ /nw-deliver "fix-{bug-id}" — roadmap-based bugfix flow
└─ Paradigm detection determines crafter (OOP or FP)
└─ Regression test (RED) → fix (GREEN) → verify (COMMIT)
Skill loading: The troubleshooter loads its skills from ~/.claude/skills/nw-{skill}/SKILL.md:
nw-five-whys-methodology — core investigation methodologynw-investigation-techniques — systematic debugging patternsnw-post-mortem-framework — structured incident analysisInvoke @nw-troubleshooter via Agent tool:
Execute *investigate-root-cause for the following defect:
{bug-description}
Configuration:
- investigation_depth: 5
- multi_causal: true
- evidence_required: true
Produce:
1. Root cause chain (5 Whys with evidence at each level)
2. Contributing factors
3. Proposed fix with specific code changes
4. Files affected
5. Risk assessment of the fix
After the troubleshooter returns, present findings to the user. Include:
STOP and wait for user confirmation before proceeding to Phase 3.
Present the RCA findings and ask:
If user rejects:
If user approves → proceed to Phase 3.
Phase 3 dispatches the fix through the roadmap-based bugfix flow. It does
paradigm detection (reads project CLAUDE.md for ## Development Paradigm),
crafter selection (@nw-software-crafter for OOP, @nw-functional-software-crafter
for FP), DES enforcement, and reads the rigor profile from
.nwave/des-config.json.
Preparation:
fix-{kebab-case-bug-summary} (max 5 words)docs/feature/{feature-id}/deliver/ directoryDelegate to /nw-deliver:
/nw-deliver "fix-{bug-summary}"
The deliver orchestrator builds a minimal two-step roadmap:
Step 01-01: Regression test (RED)
tests/regression/{component}/ or tests/bugs/test_bug_{description}.pyStep 01-02: Fix implementation (GREEN)
The crafter handles the TDD cycle (3-phase canon RED → GREEN → COMMIT per
ADR-025) with DES monitoring.
fix(scope): description/nw-bugfix "DES hook crashes with FileNotFoundError when template schema is missing"
Phase 1: Rex traces to missing step-tdd-cycle-schema.json in plugin cache.
Phase 2: User confirms.
Phase 3: /nw-deliver "fix-missing-template-schema" → crafter writes test_bug_missing_template_schema.py (RED), adds fallback path resolution (GREEN), commits.
/nw-bugfix "Skills plugin reports success but installs zero files when source has nw-prefixed layout"
Phase 1: Rex traces to is_public_skill() returning False for all nw-prefixed names due to ownership map key mismatch.
Phase 2: User confirms.
Phase 3: /nw-deliver "fix-ownership-map-keys" → crafter writes regression test with nw-prefixed fixture (RED), fixes ownership map keys (GREEN), commits.
/nw-bugfix "Pipeline composition breaks when filter predicate returns None"
Phase 1: Rex traces to missing None guard in compose() function.
Phase 2: User confirms.
Phase 3: /nw-deliver "fix-compose-none-guard" → paradigm detected as FP → @nw-functional-software-crafter writes property-based test (RED), adds None guard (GREEN), commits.
/nw-deliver./nw-refactor, not here./nw-design before fixing./nw-deliver, which handles paradigm detection, DES enforcement, and rigor profile automatically.Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.
Use when implementation is complete, all tests pass, and you need to decide how to integrate the work - guides completion of development work by presenting structured options for merge, PR, or cleanup
Use when implementing any feature or bugfix, before writing implementation code
Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes
Use when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always
Expert guidance for systematic backtesting of trading strategies. Use when developing, testing, stress-testing, or validating quantitative trading strategies. Covers "beating ideas to death" methodology, parameter robustness testing, slippage modeling, bias prevention, and interpreting backtest results. Applicable when user asks about backtesting, strategy validation, robustness testing, avoiding overfitting, or systematic trading development.
Cloud laboratory platform for automated protein testing and validation. Use when designing proteins and needing experimental validation including binding assays, expression testing, thermostability measurements, enzyme activity assays, or protein sequence optimization. Also use for submitting experiments via API, tracking experiment status, downloading results, optimizing protein sequences for better expression using computational tools (NetSolP, SoluProt, SolubleMPNN, ESM), or managing protein design workflows with wet-lab validation.
This skill should be used for time series machine learning tasks including classification, regression, clustering, forecasting, anomaly detection, segmentation, and similarity search. Use when working with temporal data, sequential patterns, or time-indexed observations requiring specialized algorithms beyond standard ML approaches. Particularly suited for univariate and multivariate time series analysis with scikit-learn compatible APIs.
Take nwave-ai/nw-bugfix from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.