sdtk-spec-kit 0.3.10 → 0.3.12

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 (40) hide show
  1. package/README.md +219 -197
  2. package/assets/manifest/toolkit-bundle.manifest.json +72 -57
  3. package/assets/manifest/toolkit-bundle.sha256.txt +30 -27
  4. package/assets/toolkit/toolkit/README.md +50 -0
  5. package/assets/toolkit/toolkit/SDTK_TOOLKIT.md +185 -0
  6. package/assets/toolkit/toolkit/install.ps1 +347 -310
  7. package/assets/toolkit/toolkit/scripts/init-feature.ps1 +2 -1
  8. package/assets/toolkit/toolkit/skills/sdtk-api-design-spec/SKILL.md +84 -84
  9. package/assets/toolkit/toolkit/skills/sdtk-api-design-spec/references/API_DESIGN_FLOWCHART_CREATION_RULES.md +468 -468
  10. package/assets/toolkit/toolkit/skills/sdtk-api-doc/references/API_DESIGN_FLOWCHART_CREATION_RULES.md +468 -468
  11. package/assets/toolkit/toolkit/skills/sdtk-api-doc/references/YAML_CREATION_RULES.md +127 -127
  12. package/assets/toolkit/toolkit/skills/sdtk-arch/SKILL.md +85 -83
  13. package/assets/toolkit/toolkit/skills/sdtk-arch/references/API_DESIGN_FLOWCHART_CREATION_RULES.md +468 -468
  14. package/assets/toolkit/toolkit/skills/sdtk-arch/references/FLOW_ACTION_SPEC_CREATION_RULES.md +220 -220
  15. package/assets/toolkit/toolkit/skills/sdtk-arch/references/YAML_CREATION_RULES.md +127 -127
  16. package/assets/toolkit/toolkit/skills/sdtk-dev/SKILL.md +108 -102
  17. package/assets/toolkit/toolkit/skills/sdtk-orchestrator/SKILL.md +97 -81
  18. package/assets/toolkit/toolkit/skills/sdtk-pm/SKILL.md +37 -30
  19. package/assets/toolkit/toolkit/skills/sdtk-qa/SKILL.md +75 -61
  20. package/assets/toolkit/toolkit/skills/sdtk-screen-design-spec/references/FLOW_ACTION_SPEC_CREATION_RULES.md +220 -220
  21. package/assets/toolkit/toolkit/skills-claude/api-design-spec/SKILL.md +90 -90
  22. package/assets/toolkit/toolkit/skills-claude/orchestrator/SKILL.md +25 -53
  23. package/assets/toolkit/toolkit/skills-claude/qa/SKILL.md +12 -6
  24. package/assets/toolkit/toolkit/templates/QUALITY_CHECKLIST.md +124 -124
  25. package/assets/toolkit/toolkit/templates/README.md +1 -0
  26. package/assets/toolkit/toolkit/templates/SHARED_PLANNING.md +81 -81
  27. package/assets/toolkit/toolkit/templates/docs/api/API_DESIGN_FLOWCHART_CREATION_RULES.md +468 -468
  28. package/assets/toolkit/toolkit/templates/docs/api/YAML_CREATION_RULES.md +127 -127
  29. package/assets/toolkit/toolkit/templates/docs/database/DATABASE_SPEC_TEMPLATE.md +174 -174
  30. package/assets/toolkit/toolkit/templates/docs/dev/FEATURE_IMPL_PLAN_TEMPLATE.md +106 -96
  31. package/assets/toolkit/toolkit/templates/docs/qa/CONTROLLER_ACCEPTANCE_TEMPLATE.md +90 -0
  32. package/assets/toolkit/toolkit/templates/docs/qa/QA_RELEASE_REPORT_TEMPLATE.md +162 -95
  33. package/assets/toolkit/toolkit/templates/docs/specs/FLOW_ACTION_SPEC_CREATION_RULES.md +220 -220
  34. package/package.json +20 -20
  35. package/src/commands/help.js +26 -10
  36. package/src/commands/init.js +108 -105
  37. package/src/commands/update.js +11 -0
  38. package/src/index.js +62 -59
  39. package/src/lib/project-target-guard.js +53 -0
  40. package/src/lib/update.js +333 -0
