speccrew 0.7.63 → 0.7.65

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.
@@ -14,248 +14,4 @@ tools: Read, Write, Glob, Grep
14
14
 
15
15
  <!-- @agentflow: SKILL.xml -->
16
16
 
17
- > **REQUIRED**: Before executing this workflow, read the XML workflow specification: `speccrew-workspace/docs/rules/agentflow-spec.md`
18
-
19
- ## Workflow
20
-
21
- ## Absolute Constraints
22
-
23
- > **These rules apply to ALL steps. Violation = task failure.**
24
-
25
- 1. **READ-ONLY on Feature Spec and API Contract** — NEVER modify Feature Spec or API Contract documents. Only read for analysis.
26
- 2. **READ-ONLY on techs knowledge** — NEVER modify techs knowledge files. Only read for capability assessment.
27
- 3. **Evidence-based evaluation** — Every recommendation MUST cite specific Feature Spec requirements and specific tech stack limitations.
28
- 4. **No assumptions** — DO NOT assume framework capabilities. Only recommend frameworks with documented capabilities.
29
-
30
- ## Step 1: Read Inputs
31
-
32
- **Input Parameters** (from agent context):
33
-
34
- | Parameter | Required | Description |
35
- |-----------|----------|-------------|
36
- | `feature_spec_paths` | Yes | Array of Feature Spec file paths |
37
- | `api_contract_paths` | Yes | Array of API Contract file paths |
38
- | `techs_knowledge_paths` | Yes | Object with platform_id → knowledge paths mapping |
39
- | `iteration_path` | Yes | Current iteration directory path |
40
- | `output_path` | No | Output file path (default: `iteration_path/03.system-design/framework-evaluation.md`) |
41
-
42
- Read in order:
43
-
44
- 1. **All Feature Spec documents** — Extract functional requirements, especially:
45
- - Real-time features (WebSocket, SSE, push notifications)
46
- - File processing (upload, download, preview, conversion)
47
- - Data visualization (charts, dashboards, reports)
48
- - Rich text / editor features
49
- - Map / geolocation features
50
- - Payment / third-party integrations
51
- - Search / filtering / pagination patterns
52
- - Media processing (image, video, audio)
53
-
54
- 2. **All API Contract documents** — Extract:
55
- - Communication protocols (REST, GraphQL, WebSocket, gRPC)
56
- - Authentication patterns (JWT, OAuth, Session)
57
- - Data formats (JSON, protobuf, multipart)
58
-
59
- 3. **Techs knowledge per platform**:
60
- - `tech-stack.md` — Current frameworks, libraries, versions
61
- - `architecture.md` — Current architecture patterns
62
- - `conventions-design.md` — Design conventions
63
- - `conventions-dev.md` — Development conventions
64
-
65
- ## Step 2: Gap Analysis
66
-
67
- For each requirement extracted in Step 1, evaluate against current tech stack:
68
-
69
- ### 2.1 Build Capability Matrix
70
-
71
- | Requirement Category | Specific Requirement | Source (Feature ID) | Current Stack Support | Gap? |
72
- |---------------------|---------------------|--------------------|-----------------------|------|
73
- | Real-time | WebSocket connections | F-CRM-01 | Not in current stack | YES |
74
- | File Processing | PDF preview | F-ORD-02 | Not in current stack | YES |
75
- | Data Viz | Dashboard charts | F-RPT-01 | Not in current stack | YES |
76
- | Authentication | JWT token | F-SYS-01 | Already supported | NO |
77
-
78
- ### 2.2 Categorize Gaps
79
-
80
- Group identified gaps by category:
81
-
82
- - **Critical Gaps**: Core functionality cannot be implemented without new framework
83
- - **Enhancement Gaps**: Functionality possible but significantly better with dedicated library
84
- - **Optional Gaps**: Nice-to-have improvements, current stack can handle acceptably
85
-
86
- ## Step 3: Framework Research
87
-
88
- For each identified gap (Critical and Enhancement only):
89
-
90
- ### 3.1 Evaluate Candidates
91
-
92
- For each gap, research and evaluate 1-3 candidate frameworks/libraries:
93
-
94
- | Evaluation Criteria | Description |
95
- |--------------------|-------------|
96
- | **Functionality Fit** | Does it solve the specific capability gap? |
97
- | **License** | MIT, Apache 2.0, BSD preferred. GPL requires flagging. |
98
- | **Maturity** | GitHub stars, npm downloads, last release date, version stability |
99
- | **Bundle Size** | Impact on frontend bundle (if applicable) |
100
- | **Integration Complexity** | How much existing code needs modification? |
101
- | **Community & Docs** | Documentation quality, community support, ecosystem |
102
-
103
- ### 3.2 Make Recommendations
104
-
105
- For each gap, provide a single primary recommendation with justification.
106
-
107
- ## Step 4: Generate Report
108
-
109
- Write the framework evaluation report to `output_path`.
110
-
111
- ### Report Structure (When Gaps Found)
112
-
113
- ```markdown
114
- # Framework Evaluation Report — iteration_name
115
-
116
- ## 1. Evaluation Summary
117
-
118
- - **Iteration**: iteration_name
119
- - **Feature Specs Analyzed**: feature_count
120
- - **Platforms Evaluated**: platform_count
121
- - **Capability Gaps Found**: gap_count
122
- - **New Frameworks Recommended**: framework_count
123
-
124
- ## 2. Capability Gap Analysis
125
-
126
- ### 2.1 Gap Summary
127
-
128
- | # | Gap Category | Specific Gap | Severity | Source Features | Recommendation |
129
- |---|-------------|-------------|----------|----------------|---------------|
130
- | 1 | Real-time | WebSocket support | Critical | F-CRM-01, F-MSG-01 | Socket.IO |
131
- | 2 | Data Viz | Chart rendering | Enhancement | F-RPT-01 | ECharts |
132
- | ... | ... | ... | ... | ... | ... |
133
-
134
- ### 2.2 Detailed Gap Analysis
135
-
136
- #### Gap 1: {Gap Name}
137
-
138
- **Requirement Source**: {Feature IDs and specific requirement text}
139
- **Current Stack Status**: {What the current stack provides/lacks}
140
- **Impact**: {What cannot be implemented without addressing this gap}
141
-
142
- ## 3. Framework Recommendations
143
-
144
- ### 3.1 Recommendation Summary
145
-
146
- | # | Framework | Version | License | For Gap | Platform | Integration Impact |
147
- |---|-----------|---------|---------|---------|----------|-------------------|
148
- | 1 | Socket.IO | ^4.x | MIT | WebSocket support | backend + web | Medium |
149
- | 2 | ECharts | ^5.x | Apache 2.0 | Chart rendering | web | Low |
150
-
151
- ### 3.2 Detailed Recommendations
152
-
153
- #### Recommendation 1: {Framework Name}
154
-
155
- - **Solves Gap**: {gap description}
156
- - **License**: {license type}
157
- - **Maturity**: {stars, downloads, last release}
158
- - **Integration Impact**: Low / Medium / High
159
- - **Integration Notes**: {specific integration considerations}
160
- - **Alternatives Considered**: {other options and why not chosen}
161
-
162
- ## 4. No-Change Confirmations
163
-
164
- Capabilities already covered by current stack:
165
- - {capability 1}: Covered by {existing framework}
166
- - {capability 2}: Covered by {existing framework}
167
-
168
- ## 5. Version Constraints
169
-
170
- | Framework | Required Version | Constraint Reason |
171
- |-----------|-----------------|-------------------|
172
- | {name} | {version range} | {compatibility reason} |
173
- ```
174
-
175
- ### Simplified Report Structure (When No Gaps Found)
176
-
177
- ```markdown
178
- # Framework Evaluation Report — iteration_name
179
-
180
- ## 1. Evaluation Summary
181
-
182
- - **Feature Specs Analyzed**: feature_count
183
- - **Platforms Evaluated**: platform_count
184
- - **Capability Gaps Found**: 0
185
- - **New Frameworks Recommended**: 0
186
-
187
- ## 2. Assessment
188
-
189
- All Feature Spec requirements can be fully implemented with the current technology stack. No new frameworks or libraries are needed.
190
-
191
- ### Capabilities Confirmed
192
- - {list each major capability confirmed as supported}
193
-
194
- ## 3. Conclusion
195
-
196
- Current tech stack is sufficient. Proceed to system design without framework changes.
197
- ```
198
-
199
- ## Step 5: Output Task Completion Report
200
-
201
- After writing the report, output:
202
-
203
- ```
204
- --- TASK COMPLETION REPORT ---
205
- Task: Framework Evaluation
206
- Status: SUCCESS
207
- Output: output_path
208
- Gaps Found: gap_count
209
- Frameworks Recommended: framework_count
210
- --- END REPORT ---
211
- ```
212
-
213
- If any step fails:
214
-
215
- ```
216
- --- TASK COMPLETION REPORT ---
217
- Task: Framework Evaluation
218
- Status: FAILED
219
- Error: {specific error description}
220
- Failed At: Step {N}
221
- --- END REPORT ---
222
- ```
223
-
224
- ## OUTPUT EFFICIENCY RULES
225
-
226
- When executing this skill:
227
-
228
- 1. **Direct-to-File Output**: All design content (architecture diagrams, API mappings, component specifications, data models) MUST be written directly to the output file
229
- 2. **Minimal Conversation Output**: Only output:
230
- - Block execution announcements (1 line each): `"[Block XX] Designing..."`
231
- - Error messages requiring attention
232
- - Task Completion Report (final summary)
233
- 3. **FORBIDDEN in conversation**:
234
- - ❌ Full document sections or drafts
235
- - ❌ Mermaid diagrams displayed in chat
236
- - ❌ API endpoint listings
237
- - ❌ Data model tables
238
- - ❌ Architecture descriptions longer than 2 lines
239
- 4. **Rationale**: Workers run in batch mode. Displaying design content in conversation wastes context window and provides no value since content goes to file anyway.
240
-
241
- # Key Rules
242
-
243
- | Rule | Description |
244
- |------|-------------|
245
- | **READ-ONLY Inputs** | Feature Spec, API Contract, and techs knowledge are reference only — never modify |
246
- | **Evidence-based** | Every gap and recommendation must cite specific requirement sources |
247
- | **Gap Categories** | Only Critical and Enhancement gaps require framework recommendations |
248
- | **License Awareness** | GPL and copyleft licenses must be flagged in recommendations |
249
- | **No Assumptions** | Only recommend frameworks with documented, verified capabilities |
250
-
251
- # Checklist
252
-
253
- - [ ] All Feature Spec documents read and requirements extracted
254
- - [ ] All API Contract documents read and protocols identified
255
- - [ ] Techs knowledge loaded for all platforms
256
- - [ ] Capability matrix built with all requirements mapped
257
- - [ ] Gaps categorized by severity (Critical/Enhancement/Optional)
258
- - [ ] Framework candidates evaluated against criteria
259
- - [ ] Primary recommendations made for each gap
260
- - [ ] Report generated with correct structure
261
- - [ ] Task Completion Report output
17
+ > **REQUIRED**: Read and execute the XML workflow above. The XML contains the complete workflow definition including all steps, rules, conditions, and checklist.
@@ -36,6 +36,19 @@
36
36
  <field name="text">Only recommend frameworks with documented capabilities</field>
