speccrew 0.6.69 → 0.7.0

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.
Files changed (134) hide show
  1. package/.speccrew/agents/speccrew-task-worker.md +1 -1
  2. package/.speccrew/agents/speccrew-team-leader.md +336 -189
  3. package/.speccrew/skills/speccrew-agentflow-manager/SKILL.md +161 -0
  4. package/.speccrew/skills/speccrew-agentflow-manager/workflow.agentflow.xml +347 -0
  5. package/.speccrew/skills/speccrew-deploy-build/SKILL.md +3 -56
  6. package/.speccrew/skills/speccrew-deploy-build/workflow.agentflow.xml +125 -0
  7. package/.speccrew/skills/speccrew-deploy-migrate/SKILL.md +3 -64
  8. package/.speccrew/skills/speccrew-deploy-migrate/workflow.agentflow.xml +135 -0
  9. package/.speccrew/skills/speccrew-deploy-smoke-test/SKILL.md +4 -156
  10. package/.speccrew/skills/speccrew-deploy-smoke-test/workflow.agentflow.xml +178 -0
  11. package/.speccrew/skills/speccrew-deploy-startup/SKILL.md +3 -135
  12. package/.speccrew/skills/speccrew-deploy-startup/workflow.agentflow.xml +223 -0
  13. package/.speccrew/skills/speccrew-dev-backend/SKILL.md +10 -2
  14. package/.speccrew/skills/speccrew-dev-backend/workflow.agentflow.xml +254 -0
  15. package/.speccrew/skills/speccrew-dev-desktop-electron/SKILL.md +10 -2
  16. package/.speccrew/skills/speccrew-dev-desktop-electron/workflow.agentflow.xml +259 -0
  17. package/.speccrew/skills/speccrew-dev-desktop-tauri/SKILL.md +10 -2
  18. package/.speccrew/skills/speccrew-dev-desktop-tauri/workflow.agentflow.xml +245 -0
  19. package/.speccrew/skills/speccrew-dev-frontend/SKILL.md +10 -2
  20. package/.speccrew/skills/speccrew-dev-frontend/workflow.agentflow.xml +262 -0
  21. package/.speccrew/skills/speccrew-dev-mobile/SKILL.md +10 -2
  22. package/.speccrew/skills/speccrew-dev-mobile/workflow.agentflow.xml +244 -0
  23. package/.speccrew/skills/speccrew-dev-review-backend/SKILL.md +10 -2
  24. package/.speccrew/skills/speccrew-dev-review-backend/workflow.agentflow.xml +251 -0
  25. package/.speccrew/skills/speccrew-dev-review-desktop/SKILL.md +10 -2
  26. package/.speccrew/skills/speccrew-dev-review-desktop/workflow.agentflow.xml +214 -0
  27. package/.speccrew/skills/speccrew-dev-review-frontend/SKILL.md +10 -2
  28. package/.speccrew/skills/speccrew-dev-review-frontend/workflow.agentflow.xml +213 -0
  29. package/.speccrew/skills/speccrew-dev-review-mobile/SKILL.md +10 -2
  30. package/.speccrew/skills/speccrew-dev-review-mobile/workflow.agentflow.xml +214 -0
  31. package/.speccrew/skills/speccrew-fd-api-contract/SKILL.md +7 -1
  32. package/.speccrew/skills/speccrew-fd-api-contract/workflow.agentflow.xml +222 -0
  33. package/.speccrew/skills/speccrew-fd-feature-analyze/SKILL.md +7 -1
  34. package/.speccrew/skills/speccrew-fd-feature-analyze/workflow.agentflow.xml +223 -0
  35. package/.speccrew/skills/speccrew-fd-feature-design/SKILL.md +7 -1
  36. package/.speccrew/skills/speccrew-fd-feature-design/workflow.agentflow.xml +322 -0
  37. package/.speccrew/skills/speccrew-get-timestamp/SKILL.md +3 -39
  38. package/.speccrew/skills/speccrew-get-timestamp/workflow.agentflow.xml +43 -0
  39. package/.speccrew/skills/speccrew-knowledge-bizs-api-analyze/SKILL.md +57 -508
  40. package/.speccrew/skills/{speccrew-knowledge-bizs-api-analyze-xml/SKILL.md → speccrew-knowledge-bizs-api-analyze/workflow.agentflow.xml} +1 -154
  41. package/.speccrew/skills/speccrew-knowledge-bizs-api-graph/SKILL.md +73 -283
  42. package/.speccrew/skills/{speccrew-knowledge-bizs-api-graph-xml/SKILL.md → speccrew-knowledge-bizs-api-graph/workflow.agentflow.xml} +0 -298
  43. package/.speccrew/skills/speccrew-knowledge-bizs-dispatch/SKILL.md +931 -801
  44. package/.speccrew/skills/{speccrew-knowledge-bizs-dispatch-xml/SKILL.md → speccrew-knowledge-bizs-dispatch/workflow.agentflow.xml} +42 -272
  45. package/.speccrew/skills/speccrew-knowledge-bizs-identify-entries/SKILL.md +263 -71
  46. package/.speccrew/skills/{speccrew-knowledge-bizs-identify-entries-xml/SKILL.md → speccrew-knowledge-bizs-identify-entries/workflow.agentflow.xml} +8 -184
  47. package/.speccrew/skills/speccrew-knowledge-bizs-init-features/SKILL.md +200 -181
  48. package/.speccrew/skills/{speccrew-knowledge-bizs-init-features-xml/SKILL.md → speccrew-knowledge-bizs-init-features/workflow.agentflow.xml} +7 -134
  49. package/.speccrew/skills/speccrew-knowledge-bizs-module-classify/SKILL.md +5 -89
  50. package/.speccrew/skills/speccrew-knowledge-bizs-module-classify/workflow.agentflow.xml +129 -0
  51. package/.speccrew/skills/speccrew-knowledge-bizs-ui-analyze/SKILL.md +454 -326
  52. package/.speccrew/skills/{speccrew-knowledge-bizs-ui-analyze-xml/SKILL.md → speccrew-knowledge-bizs-ui-analyze/workflow.agentflow.xml} +8 -128
  53. package/.speccrew/skills/speccrew-knowledge-bizs-ui-graph/SKILL.md +302 -247
  54. package/.speccrew/skills/{speccrew-knowledge-bizs-ui-graph-xml/SKILL.md → speccrew-knowledge-bizs-ui-graph/workflow.agentflow.xml} +7 -199
  55. package/.speccrew/skills/speccrew-knowledge-bizs-ui-style-extract/SKILL.md +267 -156
  56. package/.speccrew/skills/{speccrew-knowledge-bizs-ui-style-extract-xml/SKILL.md → speccrew-knowledge-bizs-ui-style-extract/workflow.agentflow.xml} +7 -151
  57. package/.speccrew/skills/speccrew-knowledge-graph-query/SKILL.md +3 -122
  58. package/.speccrew/skills/speccrew-knowledge-graph-query/workflow.agentflow.xml +106 -0
  59. package/.speccrew/skills/speccrew-knowledge-graph-write/SKILL.md +3 -80
  60. package/.speccrew/skills/speccrew-knowledge-graph-write/workflow.agentflow.xml +152 -0
  61. package/.speccrew/skills/speccrew-knowledge-module-summarize/SKILL.md +371 -265
  62. package/.speccrew/skills/{speccrew-knowledge-module-summarize-xml/SKILL.md → speccrew-knowledge-module-summarize/workflow.agentflow.xml} +7 -197
  63. package/.speccrew/skills/speccrew-knowledge-system-summarize/SKILL.md +45 -333
  64. package/.speccrew/skills/{speccrew-knowledge-system-summarize-xml/SKILL.md → speccrew-knowledge-system-summarize/workflow.agentflow.xml} +0 -177
  65. package/.speccrew/skills/speccrew-knowledge-techs-dispatch/SKILL.md +174 -727
  66. package/.speccrew/skills/{speccrew-knowledge-techs-dispatch-xml/SKILL.md → speccrew-knowledge-techs-dispatch/workflow.agentflow.xml} +10 -351
  67. package/.speccrew/skills/speccrew-knowledge-techs-generate/SKILL.md +20 -150
  68. package/.speccrew/skills/{speccrew-knowledge-techs-generate-xml/SKILL.md → speccrew-knowledge-techs-generate/workflow.agentflow.xml} +0 -169
  69. package/.speccrew/skills/speccrew-knowledge-techs-generate-conventions/SKILL.md +75 -587
  70. package/.speccrew/skills/{speccrew-knowledge-techs-generate-conventions-xml/SKILL.md → speccrew-knowledge-techs-generate-conventions/workflow.agentflow.xml} +0 -153
  71. package/.speccrew/skills/speccrew-knowledge-techs-generate-quality/SKILL.md +463 -297
  72. package/.speccrew/skills/{speccrew-knowledge-techs-generate-quality-xml/SKILL.md → speccrew-knowledge-techs-generate-quality/workflow.agentflow.xml} +0 -164
  73. package/.speccrew/skills/speccrew-knowledge-techs-generate-ui-style/SKILL.md +57 -292
  74. package/.speccrew/skills/{speccrew-knowledge-techs-generate-ui-style-xml/SKILL.md → speccrew-knowledge-techs-generate-ui-style/workflow.agentflow.xml} +2 -193
  75. package/.speccrew/skills/speccrew-knowledge-techs-index/SKILL.md +49 -335
  76. package/.speccrew/skills/{speccrew-knowledge-techs-index-xml/SKILL.md → speccrew-knowledge-techs-index/workflow.agentflow.xml} +0 -167
  77. package/.speccrew/skills/speccrew-knowledge-techs-init/SKILL.md +28 -109
  78. package/.speccrew/skills/{speccrew-knowledge-techs-init-xml/SKILL.md → speccrew-knowledge-techs-init/workflow.agentflow.xml} +0 -189
  79. package/.speccrew/skills/speccrew-knowledge-techs-ui-analyze/SKILL.md +3 -487
  80. package/.speccrew/skills/speccrew-knowledge-techs-ui-analyze/workflow.agentflow.xml +278 -0
  81. package/.speccrew/skills/speccrew-pm-knowledge-detector/SKILL.md +3 -71
  82. package/.speccrew/skills/speccrew-pm-knowledge-detector/workflow.agentflow.xml +108 -0
  83. package/.speccrew/skills/speccrew-pm-module-initializer/SKILL.md +3 -107
  84. package/.speccrew/skills/speccrew-pm-module-initializer/workflow.agentflow.xml +139 -0
  85. package/.speccrew/skills/speccrew-pm-module-matcher/SKILL.md +3 -115
  86. package/.speccrew/skills/speccrew-pm-module-matcher/workflow.agentflow.xml +146 -0
  87. package/.speccrew/skills/speccrew-pm-requirement-analysis/SKILL.md +3 -343
  88. package/.speccrew/skills/speccrew-pm-requirement-analysis/workflow.agentflow.xml +174 -0
  89. package/.speccrew/skills/speccrew-pm-requirement-assess/SKILL.md +3 -91
  90. package/.speccrew/skills/speccrew-pm-requirement-assess/workflow.agentflow.xml +173 -0
  91. package/.speccrew/skills/speccrew-pm-requirement-clarify/SKILL.md +3 -224
  92. package/.speccrew/skills/speccrew-pm-requirement-clarify/workflow.agentflow.xml +159 -0
  93. package/.speccrew/skills/speccrew-pm-requirement-model/SKILL.md +3 -275
  94. package/.speccrew/skills/speccrew-pm-requirement-model/workflow.agentflow.xml +210 -0
  95. package/.speccrew/skills/speccrew-pm-requirement-simple/SKILL.md +3 -76
  96. package/.speccrew/skills/speccrew-pm-requirement-simple/workflow.agentflow.xml +120 -0
  97. package/.speccrew/skills/speccrew-pm-sub-prd-generate/SKILL.md +7 -1
  98. package/.speccrew/skills/speccrew-pm-sub-prd-generate/workflow.agentflow.xml +218 -0
  99. package/.speccrew/skills/speccrew-sd-backend/SKILL.md +7 -1
  100. package/.speccrew/skills/speccrew-sd-backend/workflow.agentflow.xml +264 -0
  101. package/.speccrew/skills/speccrew-sd-desktop/SKILL.md +7 -1
  102. package/.speccrew/skills/speccrew-sd-desktop/workflow.agentflow.xml +288 -0
  103. package/.speccrew/skills/speccrew-sd-framework-evaluate/SKILL.md +7 -1
  104. package/.speccrew/skills/speccrew-sd-framework-evaluate/workflow.agentflow.xml +235 -0
  105. package/.speccrew/skills/speccrew-sd-frontend/SKILL.md +7 -1
  106. package/.speccrew/skills/speccrew-sd-frontend/workflow.agentflow.xml +299 -0
  107. package/.speccrew/skills/speccrew-sd-mobile/SKILL.md +7 -1
  108. package/.speccrew/skills/speccrew-sd-mobile/workflow.agentflow.xml +301 -0
  109. package/.speccrew/skills/speccrew-test-case-design/SKILL.md +165 -284
  110. package/.speccrew/skills/speccrew-test-case-design/workflow.agentflow.xml +210 -0
  111. package/.speccrew/skills/speccrew-test-code-gen/SKILL.md +204 -324
  112. package/.speccrew/skills/speccrew-test-code-gen/workflow.agentflow.xml +265 -0
  113. package/.speccrew/skills/speccrew-test-reporter/SKILL.md +205 -184
  114. package/.speccrew/skills/speccrew-test-reporter/workflow.agentflow.xml +284 -0
  115. package/.speccrew/skills/speccrew-test-runner/SKILL.md +242 -241
  116. package/.speccrew/skills/speccrew-test-runner/workflow.agentflow.xml +314 -0
  117. package/bin/cli.js +8 -1
  118. package/lib/commands/validate.js +565 -0
  119. package/package.json +1 -1
  120. package/workspace-template/docs/rules/{xml-workflow-spec.md → agentflow-spec.md} +5 -5
  121. package/workspace-template/scripts/validate-agentflow.js +637 -0
  122. package/.speccrew/agents/speccrew-team-leader-xml.md +0 -480
  123. package/.speccrew/skills/speccrew-knowledge-bizs-dispatch/STATUS-FORMATS.md +0 -99
  124. package/.speccrew/skills/speccrew-knowledge-bizs-dispatch/scripts/batch-orchestrator.js +0 -176
  125. package/.speccrew/skills/speccrew-knowledge-bizs-dispatch/scripts/get-next-batch.js +0 -150
  126. package/.speccrew/skills/speccrew-knowledge-bizs-dispatch/scripts/get-pending-features.js +0 -106
  127. package/.speccrew/skills/speccrew-knowledge-bizs-dispatch/scripts/mark-stale.js +0 -249
  128. package/.speccrew/skills/speccrew-knowledge-bizs-dispatch/scripts/merge-features.js +0 -300
  129. package/.speccrew/skills/speccrew-knowledge-bizs-dispatch/scripts/process-batch-results.js +0 -915
  130. package/.speccrew/skills/speccrew-knowledge-bizs-dispatch/scripts/update-feature-status.js +0 -226
  131. package/.speccrew/skills/speccrew-knowledge-bizs-init-features/examples/features.json +0 -34
  132. package/.speccrew/skills/speccrew-knowledge-bizs-init-features/scripts/generate-inventory.js +0 -1087
  133. package/.speccrew/skills/speccrew-knowledge-bizs-init-features/scripts/test-inventory.js +0 -26
  134. package/.speccrew/skills/speccrew-knowledge-techs-dispatch/STATUS-FORMATS.md +0 -550
