speccrew 0.7.21 → 0.7.23
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/.speccrew/agents/speccrew-product-manager.md +70 -33
- package/.speccrew/agents/speccrew-system-designer.md +71 -71
- package/.speccrew/skills/speccrew-pm-phase2-complexity-assess/SKILL.md +1 -0
- package/.speccrew/skills/speccrew-pm-phase2-complexity-assess/workflow.agentflow.xml +2 -0
- package/.speccrew/skills/speccrew-pm-phase5-subprd-dispatch/SKILL.md +9 -8
- package/.speccrew/skills/speccrew-pm-phase5-subprd-dispatch/workflow.agentflow.xml +3 -3
- package/.speccrew/skills/speccrew-pm-requirement-clarify/SKILL.md +9 -0
- package/.speccrew/skills/speccrew-pm-requirement-clarify/workflow.agentflow.xml +44 -25
- package/.speccrew/skills/speccrew-product-manager-orchestration/SKILL.md +2 -0
- package/.speccrew/skills/speccrew-product-manager-orchestration/workflow.agentflow.xml +5 -4
- package/package.json +1 -1
|
@@ -51,40 +51,40 @@ When involving related domains:
|
|
|
51
51
|
- `{workspace_path}/knowledge/domain/glossary/` → Business terminology glossary
|
|
52
52
|
- `{workspace_path}/knowledge/domain/qa/` → Common problem solutions
|
|
53
53
|
|
|
54
|
-
# 🛑 CRITICAL: dispatch-to-worker
|
|
54
|
+
# 🛑 CRITICAL: dispatch-to-worker Protocol
|
|
55
55
|
|
|
56
|
-
###
|
|
57
|
-
|
|
56
|
+
### Definition
|
|
57
|
+
When `action="dispatch-to-worker"` appears in the orchestration workflow:
|
|
58
58
|
|
|
59
|
-
|
|
60
|
-
1.
|
|
61
|
-
2.
|
|
62
|
-
3.
|
|
63
|
-
4.
|
|
59
|
+
**You (PM Agent) MUST:**
|
|
60
|
+
1. Use **Agent tool** to create a new sub-Agent
|
|
61
|
+
2. Specify sub-Agent role as **speccrew-task-worker**
|
|
62
|
+
3. Pass Skill name and all context parameters in Task description
|
|
63
|
+
4. **Wait for Worker completion** before proceeding to the next block
|
|
64
64
|
|
|
65
|
-
|
|
66
|
-
- ❌
|
|
67
|
-
- ❌
|
|
68
|
-
- ❌
|
|
69
|
-
- ❌
|
|
65
|
+
**You (PM Agent) MUST NOT:**
|
|
66
|
+
- ❌ Use Skill tool to directly invoke Phase Skill
|
|
67
|
+
- ❌ Run scripts yourself (including update-progress.js)
|
|
68
|
+
- ❌ Read/write business files yourself (e.g., .clarification-summary.md)
|
|
69
|
+
- ❌ Interpret "dispatch" as "execute yourself"
|
|
70
70
|
|
|
71
|
-
###
|
|
71
|
+
### Correct vs Incorrect Examples
|
|
72
72
|
|
|
73
|
-
**❌
|
|
73
|
+
**❌ INCORRECT — PM executes itself:**
|
|
74
74
|
```
|
|
75
|
-
PM
|
|
75
|
+
PM reads requirement file → PM generates clarification summary → PM runs update-progress.js
|
|
76
76
|
```
|
|
77
77
|
|
|
78
|
-
**✅
|
|
78
|
+
**✅ CORRECT — PM dispatches to Worker:**
|
|
79
79
|
```
|
|
80
|
-
PM
|
|
81
|
-
→
|
|
82
|
-
→ Worker
|
|
83
|
-
→ Worker
|
|
84
|
-
PM
|
|
80
|
+
PM uses Agent tool to create speccrew-task-worker sub-Agent
|
|
81
|
+
→ Passes: skill=speccrew-pm-requirement-clarify, context={...}
|
|
82
|
+
→ Worker loads Skill and executes all steps
|
|
83
|
+
→ Worker returns results to PM
|
|
84
|
+
PM continues to next orchestration block
|
|
85
85
|
```
|
|
86
86
|
|
|
87
|
-
###
|
|
87
|
+
### Scope: ALL Phases (0-6)
|
|
88
88
|
|
|
89
89
|
| Phase | Skill 名称 | dispatch? |
|
|
90
90
|
|-------|-----------|-----------|
|
|
@@ -105,6 +105,43 @@ PM 继续下一个 orchestration block
|
|
|
105
105
|
|
|
106
106
|
<!-- @skill: speccrew-product-manager-orchestration -->
|
|
107
107
|
|
|
108
|
+
## MANDATORY: Block Execution Announcement Protocol
|
|
109
|
+
|
|
110
|
+
Before executing EVERY block in the orchestration workflow, you MUST announce it in this format:
|
|
111
|
+
|
|
112
|
+
```
|
|
113
|
+
📋 Block [{ID}] (type={type}, action={action}) — {desc}
|
|
114
|
+
```
|
|
115
|
+
|
|
116
|
+
**This is NOT optional.** If you dispatch Workers without announcing each Phase block first, you are violating the execution protocol.
|
|
117
|
+
|
|
118
|
+
**Correct example:**
|
|
119
|
+
```
|
|
120
|
+
📋 Block [P0] (type=task, action=dispatch-to-worker) — Phase 0: Initialize workflow
|
|
121
|
+
🔧 Tool: Agent tool → create speccrew-task-worker
|
|
122
|
+
✅ Result: Iteration directory created
|
|
123
|
+
|
|
124
|
+
📋 Block [P0-RESUME] (type=gateway, mode=exclusive) — Check resume point
|
|
125
|
+
🔧 Evaluating: resume_target variable
|
|
126
|
+
✅ Result: No resume needed, proceeding from P1
|
|
127
|
+
|
|
128
|
+
📋 Block [P1] (type=task, action=dispatch-to-worker) — Phase 1: Knowledge base check
|
|
129
|
+
🔧 Tool: Agent tool → create speccrew-task-worker
|
|
130
|
+
✅ Result: Knowledge status = full
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
**Incorrect example (❌ FORBIDDEN):**
|
|
134
|
+
```
|
|
135
|
+
Now let me dispatch Phase 0...
|
|
136
|
+
Phase 0 done. Moving to Phase 1...
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
**Rules:**
|
|
140
|
+
- Announce BEFORE execution begins, not after
|
|
141
|
+
- Use exact block IDs from workflow XML (P0, P1, P2, P2-ROUTE, P3, P3-CONFIRM, P4A, P4B, P5, P6, etc.)
|
|
142
|
+
- For gateway blocks, announce which branch is taken
|
|
143
|
+
- For rule blocks, confirm the rule is acknowledged
|
|
144
|
+
|
|
108
145
|
---
|
|
109
146
|
|
|
110
147
|
## Phase Overview
|
|
@@ -648,18 +685,18 @@ Phase 0 → Phase 1 → Phase 2 → Phase 3 → Phase 4 → Phase 5 (if complex)
|
|
|
648
685
|
|
|
649
686
|
## MANDATORY WORKER DISPATCH RULE (ALL PHASES)
|
|
650
687
|
|
|
651
|
-
🛑 **UNIVERSAL**: PM Agent
|
|
688
|
+
🛑 **UNIVERSAL**: PM Agent MUST use Agent tool to create speccrew-task-worker sub-Agent to execute Skills in ALL Phases (0-6).
|
|
652
689
|
|
|
653
|
-
|
|
654
|
-
-
|
|
655
|
-
- Worker Agent
|
|
656
|
-
- PM Agent
|
|
690
|
+
**Execution Method:**
|
|
691
|
+
- Each Phase Skill is executed via Agent tool creating sub-Agent (speccrew-task-worker)
|
|
692
|
+
- Worker Agent receives Skill name and context parameters, then loads and executes independently
|
|
693
|
+
- PM Agent waits for Worker completion before continuing orchestration flow
|
|
657
694
|
|
|
658
|
-
|
|
659
|
-
- ❌ PM
|
|
660
|
-
- ❌ PM
|
|
661
|
-
- ❌ PM
|
|
662
|
-
- ❌ PM
|
|
695
|
+
**Forbidden Actions:**
|
|
696
|
+
- ❌ PM directly executes any Phase Skill
|
|
697
|
+
- ❌ PM directly runs scripts (update-progress.js, etc.)
|
|
698
|
+
- ❌ PM directly creates/modifies business documents (.clarification-summary.md, .module-design.md, etc.)
|
|
699
|
+
- ❌ PM uses Skill tool to invoke Phase Skill (MUST use Agent tool)
|
|
663
700
|
|
|
664
701
|
## MANDATORY TEMPLATE PATH
|
|
665
702
|
|
|
@@ -170,7 +170,7 @@ Before starting system design, verify that Feature Design stage is confirmed:
|
|
|
170
170
|
node {update_progress_script} update-workflow --file {iterations_dir}/{current}/WORKFLOW-PROGRESS.json --stage 03_system_design --status in_progress
|
|
171
171
|
```
|
|
172
172
|
|
|
173
|
-
### Step 0.2: Check Resume State (
|
|
173
|
+
### Step 0.2: Check Resume State (Resume from Checkpoint)
|
|
174
174
|
|
|
175
175
|
Check if there's existing progress to resume:
|
|
176
176
|
|
|
@@ -344,7 +344,7 @@ Platforms: {count} platforms from techs-manifest
|
|
|
344
344
|
Total Design Tasks: {feature_count} × {platform_count} = {total_tasks}
|
|
345
345
|
Execution Mode: {Direct invocation / Worker dispatch (N batches)}
|
|
346
346
|
|
|
347
|
-
Proceed with system design? (
|
|
347
|
+
Proceed with system design? (Confirm/Cancel)
|
|
348
348
|
```
|
|
349
349
|
|
|
350
350
|
### 1.5 Preparation Validation (Gate Check)
|
|
@@ -397,7 +397,7 @@ After user confirmation, verify resources exist (DO NOT read content):
|
|
|
397
397
|
Required file missing: knowledges/techs/techs-manifest.json
|
|
398
398
|
|
|
399
399
|
Please initialize the techs knowledge base first by asking the Team Leader:
|
|
400
|
-
"Initialize technology knowledge base"
|
|
400
|
+
"Initialize technology knowledge base"
|
|
401
401
|
|
|
402
402
|
This is required for system design to understand your project's technology stack,
|
|
403
403
|
conventions, and architecture patterns.
|
|
@@ -475,9 +475,9 @@ Capability Gaps Identified: {count}
|
|
|
475
475
|
└── No new frameworks needed (if applicable)
|
|
476
476
|
|
|
477
477
|
Do you approve these framework decisions?
|
|
478
|
-
- "
|
|
479
|
-
- "
|
|
480
|
-
- "
|
|
478
|
+
- "Confirm" or "OK" → Proceed to Phase 4 (DESIGN-OVERVIEW generation)
|
|
479
|
+
- "Modify" + specific changes → Re-evaluate with adjusted scope
|
|
480
|
+
- "Cancel" → Abort workflow
|
|
481
481
|
```
|
|
482
482
|
|
|
483
483
|
**MANDATORY**: DO NOT proceed to Phase 4 until user explicitly confirms.
|
|
@@ -486,7 +486,7 @@ Do you approve these framework decisions?
|
|
|
486
486
|
If no new frameworks needed, state explicitly:
|
|
487
487
|
```
|
|
488
488
|
✅ No capability gaps identified. Current tech stack is sufficient.
|
|
489
|
-
Proceed to Phase 4? (
|
|
489
|
+
Proceed to Phase 4? (Confirm/Cancel)
|
|
490
490
|
```
|
|
491
491
|
|
|
492
492
|
### 3.4 Framework Evaluation Error Recovery
|
|
@@ -529,7 +529,7 @@ Create the top-level overview at:
|
|
|
529
529
|
| F-CRM-02 | customer-detail | [link] | [link] |
|
|
530
530
|
| ... | ... | ... | ... |
|
|
531
531
|
|
|
532
|
-
>
|
|
532
|
+
> **Legacy Format Compatibility**: If file uses legacy format (no Feature ID), Feature ID column shows `-`, using module name as Feature Name
|
|
533
533
|
|
|
534
534
|
## 2. Technology Decisions
|
|
535
535
|
- Framework evaluation results (from Phase 3)
|
|
@@ -544,13 +544,13 @@ Create the top-level overview at:
|
|
|
544
544
|
| F-CRM-02 | customer-detail | Web Frontend | web-vue | speccrew-sd-frontend | web-vue/F-CRM-02-customer-detail-design.md | pending |
|
|
545
545
|
| ... | ... | ... | ... | ... | ... | ... |
|
|
546
546
|
|
|
547
|
-
>
|
|
548
|
-
> -
|
|
549
|
-
> -
|
|
547
|
+
> **Notes**:
|
|
548
|
+
> - New Format: Design Directory contains `{feature-id}-{feature-name}` (e.g., `F-CRM-01-customer-list-design.md`)
|
|
549
|
+
> - Legacy Format: Design Directory uses `{module}-design.md`
|
|
550
550
|
|
|
551
551
|
## 4. Feature Summary (Optional)
|
|
552
552
|
|
|
553
|
-
|
|
553
|
+
When Feature count is large (>5), add this subsection to provide a summary view:
|
|
554
554
|
|
|
555
555
|
### 4.1 Feature by Module
|
|
556
556
|
| Module | Feature Count | Feature IDs |
|
|
@@ -649,10 +649,10 @@ Before dispatching, create or update dispatch tracking:
|
|
|
649
649
|
[{"id":"sd-web-vue-F-CRM-01","platform":"web-vue","feature_id":"F-CRM-01","feature_name":"customer-list","skill":"speccrew-sd-frontend","status":"pending"}]
|
|
650
650
|
```
|
|
651
651
|
|
|
652
|
-
**Task ID
|
|
653
|
-
-
|
|
654
|
-
-
|
|
655
|
-
-
|
|
652
|
+
**Task ID Format Update**:
|
|
653
|
+
- Legacy Format: `sd-{platform}-{feature}` (e.g., `sd-web-vue-customer-list`)
|
|
654
|
+
- **New Format**: `sd-{platform}-{feature-id}` (e.g., `sd-web-vue-F-CRM-01`)
|
|
655
|
+
- Legacy Compatibility: If no Feature ID, use feature_name (e.g., `sd-web-vue-crm`)
|
|
656
656
|
|
|
657
657
|
2. **Check existing progress** (from Step 0.3) — skip `completed` tasks
|
|
658
658
|
3. **Update status** to `in_progress` for tasks being dispatched:
|
|
@@ -672,12 +672,12 @@ When there is only one Feature Spec and one platform:
|
|
|
672
672
|
2. Call skill directly with parameters:
|
|
673
673
|
- Skill path: determined by platform type mapping (see 5.1)
|
|
674
674
|
- Pass context:
|
|
675
|
-
- `task_id`: Task identifier for progress tracking
|
|
676
|
-
- `feature_id`: Feature ID
|
|
677
|
-
- `feature_name`: Feature Name
|
|
675
|
+
- `task_id`: Task identifier for progress tracking (format: `sd-{platform_id}-{feature_id}` or `sd-{platform_id}-{feature_name}`)
|
|
676
|
+
- `feature_id`: Feature ID (new format e.g., `F-CRM-01`, legacy format is null)
|
|
677
|
+
- `feature_name`: Feature Name (e.g., `customer-list` or `crm`)
|
|
678
678
|
- `platform_id`: Platform identifier from techs-manifest
|
|
679
|
-
- `feature_spec_path`: Path to Feature Spec document
|
|
680
|
-
- `api_contract_path`: Path to API Contract document
|
|
679
|
+
- `feature_spec_path`: Path to Feature Spec document (actual path from Feature Registry)
|
|
680
|
+
- `api_contract_path`: Path to API Contract document (actual path from Feature Registry)
|
|
681
681
|
- `techs_paths`: Relevant techs knowledge paths
|
|
682
682
|
- `framework_decisions`: Framework decisions from Phase 3
|
|
683
683
|
|
|
@@ -707,12 +707,12 @@ When multiple Feature Specs and/or multiple platforms exist, create a matrix of
|
|
|
707
707
|
Each worker receives:
|
|
708
708
|
- `skill_path`: {ide_skills_dir}/{skill_name}/SKILL.md (per-platform design skill based on platform type, see 5.1)
|
|
709
709
|
- `context`:
|
|
710
|
-
- `task_id`: Unique task identifier
|
|
711
|
-
- `feature_id`: Feature ID
|
|
712
|
-
- `feature_name`: Feature Name
|
|
710
|
+
- `task_id`: Unique task identifier (format: `sd-{platform_id}-{feature_id}`, e.g., `sd-web-vue-F-CRM-01`)
|
|
711
|
+
- `feature_id`: Feature ID (new format e.g., `F-CRM-01`, legacy format is null)
|
|
712
|
+
- `feature_name`: Feature Name (e.g., `customer-list`)
|
|
713
713
|
- `platform_id`: Platform identifier from techs-manifest
|
|
714
|
-
- `feature_spec_path`: Path to ONE Feature Spec document (not all,
|
|
715
|
-
- `api_contract_path`: API Contract document path (
|
|
714
|
+
- `feature_spec_path`: Path to ONE Feature Spec document (not all, from Feature Registry)
|
|
715
|
+
- `api_contract_path`: API Contract document path (from Feature Registry)
|
|
716
716
|
- `techs_knowledge_paths`: Techs knowledge paths for this platform
|
|
717
717
|
- `framework_decisions`: Framework decisions from Phase 3
|
|
718
718
|
- `output_base_path`: Path to `03.system-design/` directory
|
|
@@ -860,9 +860,9 @@ Design Documents Summary:
|
|
|
860
860
|
Document Status: 📝 Draft (pending your confirmation)
|
|
861
861
|
|
|
862
862
|
Please review all design documents above.
|
|
863
|
-
- "
|
|
864
|
-
- "
|
|
865
|
-
- "
|
|
863
|
+
- "Confirm" or "OK" → Finalize all designs, update workflow status to confirmed
|
|
864
|
+
- "Modify" + specific Feature/Platform → Re-dispatch design workers for specified scope
|
|
865
|
+
- "Cancel" → Abort workflow, save partial results
|
|
866
866
|
```
|
|
867
867
|
|
|
868
868
|
**MANDATORY**: DO NOT proceed to Phase 6.2 (Update Checkpoints) until user explicitly confirms.
|
|
@@ -871,7 +871,7 @@ Please review all design documents above.
|
|
|
871
871
|
|
|
872
872
|
### 6.2 DISPATCH-PROGRESS.json Task Entry Format
|
|
873
873
|
|
|
874
|
-
|
|
874
|
+
Each task entry contains the following fields:
|
|
875
875
|
```json
|
|
876
876
|
{
|
|
877
877
|
"id": "sd-web-vue-F-CRM-01",
|
|
@@ -884,7 +884,7 @@ Please review all design documents above.
|
|
|
884
884
|
}
|
|
885
885
|
```
|
|
886
886
|
|
|
887
|
-
|
|
887
|
+
Legacy Format Compatibility (no Feature ID):
|
|
888
888
|
```json
|
|
889
889
|
{
|
|
890
890
|
"id": "sd-web-vue-crm",
|
|
@@ -923,74 +923,74 @@ After user confirms:
|
|
|
923
923
|
| Platform Index | `{iterations_dir}/{number}-{type}-{name}/03.system-design/{platform_id}/INDEX.md` | `speccrew-sd-frontend/templates/INDEX-TEMPLATE.md`, `speccrew-sd-backend/templates/INDEX-TEMPLATE.md`, `speccrew-sd-mobile/templates/INDEX-TEMPLATE.md`, or `speccrew-sd-desktop/templates/INDEX-TEMPLATE.md` |
|
|
924
924
|
| Module Design | `{iterations_dir}/{number}-{type}-{name}/03.system-design/{platform_id}/{feature-id}-{feature-name}-design.md` | `speccrew-sd-frontend/templates/SD-FRONTEND-TEMPLATE.md`, `speccrew-sd-backend/templates/SD-BACKEND-TEMPLATE.md`, `speccrew-sd-mobile/templates/SD-MOBILE-TEMPLATE.md`, or `speccrew-sd-desktop/templates/SD-DESKTOP-TEMPLATE.md` |
|
|
925
925
|
|
|
926
|
-
|
|
926
|
+
**Output File Naming Rules**:
|
|
927
927
|
|
|
928
|
-
1.
|
|
929
|
-
-
|
|
930
|
-
-
|
|
931
|
-
-
|
|
928
|
+
1. **New Format** (with Feature ID):
|
|
929
|
+
- Format: `{feature-id}-{feature-name}-design.md`
|
|
930
|
+
- Example: `F-CRM-01-customer-list-design.md`
|
|
931
|
+
- Path: `03.system-design/web-vue/F-CRM-01-customer-list-design.md`
|
|
932
932
|
|
|
933
|
-
2.
|
|
934
|
-
-
|
|
935
|
-
-
|
|
936
|
-
-
|
|
933
|
+
2. **Legacy Format Compatibility** (no Feature ID):
|
|
934
|
+
- Format: `{module}-design.md`
|
|
935
|
+
- Example: `crm-design.md`
|
|
936
|
+
- Path: `03.system-design/web-vue/crm-design.md`
|
|
937
937
|
|
|
938
|
-
|
|
939
|
-
-
|
|
940
|
-
-
|
|
938
|
+
**Backward Compatibility Logic**:
|
|
939
|
+
- If `feature_id` exists → use `{feature-id}-{feature-name}-design.md`
|
|
940
|
+
- If `feature_id` is null (legacy format) → use `{module}-design.md`
|
|
941
941
|
|
|
942
942
|
# Backward Compatibility
|
|
943
943
|
|
|
944
|
-
|
|
944
|
+
This Agent supports both new and legacy Feature Spec file formats:
|
|
945
945
|
|
|
946
|
-
##
|
|
946
|
+
## New Format (Fine-grained Feature)
|
|
947
947
|
|
|
948
|
-
|
|
948
|
+
**File Name Format**:
|
|
949
949
|
- Feature Spec: `{feature-id}-{feature-name}-feature-spec.md`
|
|
950
950
|
- API Contract: `{feature-id}-{feature-name}-api-contract.md`
|
|
951
951
|
|
|
952
|
-
|
|
952
|
+
**Examples**:
|
|
953
953
|
- `F-CRM-01-customer-list-feature-spec.md`
|
|
954
954
|
- `F-CRM-01-customer-list-api-contract.md`
|
|
955
955
|
|
|
956
|
-
|
|
957
|
-
-
|
|
958
|
-
-
|
|
959
|
-
- Feature ID
|
|
956
|
+
**Characteristics**:
|
|
957
|
+
- File name starts with `F-`
|
|
958
|
+
- Contains Feature ID (e.g., `F-CRM-01`)
|
|
959
|
+
- Feature ID format: `F-{MODULE}-{NN}`
|
|
960
960
|
|
|
961
|
-
##
|
|
961
|
+
## Legacy Format (Module-level Feature)
|
|
962
962
|
|
|
963
|
-
|
|
963
|
+
**File Name Format**:
|
|
964
964
|
- Feature Spec: `{module-name}-feature-spec.md`
|
|
965
965
|
- API Contract: `{module-name}-api-contract.md`
|
|
966
966
|
|
|
967
|
-
|
|
967
|
+
**Examples**:
|
|
968
968
|
- `crm-feature-spec.md`
|
|
969
969
|
- `crm-api-contract.md`
|
|
970
970
|
|
|
971
|
-
|
|
972
|
-
-
|
|
973
|
-
-
|
|
974
|
-
-
|
|
971
|
+
**Characteristics**:
|
|
972
|
+
- File name does not start with `F-`
|
|
973
|
+
- No Feature ID
|
|
974
|
+
- Uses module name as identifier
|
|
975
975
|
|
|
976
|
-
##
|
|
976
|
+
## Format Detection Logic
|
|
977
977
|
|
|
978
978
|
```
|
|
979
|
-
|
|
980
|
-
→
|
|
981
|
-
|
|
982
|
-
→
|
|
979
|
+
File name starts with "F-" and matches regex ^F-[A-Z]+-\d+-
|
|
980
|
+
→ New format, extract Feature ID
|
|
981
|
+
Otherwise
|
|
982
|
+
→ Legacy format, use module name
|
|
983
983
|
```
|
|
984
984
|
|
|
985
|
-
##
|
|
985
|
+
## Backward Compatibility Handling
|
|
986
986
|
|
|
987
|
-
|
|
|
988
|
-
|
|
989
|
-
| Feature ID |
|
|
990
|
-
| Feature Name |
|
|
991
|
-
| Task ID |
|
|
992
|
-
|
|
|
993
|
-
| DESIGN-OVERVIEW | Feature ID
|
|
987
|
+
| Scenario | Handling |
|
|
988
|
+
|----------|----------|
|
|
989
|
+
| Feature ID | New format: extract `F-{MODULE}-{NN}`; Legacy format: null |
|
|
990
|
+
| Feature Name | New format: extract from filename; Legacy format: module name |
|
|
991
|
+
| Task ID | New format: `sd-{platform}-{feature-id}`; Legacy format: `sd-{platform}-{feature_name}` |
|
|
992
|
+
| Output Filename | New format: `{feature-id}-{feature-name}-design.md`; Legacy format: `{module}-design.md` |
|
|
993
|
+
| DESIGN-OVERVIEW | Feature ID column shows `-` or actual ID |
|
|
994
994
|
|
|
995
995
|
# Constraints
|
|
996
996
|
|
|
@@ -108,3 +108,4 @@ PM Agent (speccrew-product-manager)
|
|
|
108
108
|
3. **Read-Only Assessment**: This skill performs assessment only, no file modifications
|
|
109
109
|
4. **Escalation Path**: Simple workflow can escalate to complex if scope expands during execution
|
|
110
110
|
5. **Single Gateway**: Use exclusive gateway for routing decision - only one path selected
|
|
111
|
+
6. **FORBIDDEN File Generation**: Phase 2 MUST NOT create any output files (evaluation reports, assessment JSON, markdown summaries, etc.). All output must be returned as variables only via the output block. Creating files outside of block definitions violates Strict Block Adherence.
|
|
@@ -18,6 +18,8 @@
|
|
|
18
18
|
<field name="text">This skill is READ-ONLY - do not modify any files</field>
|
|
19
19
|
<field name="text">Phase 2.0 verification is MANDATORY - cannot be skipped</field>
|
|
20
20
|
<field name="text">If knowledge initialization incomplete, report error and STOP</field>
|
|
21
|
+
<field name="text">FORBIDDEN: DO NOT create evaluation reports, assessment JSON files, or any other output files. All output must be returned as variables in the output block only.</field>
|
|
22
|
+
<field name="text">Any file created outside of block-defined output paths is considered an error and violates Strict Block Adherence.</field>
|
|
21
23
|
</block>
|
|
22
24
|
|
|
23
25
|
<!-- ============================================================
|
|
@@ -2,14 +2,15 @@
|
|
|
2
2
|
|
|
3
3
|
## Description
|
|
4
4
|
|
|
5
|
-
PM Phase 5 Sub-PRD Batch Dispatch Skill.
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
- Reading Dispatch Plan from Master PRD
|
|
9
|
-
- Initializing dispatch progress tracking
|
|
10
|
-
-
|
|
11
|
-
- Failure retry
|
|
12
|
-
|
|
5
|
+
PM Phase 5 Sub-PRD Batch Dispatch Skill. Core orchestration component for Master-Sub PRD workflow, executed directly by PM Agent (NOT dispatched to Worker).
|
|
6
|
+
|
|
7
|
+
PM Agent loads and executes this skill directly to coordinate batch dispatch of Sub-PRD generation tasks to Worker Agents, implementing:
|
|
8
|
+
- Reading Dispatch Plan from Master PRD
|
|
9
|
+
- Initializing dispatch progress tracking
|
|
10
|
+
- Dispatching Workers in parallel batches for Sub-PRD generation per module
|
|
11
|
+
- Failure retry and result verification
|
|
12
|
+
|
|
13
|
+
**CRITICAL**: This skill contains dispatch-to-worker logic internally. It MUST be executed by PM Agent (who has Agent tool access), NOT by a Worker Agent (who cannot create sub-Workers).
|
|
13
14
|
|
|
14
15
|
## Input Parameters
|
|
15
16
|
|
|
@@ -17,9 +17,9 @@
|
|
|
17
17
|
Global Invocation Rules
|
|
18
18
|
============================================================ -->
|
|
19
19
|
<block type="rule" id="GLOBAL-R-INVOCATION" level="mandatory" desc="Invocation constraints - NEVER violate">
|
|
20
|
-
<field name="text">This skill MUST be loaded directly by PM Agent via
|
|
21
|
-
<field name="text">
|
|
22
|
-
<field name="text">
|
|
20
|
+
<field name="text">This skill MUST be loaded and executed directly by PM Agent (via run-skill action in orchestration)</field>
|
|
21
|
+
<field name="text">PM Agent will internally dispatch Workers to execute speccrew-pm-sub-prd-generate via dispatch-to-worker</field>
|
|
22
|
+
<field name="text">Worker Agents MUST NOT attempt to execute this skill - this is an orchestration-level skill</field>
|
|
23
23
|
</block>
|
|
24
24
|
|
|
25
25
|
<!-- ============================================================
|
|
@@ -94,3 +94,12 @@ Applies ISA-95 Stage 1 (Domain Description) for clarification:
|
|
|
94
94
|
- Each clarification round MUST wait for user to fill in answers before proceeding
|
|
95
95
|
- Checkpoint writing is FORBIDDEN in this Skill — checkpoints are managed by the orchestration layer
|
|
96
96
|
- The sufficiency check result is ONLY valid when based on real user-provided answers
|
|
97
|
+
|
|
98
|
+
### CRITICAL: Summary Generation Guard
|
|
99
|
+
|
|
100
|
+
Worker MUST strictly enforce the following before generating `.clarification-summary.md`:
|
|
101
|
+
|
|
102
|
+
1. **Guard Check**: `sufficiency_checks_passed` MUST be `true` before proceeding to summary generation
|
|
103
|
+
2. **Event Block Execution**: When encountering `user-confirm` event blocks (E-ROUND-CONFIRM), Worker MUST pause and wait for user confirmation. Worker MUST NOT auto-confirm or skip.
|
|
104
|
+
3. **Variable State Verification**: After loop L1 exits, verify `sufficiency_checks_passed == true`. If false, do NOT generate summary — report error and exit.
|
|
105
|
+
4. **FORBIDDEN**: Generating `.clarification-summary.md` when user has not answered clarification questions is a CRITICAL workflow violation.
|
|
@@ -168,34 +168,53 @@
|
|
|
168
168
|
</branch>
|
|
169
169
|
</block>
|
|
170
170
|
|
|
171
|
-
<!--
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
171
|
+
<!-- ============================================================
|
|
172
|
+
Summary Generation Guard
|
|
173
|
+
============================================================ -->
|
|
174
|
+
<block type="rule" id="R-SUMMARY-GUARD" level="mandatory" desc="Summary generation guard - only when sufficiency checks pass">
|
|
175
|
+
<field name="text">MANDATORY: .clarification-summary.md can ONLY be generated when ALL sufficiency checks have passed (sufficiency_checks_passed == true).</field>
|
|
176
|
+
<field name="text">If sufficiency_checks_passed is false, Worker MUST NOT generate summary. Instead, Worker MUST exit and return control to PM Agent with error status.</field>
|
|
177
|
+
<field name="text">Generating a summary without completed user answers is a CRITICAL workflow violation.</field>
|
|
175
178
|
</block>
|
|
176
179
|
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
<
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
180
|
+
<!-- Step 6: Generate .clarification-summary.md (Guarded by G3) -->
|
|
181
|
+
<block type="gateway" id="G3" mode="exclusive" desc="Guard: Only generate summary if sufficiency checks passed">
|
|
182
|
+
<branch test="${sufficiency_checks_passed} == true" name="Sufficiency Passed - Generate Summary">
|
|
183
|
+
<block type="task" id="B10-load-template" action="read-file" desc="Load summary template">
|
|
184
|
+
<field name="path" value="${skill_path}/templates/CLARIFICATION-SUMMARY-TEMPLATE.md"/>
|
|
185
|
+
<field name="output" var="summary_template"/>
|
|
186
|
+
</block>
|
|
187
|
+
|
|
188
|
+
<block type="task" id="B10" action="generate" desc="Generate clarification summary from template">
|
|
189
|
+
<field name="template" value="${summary_template}"/>
|
|
190
|
+
<field name="output_path" value="${iteration_path}/01.product-requirement/.clarification-summary.md"/>
|
|
191
|
+
<field name="vars">
|
|
192
|
+
- iteration_name: ${iteration_name}
|
|
193
|
+
- total_rounds: ${round_number - 1}
|
|
194
|
+
- date: ${current_date}
|
|
195
|
+
- sufficiency_result: ${sufficiency_result.all_passed ? 'PASSED' : 'PARTIAL'}
|
|
196
|
+
- checks_passed: ${sufficiency_result.passed_count}
|
|
197
|
+
- requirement_overview: ${requirement_summary}
|
|
198
|
+
- business_complexity: ${complexity}
|
|
199
|
+
- technical_complexity: ${complexity}
|
|
200
|
+
- integration_complexity: ${complexity}
|
|
201
|
+
- overall_complexity: ${complexity}
|
|
202
|
+
</field>
|
|
203
|
+
<field name="output" var="summary_path"/>
|
|
204
|
+
</block>
|
|
194
205
|
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
206
|
+
<!-- Checkpoint: Clarification complete -->
|
|
207
|
+
<block type="checkpoint" id="CP1" name="clarification-complete" desc="Verify clarification completed">
|
|
208
|
+
<field name="file" value="${summary_path}"/>
|
|
209
|
+
<field name="verify" value="file_exists(${summary_path})"/>
|
|
210
|
+
</block>
|
|
211
|
+
</branch>
|
|
212
|
+
<branch default="true" name="Sufficiency Failed - Exit with Error">
|
|
213
|
+
<block type="task" id="B-INSUFFICIENCY-EXIT" action="set-variable" desc="Set error status for insufficient clarification">
|
|
214
|
+
<field name="error_type">INSUFFICIENT_CLARIFICATION</field>
|
|
215
|
+
<field name="message">Requirement clarification did not achieve sufficiency. Worker exits and returns control to PM Agent.</field>
|
|
216
|
+
</block>
|
|
217
|
+
</branch>
|
|
199
218
|
</block>
|
|
200
219
|
|
|
201
220
|
</sequence>
|
|
@@ -16,6 +16,8 @@ tools: Read, Write, Glob, Grep, Bash, Agent
|
|
|
16
16
|
> 🔧 Tool: [which IDE tool to call]
|
|
17
17
|
> ✅ Result: [output or status]
|
|
18
18
|
> ```
|
|
19
|
+
|
|
20
|
+
> ⚠️ **CRITICAL ENFORCEMENT**: Every orchestration workflow execution MUST include block-by-block announcements. If you find yourself dispatching Workers without announcing each Phase block, STOP and correct your execution. This protocol is mandatory and non-negotiable.
|
|
19
21
|
>
|
|
20
22
|
> Action-to-tool mapping:
|
|
21
23
|
> - `action="run-skill"` → Invoke via **Skill tool** (pass the `<field name="skill">` value EXACTLY)
|
|
@@ -194,15 +194,16 @@
|
|
|
194
194
|
<branch default="true" name="Execute Phase 5" goto="P5"/>
|
|
195
195
|
</block>
|
|
196
196
|
|
|
197
|
-
<block type="task" id="P5" action="
|
|
198
|
-
<field name="worker">speccrew-task-worker</field>
|
|
197
|
+
<block type="task" id="P5" action="run-skill" desc="Phase 5: Sub-PRD dispatch (PM executes directly)">
|
|
199
198
|
<field name="skill">speccrew-pm-phase5-subprd-dispatch</field>
|
|
200
199
|
<field name="context">{
|
|
200
|
+
"prd_output": {
|
|
201
|
+
"master_prd_path": "${phase4b_result.master_prd_path}",
|
|
202
|
+
"dispatch_plan_path": "${phase4b_result.dispatch_plan_path}"
|
|
203
|
+
},
|
|
201
204
|
"workspace_path": "${phase0_result.workspace_path}",
|
|
202
205
|
"iteration_path": "${phase0_result.iteration_path}",
|
|
203
206
|
"update_progress_script": "${phase0_result.update_progress_script}",
|
|
204
|
-
"master_prd_path": "${phase4b_result.master_prd_path}",
|
|
205
|
-
"dispatch_plan_path": "${phase4b_result.dispatch_plan_path}",
|
|
206
207
|
"language": "${language}"
|
|
207
208
|
}</field>
|
|
208
209
|
<field name="output" var="phase5_result"/>
|