37
37
  </block>
38
38
 
39
+ <block type="rule" id="R5" level="mandatory" desc="Direct-to-File Output">
40
+ <field name="text">All design content MUST be written directly to the output file</field>
41
+ </block>
42
+
43
+ <block type="rule" id="R6" level="mandatory" desc="Minimal Conversation Output">
44
+ <field name="text">Only output block execution announcements, error messages, and Task Completion Report</field>
45
+ </block>
46
+
47
+ <block type="rule" id="R7" level="forbidden" desc="No conversation document output">
48
+ <field name="text">NEVER display full document sections, Mermaid diagrams, API endpoint listings, data model tables in conversation</field>
49
+ <field name="text">NEVER display architecture descriptions longer than 2 lines in conversation</field>
50
+ </block>
51
+
39
52
  <!-- ============================================================
40
53
  Main Processing Sequence
41
54
  ============================================================ -->
@@ -219,8 +232,34 @@ Frameworks Recommended: ${recommendations.length}
219
232
  </branch>
220
233
  </block>
221
234
 
235
+ <block type="checkpoint" id="CP2" name="final_checklist" desc="Framework Evaluation Final Checklist">
236
+ <field name="conditions">
237
+ feature_specs_read: all Feature Spec documents read and requirements extracted,
238
+ api_contracts_read: all API Contract documents read and protocols identified,
239
+ techs_knowledge_loaded: techs knowledge loaded for all platforms,
240
+ capability_matrix_built: capability matrix built with all requirements mapped,
241
+ gaps_categorized: gaps categorized by severity (Critical/Enhancement/Optional),
242
+ framework_candidates_evaluated: framework candidates evaluated against criteria,
243
+ primary_recommendations_made: primary recommendations made for each gap,
244
+ report_generated: report generated with correct structure,
245
+ task_completion_report_output: task completion report output
246
+ </field>
247
+ </block>
248
+
222
249
  </sequence>
