@gordon.gan/specflow 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/README.md +54 -32
- package/dist/cli/commands/change-phase.d.ts +1 -1
- package/dist/cli/commands/change-phase.js +1 -1
- package/dist/cli/commands/change-status.js +15 -6
- package/dist/core/archive.js +2 -2
- package/dist/core/artifact-graph/explore-status.d.ts +5 -0
- package/dist/core/artifact-graph/explore-status.js +21 -0
- package/dist/core/artifact-graph/index.d.ts +3 -1
- package/dist/core/artifact-graph/index.js +2 -1
- package/dist/core/artifact-graph/outputs.d.ts +3 -3
- package/dist/core/artifact-graph/outputs.js +24 -6
- package/dist/core/artifact-graph/state.d.ts +4 -0
- package/dist/core/artifact-graph/state.js +22 -0
- package/dist/core/templates/index.js +1 -0
- package/dist/core/templates/types.d.ts +1 -1
- package/dist/integrations/codex/adapter.js +1 -1
- package/dist/integrations/cursor/adapter.js +1 -1
- package/dist/integrations/shared/capability-evidence.js +12 -6
- package/dist/integrations/shared/command-catalog.js +4 -3
- package/dist/integrations/shared/parity-manifest.js +12 -6
- package/dist/utils/change-metadata.d.ts +1 -1
- package/dist/utils/change-metadata.js +1 -1
- package/package.json +5 -5
- package/prompts/{build → apply}/ecc-java-reviewer.md +1 -1
- package/prompts/{build → apply}/language-router.md +6 -6
- package/prompts/{build → apply}/phase-a-plan.md +14 -14
- package/prompts/{build → apply}/phase-b-execute.md +17 -17
- package/prompts/{build → apply}/phase-b-review.md +2 -2
- package/prompts/{build → apply}/phase-b-worktree.md +3 -3
- package/prompts/{build → apply}/plan-document-reviewer.md +6 -6
- package/prompts/{build → apply}/tdd.md +3 -3
- package/prompts/{done → archive}/branch-finish.md +4 -4
- package/prompts/explore/explore-session.md +152 -0
- package/prompts/fix/debug.md +2 -2
- package/prompts/{plan → propose}/design-draft.md +1 -1
- package/prompts/{plan → propose}/proposal.md +30 -0
- package/prompts/{plan → propose}/specs.md +1 -1
- package/prompts/{plan → propose}/tasks-draft.md +9 -9
- package/prompts/reference/specflow/example-design.md +19 -19
- package/prompts/reference/superpowers/anthropic-best-practices.md +6 -6
- package/prompts/reference/superpowers/codex-tools.md +1 -1
- package/prompts/refine/brainstorm.md +15 -15
- package/prompts/refine/design-output.md +1 -1
- package/prompts/refine/spec-document-reviewer.md +1 -1
- package/prompts/review/code-review.md +4 -4
- package/prompts/shared/code-reviewer-prompt.md +1 -1
- package/prompts/shared/executing-plans.md +12 -12
- package/prompts/shared/implementer-prompt.md +3 -3
- package/prompts/test/verification.md +1 -1
- package/prompts/verify/verification.md +3 -3
- package/schemas/specflow/schema.yaml +8 -1
- package/skills/{specflow-build → specflow-apply}/SKILL.md +12 -12
- package/skills/{specflow-done → specflow-archive}/SKILL.md +5 -5
- package/skills/specflow-explore/SKILL.md +102 -0
- package/skills/specflow-fix/SKILL.md +2 -2
- package/skills/{specflow-plan → specflow-propose}/SKILL.md +38 -11
- package/skills/specflow-refine/SKILL.md +4 -4
- package/skills/specflow-scan/SKILL.md +2 -2
- package/skills/specflow-verify/SKILL.md +1 -1
- package/templates/explore.md +89 -0
- /package/prompts/{build → apply}/ecc-go-reviewer.md +0 -0
- /package/prompts/{build → apply}/ecc-kotlin-reviewer.md +0 -0
- /package/prompts/{build → apply}/ecc-python-reviewer.md +0 -0
- /package/prompts/{build → apply}/ecc-rust-reviewer.md +0 -0
- /package/prompts/{build → apply}/ecc-typescript-reviewer.md +0 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
---
|
|
2
|
-
name: specflow-
|
|
2
|
+
name: specflow-archive
|
|
3
3
|
description: "Archive change + merge specs + git branch cleanup"
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
# SpecFlow:
|
|
6
|
+
# SpecFlow: Archive
|
|
7
7
|
|
|
8
8
|
> **HARD GATE**: Tests must pass before archive options are presented.
|
|
9
9
|
|
|
@@ -11,11 +11,11 @@ description: "Archive change + merge specs + git branch cleanup"
|
|
|
11
11
|
|
|
12
12
|
- An active change must exist with completed implementation.
|
|
13
13
|
- `specflow` CLI must be available on PATH.
|
|
14
|
-
- **Phase must be `built`** in `.specflow.yaml`. This is set automatically when `/specflow:
|
|
14
|
+
- **Phase must be `built`** in `.specflow.yaml`. This is set automatically when `/specflow:apply` Phase B completes. `specflow change archive` refuses to archive changes whose phase is not `built` unless the caller passes `--force` explicitly. Do NOT pass `--force` from this skill — the flag is reserved for explicit user discretion. If archive fails with a phase check error, route the user back to `/specflow:apply` to complete the missing phase transition rather than forcing past the guard.
|
|
15
15
|
|
|
16
16
|
## Stage 1: Test Gate
|
|
17
17
|
|
|
18
|
-
Run the project test suite for all affected modules. If implementation was done in a git worktree (common after `/specflow:
|
|
18
|
+
Run the project test suite for all affected modules. If implementation was done in a git worktree (common after `/specflow:apply`), run tests inside that worktree.
|
|
19
19
|
|
|
20
20
|
If tests fail:
|
|
21
21
|
- Report failures to the user.
|
|
@@ -30,7 +30,7 @@ All tests must pass. Only proceed once green.
|
|
|
30
30
|
|
|
31
31
|
If implementation happened on a feature branch / worktree, finish the branch FIRST so the main branch is clean before `specflow change archive` writes its outputs.
|
|
32
32
|
|
|
33
|
-
Read the file at `.claude/specflow/prompts/
|
|
33
|
+
Read the file at `.claude/specflow/prompts/archive/branch-finish.md` and follow its instructions to:
|
|
34
34
|
- Detect the base branch
|
|
35
35
|
- Present 4 options to the user:
|
|
36
36
|
1. **Merge to base branch** — merge the feature branch (no-ff or squash), delete branch, remove worktree
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: specflow-explore
|
|
3
|
+
description: "Think-before-propose exploration — problem space, options, scope (OpenSpec explore + Superpowers brainstorming)"
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# SpecFlow: Explore
|
|
7
|
+
|
|
8
|
+
> **HARD GATE**: User must confirm explored direction before handoff to propose.
|
|
9
|
+
> **NOT refine**: From-scratch exploration when requirements are fuzzy. Refine attacks existing propose artifacts.
|
|
10
|
+
|
|
11
|
+
## Purpose
|
|
12
|
+
|
|
13
|
+
Explore is the **think-before-propose** pass: investigate the problem, read relevant code, compare options, and narrow scope — then capture the outcome in `explore.md` for `/specflow:propose` to consume.
|
|
14
|
+
|
|
15
|
+
Integrates:
|
|
16
|
+
|
|
17
|
+
- **OpenSpec `/opsx:explore`** — conversation-first, read codebase, compare tradeoffs, no contract artifacts
|
|
18
|
+
- **Superpowers `brainstorming`** — one-question-at-a-time, 2–3 options with pros/cons, YAGNI, recommended direction
|
|
19
|
+
|
|
20
|
+
## When to Use
|
|
21
|
+
|
|
22
|
+
Use explore when:
|
|
23
|
+
|
|
24
|
+
- You know the problem but not the solution
|
|
25
|
+
- Requirements are fuzzy or scope is uncertain
|
|
26
|
+
- You need to investigate the codebase before committing to a change
|
|
27
|
+
- You want to compare architectural options with tradeoffs
|
|
28
|
+
|
|
29
|
+
Skip explore when you already know exactly what to build — run `/specflow:propose` directly.
|
|
30
|
+
|
|
31
|
+
## Prerequisites
|
|
32
|
+
|
|
33
|
+
- `specflow/` exists (suggest `specflow init` if missing)
|
|
34
|
+
- `specflow` CLI available on PATH
|
|
35
|
+
|
|
36
|
+
## Stage 1: Create or Reuse Change
|
|
37
|
+
|
|
38
|
+
If no active change directory exists for this work:
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
specflow change new <name>
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
The CLI sets `phase=plan` in `.specflow.yaml`. Explore does not change phase — `explore.md` with `Status: confirmed` signals that exploration completed.
|
|
45
|
+
|
|
46
|
+
If `explore.md` already exists and is confirmed, suggest `/specflow:propose` instead of re-exploring unless the user wants to revise.
|
|
47
|
+
|
|
48
|
+
If `proposal.md` already exists, explore is too late — suggest `/specflow:refine` for deepening.
|
|
49
|
+
|
|
50
|
+
## Also Valid: Re-explore Mid-Change
|
|
51
|
+
|
|
52
|
+
If stuck during `/specflow:apply` or `/specflow:refine` on a sub-problem, run explore again for that scoped decision. Update `explore.md` with the new findings, confirm direction, then return to the paused workflow. Do NOT skip refine or apply phase gates for the main change.
|
|
53
|
+
|
|
54
|
+
## Stage 2: Run Exploration Session
|
|
55
|
+
|
|
56
|
+
Read the file at `.claude/specflow/prompts/explore/explore-session.md` and follow its instructions.
|
|
57
|
+
|
|
58
|
+
Key behaviors:
|
|
59
|
+
|
|
60
|
+
1. **Bring the problem, not the solution** — redirect premature solutioning
|
|
61
|
+
2. **Read the codebase** on the relevant path before recommending
|
|
62
|
+
3. **Ask clarifying questions** one at a time (Superpowers style)
|
|
63
|
+
4. **Propose 2–3 approaches** with tradeoffs and a recommendation
|
|
64
|
+
5. **Allow bail-out** if the idea is not worth building
|
|
65
|
+
|
|
66
|
+
Do NOT write proposal, specs, design, tasks, or implementation code during explore.
|
|
67
|
+
|
|
68
|
+
## Stage 3: Write explore.md
|
|
69
|
+
|
|
70
|
+
Save to: `specflow/changes/<name>/explore.md`
|
|
71
|
+
|
|
72
|
+
Start from the template at `.claude/specflow/templates/explore.md` (package source: `templates/explore.md`). Use the exact section structure defined in `explore-session.md`. Set `Status: draft` while iterating; set `Status: confirmed` only after the user confirms in Stage 4.
|
|
73
|
+
|
|
74
|
+
## Gate: Direction Confirmation (HARD GATE)
|
|
75
|
+
|
|
76
|
+
Present a concise summary:
|
|
77
|
+
|
|
78
|
+
- Problem in one line
|
|
79
|
+
- Recommended direction
|
|
80
|
+
- MVP scope and non-goals
|
|
81
|
+
- Suggested capabilities for propose
|
|
82
|
+
|
|
83
|
+
Ask explicitly:
|
|
84
|
+
|
|
85
|
+
> "Confirm this explored direction for handoff to `/specflow:propose`?"
|
|
86
|
+
|
|
87
|
+
Do NOT mark `Status: confirmed` or suggest propose until the user explicitly confirms.
|
|
88
|
+
|
|
89
|
+
## Stage 4: Handoff
|
|
90
|
+
|
|
91
|
+
On confirmation:
|
|
92
|
+
|
|
93
|
+
1. Update `explore.md` → `Status: confirmed`
|
|
94
|
+
2. Tell the user to run `/specflow:propose` (same change name)
|
|
95
|
+
3. Explain that propose will read `explore.md` and skip Q&A already resolved there
|
|
96
|
+
|
|
97
|
+
## Not Covered by Explore
|
|
98
|
+
|
|
99
|
+
- No proposal/specs/design/tasks (propose owns those)
|
|
100
|
+
- No multi-round artifact attack (refine owns that)
|
|
101
|
+
- No implementation (apply owns that)
|
|
102
|
+
- No CLI beyond `change new` (explore is AI-orchestrated)
|
|
@@ -34,7 +34,7 @@ Perform root-cause analysis:
|
|
|
34
34
|
|
|
35
35
|
## Stage 4: TDD Fix
|
|
36
36
|
|
|
37
|
-
Read the file at `.claude/specflow/prompts/
|
|
37
|
+
Read the file at `.claude/specflow/prompts/apply/tdd.md` and follow its instructions.
|
|
38
38
|
|
|
39
39
|
1. Write a failing test that reproduces the bug
|
|
40
40
|
2. Implement the minimal fix to pass the test
|
|
@@ -63,7 +63,7 @@ If the fix addresses a genuinely new scenario that existing specs did not cover,
|
|
|
63
63
|
|
|
64
64
|
Before archive, invoke `specflow change phase fix-<desc> --set built` to mark the fix as built.
|
|
65
65
|
|
|
66
|
-
Rationale: a fix change is created with `phase=plan` (same as any other change) but the fix flow covers the equivalent of the
|
|
66
|
+
Rationale: a fix change is created with `phase=plan` (same as any other change) but the fix flow covers the equivalent of the propose → refine → apply pipeline end-to-end inside Stages 3–6 (debug → TDD → review → verify). Archive rejects non-`built` phases unless `--force` is passed, so setting the phase explicitly here keeps the guard meaningful without needing `--force`.
|
|
67
67
|
|
|
68
68
|
### Stage 7b: Run Archive
|
|
69
69
|
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
|
-
name: specflow-
|
|
2
|
+
name: specflow-propose
|
|
3
3
|
description: "First-iteration deep analysis -- proposal + specs + design + tasks"
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
# SpecFlow:
|
|
6
|
+
# SpecFlow: Propose
|
|
7
7
|
|
|
8
8
|
> **HARD GATE**: User must confirm proposal before specs generation.
|
|
9
9
|
|
|
10
10
|
## Purpose
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
Propose is the **first-iteration deep-analysis pass**: in a single invocation it produces all four change artifacts (`proposal.md`, delta `specs/`, `design.md`, `tasks.md`). The design and tasks are substantive first drafts — not placeholders — but `/specflow:refine` will later rewrite them across multiple rounds of iteration, and `/specflow:apply` Phase A will regenerate `tasks.md` under strict writing-plans rules.
|
|
13
13
|
|
|
14
14
|
Treat every artifact here as "v1, to be iterated on" — depth matters, but so does moving through all four stages in one pass.
|
|
15
15
|
|
|
@@ -18,6 +18,33 @@ Treat every artifact here as "v1, to be iterated on" — depth matters, but so d
|
|
|
18
18
|
- `specflow/specs/` directory should exist, indicating this is a specflow-initialized project. For a brand-new greenfield change with no existing specs, proceed — the prompt handles that case. If `specflow/` itself does not exist, suggest running `specflow init` first.
|
|
19
19
|
- `specflow` CLI must be available on PATH.
|
|
20
20
|
|
|
21
|
+
## Stage 0: Explore Handoff (when explore.md exists)
|
|
22
|
+
|
|
23
|
+
Before creating a new change or generating a proposal, check for an existing exploration artifact:
|
|
24
|
+
|
|
25
|
+
```bash
|
|
26
|
+
ls specflow/changes/<name>/explore.md 2>/dev/null
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
**If `explore.md` exists with `Status: confirmed`:**
|
|
30
|
+
|
|
31
|
+
1. Read `specflow/changes/<name>/explore.md` completely
|
|
32
|
+
2. Do NOT re-ask questions already answered in explore (Problem Space, Options, Recommended Direction, MVP, Non-Goals)
|
|
33
|
+
3. Map explore sections → proposal sections (see `prompts/propose/proposal.md` Step 1.5)
|
|
34
|
+
4. Only ask clarifying questions for items listed under **Open Questions**
|
|
35
|
+
5. Announce the handoff: "Reading confirmed explore.md — synthesizing proposal from explored direction"
|
|
36
|
+
|
|
37
|
+
**If `explore.md` exists with `Status: draft`:**
|
|
38
|
+
|
|
39
|
+
- REFUSE to proceed with proposal generation
|
|
40
|
+
- Tell the user to finish `/specflow:explore` and confirm direction first
|
|
41
|
+
|
|
42
|
+
**If requirements seem fuzzy and `explore.md` does NOT exist:**
|
|
43
|
+
|
|
44
|
+
- Suggest `/specflow:explore` first, but do NOT block if the user insists on planning directly
|
|
45
|
+
|
|
46
|
+
**If `proposal.md` already exists:** skip Stage 0.
|
|
47
|
+
|
|
21
48
|
## Stage 1: Create Change
|
|
22
49
|
|
|
23
50
|
Run `specflow change new <name>` to initialize a new change directory.
|
|
@@ -26,7 +53,7 @@ The CLI automatically sets `phase=plan` in `.specflow.yaml` on creation (no sepa
|
|
|
26
53
|
|
|
27
54
|
## Stage 2: Generate Proposal
|
|
28
55
|
|
|
29
|
-
Read the file at `.claude/specflow/prompts/
|
|
56
|
+
Read the file at `.claude/specflow/prompts/propose/proposal.md` and follow its instructions.
|
|
30
57
|
|
|
31
58
|
**Important**: That prompt file contains the required interactive Q&A flow, the exact proposal format (`## Why` / `## What Changes` / `## Capabilities` / `## Impact`), and the user confirmation gate. You MUST read it before writing the proposal — do not invent the format.
|
|
32
59
|
|
|
@@ -36,11 +63,11 @@ Generate the proposal document inside the change directory at `specflow/changes/
|
|
|
36
63
|
|
|
37
64
|
Present the proposal to the user.
|
|
38
65
|
**Ask the user to confirm the proposal.**
|
|
39
|
-
Do NOT proceed to specs generation until the user explicitly confirms. This is the only mandatory hard gate in the
|
|
66
|
+
Do NOT proceed to specs generation until the user explicitly confirms. This is the only mandatory hard gate in the propose flow — everything that follows flows through without interruption so the user can review the full first-iteration package at the end.
|
|
40
67
|
|
|
41
68
|
## Stage 3: Generate Specs
|
|
42
69
|
|
|
43
|
-
Read the file at `.claude/specflow/prompts/
|
|
70
|
+
Read the file at `.claude/specflow/prompts/propose/specs.md` and follow its instructions.
|
|
44
71
|
|
|
45
72
|
Generate delta specs inside the change directory at `specflow/changes/<name>/specs/<capability>/spec.md`.
|
|
46
73
|
|
|
@@ -50,7 +77,7 @@ Briefly summarize the delta specs generated. Accept a quick acknowledgement from
|
|
|
50
77
|
|
|
51
78
|
## Stage 4: Generate Design (first-iteration)
|
|
52
79
|
|
|
53
|
-
Read the file at `.claude/specflow/prompts/
|
|
80
|
+
Read the file at `.claude/specflow/prompts/propose/design-draft.md` and follow its instructions.
|
|
54
81
|
|
|
55
82
|
Generate `design.md` inside the change directory. This draft should be substantive: identify real architectural decisions, capture options considered, and record rationale. It is a first iteration — `/specflow:refine` will deepen it through multiple brainstorming rounds — but it is NOT a placeholder.
|
|
56
83
|
|
|
@@ -58,9 +85,9 @@ Generate `design.md` inside the change directory. This draft should be substanti
|
|
|
58
85
|
|
|
59
86
|
## Stage 5: Generate Tasks (first-iteration)
|
|
60
87
|
|
|
61
|
-
Read the file at `.claude/specflow/prompts/
|
|
88
|
+
Read the file at `.claude/specflow/prompts/propose/tasks-draft.md` and follow its instructions.
|
|
62
89
|
|
|
63
|
-
Generate `tasks.md` inside the change directory. Produce a substantive first-iteration task breakdown (3–8 tasks typical), ordered with dependencies. Do not write placeholders like "TBD" or "implement feature". `/specflow:
|
|
90
|
+
Generate `tasks.md` inside the change directory. Produce a substantive first-iteration task breakdown (3–8 tasks typical), ordered with dependencies. Do not write placeholders like "TBD" or "implement feature". `/specflow:apply` Phase A will rewrite this file under strict writing-plans rules, but this first draft feeds both `/specflow:refine` context and Phase A analysis.
|
|
64
91
|
|
|
65
92
|
**No gate here.** Continue directly to Stage 6.
|
|
66
93
|
|
|
@@ -71,12 +98,12 @@ Present all four artifacts to the user with clear "first-iteration" labeling:
|
|
|
71
98
|
- `proposal.md` — confirmed in Stage 2
|
|
72
99
|
- Delta `specs/` under the change directory — the contract
|
|
73
100
|
- `design.md` — **first-iteration draft**; `/specflow:refine` will deepen this across multiple rounds
|
|
74
|
-
- `tasks.md` — **first-iteration draft**; `/specflow:
|
|
101
|
+
- `tasks.md` — **first-iteration draft**; `/specflow:apply` Phase A will rewrite this under strict writing-plans rules
|
|
75
102
|
|
|
76
103
|
Make the iteration expectation explicit: the user should not treat design/tasks as final. They are deliberate first drafts produced so downstream skills have real substance to work with.
|
|
77
104
|
|
|
78
105
|
### Next Step
|
|
79
106
|
|
|
80
|
-
Suggest `/specflow:refine` to enter the multi-round refinement loop that rewrites `design.md` (and optionally updates the other artifacts) based on brainstorming. After refine completes, `/specflow:
|
|
107
|
+
Suggest `/specflow:refine` to enter the multi-round refinement loop that rewrites `design.md` (and optionally updates the other artifacts) based on brainstorming. After refine completes, `/specflow:apply` will consume the refined artifacts.
|
|
81
108
|
|
|
82
109
|
No hard gate after Stage 6 — `/specflow:refine` owns the next overall validation gate.
|
|
@@ -24,7 +24,7 @@ emits a round diff summary.
|
|
|
24
24
|
- `tasks.md`
|
|
25
25
|
- `specflow` CLI available on PATH (for `specflow validate` and the final phase transition).
|
|
26
26
|
|
|
27
|
-
If any precondition fails, stop and instruct the user to run `/specflow:
|
|
27
|
+
If any precondition fails, stop and instruct the user to run `/specflow:propose` first.
|
|
28
28
|
|
|
29
29
|
## Stage 1: Pre-loop setup
|
|
30
30
|
|
|
@@ -115,7 +115,7 @@ Only reached after Stage 5 declared convergence AND the user did not request ano
|
|
|
115
115
|
the phase as `refined`?"
|
|
116
116
|
3. On explicit confirmation: invoke `specflow change phase <name> --set refined` to
|
|
117
117
|
advance `.specflow.yaml` `phase` from `plan` to `refined`.
|
|
118
|
-
4. Suggest `/specflow:
|
|
118
|
+
4. Suggest `/specflow:apply` as the next slash command.
|
|
119
119
|
|
|
120
120
|
If the user declines to confirm and requests more exploration, treat it as a user-requested
|
|
121
121
|
extra round (loop back to Stage 2, phase stays `plan`).
|
|
@@ -123,6 +123,6 @@ extra round (loop back to Stage 2, phase stays `plan`).
|
|
|
123
123
|
## Not covered by refine
|
|
124
124
|
|
|
125
125
|
- No Phase A rewriting of `tasks.md` at writing-plans precision — that belongs to
|
|
126
|
-
`/specflow:
|
|
127
|
-
- No code scaffolding, no implementation, no worktree setup —
|
|
126
|
+
`/specflow:apply` Phase A.
|
|
127
|
+
- No code scaffolding, no implementation, no worktree setup — apply owns all of that.
|
|
128
128
|
- Refine only updates artifacts and advances phase to `refined`; it never touches code.
|
|
@@ -15,7 +15,7 @@ If the user triggers `/specflow:scan` or `$specflow-scan`, do NOT attempt to run
|
|
|
15
15
|
>
|
|
16
16
|
> 1. Run `specflow init --ide both` (or `--ide all` / `--ide codex`) if not already done (creates `specflow/` and IDE assets under `.cursor/`, `.claude/`, and/or `.agents/`).
|
|
17
17
|
> 2. Identify one capability area you are about to change (e.g. `user-auth`, `billing`).
|
|
18
|
-
> 3. Run `/specflow:
|
|
18
|
+
> 3. Run `/specflow:explore` when requirements are fuzzy, then `/specflow:propose`. Or run `/specflow:propose` directly if you already know exactly what to build. In the proposal Q&A, describe the existing behavior in the affected area — propose will generate both the delta spec for your change and an implicit first pass at the capability's contract. After the first archive, the delta becomes the main spec baseline for that capability.
|
|
19
19
|
>
|
|
20
20
|
> This is not a perfect substitute for a full code scan, but it keeps the spec-driven flow moving without waiting for v0.3."
|
|
21
21
|
|
|
@@ -43,6 +43,6 @@ Ask the user to confirm the scan results. Do NOT proceed until explicit confirma
|
|
|
43
43
|
|
|
44
44
|
### Planned Stage 3: Finalize
|
|
45
45
|
|
|
46
|
-
Once confirmed, the scan results are locked and the user can run `/specflow:
|
|
46
|
+
Once confirmed, the scan results are locked and the user can run `/specflow:propose` to begin requirements planning.
|
|
47
47
|
|
|
48
48
|
The v0.3 design rationale, scope, and risks will be captured in a dedicated `openspec` change at v0.3 planning time.
|
|
@@ -57,7 +57,7 @@ When Pass 1–3 all PASS:
|
|
|
57
57
|
|
|
58
58
|
**Pass 4 verdict rules:**
|
|
59
59
|
- Any CRITICAL finding → overall verify verdict is `FAIL`
|
|
60
|
-
- Only HIGH findings (no CRITICAL) → overall verify verdict is `PASS with warnings`; list HIGH findings and require user acknowledgement before `/specflow:
|
|
60
|
+
- Only HIGH findings (no CRITICAL) → overall verify verdict is `PASS with warnings`; list HIGH findings and require user acknowledgement before `/specflow:archive`
|
|
61
61
|
- No CRITICAL or HIGH findings → overall verify verdict remains `PASS`
|
|
62
62
|
|
|
63
63
|
## Stage 3: Report
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
# Explore: <change-name>
|
|
2
|
+
|
|
3
|
+
<!-- SOURCE: OpenSpec /opsx:explore (conversation-first, read codebase) + Superpowers brainstorming (options, YAGNI) + SpecFlow propose handoff mapping -->
|
|
4
|
+
<!-- Fill during /specflow:explore. Set Status: confirmed only after user confirms direction. -->
|
|
5
|
+
|
|
6
|
+
**Status**: draft
|
|
7
|
+
**Explored**: YYYY-MM-DD
|
|
8
|
+
|
|
9
|
+
## Problem Space
|
|
10
|
+
|
|
11
|
+
<!-- Who is affected? What breaks today? Cost of inaction if we do nothing? -->
|
|
12
|
+
<!-- Prefer problem statements ("checkout duplicates orders") over pre-committed solutions ("add Redis"). -->
|
|
13
|
+
|
|
14
|
+
**Who / pain:**
|
|
15
|
+
<!-- e.g. ops team, end users checking out -->
|
|
16
|
+
|
|
17
|
+
**Success signal:**
|
|
18
|
+
<!-- How will we know this worked? Measurable if possible. -->
|
|
19
|
+
|
|
20
|
+
## Evidence
|
|
21
|
+
|
|
22
|
+
<!-- User quotes, metrics, logs, support tickets — or tag assumptions explicitly: -->
|
|
23
|
+
<!-- Assumption — needs validation via ... -->
|
|
24
|
+
|
|
25
|
+
## What Exists Today
|
|
26
|
+
|
|
27
|
+
<!-- Summary from codebase investigation. Omit this section entirely for greenfield. -->
|
|
28
|
+
<!-- OpenSpec explore Step 2: read critical path before recommending. -->
|
|
29
|
+
|
|
30
|
+
### What I Found
|
|
31
|
+
|
|
32
|
+
<!-- Plain-language summary of relevant code, data flow, constraints -->
|
|
33
|
+
|
|
34
|
+
### Implications
|
|
35
|
+
|
|
36
|
+
<!-- Root causes, coupling, risks tied to actual code — do not guess without reading -->
|
|
37
|
+
|
|
38
|
+
## Options Considered
|
|
39
|
+
|
|
40
|
+
<!-- At least 2 genuinely different approaches (not cosmetic variants). Include YAGNI flags for nice-to-haves. -->
|
|
41
|
+
|
|
42
|
+
### Option A: <short name>
|
|
43
|
+
|
|
44
|
+
- **Pros**:
|
|
45
|
+
- **Cons**:
|
|
46
|
+
- **Best when**:
|
|
47
|
+
|
|
48
|
+
### Option B: <short name>
|
|
49
|
+
|
|
50
|
+
- **Pros**:
|
|
51
|
+
- **Cons**:
|
|
52
|
+
- **Best when**:
|
|
53
|
+
|
|
54
|
+
### Option C: <short name> (optional)
|
|
55
|
+
|
|
56
|
+
- **Pros**:
|
|
57
|
+
- **Cons**:
|
|
58
|
+
- **Best when**:
|
|
59
|
+
|
|
60
|
+
## Recommended Direction
|
|
61
|
+
|
|
62
|
+
<!-- Chosen path and why it beat alternatives. Tie rationale to Evidence / What Exists Today. -->
|
|
63
|
+
<!-- If exploration shows the idea is not worth building, say so here and stop — valid outcome. -->
|
|
64
|
+
|
|
65
|
+
## MVP Scope
|
|
66
|
+
|
|
67
|
+
<!-- Minimum slice to test the hypothesis. Smallest change that validates direction. -->
|
|
68
|
+
|
|
69
|
+
## Non-Goals
|
|
70
|
+
|
|
71
|
+
<!-- Explicit exclusions. Flag features that sound nice but are not required for the stated problem (YAGNI). -->
|
|
72
|
+
|
|
73
|
+
## Suggested Capabilities
|
|
74
|
+
|
|
75
|
+
<!-- kebab-case names for propose → proposal ## Capabilities. One bullet per capability. -->
|
|
76
|
+
- `<capability>`: <brief description>
|
|
77
|
+
|
|
78
|
+
## Open Questions
|
|
79
|
+
|
|
80
|
+
<!-- Items for plan/refine to resolve. Do not leave empty if unknowns remain. -->
|
|
81
|
+
- [ ] <question propose should ask>
|
|
82
|
+
|
|
83
|
+
## Handoff Notes
|
|
84
|
+
|
|
85
|
+
<!-- Optional hints for propose Step 1.5 mapping: -->
|
|
86
|
+
<!-- Problem Space + Evidence → proposal ## Why -->
|
|
87
|
+
<!-- Recommended Direction + MVP Scope → proposal ## What Changes -->
|
|
88
|
+
<!-- Suggested Capabilities → proposal ## Capabilities -->
|
|
89
|
+
<!-- Non-Goals + Open Questions (impact) → proposal ## Impact -->
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|