speccrew 0.6.68 → 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 -1071
  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
@@ -1,46 +1,3 @@
1
- ---
2
- name: speccrew-knowledge-techs-generate-ui-style-xml
3
- description: Generate UI style analysis documents for a specific frontend platform using XML workflow blocks. Analyzes page types, components, layouts, and styling conventions from source code. Only applicable to frontend platforms (web, mobile, desktop).
4
- tools: Read, Write, Glob, Grep, Skill
5
- ---
6
-
7
- # Stage 2: Generate Platform UI Style Documents (XML Workflow)
8
-
9
- Generate comprehensive UI style documentation for a specific frontend platform by analyzing its source code structure, components, and styling patterns using XML workflow blocks.
10
-
11
- ## Language Adaptation
12
-
13
- **CRITICAL**: All generated documents must match the user's language. Detect the language from the user's input and generate content accordingly.
14
-
15
- - User writes in 中文 → Generate Chinese documents, use `language: "zh"`
16
- - User writes in English → Generate English documents, use `language: "en"`
17
- - Other languages → Use the specified language code
18
-
19
- ## Prerequisite
20
-
21
- This skill ONLY applies to frontend platforms. The dispatcher MUST check platform_type before invoking:
22
-
23
- - `web` → Execute this skill
24
- - `mobile` → Execute this skill
25
- - `desktop` → Execute this skill
26
- - `backend` → DO NOT invoke this skill
27
- - `api` → DO NOT invoke this skill
28
-
29
- ## Trigger Scenarios
30
-
31
- - "Generate UI style documents for {platform}"
32
- - "Analyze UI components and layouts"
33
- - "Extract design system from {platform}"
34
-
35
- ## User
36
-
37
- Worker Agent (speccrew-task-worker)
38
-
39
- ---
40
-
41
- ## XML Workflow Definition
42
- > **REQUIRED**: Before executing this workflow, read the XML workflow specification: `speccrew-workspace/docs/rules/xml-workflow-spec.md`
43
- ```xml
44
1
  <?xml version="1.0" encoding="UTF-8"?>
45
2
  <workflow id="techs-ui-style-generate" status="pending" version="1.0" desc="Generate UI style documents for frontend platform">
46
3
 
@@ -259,8 +216,8 @@ Worker Agent (speccrew-task-worker)
259
216
  <field name="output_file" value="${output_path}/ui-style/ui-style-guide.md"/>
260
217
  <field name="content"># UI Style Guide - ${platform_id}
261
218
 
262
- > Note: Automated and manual UI analysis were not possible for this platform.
263
- > Manual inspection of source code is required.
219
+ &gt; Note: Automated and manual UI analysis were not possible for this platform.
220
+ &gt; Manual inspection of source code is required.
264
221
 
265
222
  ## References
266
223
  - Source components: ${source_path}/src/components/ (if exists)
@@ -407,151 +364,3 @@ Worker Agent (speccrew-task-worker)
407
364
  </block>
408
365
 
409
366
  </workflow>
410
- ```
411
-
412
- ---
413
-
414
- ## Output Directory Structure
415
-
416
- ```
417
- {output_path}/
418
- └── ui-style/
419
- ├── ui-style-guide.md # Main UI style guide (Required)
420
- ├── page-types/
421
- │ ├── page-type-summary.md # Page type overview (Required)
422
- │ └── [type]-pages.md # Per-type detail (Dynamic)
423
- ├── components/
424
- │ ├── component-library.md # Component catalog (Required)
425
- │ ├── common-components.md # Common components (Required)
426
- │ ├── business-components.md # Business components (Required)
427
- │ └── {component-name}.md # Per-component detail (Dynamic)
428
- ├── layouts/
429
- │ ├── page-layouts.md # Layout patterns (Required)
430
- │ ├── navigation-patterns.md # Navigation patterns (Required)
431
- │ └── {layout-name}-layout.md # Per-layout detail (Dynamic)
432
- └── styles/
433
- ├── color-system.md # Color system (Required)
434
- ├── typography.md # Typography (Required)
435
- └── spacing-system.md # Spacing system (Required)
436
- ```
437
-
438
- ## Directory Ownership
439
-
440
- - `ui-style/` — Fully managed by this skill (techs pipeline)
441
- - Contains: ui-style-guide.md, styles/, page-types/, components/, layouts/
442
- - Source: Framework-level design system analysis from source code
443
- - `ui-style-patterns/` — Managed by bizs pipeline (Stage 3.5: bizs-ui-style-extract)
444
- - Contains: Business pattern aggregation from feature documents
445
- - NOT created or written by this skill
446
- - May not exist if bizs pipeline has not been executed
447
-
448
- ---
449
-
450
- ## Quality Requirements
451
-
452
- - ui-style-guide.md MUST have substantial content (not just template placeholders)
453
- - At least 5 mandatory files MUST exist (see Self-Verification Checklist)
454
- - Analysis report MUST honestly reflect coverage level
455
- - All paths in documents MUST be relative (never absolute or file:// protocol)
456
-
457
- ---
458
-
459
- ## Error Handling
460
-
461
- | Error Type | Action |
462
- |------------|--------|
463
- | Platform type is backend/api | Skip execution, return skipped status |
464
- | UI analyzer skill invocation fails | Execute Secondary Path (template fill) |
465
- | Source code structure is non-standard | Execute Tertiary Path (reference only) |
466
- | Template not found | Use default structure, log warning |
467
- | Any path MUST output the done file and analysis file | Never report "completed" with missing mandatory files |
468
-
469
- ---
470
-
471
- ## Task Completion Report
472
-
473
- Upon completion, return the following structured report:
474
-
475
- ```json
476
- {
477
- "status": "success | partial | failed",
478
- "skill": "speccrew-knowledge-techs-generate-ui-style-xml",
479
- "output_files": [
480
- "{output_path}/ui-style/ui-style-guide.md",
481
- "{output_path}/ui-style/page-types/page-type-summary.md",
482
- "{output_path}/ui-style/components/component-library.md",
483
- "{output_path}/ui-style/layouts/page-layouts.md",
484
- "{output_path}/ui-style/styles/color-system.md",
485
- "{completed_dir}/{platform_id}.analysis-ui-style.json",
486
- "{completed_dir}/{platform_id}.done-ui-style.json"
487
- ],
488
- "summary": "UI style documents generated for {platform_id} at {ui_analysis_level} analysis level",
489
- "metrics": {
490
- "components_documented": 0,
491
- "style_patterns_captured": 0,
492
- "design_tokens_extracted": 0
493
- },
494
- "errors": [],
495
- "next_steps": [
496
- "Review ui-style-guide.md for design system completeness",
497
- "Coordinate with bizs-ui-style-extract for business pattern integration"
498
- ]
499
- }
500
- ```
501
-
502
- ---
503
-
504
- ## Checklist
505
-
506
- ### Pre-Generation
507
- - [ ] Platform type verified (web/mobile/desktop only)
508
- - [ ] Template files read and understood
509
- - [ ] Source directory structure scanned
510
-
511
- ### UI Style Analysis
512
- - [ ] `speccrew-knowledge-techs-ui-analyze` skill invoked (Primary Path)
513
- - [ ] If Primary Path failed → Secondary Path executed
514
- - [ ] If Secondary Path failed → Tertiary Path executed
515
- - [ ] All mandatory files created per Self-Verification Checklist
516
-
517
- ### Output Verification
518
- - [ ] ui-style/ui-style-guide.md exists and has content
519
- - [ ] ui-style/page-types/page-type-summary.md exists and has content
520
- - [ ] ui-style/components/component-library.md exists and has content
521
- - [ ] ui-style/layouts/page-layouts.md exists and has content
522
- - [ ] ui-style/styles/color-system.md exists and has content
523
-
524
- ### Reporting
525
- - [ ] Analysis report generated: `{platform_id}.analysis-ui-style.json`
526
- - [ ] Completion marker generated: `{platform_id}.done-ui-style.json`
527
- - [ ] Console output reported with correct status
528
-
529
- ---
530
-
531
- ## CONTINUOUS EXECUTION RULES
532
-
533
- This skill MUST execute all steps continuously without unnecessary interruptions.
534
-
535
- ### FORBIDDEN Interruptions
536
-
537
- 1. DO NOT ask user "Should I continue?" after completing a step
538
- 2. DO NOT suggest "Let me split this into batches" or "Let's do this in parts"
539
- 3. DO NOT pause to list what you plan to do next — just do it
540
- 4. DO NOT ask for confirmation before generating output files
541
- 5. DO NOT warn about "large number of files" — proceed with generation
542
- 6. DO NOT offer "Should I proceed with the remaining items?"
543
- 7. DO NOT present options like "Full execution / Sample execution / Pause"
544
-
545
- ### When to Pause (ONLY these cases)
546
-
547
- 1. Explicit `<event action="confirm">` blocks in the workflow
548
- 2. Ambiguous requirements that genuinely need clarification
549
- 3. Unrecoverable errors that prevent further progress
550
- 4. Security-sensitive operations (e.g., deleting existing files)
551
-
552
- ### Execution Behavior
553
-
554
- - When multiple templates need filling, process ALL of them sequentially without asking
555
- - Use checkpoint files to track progress, enabling resumption if interrupted
556
- - If context window is approaching limit, save progress and inform user how to resume
557
- - NEVER voluntarily stop mid-process to ask if user wants to continue
@@ -1,10 +1,10 @@
1
1
  ---
2
2
  name: speccrew-knowledge-techs-index
3
- description: Stage 3 of technology knowledge initialization - Generate root INDEX.md by aggregating all platform technology documents. Creates the master index that maps platforms to their documentation and provides Agent-to-Platform mapping guide. Used by Worker Agent after all platform documents are generated.
3
+ description: Stage 3 of technology knowledge initialization - Generate root INDEX.md by aggregating all platform technology documents using XML workflow blocks. Creates the master index that maps platforms to their documentation and provides Agent-to-Platform mapping guide. Used by Worker Agent after all platform documents are generated.
4
4
  tools: Read, Write, Skill
5
5
  ---
6
6
 
7
- # Stage 3: Generate Root Technology Index
7
+ # Stage 3: Generate Root Technology Index (XML Workflow)
8
8
 
9
9
  Aggregate all platform technology documentation into a single root INDEX.md that serves as the master navigation hub for technology knowledge.
10
10
 
@@ -46,126 +46,33 @@ Worker Agent (speccrew-task-worker)
46
46
  - Document Guide (explains each document type)
47
47
  - Usage Guide (how to use the knowledge)
48
48
 
49
- ## Workflow
50
-
51
- ```mermaid
52
- flowchart TD
53
- Start([Start]) --> Step0[Step 0: Read Root Index Template]
54
- Step0 --> Step1[Step 1: Read Manifest]
55
- Step1 --> Step2[Step 2: Verify Platform Documents]
56
- Step2 --> Step3[Step 3: Extract Platform Summaries]
57
- Step3 --> Step4[Step 4: Generate Root INDEX.md]
58
- Step4 --> Step5[Step 5: Write Output]
59
- Step5 --> Step6[Step 6: Report Results]
60
- Step6 --> End([End])
61
- ```
62
-
63
- ### Step 0: Read Root Index Template
64
-
65
- Before processing, read the template file to understand the required content structure:
66
- - **Read**: `templates/INDEX-TEMPLATE.md`
67
- - **Purpose**: Understand the template chapters and example content requirements for root technology index documents
68
- - **Key sections to follow**:
69
- - Introduction (generation info, platform count)
70
- - Project Structure (Platform Overview table, Directory Structure)
71
- - Core Components (Technology Stacks, Architecture Guidelines, Design Conventions, Development Conventions, Testing Conventions)
72
- - Architecture Overview (Platform Architecture Map with Mermaid diagram)
73
- - Detailed Component Analysis (Agent-to-Platform Mapping)
74
- - Dependency Analysis (Cross-Platform Dependencies with Mermaid diagram)
75
- - Performance Considerations
76
- - Troubleshooting Guide
77
- - Conclusion
78
- - Appendix (Document Guide, Usage Guide)
79
-
80
- ### Step 1: Read Manifest
81
-
82
- Read `techs-manifest.json` to get the list of all platforms:
83
-
84
- ```json
85
- {
86
- "generated_at": "2024-01-15T10:30:00Z",
87
- "source_path": "/project",
88
- "language": "zh",
89
- "platforms": [
90
- {
91
- "platform_id": "web-react",
92
- "platform_type": "web",
93
- "framework": "react",
94
- "language": "typescript"
95
- },
96
- {
97
- "platform_id": "backend-nestjs",
98
- "platform_type": "backend",
99
- "framework": "nestjs",
100
- "language": "typescript"
101
- }
102
- ]
103
- }
104
- ```
105
-
106
- ### Step 2: Verify Platform Documents
107
-
108
- **CRITICAL**: Do NOT assume all platforms have the same document set. Must dynamically detect which documents actually exist.
109
-
110
- **Step 2a: Scan Platform Directories**
111
-
112
- For each platform in manifest:
113
- 1. List all `.md` files in `{{techs_base_path}}/{{platform_id}}/`
114
- 2. Build a document availability map for each platform
115
-
116
- **Step 2b: Verify Required Documents**
117
-
118
- Check each platform for required documents:
119
- | Document | Required? | If Missing |
120
- |----------|-----------|------------|
121
- | INDEX.md | YES | Skip entire platform from root INDEX |
122
- | tech-stack.md | YES | Mark as "[Missing]" in links |
123
- | architecture.md | YES | Mark as "[Missing]" in links |
124
- | conventions-design.md | YES | Mark as "[Missing]" in links |
125
- | conventions-dev.md | YES | Mark as "[Missing]" in links |
126
- | conventions-test.md | YES | Mark as "[Missing]" in links |
127
- | conventions-build.md | YES | Mark as "[Missing]" in links |
128
- | conventions-data.md | NO | Silently skip link |
129
-
130
- **Step 2c: Determine Platform Eligibility**
131
-
132
- - IF `INDEX.md` missing → Platform SKIPPED entirely
133
- - IF any required doc missing (except INDEX.md) → Platform INCLUDED but marked INCOMPLETE
134
- - IF only conventions-data.md missing → Platform is COMPLETE (it's optional)
49
+ ## AgentFlow Definition
135
50
 
136
- ### Step 3: Extract Platform Summaries
51
+ <!-- @agentflow: workflow.agentflow.xml -->
137
52
 
138
- Read each platform's INDEX.md to extract:
139
- - Platform name/type
140
- - Framework and version
141
- - Primary language
142
- - Key technologies (brief)
53
+ > **REQUIRED**: Before executing this workflow, read the XML workflow specification: `speccrew-workspace/docs/rules/agentflow-spec.md`
143
54
 
144
- ### Step 4: Generate Root INDEX.md (MANDATORY: Copy Template + Fill)
145
-
146
- **CRITICAL**: This step MUST follow the template fill workflow - copy template first, then fill sections.
55
+ ---
147
56
 
148
- 1. **Copy Template File**:
149
- - Copy `templates/INDEX-TEMPLATE.md` to `{output_path}/INDEX.md`
150
- - This preserves the template structure and all required sections
57
+ ## Template Usage
151
58
 
152
- 2. **Fill Template Sections with search_replace**:
153
- - Use `search_replace` tool to fill each section of the template
154
- - Replace placeholder content with actual data from platform analysis
59
+ Templates are located at `./templates/`:
155
60
 
156
- **MANDATORY RULES**:
157
- - **Do NOT use create_file to rewrite the entire document**
158
- - **Do NOT delete or skip any template section**
159
- - Only replace the placeholder content within each section
160
- - Preserve all template section headers and structure
61
+ **Template Variables:**
62
+ - `{{generated_at}}`: ISO timestamp
63
+ - `{{source_path}}`: Source path
64
+ - `{{platform_count}}`: Number of platforms
65
+ - `{{#each platforms}}`: Loop through platforms
66
+ - `{{platform_id}}`: Platform identifier
67
+ - `{{platform_type}}`: Platform type
68
+ - `{{framework}}`: Framework name
69
+ - `{{language}}`: Programming language
161
70
 
162
- 3. **Get Timestamp**:
163
- - **CRITICAL**: Run `node scripts/get-timestamp.js` to get current timestamp (no format parameter needed, uses default)
164
- - Store the output as `{{generated_at}}` template variable
71
+ ---
165
72
 
166
- 4. **Fill the following sections** in the copied template:
73
+ ## Document Structure Details
167
74
 
168
- #### Section 1: Header
75
+ ### Section 1: Header
169
76
 
170
77
  ```markdown
171
78
  # Technology Knowledge Index
@@ -175,30 +82,9 @@ Read each platform's INDEX.md to extract:
175
82
  - [techs-manifest.json](../../../speccrew-workspace/knowledges/techs/techs-manifest.json)
176
83
 
177
84
  > **Target Audience**: devcrew-designer-*, devcrew-dev-*, devcrew-test-*
178
-
179
- ## Table of Contents
180
-
181
- 1. [Introduction](#introduction)
182
- 2. [Project Structure](#project-structure)
183
- 3. [Core Components](#core-components)
184
- 4. [Architecture Overview](#architecture-overview)
185
- 5. [Detailed Component Analysis](#detailed-component-analysis)
186
- 6. [Dependency Analysis](#dependency-analysis)
187
- 7. [Performance Considerations](#performance-considerations)
188
- 8. [Troubleshooting Guide](#troubleshooting-guide)
189
- 9. [Conclusion](#conclusion)
190
- 10. [Appendix](#appendix)
191
-
192
- ## Introduction
193
-
194
- This technology knowledge index serves all platforms in the project, providing platform overview, document navigation, and Agent usage guidelines.
195
-
196
- > Generated at: {{generated_at}}
197
- > Source: {{source_path}}
198
- > Platforms: {{platform_count}}
199
85
  ```
200
86
 
201
- #### Section 2: Platform Overview
87
+ ### Section 2: Platform Overview
202
88
 
203
89
  Summary table of all platforms with **dynamically generated document links**:
204
90
 
@@ -207,220 +93,38 @@ Summary table of all platforms with **dynamically generated document links**:
207
93
 
208
94
  | Platform | Type | Framework | Stack | Arch | Design | Dev | Test | Build | Data |
209
95
  |----------|------|-----------|-------|------|--------|-----|------|-------|------|
210
- | [web-react](web-react/INDEX.md) | web | React | [Stack](web-react/tech-stack.md) | [Arch](web-react/architecture.md) | [Design](web-react/conventions-design.md) | [Dev](web-react/conventions-dev.md) | [Test](web-react/conventions-test.md) | [Build](web-react/conventions-build.md) | - |
211
- | [backend-nestjs](backend-nestjs/INDEX.md) | backend | NestJS | [Stack](backend-nestjs/tech-stack.md) | [Arch](backend-nestjs/architecture.md) | [Design](backend-nestjs/conventions-design.md) | [Dev](backend-nestjs/conventions-dev.md) | [Test](backend-nestjs/conventions-test.md) | [Build](backend-nestjs/conventions-build.md) | [Data](backend-nestjs/conventions-data.md) |
212
- | [mobile-uniapp](mobile-uniapp/INDEX.md) | mobile | UniApp | [Stack](mobile-uniapp/tech-stack.md) | [Arch](mobile-uniapp/architecture.md) | [Design](mobile-uniapp/conventions-design.md) | [Dev](mobile-uniapp/conventions-dev.md) | [Test](mobile-uniapp/conventions-test.md) | [Build](mobile-uniapp/conventions-build.md) | - |
96
+ | [web-react](web-react/INDEX.md) | web | React | [Stack](web-react/tech-stack.md) | ... | ... | ... | ... | ... | - |
213
97
  ```
214
98
 
215
99
  **Dynamic Link Generation Rules:**
216
100
 
217
- 1. **Always include links to required documents** (if they exist):
218
- - INDEX.md, tech-stack.md, architecture.md, conventions-design.md, conventions-dev.md, conventions-test.md, conventions-build.md
219
- - If document missing Display `[Missing]` instead of link
101
+ 1. **Always include links to required documents** (if they exist)
102
+ 2. **Conditionally include conventions-data.md**: Show `-` if not exists
103
+ 3. **Link Format**: Use short abbreviations to save space
220
104
 
221
- 2. **Conditionally include conventions-data.md**:
222
- - If exists → Add link `[Data](...)`
223
- - If not exists → Display `-` (dash, not [Missing])
224
- - For `backend` platforms, typically include
225
- - For `mobile` platforms without data layer, omit
226
-
227
- 3. **Link Format**: Use short abbreviations to save space:
228
- - `[Stack]` → tech-stack.md
229
- - `[Arch]` → architecture.md
230
- - `[Design]` → conventions-design.md
231
- - `[Dev]` → conventions-dev.md
232
- - `[Test]` → conventions-test.md
233
- - `[Build]` → conventions-build.md (Required column)
234
- - `[Data]` → conventions-data.md (Optional column, show `-` if missing)
235
-
236
- #### Section 3: Quick Reference
237
-
238
- Quick links organized by document type:
239
-
240
- ```markdown
241
- ## Quick Reference
105
+ ### Section 3: Quick Reference
242
106
 
243
- ### Technology Stacks
244
- - [Web Frontend - React](web-react/tech-stack.md)
245
- - [Backend API - NestJS](backend-nestjs/tech-stack.md)
107
+ Quick links organized by document type (Technology Stacks, Architecture Guidelines, Design Conventions, etc.)
246
108
 
247
- ### Architecture Guidelines
248
- - [Web Frontend](web-react/architecture.md)
249
- - [Backend API](backend-nestjs/architecture.md)
109
+ ### Section 4: Agent-to-Platform Mapping
250
110
 
251
- ### Design Conventions
252
- - [Web Frontend](web-react/conventions-design.md)
253
- - [Backend API](backend-nestjs/conventions-design.md)
254
-
255
- ### Development Conventions
256
- - [Web Frontend](web-react/conventions-dev.md)
257
- - [Backend API](backend-nestjs/conventions-dev.md)
258
-
259
- ### Testing Conventions
260
- - [Web Frontend](web-react/conventions-test.md)
261
- - [Backend API](backend-nestjs/conventions-test.md)
262
- ```
263
-
264
- #### Section 4: Agent-to-Platform Mapping
265
-
266
- Critical section that defines how Agents map to platform documentation. **Must dynamically adjust based on actual document availability**:
267
-
268
- ```markdown
269
- ## Agent-to-Platform Mapping
270
-
271
- This section maps dynamically generated Agents to their respective platform documentation.
272
-
273
- ### Web Frontend (web-react)
274
-
275
- | Agent Role | Agent Name | Documentation Path |
276
- |------------|------------|-------------------|
277
- | Designer | speccrew-designer-web-react | [speccrew-workspace/knowledges/techs/web-react/](web-react/) |
278
- | Developer | speccrew-dev-web-react | [speccrew-workspace/knowledges/techs/web-react/](web-react/) |
279
- | Tester | speccrew-test-web-react | [speccrew-workspace/knowledges/techs/web-react/](web-react/) |
280
-
281
- **Key Documents for Web Agents:**
282
- - Designer: [architecture.md](web-react/architecture.md), [conventions-design.md](web-react/conventions-design.md), [ui-style/ui-style-guide.md](web-react/ui-style/ui-style-guide.md)
283
- - If bizs pipeline executed: Also reference [ui-style-patterns/](web-react/ui-style-patterns/) for business UI patterns
284
- - Developer: [conventions-dev.md](web-react/conventions-dev.md), [conventions-build.md](web-react/conventions-build.md)
285
- - Tester: [conventions-test.md](web-react/conventions-test.md), [conventions-build.md](web-react/conventions-build.md)
286
-
287
- ### Backend API (backend-nestjs)
288
-
289
- | Agent Role | Agent Name | Documentation Path |
290
- |------------|------------|-------------------|
291
- | Designer | speccrew-designer-backend-nestjs | [speccrew-workspace/knowledges/techs/backend-nestjs/](backend-nestjs/) |
292
- | Developer | speccrew-dev-backend-nestjs | [speccrew-workspace/knowledges/techs/backend-nestjs/](backend-nestjs/) |
293
- | Tester | speccrew-test-backend-nestjs | [speccrew-workspace/knowledges/techs/backend-nestjs/](backend-nestjs/) |
294
-
295
- **Key Documents for Backend Agents:**
296
- - Designer: [architecture.md](backend-nestjs/architecture.md), [conventions-design.md](backend-nestjs/conventions-design.md), [conventions-data.md](backend-nestjs/conventions-data.md)
297
- - Developer: [conventions-dev.md](backend-nestjs/conventions-dev.md), [conventions-build.md](backend-nestjs/conventions-build.md), [conventions-data.md](backend-nestjs/conventions-data.md)
298
- - Tester: [conventions-test.md](backend-nestjs/conventions-test.md), [conventions-build.md](backend-nestjs/conventions-build.md)
299
-
300
- ### Mobile App (mobile-uniapp) - Example without conventions-data.md
301
-
302
- | Agent Role | Agent Name | Documentation Path |
303
- |------------|------------|-------------------|
304
- | Designer | speccrew-designer-mobile-uniapp | [speccrew-workspace/knowledges/techs/mobile-uniapp/](mobile-uniapp/) |
305
- | Developer | speccrew-dev-mobile-uniapp | [speccrew-workspace/knowledges/techs/mobile-uniapp/](mobile-uniapp/) |
306
- | Tester | speccrew-test-mobile-uniapp | [speccrew-workspace/knowledges/techs/mobile-uniapp/](mobile-uniapp/) |
307
-
308
- **Key Documents for Mobile Agents:**
309
- - Designer: [architecture.md](mobile-uniapp/architecture.md), [conventions-design.md](mobile-uniapp/conventions-design.md), [ui-style/ui-style-guide.md](mobile-uniapp/ui-style/ui-style-guide.md)
310
- - If bizs pipeline executed: Also reference [ui-style-patterns/](mobile-uniapp/ui-style-patterns/) for business UI patterns
311
- - Developer: [conventions-dev.md](mobile-uniapp/conventions-dev.md), [conventions-build.md](mobile-uniapp/conventions-build.md)
312
- - Tester: [conventions-test.md](mobile-uniapp/conventions-test.md), [conventions-build.md](mobile-uniapp/conventions-build.md)
313
- ```
111
+ Critical section that defines how Agents map to platform documentation. **Must dynamically adjust based on actual document availability.**
314
112
 
315
113
  **Dynamic Adjustment Rules:**
316
114
 
317
- 1. **Designer Agent Documents**:
318
- - Primary: architecture.md, conventions-design.md, ui-style/ui-style-guide.md
319
- - Optional: conventions-data.md (if data layer involved)
320
- - Optional: ui-style-patterns/ directory (if bizs pipeline Stage 3.5 executed)
321
- - Note: For frontend/mobile platforms, Designer should reference both ui-style/ (tech perspective) and ui-style-patterns/ (business perspective, if exists)
322
-
323
- 2. **Developer Agent Documents**:
324
- - Primary: conventions-dev.md, conventions-build.md
325
- - Optional: conventions-data.md
326
- - Note: Developer needs conventions-build.md for build process, environment configuration, and CI/CD conventions
327
-
328
- 3. **Tester Agent Documents**:
329
- - Primary: conventions-test.md, conventions-build.md
330
- - Optional: conventions-data.md (for database testing)
331
- - Note: Tester needs conventions-build.md for CI/CD pipeline and test environment configuration
115
+ 1. **Designer Agent Documents**: Primary + Optional (conventions-data.md, ui-style-patterns/)
116
+ 2. **Developer Agent Documents**: Primary (conventions-dev.md, conventions-build.md) + Optional
117
+ 3. **Tester Agent Documents**: Primary (conventions-test.md, conventions-build.md) + Optional
332
118
 
333
- **UI Style Directory Reference Guide**:
119
+ ### Section 5: Document Guide
334
120
 
335
- For frontend platforms (web, mobile, desktop), the INDEX.md should document both UI style directories:
121
+ Explain what each document type contains.
336
122
 
337
- | Directory | Managed By | Content | Reference Condition |
338
- |-----------|------------|---------|---------------------|
339
- | `ui-style/` | techs pipeline Stage 2 | Framework-level design system | Always reference for frontend platforms |
340
- | `ui-style-patterns/` | bizs pipeline Stage 3.5 | Business UI patterns | Only reference if directory exists |
123
+ ### Section 6: Usage Guide
341
124
 
342
- #### Section 5: Document Guide
125
+ How to use the technology knowledge for Designer, Developer, and Tester Agents.
343
126
 
344
- Explain what each document type contains:
345
-
346
- ```markdown
347
- ## Document Guide
348
-
349
- ### INDEX.md (per platform)
350
- Platform-specific overview and navigation.
351
-
352
- ### tech-stack.md
353
- Framework versions, dependencies, build tools, and configuration files.
354
-
355
- ### architecture.md
356
- Architecture patterns, layering, component organization, and design patterns.
357
-
358
- ### conventions-design.md
359
- Design principles, patterns, and guidelines for detailed design work.
360
-
361
- ### conventions-dev.md
362
- Naming conventions, code style, directory structure, and Git conventions.
363
-
364
- ### conventions-test.md
365
- Testing frameworks, coverage requirements, and testing patterns.
366
-
367
- ### conventions-build.md
368
- Build process, environment configuration, CI/CD pipelines, and deployment conventions.
369
-
370
- ### conventions-data.md
371
- Data modeling, ORM usage, and database conventions (if applicable).
372
- ```
373
-
374
- #### Section 6: Usage Guide
375
-
376
- How to use the technology knowledge:
377
-
378
- ```markdown
379
- ## Usage Guide
380
-
381
- ### For Designer Agents
382
- 1. Read [architecture.md] for platform architecture patterns
383
- 2. Read [conventions-design.md] for design principles
384
- 3. Reference [tech-stack.md] for technology capabilities
385
-
386
- ### For Developer Agents
387
- 1. Read [conventions-dev.md] for coding standards
388
- 2. Read [conventions-test.md] for testing requirements
389
- 3. Reference [architecture.md] when implementation details are unclear
390
-
391
- ### For Tester Agents
392
- 1. Read [conventions-test.md] for testing standards
393
- 2. Reference [conventions-design.md] to understand design intent
394
- ```
395
-
396
- ### Step 5: Write Output
397
-
398
- Write the generated INDEX.md to `{{output_path}}/INDEX.md`.
399
-
400
- ### Step 6: Report Results
401
-
402
- ```
403
- Stage 3 completed: Root Technology Index Generated
404
- - Platforms Indexed: {{platform_count}}
405
- - web-react: ✓
406
- - backend-nestjs: ✓
407
- - Root Index: {{output_path}}/INDEX.md
408
- - Agent Mappings: Documented for all platforms
409
- ```
410
-
411
- ## Template
412
-
413
- Use template at `templates/INDEX-TEMPLATE.md`:
414
-
415
- **Template Variables:**
416
- - `{{generated_at}}`: ISO timestamp
417
- - `{{source_path}}`: Source path
418
- - `{{platform_count}}`: Number of platforms
419
- - `{{#each platforms}}`: Loop through platforms
420
- - `{{platform_id}}`: Platform identifier
421
- - `{{platform_type}}`: Platform type
422
- - `{{framework}}`: Framework name
423
- - `{{language}}`: Programming language
127
+ ---
424
128
 
425
129
  ## Checklist
426
130
 
@@ -431,7 +135,7 @@ Use template at `templates/INDEX-TEMPLATE.md`:
431
135
  ### Dynamic Document Detection
432
136
  - [ ] Each platform directory scanned for actual document existence
433
137
  - [ ] Document availability map created for each platform
434
- - [ ] Required documents verified (INDEX.md, tech-stack.md, architecture.md, conventions-design.md, conventions-dev.md, conventions-test.md, conventions-build.md)
138
+ - [ ] Required documents verified
435
139
  - [ ] Optional conventions-data.md existence checked per platform
436
140
 
437
141
  ### Content Generation
@@ -446,7 +150,17 @@ Use template at `templates/INDEX-TEMPLATE.md`:
446
150
  - [ ] No broken links to non-existent documents
447
151
  - [ ] conventions-data.md links only included for platforms where it exists
448
152
  - [ ] **Source traceability**: File reference block added to root INDEX.md
449
- - [ ] **Source traceability**: Section Source annotations added at end of major sections
450
153
  - [ ] Output file written successfully
451
154
  - [ ] Results reported with document availability summary
452
155
 
156
+ ---
157
+
158
+ ## CONTINUOUS EXECUTION RULES
159
+
160
+ This skill follows the continuous execution pattern defined in `GLOBAL-R1`:
161
+
162
+ 1. **Sequential Execution**: All workflow steps must execute in the defined order without interruption.
163
+ 2. **No User Prompts**: Worker must not pause for user confirmation between steps.
164
+ 3. **Complete All Steps**: Worker must complete all steps before reporting results.
165
+ 4. **Error Handling**: If any step fails, continue with remaining steps if possible, then report all errors together.
166
+ 5. **Technology Stack Constraint**: Per `GLOBAL-R-TECHSTACK`, all generated index documents must accurately reflect detected platform technology stacks.