@@ -0,0 +1,185 @@
1
+ # SDTK-SPEC Multi-Agent Software Development Toolkit
2
+
3
+ This guide explains how to run SDTK-SPEC as a runtime-agnostic toolkit with adapters for Codex and Claude Code.
4
+ It is product-specific to `SDTK-SPEC` within the broader `SDTK Suite` family (`SDTK-SPEC`, `SDTK-CODE`, `SDTK-OPS`).
5
+ Use the root `README.md` for suite-level framing and `products/sdtk-code/toolkit/SDTKCODE_TOOLKIT.md` for the downstream coding product.
6
+
7
+ Canonical install/runtime source of truth:
8
+ - `governance/ai/cli/SDTK_RUNTIME_AND_FEATURE_STATUS.md`
9
+
10
+ ## 1. What SDTK-SPEC Is
11
+ SDTK-SPEC is a practical delivery framework for software teams.
12
+ It provides:
13
+ - a fixed SDLC workflow,
14
+ - reusable documentation templates,
15
+ - specialized skills for each phase,
16
+ - and explicit quality gates.
17
+
18
+ This guide does not document `SDTK-OPS` as a runnable product because that surface is still planned/partial only.
19
+
20
+ ## 2. SDLC Model
21
+ Default flow:
22
+ 1. PM initiation
23
+ 2. BA analysis
24
+ 3. PM planning
25
+ 4. Architecture design
26
+ 5. Development planning + SDTK-CODE handoff
27
+ 6. QA validation and release decision
28
+
29
+ SDTK-SPEC and SDTK-CODE stay separate:
30
+ - SDTK-SPEC owns upstream docs, planning, and handoff generation
31
+ - SDTK-CODE owns downstream coding workflow (`start -> plan -> build -> verify -> ship`)
32
+ - QA remains in SDTK-SPEC and normally consumes downstream evidence from SDTK-CODE
33
+
34
+ ## 3. Runtime-Adaptive Installation
35
+ From project root:
36
+
37
+ ### 3.1 Codex runtime
38
+ `powershell -ExecutionPolicy Bypass -File ".\toolkit\install.ps1" -Runtime codex`
39
+
40
+ ### 3.2 Claude Code runtime
41
+ `powershell -ExecutionPolicy Bypass -File ".\toolkit\install.ps1" -Runtime claude`
42
+
43
+ ### 3.3 Common installer options
44
+ - `-Force`: overwrite existing adapter/config files in project root.
45
+ - `-RuntimeScope`: `project` or `user` -- controls where skill files are installed (default: `project` for Claude, `user` for Codex).
46
+ - `-SkipRuntimeAssets`: skip skill file installation for the selected runtime.
47
+ - `-SkipSkills`: **(deprecated)** use `-SkipRuntimeAssets` instead.
48
+
49
+ ## 4. What Installer Copies
50
+ Always:
51
+ - `toolkit/AGENTS.md` -> `AGENTS.md`
52
+ - `toolkit/sdtk-spec.config.json` -> `sdtk-spec.config.json`
53
+ - `toolkit/sdtk-spec.config.profiles.example.json` -> `sdtk-spec.config.profiles.example.json`
54
+
55
+ By runtime:
56
+ - `codex` -> `toolkit/runtimes/codex/CODEX_TEMPLATE.md` -> `CODEX.md`
57
+ - `claude` -> `toolkit/runtimes/claude/CLAUDE_TEMPLATE.md` -> `CLAUDE.md`
58
+
59
+ Runtime behavior (scope-aware installation):
60
+ - `codex`: installs skills into `$CODEX_HOME/skills/` or `~/.codex/skills/` by default, and into `<project>/.codex/skills/` only through the explicit local `CODEX_HOME=<project>/.codex` contract. Native `.codex/skills` auto-discovery is not claimed.
61
+ - `claude`: installs skills into `.claude/skills/` in the project root (project scope, default) or `~/.claude/skills/` (user scope).
62
+
63
+ ## 5. Feature Bootstrap
64
+ After install:
65
+
66
+ `powershell -ExecutionPolicy Bypass -File ".\toolkit\scripts\init-feature.ps1" -FeatureKey WORKFLOW_ENGINE -FeatureName "Workflow Engine"`
67
+
68
+ Use `-ProjectPath` when toolkit is not directly under project root.
69
+ Use `-ValidateOnly` to verify inputs/templates without writing files.
70
+
71
+ ## 6. Role Tags
72
+ Use the same role tags across runtimes:
73
+ - `/pm`
74
+ - `/ba`
75
+ - `/arch`
76
+ - `/dev`
77
+ - `/qa`
78
+ - `/engineer` (technical escalation)
79
+
80
+ Default role is `/pm` when role is not specified.
81
+
82
+ ## 7. Orchestration Mapping
83
+ Architecture phase:
84
+ - API contract/flow scope -> `sdtk-api-doc`
85
+ - API design detail from YAML + flow list -> `sdtk-api-design-spec`
86
+ - UI flow-action scope -> `sdtk-screen-design-spec`
87
+
88
+ DEV phase:
89
+ - `/dev` creates `FEATURE_IMPL_PLAN` + `CODE_HANDOFF`
90
+ - `toolkit/scripts/generate-code-handoff.ps1` generates the canonical machine-readable handoff JSON
91
+ - legacy prompt templates under `toolkit/skills/sdtk-dev/prompts/` remain available as manual helper assets only
92
+
93
+ QA phase:
94
+ - detailed reusable test-case artifact -> `sdtk-test-case-spec`
95
+ - execution report and release decision -> `sdtk-qa`
96
+ - normal prerequisite is downstream implementation evidence, normally from SDTK-CODE
97
+
98
+ ## 8. Hybrid Controls (`sdtk-spec.config.json`)
99
+ - `orchestration.apiDesignDetailMode = auto|on|off`
100
+ - `orchestration.testCaseSpecMode = auto|on|off`
101
+
102
+ ## 8.1 Skill Catalog and Handoff Assets
103
+ - `toolkit/skills/skills.catalog.yaml` is the canonical inventory for the 13 core SDTK-SPEC skills.
104
+ - `toolkit/templates/handoffs/` provides the standard PM/BA/ARCH/DEV/QA handoff prompts and review gates.
105
+ - Every core `SKILL.md` includes `## Critical Constraints` derived from the active hard gates and verification policy.
106
+ - Use `governance/ai/core/SDTK_SKILL_AUTHORING_AND_TESTING.md` when creating or updating skills.
107
+
108
+ ## 9. Workflow Quality Contracts
109
+
110
+ ### Verification Before Completion
111
+ All phases apply `governance/ai/core/SDTK_VERIFICATION_BEFORE_COMPLETION_POLICY.md`. No workflow step may report done, pass, or release-ready without fresh command evidence. Red flags include `should pass`, `probably works`, and trusting agent reports without verification.
112
+
113
+ ### Order-Critical Hard Gates
114
+ Three hard gates enforce mandatory sequencing:
115
+ - ARCH: `DESIGN_LAYOUT` must be generated before `FLOW_ACTION_SPEC` for UI-scope features
116
+ - DEV: `FEATURE_IMPL_PLAN` must be approved before `READY_FOR_SDTK_CODE` can be emitted
117
+ - QA: downstream implementation evidence must exist before QA handoff starts
118
+
119
+ ### `/dev` Ownership
120
+ The default `/dev` role does not implement code in this wave.
121
+ It:
122
+ 1. refines `FEATURE_IMPL_PLAN`
123
+ 2. determines readiness
124
+ 3. emits `CODE_HANDOFF`
125
+ 4. suggests the exact `sdtk-code start ...` command when ready
126
+
127
+ ### Specification Quoting
128
+ QA validation and reusable test-case design must quote exact requirement text when judging a match or mismatch.
129
+ Use:
130
+ - `Spec says: "[exact quote]" -> Evidence: [match/mismatch + file reference]`
131
+
132
+ ### Assumptions Discipline
133
+ `FLOW_ACTION_SPEC_TEMPLATE.md` and `API_DESIGN_DETAIL_TEMPLATE.md` require a top-level `## Assumptions` section so inferred or deferred decisions stay explicit during ARCH output review.
134
+
135
+ ### Subagent Model Selection
136
+ When dispatching manual helper tasks via `sdtk-dev`, use:
137
+ - Fast or cheap model for mechanical single-file changes
138
+ - Standard model for multi-file integration tasks
139
+ - Most capable model for architecture and design decisions
140
+
141
+ ## 10. Artifact Structure
142
+ Shared state:
143
+ - `SHARED_PLANNING.md`
144
+ - `QUALITY_CHECKLIST.md`
145
+
146
+ Phase outputs:
147
+ - `docs/product/`
148
+ - `docs/specs/`
149
+ - `docs/architecture/`
150
+ - `docs/api/`
151
+ - `docs/design/`
152
+ - `docs/dev/`
153
+ - `docs/qa/`
154
+ - `docs/database/`
155
+
156
+ ## 11. Rule Sources
157
+ - API YAML rules:
158
+ - `toolkit/templates/docs/api/YAML_CREATION_RULES.md`
159
+ - API design detail + flowchart rules:
160
+ - `toolkit/templates/docs/api/API_DESIGN_FLOWCHART_CREATION_RULES.md`
161
+ - Compatibility notes kept for legacy references:
162
+ - `toolkit/templates/docs/api/FLOWCHART_CREATION_RULES.md`
163
+ - `toolkit/templates/docs/api/API_DESIGN_CREATION_RULES.md`
164
+ - Screen flow-action rules:
165
+ - `toolkit/templates/docs/specs/FLOW_ACTION_SPEC_CREATION_RULES.md`
166
+ - QA test-case rules:
167
+ - `toolkit/templates/docs/qa/TEST_CASE_CREATION_RULES.md`
168
+
169
+ ## 12. Examples
170
+ Use `examples/` for onboarding-ready scenario packs:
171
+ - `enterprise-crud-ui-api-db`
172
+ - `api-only-service`
173
+ - `admin-console-flow-action`
174
+ - `bugfix-hotfix-flow`
175
+
176
+ ## 13. Runtime Readiness Audit
177
+ Run the audit script before maintainer testing or runtime troubleshooting:
178
+
179
+ `powershell -ExecutionPolicy Bypass -File ".\toolkit\scripts\check-runtime-readiness.ps1" -Runtime <claude|codex>`
180
+
181
+ Use `-Json` for machine-readable output.
182
+
183
+ ## 14. Output Language
184
+ - Feature artifacts under `docs/**`: default English.
185
+ - Toolkit guidance docs: English or Vietnamese.