223
250
 
251
+ <!-- ============================================================
252
+ Failure Report Format
253
+ ============================================================ -->
254
+ <block type="event" id="E4" action="log" level="error" desc="Task failure report">
255
+ <field name="message">--- TASK COMPLETION REPORT ---
256
+ Task: Framework Evaluation
257
+ Status: FAILED
258
+ Error: {specific error description}
259
+ Failed At: Step {N}
260
+ --- END REPORT ---</field>
261
+ </block>
262
+
224
263
  <!-- ============================================================
225
264
  Output Results
226
265
  ============================================================ -->
@@ -1,209 +1,17 @@
1
1
  ---
2
2
  name: speccrew-system-designer-orchestration
3
- version: 1.0.0
4
- description: System Designer 的核心编排技能,负责读取已确认的 Feature Spec 和 API Contract 文档,加载技术知识库,评估框架需求,调度各平台详细设计技能生成系统设计文档。支持 web、mobile、desktop 平台。
3
+ description: System Designer orchestration skill. Manages the complete system design workflow from stage gate checking through platform dispatch to joint confirmation. Coordinates framework evaluation, design overview generation, and parallel platform-specific design tasks across web, mobile, desktop platforms.
5
4
  tools: Read, Write, Glob, Grep, Bash, Agent
6
5
  ---
