From 2a3171d66ada4ca507a034a4766af9ee9b712d0f Mon Sep 17 00:00:00 2001 From: Alex Verkhovsky Date: Sat, 4 Apr 2026 21:05:49 -0700 Subject: [PATCH] refactor(quick-dev): eliminate spec-wip.md singleton Write directly to spec-{slug}.md with status: draft instead of using a shared spec-wip.md file. Use draft status for resume detection in step-01. Removes wipFile variable from all step frontmatter and workflow initialization. Co-Authored-By: Claude Opus 4.6 (1M context) --- .../bmad-quick-dev/step-01-clarify-and-route.md | 7 +++---- .../4-implementation/bmad-quick-dev/step-02-plan.md | 5 ++--- src/bmm-skills/4-implementation/bmad-quick-dev/workflow.md | 6 +----- 3 files changed, 6 insertions(+), 12 deletions(-) diff --git a/src/bmm-skills/4-implementation/bmad-quick-dev/step-01-clarify-and-route.md b/src/bmm-skills/4-implementation/bmad-quick-dev/step-01-clarify-and-route.md index da55cb9a0..5181164c2 100644 --- a/src/bmm-skills/4-implementation/bmad-quick-dev/step-01-clarify-and-route.md +++ b/src/bmm-skills/4-implementation/bmad-quick-dev/step-01-clarify-and-route.md @@ -1,5 +1,4 @@ --- -wipFile: '{implementation_artifacts}/spec-wip.md' deferred_work_file: '{implementation_artifacts}/deferred-work.md' spec_file: '' # set at runtime for both routes before leaving this step --- @@ -21,7 +20,7 @@ Before listing artifacts or prompting the user, check whether you already know t 1. Explicit argument Did the user pass a specific file path, spec name, or clear instruction this message? - - If it points to a file that matches the spec template (has `status` frontmatter with a recognized value: ready-for-dev, in-progress, or in-review) → set `spec_file` and **EARLY EXIT** to the appropriate step (step-03 for ready/in-progress, step-04 for review). + - If it points to a file that matches the spec template (has `status` frontmatter with a recognized value: draft, ready-for-dev, in-progress, or in-review) → set `spec_file` and **EARLY EXIT** to the appropriate step (step-02 for draft, step-03 for ready/in-progress, step-04 for review). - Anything else (intent files, external docs, plans, descriptions) → ingest it as starting intent and proceed to INSTRUCTIONS. Do not attempt to infer a workflow state from it. 2. Recent conversation @@ -29,8 +28,8 @@ Before listing artifacts or prompting the user, check whether you already know t Use the same routing as above. 3. Otherwise — scan artifacts and ask - - `{wipFile}` exists? → Offer resume or archive. - - Active specs (`ready-for-dev`, `in-progress`, `in-review`) in `{implementation_artifacts}`? → List them and HALT. Ask user which to resume (or `[N]` for new). + - Active specs (`draft`, `ready-for-dev`, `in-progress`, `in-review`) in `{implementation_artifacts}`? → List them and HALT. Ask user which to resume (or `[N]` for new). + - If `draft` selected: Set `spec_file`. **EARLY EXIT** → `./step-02-plan.md` (resume planning from the draft) - If `ready-for-dev` or `in-progress` selected: Set `spec_file`. **EARLY EXIT** → `./step-03-implement.md` - If `in-review` selected: Set `spec_file`. **EARLY EXIT** → `./step-04-review.md` - Unformatted spec or intent file lacking `status` frontmatter? → Suggest treating its contents as the starting intent. Do NOT attempt to infer a state and resume it. diff --git a/src/bmm-skills/4-implementation/bmad-quick-dev/step-02-plan.md b/src/bmm-skills/4-implementation/bmad-quick-dev/step-02-plan.md index 361d4c566..42ca96394 100644 --- a/src/bmm-skills/4-implementation/bmad-quick-dev/step-02-plan.md +++ b/src/bmm-skills/4-implementation/bmad-quick-dev/step-02-plan.md @@ -1,5 +1,4 @@ --- -wipFile: '{implementation_artifacts}/spec-wip.md' deferred_work_file: '{implementation_artifacts}/deferred-work.md' --- @@ -13,7 +12,7 @@ deferred_work_file: '{implementation_artifacts}/deferred-work.md' ## INSTRUCTIONS 1. Investigate codebase. _Isolate deep exploration in sub-agents/tasks where available. To prevent context snowballing, instruct subagents to give you distilled summaries only._ -2. Read `./spec-template.md` fully. Fill it out based on the intent and investigation, and write the result to `{wipFile}`. +2. Read `./spec-template.md` fully. Fill it out based on the intent and investigation, and write the result to `{spec_file}`. 3. Self-review against READY FOR DEVELOPMENT standard. 4. If intent gaps exist, do not fantasize, do not leave open questions, HALT and ask the human. 5. Token count check (see SCOPE STANDARD). If spec exceeds 1600 tokens: @@ -26,7 +25,7 @@ deferred_work_file: '{implementation_artifacts}/deferred-work.md' Present summary. If token count exceeded 1600 and user chose [K], include the token count and explain why it may be a problem. HALT and ask human: `[A] Approve` | `[E] Edit` -- **A**: Rename `{wipFile}` to `{spec_file}`, set status `ready-for-dev`. Everything inside `` is now locked — only the human can change it. Display the finalized spec path to the user as a CWD-relative path (no leading `/`) so it is clickable in the terminal. → Step 3. +- **A**: Set status `ready-for-dev` in `{spec_file}`. Everything inside `` is now locked — only the human can change it. Display the finalized spec path to the user as a CWD-relative path (no leading `/`) so it is clickable in the terminal. → Step 3. - **E**: Apply changes, then return to CHECKPOINT 1. diff --git a/src/bmm-skills/4-implementation/bmad-quick-dev/workflow.md b/src/bmm-skills/4-implementation/bmad-quick-dev/workflow.md index f842532bf..55b8fda72 100644 --- a/src/bmm-skills/4-implementation/bmad-quick-dev/workflow.md +++ b/src/bmm-skills/4-implementation/bmad-quick-dev/workflow.md @@ -70,10 +70,6 @@ Load and read full config from `{main_config}` and resolve: YOU MUST ALWAYS SPEAK OUTPUT in your Agent communication style with the config `{communication_language}`. -### 2. Paths - -- `wipFile` = `{implementation_artifacts}/spec-wip.md` - -### 3. First Step Execution +### 2. First Step Execution Read fully and follow: `./step-01-clarify-and-route.md` to begin the workflow.