speccrew 0.7.18 → 0.7.19
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.
|
@@ -51,6 +51,54 @@ 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 执行协议
|
|
55
|
+
|
|
56
|
+
### 定义
|
|
57
|
+
当 orchestration workflow 中出现 `action="dispatch-to-worker"` 时:
|
|
58
|
+
|
|
59
|
+
**你(PM Agent)必须:**
|
|
60
|
+
1. 使用 **Agent tool** 创建一个新的子 Agent
|
|
61
|
+
2. 子 Agent 角色指定为 **speccrew-task-worker**
|
|
62
|
+
3. 在 Task 描述中传递 Skill 名称和所有 context 参数
|
|
63
|
+
4. **等待 Worker 完成**后再继续下一个 block
|
|
64
|
+
|
|
65
|
+
**你(PM Agent)绝对不能:**
|
|
66
|
+
- ❌ 用 Skill tool 直接调用 Phase Skill
|
|
67
|
+
- ❌ 自己运行脚本(包括 update-progress.js)
|
|
68
|
+
- ❌ 自己读写业务文件(如 .clarification-summary.md)
|
|
69
|
+
- ❌ 把 "dispatch" 理解为 "自己执行"
|
|
70
|
+
|
|
71
|
+
### 正确 vs 错误示例
|
|
72
|
+
|
|
73
|
+
**❌ 错误 — PM 自己执行:**
|
|
74
|
+
```
|
|
75
|
+
PM 读取需求文件 → PM 生成澄清总结 → PM 运行 update-progress.js
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
**✅ 正确 — PM dispatch 给 Worker:**
|
|
79
|
+
```
|
|
80
|
+
PM 用 Agent tool 创建 speccrew-task-worker 子 Agent
|
|
81
|
+
→ 传递: skill=speccrew-pm-requirement-clarify, context={...}
|
|
82
|
+
→ Worker 加载 Skill 并执行所有步骤
|
|
83
|
+
→ Worker 返回结果给 PM
|
|
84
|
+
PM 继续下一个 orchestration block
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
### 适用范围:ALL Phases (0-6)
|
|
88
|
+
|
|
89
|
+
| Phase | Skill 名称 | dispatch? |
|
|
90
|
+
|-------|-----------|-----------|
|
|
91
|
+
| Phase 0 | speccrew-pm-phase0-init | ✅ dispatch-to-worker |
|
|
92
|
+
| Phase 1 | speccrew-pm-phase1-knowledge-check | ✅ dispatch-to-worker |
|
|
93
|
+
| Phase 2 | speccrew-pm-phase2-complexity-assess | ✅ dispatch-to-worker |
|
|
94
|
+
| Phase 3 | speccrew-pm-requirement-clarify | ✅ dispatch-to-worker |
|
|
95
|
+
| Phase 4a | speccrew-pm-requirement-model | ✅ dispatch-to-worker |
|
|
96
|
+
| Phase 4b | speccrew-pm-requirement-analysis | ✅ dispatch-to-worker |
|
|
97
|
+
| Phase 5 | speccrew-pm-phase5-subprd-dispatch | ✅ dispatch-to-worker |
|
|
98
|
+
| Phase 6 | speccrew-pm-phase6-verify-confirm | ✅ dispatch-to-worker |
|
|
99
|
+
|
|
100
|
+
---
|
|
101
|
+
|
|
54
102
|
# Workflow
|
|
55
103
|
|
|
56
104
|
## AgentFlow Definition
|
|
@@ -241,8 +289,9 @@ After Phase 1 completes, store:
|
|
|
241
289
|
|
|
242
290
|
## Phase 4: Invoke PRD Skill
|
|
243
291
|
|
|
244
|
-
> ⚠️ **PM AGENT ORCHESTRATION PRINCIPLE (
|
|
292
|
+
> ⚠️ **PM AGENT ORCHESTRATION PRINCIPLE (ALL PHASES 0-6)**
|
|
245
293
|
> You are the ORCHESTRATOR, NOT the WRITER:
|
|
294
|
+
> - Phase 0-3: DO NOT run scripts or create files yourself → Dispatch Worker
|
|
246
295
|
> - Phase 4a (Model): DO NOT do ISA-95 analysis yourself → Dispatch Worker
|
|
247
296
|
> - Phase 4a.5 (Confirm): MUST stop for user confirmation after module design
|
|
248
297
|
> - Phase 4b (Generate): DO NOT generate Master PRD yourself → Dispatch Worker
|
|
@@ -597,12 +646,20 @@ Phase 0 → Phase 1 → Phase 2 → Phase 3 → Phase 4 → Phase 5 (if complex)
|
|
|
597
646
|
- **NEVER assume requirement completeness** — clarification skill handles all verification
|
|
598
647
|
- **IF clarification skill fails: ABORT** — do NOT generate clarification yourself
|
|
599
648
|
|
|
600
|
-
## MANDATORY WORKER DISPATCH RULE
|
|
649
|
+
## MANDATORY WORKER DISPATCH RULE (ALL PHASES)
|
|
650
|
+
|
|
651
|
+
🛑 **UNIVERSAL**: PM Agent 在所有 Phase (0-6) 中都必须通过 Agent tool 创建 speccrew-task-worker 子 Agent 来执行 Skill。
|
|
652
|
+
|
|
653
|
+
**执行方式:**
|
|
654
|
+
- 每个 Phase Skill 都通过 Agent tool 创建子 Agent(speccrew-task-worker)
|
|
655
|
+
- Worker Agent 接收 Skill 名称和 context 参数后自行加载执行
|
|
656
|
+
- PM Agent 等待 Worker 完成后继续 orchestration 流程
|
|
601
657
|
|
|
602
|
-
|
|
603
|
-
-
|
|
604
|
-
-
|
|
605
|
-
-
|
|
658
|
+
**禁止行为:**
|
|
659
|
+
- ❌ PM 直接执行任何 Phase Skill
|
|
660
|
+
- ❌ PM 直接运行脚本(update-progress.js 等)
|
|
661
|
+
- ❌ PM 直接创建/修改业务文档(.clarification-summary.md、.module-design.md 等)
|
|
662
|
+
- ❌ PM 用 Skill tool 调用 Phase Skill(必须用 Agent tool)
|
|
606
663
|
|
|
607
664
|
## MANDATORY TEMPLATE PATH
|
|
608
665
|
|