7
6
 
8
- > **⚠️ MANDATORY EXECUTION PROTOCOL — READ BEFORE EXECUTING ANY BLOCK**
9
- >
10
- > **Step 1**: Load XML workflow specification: `speccrew-workspace/docs/rules/agentflow-spec.md` — this defines all block types and action-to-tool mappings
11
- >
12
- > **Step 2**: Execute this SKILL.md's XML workflow **block by block in document order**. For EVERY block, you MUST follow this 3-step cycle:
13
- >
14
- > ```
15
- > 📋 Block [ID] (action=[action]) — [desc]
16
- > 🔧 Tool: [which IDE tool to call]
17
- > ✅ Result: [output or status]
18
- > ```
19
- >
20
- > Action-to-tool mapping:
21
- > - `action="run-skill"` → Invoke via **Skill tool** (pass the `<field name="skill">` value EXACTLY)
22
- > - `action="run-script"` → Execute via **Terminal tool** (pass the `<field name="command">` value EXACTLY)
23
- > - `action="dispatch-to-worker"` → Use **Agent tool** to create a new `speccrew-task-worker` agent, passing skill_path and context
24
- > - `action="read-file"` → Read via **Read tool**
25
- > - `action="log"` → Output message directly
26
- > - `action="confirm"` → Present to user and wait for response
27
- >
28
- > **Step 3**: Execute ALL blocks sequentially without pausing (only stop at explicit `<event action="confirm">` blocks)
7
+ # Trigger Scenarios
29
8
 