@@ -0,0 +1,245 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <workflow id="dev-desktop-tauri" status="pending" version="1.0" desc="Tauri Desktop Development - Implements desktop application features using Tauri framework">
3
+
4
+ <!-- ============================================================
5
+ Input Parameters Definition
6
+ ============================================================ -->
7
+ <block type="input" id="I1" desc="Workflow input parameters">
8
+ <field name="design_doc_path" required="true" type="string" desc="Path to single module design document"/>
9
+ <field name="platform_id" required="true" type="string" desc="Desktop platform identifier (desktop-tauri)"/>
10
+ <field name="task_id" required="true" type="string" desc="Task identifier from dispatch context"/>
11
+ <field name="source_root" required="true" type="string" desc="Root directory of Tauri source code"/>
12
+ </block>
13
+
14
+ <!-- ============================================================
15
+ Global Constraints
16
+ ============================================================ -->
17
+ <block type="rule" id="R1" level="forbidden" desc="Task Record document constraints">
18
+ <field name="text">NEVER use create_file or full-content overwrite for Task Record after Step 3.1a</field>
19
+ <field name="text">All subsequent updates MUST use targeted search_replace on specific sections</field>
20
+ </block>
21
+
22
+ <block type="rule" id="R2" level="mandatory" desc="Template-first workflow">
23
+ <field name="text">Copy template MUST execute before fill sections</field>
24
+ <field name="text">Source code is NOT template-filled - write directly based on design blueprints</field>
25
+ </block>
26
+
27
+ <block type="rule" id="R3" level="mandatory" desc="Security and error handling">
28
+ <field name="text">Minimize dangerous API allowlist scope</field>
29
+ <field name="text">All commands must return Result&lt;T, E&gt;</field>
30
+ </block>
31
+
32
+ <!-- ============================================================
33
+ Main Processing Sequence
34
+ ============================================================ -->
35
+ <sequence id="S1" name="Tauri Desktop Development" status="pending" desc="Execute Tauri development workflow">
36
+
37
+ <!-- Step 1: Read Design Documents -->
38
+ <block type="task" id="B1" action="read-file" desc="Read Module Design Document">
39
+ <field name="path" value="${design_doc_path}"/>
40
+ <field name="output" var="module_design"/>
41
+ </block>
42
+
43
+ <block type="task" id="B2" action="read-file" desc="Read API Contract">
44
+ <field name="path">speccrew-workspace/iterations/{number}-{type}-{name}/02.feature-design/[feature-name]-api-contract.md</field>
45
+ <field name="output" var="api_contract"/>
46
+ </block>
47
+
48
+ <block type="task" id="B3" action="read-file" desc="Read Techs Knowledge - tech-stack">
49
+ <field name="path">speccrew-workspace/knowledges/techs/${platform_id}/tech-stack.md</field>
50
+ <field name="output" var="tech_stack"/>
51
+ </block>
52
+
53
+ <block type="task" id="B4" action="read-file" desc="Read Techs Knowledge - architecture">
54
+ <field name="path">speccrew-workspace/knowledges/techs/${platform_id}/architecture.md</field>
55
+ <field name="output" var="architecture"/>
56
+ </block>
57
+
58
+ <block type="task" id="B5" action="read-file" desc="Read Techs Knowledge - conventions-design">
59
+ <field name="path">speccrew-workspace/knowledges/techs/${platform_id}/conventions-design.md</field>
60
+ <field name="output" var="conventions_design"/>
61
+ </block>
62
+
63
+ <block type="task" id="B6" action="read-file" desc="Read Techs Knowledge - conventions-dev">
64
+ <field name="path">speccrew-workspace/knowledges/techs/${platform_id}/conventions-dev.md</field>
65
+ <field name="output" var="conventions_dev"/>
66
+ </block>
67
+
68
+ <!-- Step 2: Analyze Existing Code Structure -->
69
+ <block type="task" id="B7" action="analyze" desc="Analyze existing Tauri codebase structure">
70
+ <field name="patterns">
71
+ - Rust commands: src-tauri/src/**/*.rs
72
+ - Frontend integration: src/**/*.{tsx,vue}
73
+ - Tauri commands: src-tauri/src/commands/**/*.rs
74
+ - Window management: src-tauri/src/window/**/*.rs
75
+ - State management: src/stores/**/*
76
+ - API layer: src/apis/**/*
77
+ - Configuration: package.json, tauri.conf.json
78
+ - Cargo.toml: src-tauri/Cargo.toml
79
+ </field>
80
+ <field name="output" var="codebase_structure"/>
81
+ </block>
82
+
83
+ <!-- Step 3: Extract Task List and Create Task Record -->
84
+ <block type="task" id="B8" action="read-file" desc="Read Task Record Template">
85
+ <field name="path">templates/TASK-RECORD-TEMPLATE.md</field>
86
+ <field name="output" var="task_template"/>
87
+ </block>
88
+
89
+ <block type="task" id="B9" action="create-file" desc="Copy template to Task Record path">
90
+ <field name="path">speccrew-workspace/iterations/{number}-{type}-{name}/04.development/${platform_id}/[feature-name]-task.md</field>
91
+ <field name="content">${task_template} with top-level placeholders replaced</field>
92
+ <field name="output" var="task_record_path"/>
93
+ </block>
94
+
95
+ <block type="task" id="B10" action="edit-file" desc="Fill Task Record sections using search_replace">
96
+ <field name="path" value="${task_record_path}"/>
97
+ <field name="action">Fill each section with task checklist and design metadata</field>
98
+ <field name="output" var="task_record_filled"/>
99
+ </block>
100
+
101
+ <!-- Extract Tauri-specific task types -->
102
+ <block type="task" id="B11" action="analyze" desc="Extract Tauri-specific task list">
103
+ <field name="input" value="${module_design}"/>
104
+ <field name="extraction_rules">
105
+ - Tauri Command: Rust backend command (#[tauri::command] functions)
106
+ - Frontend Component: UI components (React/Vue components, pages)
107
+ - Command Handler: Frontend-to-Rust communication (invoke() calls)
108
+ - Window Management: Window creation and lifecycle
109
+ - Native Integration: File system, notifications
110
+ - Menu/Shortcut: Application menus and accelerators
111
+ - Auto-Update: Update mechanism
112
+ - Security Hardening: CSP, permissions in tauri.conf.json
113
+ </field>
114
+ <field name="output" var="task_list"/>
115
+ </block>
116
+
117
+ <!-- Checkpoint: Task list extracted -->
118
+ <block type="checkpoint" id="CP1" name="task-list-extracted" desc="Verify task list extracted">
119
+ <field name="verify" value="${task_list.length} > 0"/>
120
+ </block>
121
+
122
+ <!-- Step 4: Implement Tasks -->
123
+ <block type="loop" id="L1" over="${task_list}" as="task" desc="Execute tasks in dependency order">
124
+ <block type="task" id="B12" action="edit-file" desc="Mark task as In Progress">
125
+ <field name="path" value="${task_record_path}"/>
126
+ <field name="action">Update task status to In Progress</field>
127
+ </block>
128
+
129
+ <block type="task" id="B13" action="generate" desc="Implement task following Tauri patterns">
130
+ <field name="task" value="${task}"/>
131
+ <field name="design" value="${module_design}"/>
132
+ <field name="conventions" value="${conventions_dev}"/>
133
+ <field name="codebase" value="${codebase_structure}"/>
134
+ <field name="output" var="implementation_result"/>
135
+ </block>
136
+
137
+ <!-- Step 5: Local Checks (embedded in loop) -->
138
+ <block type="task" id="B14" action="run-script" desc="Rust checks">
139
+ <field name="command">cd src-tauri; cargo check; cargo clippy; cargo test</field>
140
+ <field name="output" var="rust_result"/>
141
+ </block>
142
+
143
+ <block type="task" id="B15" action="run-script" desc="Frontend build verification">
144
+ <field name="command">npm run build OR npm run tauri build --debug</field>
145
+ <field name="output" var="build_result"/>
146
+ </block>
147
+
148
+ <block type="task" id="B16" action="run-script" desc="Lint check">
149
+ <field name="command">npm run lint OR npx eslint [modified-files]</field>
150
+ <field name="output" var="lint_result"/>
151
+ </block>
152
+
153
+ <block type="task" id="B17" action="run-script" desc="Type check">
154
+ <field name="command">npx tsc --noEmit</field>
155
+ <field name="output" var="type_result"/>
156
+ </block>
157
+
158
+ <block type="task" id="B18" action="analyze" desc="Quick verify">
159
+ <field name="checks">
160
+ - Application window launches without crash
161
+ - No console errors in DevTools
162
+ - Tauri commands respond correctly
163
+ - Native integrations work as expected
164
+ </field>
165
+ <field name="output" var="verify_result"/>
166
+ </block>
167
+
168
+ <block type="gateway" id="G1" mode="guard" desc="Verify all checks passed"
169
+ test="${rust_result.status} == 'passed' AND ${build_result.status} == 'passed' AND ${lint_result.status} == 'passed'"
170
+ fail-action="stop">
171
+ <field name="message">Local checks failed for task ${task.id}</field>
172
+ </block>
173
+
174
+ <block type="task" id="B19" action="edit-file" desc="Update status to Completed">
175
+ <field name="path" value="${task_record_path}"/>
176
+ <field name="action">Update task status to Completed</field>
177
+ </block>
178
+ </block>
179
+
180
+ <!-- Step 6: Record Deviations -->
181
+ <block type="gateway" id="G2" mode="exclusive" desc="Check if deviations exist">
182
+ <branch test="${deviations.length} > 0" name="Has Deviations">
183
+ <block type="task" id="B20" action="edit-file" desc="Record deviations in task file">
184
+ <field name="path" value="${task_record_path}"/>
185
+ <field name="action">Add Deviation Log section with TR-XXX prefix</field>
186
+ </block>
187
+ </branch>
188
+ <branch default="true" name="No Deviations">
189
+ <block type="event" id="E1" action="log" level="info" desc="No deviations">
190
+ <field name="message">No deviations from design</field>
191
+ </block>
192
+ </branch>
193
+ </block>
194
+
195
+ <!-- Step 7: Record Technical Debt -->
196
+ <block type="gateway" id="G3" mode="exclusive" desc="Check if technical debt exists">
197
+ <branch test="${tech_debt.length} > 0" name="Has Tech Debt">
198
+ <block type="task" id="B21" action="create-file" desc="Write technical debt document">
199
+ <field name="path">speccrew-workspace/iterations/{number}-{type}-{name}/tech-debt/[feature-name]-tech-debt.md</field>
200
+ <field name="content">${tech_debt} with categories: Security, Performance, Refactoring, Dependencies</field>
201
+ <field name="output" var="tech_debt_path"/>
202
+ </block>
203
+ </branch>
204
+ <branch default="true" name="No Tech Debt">
205
+ <block type="event" id="E2" action="log" level="info" desc="No tech debt">
206
+ <field name="message">No technical debt identified</field>
207
+ </block>
208
+ </branch>
209
+ </block>
210
+
211
+ <!-- Step 8: Complete Notification -->
212
+ <block type="task" id="B22" action="report" desc="Generate completion summary">
213
+ <field name="template">
214
+ Tauri Development Complete: {feature-name}
215
+ Platform: {platform_id}
216
+ Framework: Tauri
217
+
218
+ Tasks Completed: {count}
219
+ ├── Tauri Commands: {count}
220
+ ├── Frontend Integration: {count}
221
+ ├── Native Integration: {count}
222
+ └── Security/Other: {count}
223
+
224
+ Deviations Recorded: {count}
225
+ Technical Debt Items: {count}
226
+
227
+ Task Record: speccrew-workspace/iterations/{number}-{type}-{name}/04.development/{platform_id}/[feature-name]-task.md
228
+ </field>
229
+ <field name="output" var="completion_report"/>
230
+ </block>
231
+
232
+ </sequence>
233
+
234
+ <!-- ============================================================
235
+ Output Results
236
+ ============================================================ -->
237
+ <block type="output" id="O1" desc="Workflow output results">
238
+ <field name="task_record_path" value="${task_record_path}" type="string" desc="Path to task record document"/>
239
+ <field name="task_count" from="${task_list.length}" type="number" desc="Number of tasks completed"/>
240
+ <field name="deviation_count" type="number" desc="Number of deviations recorded"/>
241
+ <field name="tech_debt_count" type="number" desc="Number of tech debt items"/>
242
+ <field name="completion_report" value="${completion_report}" type="string" desc="Completion notification text"/>
243
+ </block>
244
+
245
+ </workflow>
@@ -10,9 +10,17 @@ tools: Bash, Edit, Write, Glob, Grep, Read
10
10
  - System design confirmed, user requests frontend development
11
11
  - User asks "Start frontend development" or "Implement frontend code"
12
12
 
13
- # Workflow
13
+ ## AgentFlow Definition
14
14
 
15
- ## Absolute Constraints
15
+ <!-- @agentflow: workflow.agentflow.xml -->
16
+
17
+ > **REQUIRED**: Before executing this workflow, read the XML workflow specification: `speccrew-workspace/docs/rules/agentflow-spec.md`
18
+
19
+ ---
20
+
21
+ ## Workflow
22
+
23
+ ### Absolute Constraints
16
24
 
17
25
  > **These rules apply to Task Record document generation. Violation = task failure.**
18
26
 
@@ -0,0 +1,262 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <workflow id="dev-frontend" status="pending" version="1.0" desc="Frontend Development SOP - Guide System Developer Agent to implement frontend code">
3
+
4
+ <!-- ============================================================
5
+ Input Parameters Definition
6
+ ============================================================ -->
7
+ <block type="input" id="I1" desc="Workflow input parameters">
8
+ <field name="design_doc_path" required="true" type="string" desc="Path to a single module design document"/>
9
+ <field name="platform_id" required="true" type="string" desc="Platform identifier (e.g., web-vue, web-react)"/>
10
+ <field name="task_id" required="true" type="string" desc="Task identifier from dispatch context"/>
11
+ <field name="iteration_id" required="false" type="string" desc="Current iteration identifier for progress messages"/>
12
+ <field name="output_dir" required="false" type="string" desc="Output directory for task record"/>
13
+ </block>
14
+
15
+ <!-- ============================================================
16
+ Global Constraints
17
+ ============================================================ -->
18
+ <block type="rule" id="R1" level="forbidden" desc="Task Record document constraints">
19
+ <field name="text">NEVER use create_file to write the Task Record document</field>
20
+ <field name="text">MUST create Task Record by copying template then filling sections with search_replace</field>
21
+ <field name="text">NEVER replace the entire Task Record content in a single operation</field>
22
+ </block>
23
+
24
+ <block type="rule" id="R2" level="mandatory" desc="Template-first workflow">
25
+ <field name="text">Copy template MUST execute before fill sections</field>
26
+ <field name="text">Source code is NOT template-filled - write directly based on design blueprints</field>
27
+ </block>
28
+
29
+ <!-- ============================================================
30
+ Main Processing Sequence
31
+ ============================================================ -->
32
+ <sequence id="S1" name="Frontend Development" status="pending" desc="Execute frontend development workflow">
33
+
34
+ <!-- Step 1: Read Design Documents -->
35
+ <block type="task" id="B1" action="read-file" desc="Read Platform INDEX">
36
+ <field name="path">speccrew-workspace/iterations/{number}-{type}-{name}/03.system-design/${platform_id}/INDEX.md</field>
37
+ <field name="output" var="platform_index"/>
38
+ </block>
39
+
40
+ <block type="task" id="B2" action="read-file" desc="Read Module Design Document">
41
+ <field name="path" value="${design_doc_path}"/>
42
+ <field name="output" var="module_design"/>
43
+ </block>
44
+
45
+ <block type="task" id="B3" action="read-file" desc="Read API Contract">
46
+ <field name="path">speccrew-workspace/iterations/{number}-{type}-{name}/02.feature-design/*-api-contract.md</field>
47
+ <field name="output" var="api_contract"/>
48
+ </block>
49
+
50
+ <!-- Step 2: Read Techs Knowledge -->
51
+ <block type="task" id="B4" action="read-file" desc="Read Techs Knowledge - conventions-dev">
52
+ <field name="path">speccrew-workspace/knowledges/techs/${platform_id}/conventions-dev.md</field>
53
+ <field name="output" var="conventions_dev"/>
54
+ </block>
55
+
56
+ <block type="task" id="B5" action="read-file" desc="Read Techs Knowledge - architecture">
57
+ <field name="path">speccrew-workspace/knowledges/techs/${platform_id}/architecture.md</field>
58
+ <field name="output" var="architecture"/>
59
+ </block>
60
+
61
+ <block type="task" id="B6" action="read-file" desc="Read Techs Knowledge - tech-stack">
62
+ <field name="path">speccrew-workspace/knowledges/techs/${platform_id}/tech-stack.md</field>
63
+ <field name="output" var="tech_stack"/>
64
+ </block>
65
+
66
+ <block type="task" id="B7" action="read-file" desc="Read Techs Knowledge - ui-style-guide">
67
+ <field name="path">speccrew-workspace/knowledges/techs/${platform_id}/ui-style/ui-style-guide.md</field>
68
+ <field name="output" var="ui_style_guide"/>
69
+ </block>
70
+
71
+ <block type="task" id="B8" action="read-file" desc="Read Techs Knowledge - ui-patterns">
72
+ <field name="path">speccrew-workspace/knowledges/techs/${platform_id}/ui-style-patterns/</field>
73
+ <field name="output" var="ui_patterns"/>
74
+ </block>
75
+
76
+ <!-- Step 3: Extract Task List -->
77
+ <block type="task" id="B9" action="read-file" desc="Read Task Record Template">
78
+ <field name="path">speccrew-dev-frontend/templates/TASK-RECORD-TEMPLATE.md</field>
79
+ <field name="output" var="task_template"/>
80
+ </block>
81
+
82
+ <block type="task" id="B10" action="analyze" desc="Parse Module Design and extract tasks">
83
+ <field name="input" value="${module_design}"/>
84
+ <field name="extraction_rules">
85
+ - Components: [NEW], [MODIFIED], [EXISTING] markers
86
+ - Store modules: [NEW], [MODIFIED], [EXISTING] markers
87
+ - API integration: API calls in pseudo-code
88
+ - Routes: Route configurations
89
+ - Styles: Layout/styling work
90
+ </field>
91
+ <field name="output" var="extracted_items"/>
92
+ </block>
93
+
94
+ <block type="task" id="B11" action="analyze" desc="Generate Task Table">
95
+ <field name="input" value="${extracted_items}"/>
96
+ <field name="format">
97
+ | Task ID | Module | Description | Target Files | Dependencies | Status |
98
+ | FE-001 | {module} | {description} | {file paths from design} | {depends on} | Pending |
99
+ </field>
100
+ <field name="output" var="task_list"/>
101
+ </block>
102
+
103
+ <!-- Step 4: Create Task Record -->
104
+ <block type="task" id="B12" action="create-file" desc="Copy template to Task Record path">
105
+ <field name="path">speccrew-workspace/iterations/{number}-{type}-{name}/04.development/${platform_id}/{feature-name}-tasks.md</field>
106
+ <field name="content">${task_template} with top-level placeholders replaced</field>
107
+ <field name="output" var="task_record_path"/>
108
+ </block>
109
+
110
+ <block type="task" id="B13" action="edit-file" desc="Fill Task Record sections using search_replace">
111
+ <field name="path" value="${task_record_path}"/>
112
+ <field name="action">Fill each section with task checklist and design metadata</field>
113
+ <field name="output" var="task_record_filled"/>
114
+ </block>
115
+
116
+ <!-- Checkpoint: Task list extracted -->
117
+ <block type="checkpoint" id="CP1" name="task-list-extracted" desc="Verify task list extracted">
118
+ <field name="verify" value="${task_list.length} > 0"/>
119
+ </block>
120
+
121
+ <!-- Step 5: Execute Tasks -->
122
+ <block type="loop" id="L1" over="${task_list}" as="task" desc="Execute tasks in checklist order">
123
+ <block type="task" id="B14" action="read-file" desc="Read Design Section for this task">
124
+ <field name="path" value="${design_doc_path}"/>
125
+ <field name="section">Corresponding module design section for ${task.id}</field>
126
+ <field name="output" var="design_section"/>
127
+ </block>
128
+
129
+ <block type="task" id="B15" action="generate" desc="Implement According to Blueprint">
130
+ <field name="task" value="${task}"/>
131
+ <field name="design" value="${design_section}"/>
132
+ <field name="conventions" value="${conventions_dev}"/>
133
+ <field name="architecture" value="${architecture}"/>
134
+ <field name="rules">
135
+ - Use actual syntax from conventions-dev.md
136
+ - Follow architecture.md patterns
137
+ - Use [EXISTING] components as marked in design
138
+ - Follow conventions strictly
139
+ - Use paths specified in design document
140
+ </field>
141
+ <field name="output" var="implementation_result"/>
142
+ </block>
143
+
144
+ <block type="task" id="B16" action="edit-file" desc="Update Task Status">
145
+ <field name="path" value="${task_record_path}"/>
146
+ <field name="action">Update task status to Done</field>
147
+ </block>
148
+
149
+ <!-- Gateway: Handle Design Issues -->
150
+ <block type="gateway" id="G1" mode="exclusive" desc="Check if design issue found">
151
+ <branch test="${design_issue.found} == true" name="Has Design Issue">
152
+ <block type="task" id="B17" action="report" desc="Report design issue">
153
+ <field name="content">
154
+ - Task ID affected: ${task.id}
155
+ - Design document reference: ${design_doc_path}
156
+ - Problem description: ${design_issue.description}
157
+ - Suggested resolution: ${design_issue.suggestion}
158
+ </field>
159
+ <field name="output" var="issue_report"/>
160
+ </block>
161
+ <block type="event" id="E1" action="log" level="warn" desc="Stop for user decision">
162
+ <field name="message">Design issue discovered - waiting for user decision</field>
163
+ </block>
164
+ </branch>
165
+ <branch default="true" name="No Issue">
166
+ <block type="event" id="E2" action="log" level="info" desc="Continue">
167
+ <field name="message">Task ${task.id} completed normally</field>
168
+ </block>
169
+ </branch>
170
+ </block>
171
+ </block>
172
+
173
+ <!-- Step 6: Local Checks -->
174
+ <block type="task" id="B18" action="run-script" desc="Lint Check">
175
+ <field name="command">npm run lint OR npx eslint {modified files}</field>
176
+ <field name="output" var="lint_result"/>
177
+ </block>
178
+
179
+ <block type="task" id="B19" action="run-script" desc="Type Check">
180
+ <field name="command">npx tsc --noEmit</field>
181
+ <field name="output" var="type_result"/>
182
+ </block>
183
+
184
+ <block type="task" id="B20" action="run-script" desc="Unit Tests">
185
+ <field name="command">Run relevant unit tests</field>
186
+ <field name="output" var="test_result"/>
187
+ </block>
188
+
189
+ <block type="task" id="B21" action="analyze" desc="Quick Verify">
190
+ <field name="checks">
191
+ - Page renders without console errors
192
+ - No runtime exceptions
193
+ </field>
194
+ <field name="output" var="verify_result"/>
195
+ </block>
196
+
197
+ <!-- Step 7: Complete Task Record -->
198
+ <block type="task" id="B22" action="edit-file" desc="Update Final Statuses">
199
+ <field name="path" value="${task_record_path}"/>
200
+ <field name="action">Update task record file with final statuses for all tasks</field>
201
+ </block>
202
+
203
+ <!-- Record Deviations -->
204
+ <block type="gateway" id="G2" mode="exclusive" desc="Check if deviations exist">
205
+ <branch test="${deviations.length} > 0" name="Has Deviations">
206
+ <block type="task" id="B23" action="edit-file" desc="Record deviations">
207
+ <field name="path" value="${task_record_path}"/>
208
+ <field name="action">Add Deviation Log section with Task ID, Design Intent, Actual Implementation, Reason</field>
209
+ </block>
210
+ </branch>
211
+ <branch default="true" name="No Deviations">
212
+ <block type="event" id="E3" action="log" level="info" desc="No deviations">
213
+ <field name="message">No deviations from design</field>
214
+ </block>
215
+ </branch>
216
+ </block>
217
+
218
+ <!-- Write Tech Debt -->
219
+ <block type="gateway" id="G3" mode="exclusive" desc="Check if tech debt exists">
220
+ <branch test="${tech_debt.length} > 0" name="Has Tech Debt">
221
+ <block type="task" id="B24" action="create-file" desc="Write tech debt document">
222
+ <field name="path">speccrew-workspace/iterations/{number}-{type}-{name}/tech-debt/{debt-id}.md</field>
223
+ <field name="content">${tech_debt}</field>
224
+ <field name="output" var="tech_debt_path"/>
225
+ </block>
226
+ </branch>
227
+ <branch default="true" name="No Tech Debt">
228
+ <block type="event" id="E4" action="log" level="info" desc="No tech debt">
229
+ <field name="message">No technical debt identified</field>
230
+ </block>
231
+ </branch>
232
+ </block>
233
+
234
+ <!-- Completion Summary -->
235
+ <block type="task" id="B25" action="report" desc="Present Completion Summary">
236
+ <field name="template">
237
+ Frontend Development Complete: {feature-name}
238
+ Platform: {platform_id}
239
+
240
+ Tasks: {completed}/{total} completed
241
+ Deviations: {count}
242
+ Tech Debt: {count}
243
+
244
+ Task Record: speccrew-workspace/iterations/{number}-{type}-{name}/04.development/{platform_id}/{feature-name}-tasks.md
245
+ </field>
246
+ <field name="output" var="completion_report"/>
247
+ </block>
248
+
249
+ </sequence>
250
+
251
+ <!-- ============================================================
252
+ Output Results
253
+ ============================================================ -->
254
+ <block type="output" id="O1" desc="Workflow output results">
255
+ <field name="task_record_path" value="${task_record_path}" type="string" desc="Path to task record document"/>
256
+ <field name="task_count" from="${task_list.length}" type="number" desc="Number of tasks completed"/>
257
+ <field name="deviation_count" type="number" desc="Number of deviations recorded"/>
258
+ <field name="tech_debt_count" type="number" desc="Number of tech debt items"/>
259
+ <field name="completion_report" value="${completion_report}" type="string" desc="Completion notification text"/>
260
+ </block>
261
+
262
+ </workflow>
@@ -10,9 +10,17 @@ tools: Bash, Edit, Write, Glob, Grep, Read
10
10
  - User asks "Start mobile development", "Implement mobile app", "Write mobile code"
11
11
  - System Developer Agent dispatches this skill with platform context (platform_id, techs paths)
12
12
 
13
- # Workflow
13
+ ## AgentFlow Definition
14
14
 
15
- ## Absolute Constraints
15
+ <!-- @agentflow: workflow.agentflow.xml -->
16
+
17
+ > **REQUIRED**: Before executing this workflow, read the XML workflow specification: `speccrew-workspace/docs/rules/agentflow-spec.md`
18
+
19
+ ---
20
+
21
+ ## Workflow
22
+
23
+ ### Absolute Constraints
16
24
 
17
25
  > **These rules apply to Task Record document generation. Violation = task failure.**
18
26