nWave/skills/nw-spike/SKILL.md
Runs a timeboxed PROBE to validate one core assumption, then optionally PROMOTES the probe into a walking skeleton — the first e2e thin slice of the feature, committed and demo-able. Use after DISCUSS when the feature involves a new mechanism, performance requirement, or external integration.
npx skillsauth add nwave-ai/nwave nw-spikeInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Wave: SPIKE (between DISCUSS and DESIGN) | Agent: Attila (nw-software-crafter) | Command: /nw-spike
Execute a two-phase wave that turns a risky assumption into visible, iterable value as fast as possible:
/tmp/)src/ + 1 acceptance test)The PROBE answers "does the mechanism work?". The WALKING SKELETON answers "can a user see it working end-to-end?". You never throw away working validated code — you promote it and iterate.
The spike is needed when the feature introduces:
If none of the above apply, skip SPIKE and go to DESIGN.
docs/feature/{feature-id}/discuss/ (required)
user-stories.md — scope and acceptance criteriawave-decisions.md — constraints and assumptions to testdocs/feature/{feature-id}/diverge/recommendation.md (if present)Question: What is the ONE assumption you need to validate? Examples:
.git/hooks/ from a subprocess without corruption?"Question: What is the timing constraint? (Enter "none" if mechanism validation only) Examples:
Question: If this probe works, what would the thinnest end-to-end slice look like?
Capture the rough path: user-facing entry → business logic → persistence/services → user-visible output. This is not a commitment — it's context for the promotion gate later.
Throwaway validation of the assumption.
@nw-software-crafter
Execute PROBE for "{feature-description}".
Probe question: {Decision 1 answer} Performance budget: {Decision 2 answer} Target e2e path (for later): {Decision 3 answer}
Rules:
/tmp/spike_{feature_id}/. Never in src/.time.perf_counter() for timing.After probe completes:
docs/feature/{feature-id}/spike/findings.md — binary verdict (WORKS / DOESN'T WORK), timing, edge cases, design implications.Run this gate only after the probe completes and findings.md is written.
Present the user with three choices:
| Choice | When to pick | Outcome |
|---|---|---|
| PROMOTE | Probe verdict is WORKS and the mechanism is worth building on | Proceed to Phase 3 — walking skeleton |
| DISCARD | Probe verdict is WORKS but not worth pursuing (findings are enough) | Delete /tmp/spike_{feature_id}/. Commit findings.md. Hand off to DESIGN. |
| PIVOT | Probe verdict is DOESN'T WORK or revealed a better approach | Delete probe code. Annotate findings.md with the pivot. Either loop back to DISCUSS or run a second probe. |
Default: if the probe verdict is WORKS and no reason to stop, recommend PROMOTE but let the user override.
Record the promotion decision in docs/feature/{feature-id}/spike/wave-decisions.md as an explicit wave decision with rationale.
Refactor the probe into the thinnest end-to-end slice that is committed, tested, and demo-able.
@walking_skeleton @driving_port tagged scenario in tests/{test-type-path}/{feature-id}/acceptance/walking-skeleton.feature. The scenario MUST be green before hand-off.src/{production-path}/, not in /tmp/. Minimal module skeleton is fine — no premature abstractions, no features beyond the walking skeleton.feat({feature-id}): walking skeleton — {one-line description}.docs/feature/{feature-id}/spike/upstream-issues.md and stop — do not hand off to DISTILL until resolved.@nw-software-crafter
Promote probe for "{feature-description}" into a walking skeleton.
Source probe: /tmp/spike_{feature_id}/
Target driving adapter: {from Decision 3, refined with user}
Target acceptance test path: tests/{test-type-path}/{feature-id}/acceptance/walking-skeleton.feature
Rules:
/tmp/spike_{feature_id}/ after promotion.src/, not /tmp/The invoked agent MUST create a task list from its workflow phases at the start of execution using TaskCreate. Each phase becomes a task with the gate condition as completion criterion. Phase 1, Phase 2, and Phase 3 are separate task groups — Phase 3 tasks are only created if the promotion gate says PROMOTE.
/tmp/, never in src/findings.md written with binary verdict, timing, and edge caseswave-decisions.mdsrc/, committedHandoff to: nw-solution-architect (DESIGN) — DESIGN reads findings.md and the walking skeleton (if promoted) before starting. The skeleton is a fait accompli — DESIGN designs the rest of the feature around it, not in place of it.
DISTILL (next wave after DESIGN) reads the walking skeleton as a prior artifact and adds additional scenarios and integration tests on top of it — it does not write the walking skeleton from scratch.
Before completing SPIKE, produce docs/feature/{feature-id}/spike/wave-decisions.md:
# SPIKE Decisions -- {feature-id}
## Assumption Tested
- {the one question}
## Probe Verdict
- {WORKS / DOESN'T WORK}: {one-line summary}
## Promotion Decision
- {PROMOTE / DISCARD / PIVOT}: {rationale}
## Walking Skeleton (only if PROMOTE)
- Driving adapter: {entry point}
- Acceptance test: {path to .feature file}
- Commit: {commit sha of walking skeleton}
- Demo command: {how to run the skeleton}
## Design Implications
- {what DESIGN must account for based on probe results and skeleton learnings}
## Constraints Discovered
- {any new constraints from edge cases}
/nw-spike "wave-matrix -- derive feature status from pytest + filesystem"
Probe question: "Can we collect pytest markers + parse filesystem state in <5 seconds?"
Agent writes 50-line script in /tmp/spike_wave_matrix/. Result: 44 seconds (budget blown), but discovers pytest --collect-only --cache-only completes in 200 ms.
Gate: user picks PROMOTE with the cache-only approach.
Phase 3: agent refactors the probe into src/des/cli/wave_matrix.py with a wave-matrix CLI command; one acceptance test exercises subprocess.run(["wave-matrix", "--feature", "alpha"]) end-to-end and asserts the markdown output contains a row for alpha.
DESIGN now designs the rest (multi-feature aggregation, cell navigation, refresh strategy) around the already-working skeleton.
/nw-spike "cel-policy-engine -- evaluate access control expressions"
Probe question: "Can cel-python evaluate 100 policy expressions in <1 second?" Agent installs cel-python, writes evaluation loop, measures 23 ms for 100 expressions. Verdict: WORKS. Edge case: nested map access syntax differs from Go CEL. Gate: user picks DISCARD — the findings are enough, the real access-control feature is large enough to deserve its own design wave. Phase 3 skipped. Findings committed. DESIGN reads findings.md.
/nw-spike "git-hook-wiring -- install hooks via subprocess"
Probe question: "Can we write to .git/hooks/ from a Python subprocess without file corruption?"
Agent tries concurrent access, discovers that the real risk is not corruption but the existing user hook being silently overwritten.
Gate: user picks PIVOT — the real question is "how do we install alongside existing user hooks?". Findings annotated with the pivot, new probe scheduled.
docs/feature/{feature-id}/spike/
findings.md # always
wave-decisions.md # always (with promotion decision)
upstream-issues.md # only if skeleton revealed prior-wave contradictions
src/{production-path}/ # only if PROMOTE
{module}.py # minimal walking skeleton
tests/{test-type-path}/{feature-id}/acceptance/
walking-skeleton.feature # only if PROMOTE — 1 scenario, @walking_skeleton @driving_port
steps/ # only if PROMOTE
testing
Acceptance test creation methodology for the DISTILL wave. Domain knowledge for the acceptance designer agent: port-to-port principle, prior wave reading, wave-decision reconciliation, graceful degradation, and document back-propagation.
development
Cross-agent collaboration protocols, workflow handoff patterns, and commit message formats for TDD/Mikado/refactoring workflows
development
Creates a phased roadmap.json for a feature goal with acceptance criteria and TDD steps. Use when planning implementation steps before execution.
testing
Acceptance test creation methodology for the DISTILL wave. Domain knowledge for the acceptance designer agent: port-to-port principle, prior wave reading, wave-decision reconciliation, graceful degradation, and document back-propagation.