30
- # System Designer Orchestration
31
-
32
- System Designer 的核心编排技能,负责:
33
-
34
- 1. **Stage Gate** - 验证 Feature Design 阶段已确认
35
- 2. **Preparation** - 加载 Feature Registry,验证文件存在性
36
- 3. **Resource Verification** - 验证技术知识库可用性
37
- 4. **Framework Evaluation** - 派发单个 worker agent 执行框架评估技能,等待 worker 完成并验证 framework-evaluation.md 生成后进入下一阶段(HARD STOP 等待用户确认)
38
- 5. **Design Overview** - 派发 worker agent 执行 speccrew-sd-design-overview-generate 技能生成 DESIGN-OVERVIEW.md,等待 worker 完成并验证输出
39
- 6. **Platform Dispatch** - 分发各平台设计任务给 Worker
40
- 7. **Joint Confirmation** - 联合确认所有设计文档
41
-
42
- ## Invocation Method
43
-
44
- **CRITICAL**: This skill is loaded directly by System Designer Agent — do NOT invoke via Worker Agent.
45
-
46
- ```xml
47
- <block type="task" action="run-skill" desc="System Designer orchestration workflow">
48
- <field name="skill">speccrew-system-designer-orchestration</field>
49
- </block>
50
- ```
51
-
52
- ## Input Parameters
53
-
54
- | Parameter | Type | Required | Description |
55
- |-----------|------|----------|-------------|
56
- | `workspace_path` | string | Yes | speccrew-workspace root directory path |
57
- | `iterations_dir` | string | Yes | iterations directory path |
58
- | `update_progress_script` | string | Yes | Path to update-progress.js script |
59
- | `current_iteration` | string | No | Current active iteration identifier |
60
-
61
- ## Output
62
-
63
- - `status` - Execution status (success / partial / failed)
64
- - `output_files` - List of generated design documents
65
- - `summary` - Execution summary
66
- - `next_steps` - Suggested next actions
67
-
68
- ---
9
+ - System Designer Agent starts system design workflow
10
+ - Feature Spec and API Contract have been confirmed (02_feature_design stage = confirmed)
11
+ - User requests system design execution for confirmed features
69
12
 
70
13
  ## AgentFlow Definition
71
14
 
72
15
  <!-- @agentflow: SKILL.xml -->
73
16
 
74
- ---
75
-
76
- ## CONTINUOUS EXECUTION RULES
77
-
78
- This skill MUST execute tasks continuously without unnecessary interruptions.
79
-
80
- ### FORBIDDEN Interruptions
81
-
82
- 1. DO NOT ask user "Should I continue?" after completing a subtask
83
- 2. DO NOT suggest "Let me split this into batches" or "Let's do this in parts"
84
- 3. DO NOT pause to list what you plan to do next — just do it
85
- 4. DO NOT ask for confirmation before generating output files
86
- 5. DO NOT warn about "large number of files" — proceed with generation
87
- 6. DO NOT offer "Should I proceed with the remaining items?"
88
-
89
- ### When to Pause (ONLY these cases)
90
-
91
- 1. CHECKPOINT gates defined in workflow (user confirmation required by design)
92
- 2. Ambiguous requirements that genuinely need clarification
93
- 3. Unrecoverable errors that prevent further progress
94
- 4. Security-sensitive operations (e.g., deleting existing files)
95
-
96
- ### Phase 3 Execution Method — Worker Agent Dispatch
97
-
98
- **HOW TO DISPATCH**: When executing Phase 3 block P3-B1 (action="dispatch-to-worker"):
99
- 1. Use the **Agent tool** to create a new `speccrew-task-worker` agent
100
- 2. Pass `skill_path` to the worker: `${workspace_path}/.speccrew/skills/speccrew-sd-framework-evaluate/SKILL.md`
101
- 3. Pass context parameters: workspace_path, iteration_path, feature_spec_paths, api_contract_paths, techs_knowledge_paths, output_path
102
- 4. **Wait** for the worker agent to complete and return results
103
- 5. After worker completes, verify framework-evaluation.md exists at output_path
104
- 6. Then proceed to Phase 3.5 HARD STOP for user confirmation
105
-
106
- **CRITICAL**: The `Agent tool` creates a NEW agent session — this is completely different from the `Skill tool` which executes inline.
107
-
108
- ### Phase 4 Execution Method — Worker Agent Dispatch
109
-
110
- **HOW TO DISPATCH**: When executing Phase 4 block P4-B1 (action="dispatch-to-worker"):
111
- 1. Use the **Agent tool** to create a new `speccrew-task-worker` agent
112
- 2. Pass `skill_path` to the worker: `${workspace_path}/.speccrew/skills/speccrew-sd-design-overview-generate/SKILL.md`
113
- 3. Pass context parameters: workspace_path, iteration_path, feature_registry_path (.prd-feature-list.json path), techs_manifest_path (techs-manifest.json path), framework_evaluation_path (framework-evaluation.md path), output_path
114
- 4. **Wait** for the worker agent to complete and return results
115
- 5. After worker completes, verify DESIGN-OVERVIEW.md exists at output_path
116
- 6. Then proceed to Phase 4 checkpoint validation (P4-CP1)
117
- 7. Present DESIGN-OVERVIEW.md summary to user (feature count, platform count, matrix entries)
118
- 8. **⚠️ HARD STOP** — Wait for user explicit confirmation before proceeding to Phase 5
119
-
120
- **CRITICAL**: The `Agent tool` creates a NEW agent session — this is completely different from the `Skill tool` which executes inline.
121
-
122
- ### Phase 5 Execution Method — Feature×Platform Worker Dispatch
123
-
124
- **DISPATCH GRANULARITY**: ONE Worker per Feature×Platform combination — NO EXCEPTIONS.
125
-
126
- **HOW TO DISPATCH**: When executing Phase 5 dispatch blocks (action="dispatch-to-worker"):
127
- 1. Build Feature×Platform matrix from DESIGN-OVERVIEW.md Platform Design Index
128
- 2. Create `.tasks-temp.json` with one entry per Feature×Platform combination
129
- 3. Initialize DISPATCH-PROGRESS.json via `update-progress.js init`
130
- 4. Compute batch plan (batch size = 6)
131
- 5. For each batch:
132
- a. Use **Agent tool** to create `speccrew-task-worker` agents for ALL tasks in the batch **SIMULTANEOUSLY**
133
- b. Each Worker receives: `skill_path` (platform-specific skill), `task_id`, `feature_id`, `feature_name`, `platform_id`, `feature_spec_path`, `api_contract_path`, `techs_knowledge_paths`, `framework_decisions`, `output_base_path`, `skip_confirmation: true`, `skip_index_generation: true`, `dispatch_progress_file`, `update_progress_script`
134
- c. **Wait** for ALL Workers in the batch to complete
135
- d. Update DISPATCH-PROGRESS.json for each completed Worker
136
- e. Log batch progress
137
- 6. After all batches complete, read final progress summary
138
- 7. Dispatch worker per platform with `index_only: true` to generate INDEX.md (see Phase 5.5)
139
-
140
- **CRITICAL**: Each Worker handles exactly ONE feature on ONE platform. DO NOT group multiple features or platforms into a single Worker.
141
-
142
- **Batch Dispatch Context Parameters**: When dispatching Workers in batch mode, the following parameters MUST be included in each Worker's context:
143
- - `skip_confirmation: true` — Workers skip Checkpoint A user confirmation (not feasible in batch mode)
144
- - `skip_index_generation: true` — Workers skip Step 5 INDEX.md generation (INDEX.md will be generated by orchestrator after all workers complete)
145
- - `dispatch_progress_file` — Path to DISPATCH-PROGRESS.json, enables Worker to self-update its task status on completion
146
- - `update_progress_script` — Path to update-progress.js script, used by Worker to execute status updates
147
- - `task_id` — Task identifier in DISPATCH-PROGRESS.json (already part of dispatch context, listed here for completeness)
148
-
149
- > **Worker Self-Update**: When `dispatch_progress_file` and `task_id` are provided, the Worker is responsible for updating its own task status in DISPATCH-PROGRESS.json upon completion (Step 7 of platform skills). The orchestrator's P5-B4-POST block serves as a fallback, but the Worker self-update is the primary mechanism.
150
-
151
- ### Phase 5.5: INDEX.md Generation (WORKER-DISPATCH)
152
-
153
- After ALL Feature×Platform workers complete successfully, dispatch ONE worker per platform to generate INDEX.md. Each worker receives `index_only: true` and `skip_index_generation: false`, executing ONLY Step 5 of the platform skill.
154
-
155
- **Dispatch parameters per platform**:
156
- - `agent`: speccrew-task-worker
157
- - `skill`: speccrew-sd-${platform.type}
158
- - `skill_path`: ${ide_skills_dir}/speccrew-sd-${platform.type}/SKILL.md
159
- - `context`:
160
- - `index_only: true`
161
- - `skip_index_generation: false`
162
- - `platform_id`: ${platform.id}
163
- - `output_dir`: ${iterations_dir}/${current_iteration}/03.system-design/${platform.id}
164
- - `completed_documents`: ${platform.completed_documents}
165
- - `techs_knowledge_dir`: ${techs_knowledge_dir}
166
- - `workspace_path`: ${workspace_path}
167
- - `task_id`: idx-${platform.id}
168
- - `dispatch_progress_file`: ${iterations_dir}/${current_iteration}/03.system-design/DISPATCH-PROGRESS.json
169
- - `update_progress_script`: ${update_progress_script}
170
-
171
- **FORBIDDEN**: Orchestrator generating INDEX.md directly. INDEX.md MUST be generated by worker.
172
-
173
- **Example** (5 features × 3 platforms = 15 workers, 3 batches of 6/6/3):
174
- - Batch 1: Workers 1-6 (parallel)
175
- - Batch 2: Workers 7-12 (parallel, after batch 1 completes)
176
- - Batch 3: Workers 13-15 (parallel, after batch 2 completes)
177
-
178
- ### HARD STOP Checkpoints
179
-
180
- This workflow has **mandatory HARD STOP** checkpoints at:
181
- - **Phase 3.5**: Framework evaluation confirmation (user MUST approve framework decisions)
182
- - **Phase 4.5**: Design overview confirmation (user MUST approve DESIGN-OVERVIEW.md before Phase 5 dispatch)
183
- - **Phase 5.5**: (No HARD STOP — INDEX.md generation is automatic after all workers complete)
184
- - **Phase 6.1**: Joint design confirmation (user MUST approve all designs)
185
-
186
- DO NOT proceed past these checkpoints without explicit user confirmation.
187
-
188
- ## Must Do
189
-
190
- - **READ SKILL.xml FIRST** — Execute blocks in document order
191
- - **Use Agent tool for dispatch-to-worker blocks** — Agent tool creates a new speccrew-task-worker agent session
192
- - **Pass skill_path explicitly to worker** — Worker cannot find skills via glob on first run
193
- - **Wait for worker completion before verifying output** — Do not proceed until worker returns
194
- - **Update progress via update-progress.js script** — Use run-script commands exactly as defined in XML
195
-
196
- ## Must Not Do
197
-
198
- - **DO NOT use Skill tool for Phase 3 framework evaluation** — Skill tool executes inline, Agent tool creates a worker
199
- - **DO NOT read feature spec files yourself** — Workers read them
200
- - **DO NOT read tech knowledge files yourself** — Workers read them
201
- - **DO NOT generate framework-evaluation.md yourself** — Only workers generate it
202
- - **DO NOT create scripts for batch analysis** — Workers handle this via their own skill
203
- - **DO NOT fallback to inline execution if worker fails** — ABORT instead
204
- - **DO NOT let individual workers generate INDEX.md in batch mode** — `skip_index_generation: true` must be set; INDEX.md is generated in Phase 5.5 by separate worker with `index_only: true`
205
- - **DO NOT skip reading SKILL.xml** — XML is the execution authority
206
- - **DO NOT generate DESIGN-OVERVIEW.md yourself** — Dispatch speccrew-task-worker with speccrew-sd-design-overview-generate skill
207
- - **DO NOT use Skill tool for Phase 4 design overview generation** — Skill tool executes inline, Agent tool creates a worker
208
- - **DO NOT group multiple features into a single Worker** — Each Worker handles exactly ONE feature on ONE platform
209
- - **DO NOT dispatch Workers sequentially** — ALL Workers in the same batch MUST be dispatched simultaneously
17
+ > **REQUIRED**: Read and execute the XML workflow above. The XML contains the complete workflow definition including all phases (Stage Gate → Preparation → Resource Verification → Framework Evaluation → Design Overview → Platform Dispatch → Joint Confirmation), rules, conditions, and checklist.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "speccrew",
3
- "version": "0.7.63",
3
+ "version": "0.7.65",
4
4
  "description": "Spec-Driven Development toolkit for AI-powered IDEs",
5
5
  "author": "charlesmu99",
6
6
  "repository": {
@@ -1502,26 +1502,30 @@ function cmdInitTasks(args) {
1502
1502
  outputError(`Features directory not found: ${featuresDir}`);
1503
1503
  }
1504
1504
 
1505
- // Scan .feature-spec.md files
1505
+ // Scan feature-spec.md files (support both new and old filename formats)
1506
+ // New format: *.feature-spec.md (dot separator before feature-spec)
1507
+ // Old format: *-feature-spec.md (hyphen separator before feature-spec)
1506
1508
  const featureFiles = [];
1507
1509
  const files = fs.readdirSync(featuresDir);
1508
1510
  for (const file of files) {
1509
- if (file.endsWith('.feature-spec.md')) {
1511
+ if (file.endsWith('.feature-spec.md') || file.endsWith('-feature-spec.md')) {
1510
1512
  featureFiles.push(file);
1511
1513
  }
1512
1514
  }
1513
1515
 
1514
1516
  if (featureFiles.length === 0) {
1515
- outputError(`No .feature-spec.md files found in: ${featuresDir}`);
1517
+ outputError(`No feature-spec files found in: ${featuresDir}. Supported formats:\n New: F-{MODULE}-{NNN}-{feature-name}.feature-spec.md (e.g. F-APPT-001-appointment-crud.feature-spec.md)\n Old: F-{MODULE}-{NNN}-{feature-name}-feature-spec.md (e.g. F-M01-01-member-level-history-feature-spec.md)`);
1516
1518
  }
1517
1519
 
1518
1520
  // Extract feature info from filenames
1519
- // Format: F-{MODULE}-{NNN}-{feature-name}.feature-spec.md
1520
- const featurePattern = /^(F-([A-Z]+)-\d+)-(.+)\.feature-spec\.md$/;
1521
+ // New format: F-{MODULE}-{NNN}-{feature-name}.feature-spec.md (module: uppercase letters, e.g. APPT)
1522
+ // Old format: F-{MODULE}-{NNN}-{feature-name}-feature-spec.md (module: M+digits, e.g. M01)
1523
+ const newFormatPattern = /^(F-([A-Z]+)-\d+)-(.+)\.feature-spec\.md$/;
1524
+ const oldFormatPattern = /^(F-(M\d+)-\d+)-(.+)-feature-spec\.md$/;
1521
1525
  const features = [];
1522
1526
 
1523
1527
  for (const file of featureFiles) {
1524
- const match = file.match(featurePattern);
1528
+ let match = file.match(newFormatPattern);
1525
1529
  if (match) {
1526
1530
  features.push({
1527
1531
  feature_id: match[1], // F-APPT-001
@@ -1529,11 +1533,22 @@ function cmdInitTasks(args) {
1529
1533
  name: match[3], // appointment-crud
1530
1534
  file: file
1531
1535
  });
1536
+ continue;
1537
+ }
1538
+ match = file.match(oldFormatPattern);
1539
+ if (match) {
1540
+ features.push({
1541
+ feature_id: match[1], // F-M01-01
1542
+ module: match[2], // M01
1543
+ name: match[3], // member-level-history
1544
+ file: file
1545
+ });
1546
+ continue;
1532
1547
  }
1533
1548
  }
1534
1549
 
1535
1550
  if (features.length === 0) {
1536
- outputError('No valid feature files found. Expected format: F-{MODULE}-{NNN}-{feature-name}.feature-spec.md');
1551
+ outputError('No valid feature files found. Supported formats:\n New: F-{MODULE}-{NNN}-{feature-name}.feature-spec.md (e.g. F-APPT-001-appointment-crud.feature-spec.md)\n Old: F-{MODULE}-{NNN}-{feature-name}-feature-spec.md (e.g. F-M01-01-member-level-history-feature-spec.md)');
1537
1552
  }
1538
1553
 
1539
1554
  // Sort by feature ID