@anhth2/spec-driven-dev-plugin 0.9.2 → 0.11.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.
- package/commands/debug.md +50 -20
- package/commands/define-product.md +49 -19
- package/commands/{generate-tests.md → dev-gen-test.md} +85 -23
- package/commands/{generate-tests.tmpl → dev-gen-test.tmpl} +18 -4
- package/{core/commands/run-tests.md → commands/dev-run-test.md} +102 -21
- package/commands/{run-tests.tmpl → dev-run-test.tmpl} +35 -2
- package/commands/{smoke-test.md → dev-smoke-test.md} +54 -24
- package/commands/{smoke-test.tmpl → dev-smoke-test.tmpl} +5 -5
- package/commands/fix-bug.md +50 -20
- package/commands/generate-bdd.md +78 -21
- package/commands/generate-bdd.tmpl +11 -2
- package/commands/generate-code.md +123 -23
- package/commands/generate-code.tmpl +56 -4
- package/commands/generate-design-spec.md +142 -47
- package/commands/generate-design-spec.tmpl +93 -28
- package/commands/generate-prd.md +49 -19
- package/commands/generate-spec-manifest.md +49 -19
- package/commands/generate-tech-docs.md +50 -20
- package/commands/generate-tech-docs.tmpl +1 -1
- package/commands/learn.md +50 -20
- package/commands/propose-scenario.md +50 -20
- package/commands/propose-scenario.tmpl +1 -1
- package/commands/qc-analyze.md +514 -0
- package/commands/qc-analyze.tmpl +71 -0
- package/commands/qc-design-test.md +510 -0
- package/commands/qc-design-test.tmpl +67 -0
- package/commands/qc-plan.md +492 -0
- package/commands/qc-plan.tmpl +49 -0
- package/commands/qc-report.md +491 -0
- package/commands/qc-report.tmpl +48 -0
- package/commands/qc-review.md +496 -0
- package/commands/qc-review.tmpl +53 -0
- package/commands/qc-run-test.md +538 -0
- package/commands/qc-run-test.tmpl +77 -0
- package/commands/refine-prd.md +203 -24
- package/commands/refine-prd.tmpl +16 -5
- package/commands/report-bug.md +49 -19
- package/commands/review-code.md +51 -21
- package/commands/review-code.tmpl +1 -1
- package/commands/review-context.md +198 -20
- package/commands/review-context.tmpl +11 -1
- package/commands/review-tech-docs.md +49 -19
- package/commands/setup-ai-first.md +14 -7
- package/commands/sync.md +30 -20
- package/commands/sync.tmpl +16 -13
- package/commands/update-framework.md +14 -7
- package/commands/validate-traces.md +106 -45
- package/commands/validate-traces.tmpl +57 -26
- package/core/FRAMEWORK_VERSION +1 -1
- package/core/commands/debug.md +50 -20
- package/core/commands/define-product.md +49 -19
- package/core/commands/{generate-tests.md → dev-gen-test.md} +85 -23
- package/{commands/run-tests.md → core/commands/dev-run-test.md} +102 -21
- package/core/commands/{smoke-test.md → dev-smoke-test.md} +54 -24
- package/core/commands/fix-bug.md +50 -20
- package/core/commands/generate-bdd.md +78 -21
- package/core/commands/generate-code.md +123 -23
- package/core/commands/generate-design-spec.md +142 -47
- package/core/commands/generate-prd.md +49 -19
- package/core/commands/generate-spec-manifest.md +49 -19
- package/core/commands/generate-tech-docs.md +50 -20
- package/core/commands/learn.md +50 -20
- package/core/commands/propose-scenario.md +50 -20
- package/core/commands/qc-analyze.md +514 -0
- package/core/commands/qc-design-test.md +510 -0
- package/core/commands/qc-plan.md +492 -0
- package/core/commands/qc-report.md +491 -0
- package/core/commands/qc-review.md +496 -0
- package/core/commands/qc-run-test.md +538 -0
- package/core/commands/refine-prd.md +203 -24
- package/core/commands/report-bug.md +49 -19
- package/core/commands/review-code.md +51 -21
- package/core/commands/review-context.md +198 -20
- package/core/commands/review-tech-docs.md +49 -19
- package/core/commands/setup-ai-first.md +14 -7
- package/core/commands/sync.md +30 -20
- package/core/commands/update-framework.md +14 -7
- package/core/commands/validate-traces.md +106 -45
- package/core/modules/qc-playwright/stack-profile.yaml +65 -0
- package/core/skills/code/SKILL.md +63 -26
- package/core/skills/debug/SKILL.md +78 -34
- package/core/skills/design-spec/SKILL.md +49 -19
- package/core/skills/discovery/SKILL.md +49 -19
- package/core/skills/prd/SKILL.md +28 -14
- package/core/skills/qc/qa-analyst/DOC_GAPS.template.md +63 -0
- package/core/skills/qc/qa-analyst/acceptance-criteria.md +56 -0
- package/core/skills/qc/qa-analyst/business-rules.md +55 -0
- package/core/skills/qc/qa-analyst/data-flow.md +60 -0
- package/core/skills/qc/qa-analyst/spec-breakdown.md +57 -0
- package/core/skills/qc/qa-designer/e2e/journey.md +41 -0
- package/core/skills/qc/qa-designer/exploratory/charter.md +68 -0
- package/core/skills/qc/qa-designer/exploratory/explore-to-functional.md +43 -0
- package/core/skills/qc/qa-designer/functional/api.md +45 -0
- package/core/skills/qc/qa-designer/functional/gui-feature.md +46 -0
- package/core/skills/qc/qa-designer/functional/gui-screen.md +52 -0
- package/core/skills/qc/qa-designer/integration/api.md +42 -0
- package/core/skills/qc/qa-designer/integration/db.md +39 -0
- package/core/skills/qc/qa-designer/integration/gui.md +40 -0
- package/core/skills/qc/qa-designer/integration/kafka.md +40 -0
- package/core/skills/qc/qa-designer/non-functional.md +40 -0
- package/core/skills/qc/qa-planner/test-plan.md +120 -0
- package/core/skills/qc/qa-reviewer/script/e2e.md +87 -0
- package/core/skills/qc/qa-reviewer/script/exploratory.md +45 -0
- package/core/skills/qc/qa-reviewer/script/functional.md +101 -0
- package/core/skills/qc/qa-reviewer/script/integration.md +91 -0
- package/core/skills/qc/qa-reviewer/script/non-functional.md +126 -0
- package/core/skills/qc/qa-reviewer/test-case/e2e.md +73 -0
- package/core/skills/qc/qa-reviewer/test-case/exploratory.md +43 -0
- package/core/skills/qc/qa-reviewer/test-case/functional.md +76 -0
- package/core/skills/qc/qa-reviewer/test-case/integration.md +69 -0
- package/core/skills/qc/qa-reviewer/test-case/non-functional.md +73 -0
- package/core/skills/qc/qa-runner/e2e.md +49 -0
- package/core/skills/qc/qa-runner/exploratory/session.md +36 -0
- package/core/skills/qc/qa-runner/functional/api.md +35 -0
- package/core/skills/qc/qa-runner/functional/gui-feature.md +51 -0
- package/core/skills/qc/qa-runner/functional/gui-screen.md +55 -0
- package/core/skills/qc/qa-runner/integration.md +47 -0
- package/core/skills/qc/qa-runner/non-functional.md +49 -0
- package/core/skills/qc/qa-runner/report/report.md +37 -0
- package/core/skills/setup-ai-first/SKILL.md +14 -7
- package/core/skills/spec/SKILL.md +28 -14
- package/core/skills/test/SKILL.md +121 -54
- package/core/steps/capture-lesson.md +1 -1
- package/core/steps/context-loader.md +35 -12
- package/core/steps/report-footer.md +14 -7
- package/core/steps/review-fanout.md +138 -0
- package/core/steps/spawn-agent.md +1 -1
- package/core/steps/trace-mirror.md +18 -0
- package/core/templates/design-spec.template.md +16 -8
- package/core/templates/project-context.yaml +8 -0
- package/docs/01-getting-started/README.md +19 -0
- package/docs/01-getting-started/core-concepts.md +102 -0
- package/docs/01-getting-started/installation.md +154 -0
- package/docs/01-getting-started/quickstart.md +85 -0
- package/docs/02-guides/README.md +27 -0
- package/docs/02-guides/developer/README.md +46 -0
- package/docs/02-guides/developer/bdd-and-trace.md +123 -0
- package/docs/02-guides/developer/commands.md +76 -0
- package/docs/02-guides/developer/pr-checklist.md +15 -0
- package/docs/02-guides/developer/scenarios.md +448 -0
- package/docs/02-guides/developer/workflow.md +59 -0
- package/docs/02-guides/product-owner/README.md +77 -0
- package/docs/02-guides/product-owner/commands.md +30 -0
- package/docs/02-guides/product-owner/handoff-checklist.md +42 -0
- package/docs/02-guides/product-owner/prd-writing-rules.md +45 -0
- package/docs/02-guides/product-owner/scenarios.md +357 -0
- package/docs/02-guides/qc-automation.md +92 -0
- package/docs/02-guides/tester/README.md +72 -0
- package/docs/02-guides/tester/bug-reporting.md +117 -0
- package/docs/02-guides/tester/reading-specs.md +79 -0
- package/docs/02-guides/tester/scenarios.md +186 -0
- package/docs/02-guides/tester/spec-manifest.md +124 -0
- package/docs/02-guides/tester/test-checklist.md +31 -0
- package/docs/02-guides/tester/workflow.md +79 -0
- package/docs/03-concepts/README.md +19 -0
- package/docs/03-concepts/architecture.md +243 -0
- package/docs/03-concepts/pipeline.md +249 -0
- package/docs/03-concepts/traceability.md +148 -0
- package/docs/04-operations/README.md +33 -0
- package/docs/04-operations/bug-flow.md +321 -0
- package/docs/04-operations/publishing.md +137 -0
- package/docs/04-operations/sync-and-update.md +328 -0
- package/docs/05-reference/README.md +29 -0
- package/docs/05-reference/commands.md +229 -0
- package/docs/05-reference/modules.md +110 -0
- package/docs/05-reference/trace-schema.md +146 -0
- package/docs/README.md +51 -0
- package/modules/qc-playwright/stack-profile.yaml +65 -0
- package/package.json +2 -2
- package/skills/code/SKILL.md +63 -26
- package/skills/debug/SKILL.md +78 -34
- package/skills/debug/SKILL.tmpl +1 -1
- package/skills/design-spec/SKILL.md +49 -19
- package/skills/discovery/SKILL.md +49 -19
- package/skills/prd/SKILL.md +28 -14
- package/skills/qc/qa-analyst/DOC_GAPS.template.md +63 -0
- package/skills/qc/qa-analyst/acceptance-criteria.md +56 -0
- package/skills/qc/qa-analyst/business-rules.md +55 -0
- package/skills/qc/qa-analyst/data-flow.md +60 -0
- package/skills/qc/qa-analyst/spec-breakdown.md +57 -0
- package/skills/qc/qa-designer/e2e/journey.md +41 -0
- package/skills/qc/qa-designer/exploratory/charter.md +68 -0
- package/skills/qc/qa-designer/exploratory/explore-to-functional.md +43 -0
- package/skills/qc/qa-designer/functional/api.md +45 -0
- package/skills/qc/qa-designer/functional/gui-feature.md +46 -0
- package/skills/qc/qa-designer/functional/gui-screen.md +52 -0
- package/skills/qc/qa-designer/integration/api.md +42 -0
- package/skills/qc/qa-designer/integration/db.md +39 -0
- package/skills/qc/qa-designer/integration/gui.md +40 -0
- package/skills/qc/qa-designer/integration/kafka.md +40 -0
- package/skills/qc/qa-designer/non-functional.md +40 -0
- package/skills/qc/qa-planner/test-plan.md +120 -0
- package/skills/qc/qa-reviewer/script/e2e.md +87 -0
- package/skills/qc/qa-reviewer/script/exploratory.md +45 -0
- package/skills/qc/qa-reviewer/script/functional.md +101 -0
- package/skills/qc/qa-reviewer/script/integration.md +91 -0
- package/skills/qc/qa-reviewer/script/non-functional.md +126 -0
- package/skills/qc/qa-reviewer/test-case/e2e.md +73 -0
- package/skills/qc/qa-reviewer/test-case/exploratory.md +43 -0
- package/skills/qc/qa-reviewer/test-case/functional.md +76 -0
- package/skills/qc/qa-reviewer/test-case/integration.md +69 -0
- package/skills/qc/qa-reviewer/test-case/non-functional.md +73 -0
- package/skills/qc/qa-runner/e2e.md +49 -0
- package/skills/qc/qa-runner/exploratory/session.md +36 -0
- package/skills/qc/qa-runner/functional/api.md +35 -0
- package/skills/qc/qa-runner/functional/gui-feature.md +51 -0
- package/skills/qc/qa-runner/functional/gui-screen.md +55 -0
- package/skills/qc/qa-runner/integration.md +47 -0
- package/skills/qc/qa-runner/non-functional.md +49 -0
- package/skills/qc/qa-runner/report/report.md +37 -0
- package/skills/setup-ai-first/SKILL.md +14 -7
- package/skills/spec/SKILL.md +28 -14
- package/skills/test/SKILL.md +121 -54
- package/skills/test/SKILL.tmpl +9 -9
- package/steps/capture-lesson.md +1 -1
- package/steps/context-loader.md +35 -12
- package/steps/report-footer.md +14 -7
- package/steps/review-fanout.md +138 -0
- package/steps/spawn-agent.md +1 -1
- package/steps/trace-mirror.md +18 -0
- package/templates/design-spec.template.md +16 -8
- package/templates/project-context.yaml +8 -0
- package/ARCHITECTURE.md +0 -247
package/skills/debug/SKILL.md
CHANGED
|
@@ -105,7 +105,7 @@ If `services` section is present:
|
|
|
105
105
|
|
|
106
106
|
**2. Route to service** — if active domain matches a key in `services`:
|
|
107
107
|
- Override `paths.specs_dir` → `services.{domain}.specs_dir`
|
|
108
|
-
- Override `paths.tech_docs_dir` → `services.{domain}.tech_docs_dir`
|
|
108
|
+
- Override `paths.tech_docs_dir` → `services.{domain}.tech_docs_dir` — **only if `setup.spec_source` is NOT set.** When `spec_source` IS set, the tech-design (API contract) is a cross-team artifact and must live in the shared spec repo (handled in step 4), so leave `tech_docs_dir` for step 4 to route — do NOT pin it per-service here.
|
|
109
109
|
- Store `active_service` = `services.{domain}.path`
|
|
110
110
|
- Store `active_service_module` = `services.{domain}.module`
|
|
111
111
|
- If service has its own `module` → use it as `active_module` (overrides `tech_stack.module`)
|
|
@@ -117,7 +117,7 @@ If `services` section is present:
|
|
|
117
117
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
118
118
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
119
119
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
120
|
-
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **
|
|
120
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **always when `spec_source` is set** (step 2 no longer pins tech-docs per-service in this case). The tech-design IS the cross-team API contract: BE authors it here, and FE/App read it from the same spec submodule at `/generate-code --phase=integration`. *(Per-service tech-docs only happen when there is no `spec_source` — a pure multi-service BE repo with no shared spec module.)*
|
|
121
121
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
122
122
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
123
123
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
@@ -148,7 +148,7 @@ When `active_service` has been resolved to a real path in Step 1.5 (e.g., `user-
|
|
|
148
148
|
| `paths.specs_dir` | `{active_service}/{service paths.specs_dir}` (if set in service config, else keep Step 1.5 override) |
|
|
149
149
|
|
|
150
150
|
**3. Store** `service_root = {active_service}` as the working directory anchor for all downstream commands:
|
|
151
|
-
- Shell commands (`/run-
|
|
151
|
+
- Shell commands (`/dev-run-test`, `/dev-gen-test`) run **from within** `service_root`
|
|
152
152
|
- File write operations (test files, trace TSVs) use paths **relative to** `service_root`
|
|
153
153
|
|
|
154
154
|
**4. If service config not found** — keep umbrella defaults, still set `service_root = {active_service}` (path anchor is always needed even without a config override).
|
|
@@ -163,19 +163,41 @@ If the file does not exist → skip silently.
|
|
|
163
163
|
|
|
164
164
|
---
|
|
165
165
|
|
|
166
|
-
## Step 3 — [CRITICAL] Load CLAUDE.md
|
|
166
|
+
## Step 3 — [CRITICAL] Load CLAUDE.md (layered: root + service overlay)
|
|
167
167
|
|
|
168
168
|
*This is the highest-priority context — it defines HOW to write code and documents for this project.*
|
|
169
169
|
|
|
170
|
-
|
|
170
|
+
CLAUDE.md is loaded in **two layers** so umbrella-wide rules and service-specific
|
|
171
|
+
architecture/coding standards compose correctly. The agent always sits at the umbrella
|
|
172
|
+
root, but the implementation code lives in a service submodule with its OWN stack,
|
|
173
|
+
architecture, and conventions — so the service's CLAUDE.md must win for code generation.
|
|
174
|
+
|
|
175
|
+
**Layer 1 — [BASE] Root CLAUDE.md (umbrella-wide).**
|
|
176
|
+
Read `CLAUDE.md` at the repo root. Treat its contents as the **shared baseline** for the
|
|
177
|
+
whole umbrella — git conventions, data-protection posture, cross-cutting rules, and (in
|
|
178
|
+
single-service mode) the project's only architecture + coding standards.
|
|
179
|
+
|
|
180
|
+
**Layer 2 — [OVERLAY] Service CLAUDE.md (umbrella mode only).**
|
|
181
|
+
*Run only if `service_root` was set in Step 1.6 (i.e. a real service was routed to).*
|
|
182
|
+
Read `{service_root}/CLAUDE.md`. This file defines the architecture + coding standards of
|
|
183
|
+
the **actual stack being implemented** (e.g. `user-service` = java-spring, `web` = nextjs).
|
|
184
|
+
Overlay it on top of Layer 1: **on any conflict, the service value WINS** for architecture,
|
|
185
|
+
coding standards, and error handling. Layer-1 values that the service does not redefine
|
|
186
|
+
(e.g. git conventions, banned patterns shared org-wide) remain in effect.
|
|
187
|
+
|
|
188
|
+
From the **merged** result, extract and store:
|
|
171
189
|
|
|
172
190
|
- **§1 Project Overview** → project name, language, framework, build/test commands, domains
|
|
173
|
-
- **§2 Architecture** → layer order (e.g., Controller → Facade → Service → Repository), architectural rules
|
|
174
|
-
- **§3 Coding Standards** → naming conventions (classes, methods), response wrapper type, forbidden patterns
|
|
175
|
-
- **§5 Error Handling** → exception types, HTTP status code mapping, not-found exception class name
|
|
176
|
-
- **§7 Git Conventions** → branch naming pattern, commit message format
|
|
191
|
+
- **§2 Architecture** → layer order (e.g., Controller → Facade → Service → Repository), architectural rules — *service overlay wins*
|
|
192
|
+
- **§3 Coding Standards** → naming conventions (classes, methods), response wrapper type, forbidden patterns — *service overlay wins*
|
|
193
|
+
- **§5 Error Handling** → exception types, HTTP status code mapping, not-found exception class name — *service overlay wins*
|
|
194
|
+
- **§7 Git Conventions** → branch naming pattern, commit message format — *root baseline unless service redefines*
|
|
177
195
|
|
|
178
|
-
|
|
196
|
+
**Resolution rules:**
|
|
197
|
+
- If both layers exist → merge as above; record `claude_md_source = root + {service_root}`.
|
|
198
|
+
- If only the service overlay exists (no root CLAUDE.md) → use the service file alone; `claude_md_source = {service_root}`.
|
|
199
|
+
- If `service_root` is set but `{service_root}/CLAUDE.md` is **missing** → fall back to root CLAUDE.md and flag ⚠️ in the Step 7 recap (the service has no architecture/coding-standards definition — code generation will use umbrella defaults, which may be the wrong stack).
|
|
200
|
+
- If neither exists → note CLAUDE.md as missing and continue with project-context.yaml data only.
|
|
179
201
|
|
|
180
202
|
---
|
|
181
203
|
|
|
@@ -241,7 +263,7 @@ active_module = tech_stack.module (e.g. "java-spring", "react", "flutter")
|
|
|
241
263
|
|
|
242
264
|
If `tech_stack.module` is blank or not recognized → set `platform_type = "unknown"` and flag as ⚠️ in the Step 7 recap.
|
|
243
265
|
|
|
244
|
-
These two variables (`active_module`, `platform_type`) are the canonical source for all branching logic in commands that need platform-specific behavior (
|
|
266
|
+
These two variables (`active_module`, `platform_type`) are the canonical source for all branching logic in commands that need platform-specific behavior (dev-gen-test, debug, fix-bug, dev-smoke-test).
|
|
245
267
|
|
|
246
268
|
---
|
|
247
269
|
|
|
@@ -275,7 +297,8 @@ Output exactly this block:
|
|
|
275
297
|
[CTX LOADED]
|
|
276
298
|
Stack : {language} / {framework} / {database}
|
|
277
299
|
Platform : {active_module} ({platform_type})
|
|
278
|
-
Layers : {layer order from CLAUDE.md §2, e.g., Controller → Facade → Service → Repository}
|
|
300
|
+
Layers : {layer order from merged CLAUDE.md §2, e.g., Controller → Facade → Service → Repository}
|
|
301
|
+
CLAUDE.md : {root + {service_root} | {service_root} only | root only | ⚠️ service overlay MISSING — using root | missing}
|
|
279
302
|
Ticket : {ticket_prefix}-
|
|
280
303
|
Dict : {loaded — N canonical terms, M banned terms | missing}
|
|
281
304
|
Entities : {loaded — EntityA, EntityB, EntityC | missing}
|
|
@@ -442,15 +465,22 @@ Suggest the logical next command based on workflow phase:
|
|
|
442
465
|
| /generate-design-spec | Designer review → Figma links confirmed → PO + Designer sign-off → `/generate-bdd {prd-file}` |
|
|
443
466
|
| /generate-bdd | `/review-context {feature-file}` to verify coverage |
|
|
444
467
|
| /review-context (BDD) | `/generate-tech-docs {UC-ID}` if APPROVED; regenerate if NEEDS_FIX |
|
|
468
|
+
| /qc-analyze | `/qc-plan {UC-ID}` (resolve 🔴 blocker gaps first) |
|
|
469
|
+
| /qc-plan | `/qc-design-test {UC-ID}` |
|
|
470
|
+
| /qc-design-test | `/qc-review {UC-ID}` (test-case review) |
|
|
471
|
+
| /qc-review (test-case) | `/qc-run-test {UC-ID}` if APPROVED; fix TCs if NEEDS_FIX |
|
|
472
|
+
| /qc-run-test | `/qc-report {UC-ID}` then `/qc-review {UC-ID}` (script review) |
|
|
473
|
+
| /qc-review (script) | `/qc-report {UC-ID}` then create PR if APPROVED |
|
|
474
|
+
| /qc-report | `/validate-traces {UC-ID}` to refresh Living Docs (qc_status) |
|
|
445
475
|
| /generate-tech-docs | `/review-tech-docs {tech-design-file}` |
|
|
446
476
|
| /review-tech-docs | `/generate-code {feature-file}` if APPROVED; fix doc if NEEDS_FIX |
|
|
447
|
-
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/
|
|
448
|
-
| /
|
|
449
|
-
| /run-
|
|
450
|
-
| /run-
|
|
451
|
-
| /review-code | `/smoke-test {UC-ID}` or create PR |
|
|
452
|
-
| /smoke-test | Create PR and link to ticket |
|
|
453
|
-
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/
|
|
477
|
+
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/dev-gen-test {UC-ID}` |
|
|
478
|
+
| /dev-gen-test | `/dev-run-test {UC-ID}` |
|
|
479
|
+
| /dev-run-test (passing) | `/review-code {UC-ID}` |
|
|
480
|
+
| /dev-run-test (failing) | `/fix-bug {ticket-id}` or `/debug {error}` |
|
|
481
|
+
| /review-code | `/dev-smoke-test {UC-ID}` or create PR |
|
|
482
|
+
| /dev-smoke-test | Create PR and link to ticket |
|
|
483
|
+
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/dev-gen-test {UC-ID}`; all OK → create PR |
|
|
454
484
|
| /fix-bug | Create PR and link to ticket |
|
|
455
485
|
| /debug | `/fix-bug {ticket-id}` if fix needed |
|
|
456
486
|
| /report-bug | Send to dev (`/fix-bug {BUG-ID}`); if coverage gap → `/propose-scenario {UC-ID}` |
|
|
@@ -586,15 +616,22 @@ Suggest the logical next command based on workflow phase:
|
|
|
586
616
|
| /generate-design-spec | Designer review → Figma links confirmed → PO + Designer sign-off → `/generate-bdd {prd-file}` |
|
|
587
617
|
| /generate-bdd | `/review-context {feature-file}` to verify coverage |
|
|
588
618
|
| /review-context (BDD) | `/generate-tech-docs {UC-ID}` if APPROVED; regenerate if NEEDS_FIX |
|
|
619
|
+
| /qc-analyze | `/qc-plan {UC-ID}` (resolve 🔴 blocker gaps first) |
|
|
620
|
+
| /qc-plan | `/qc-design-test {UC-ID}` |
|
|
621
|
+
| /qc-design-test | `/qc-review {UC-ID}` (test-case review) |
|
|
622
|
+
| /qc-review (test-case) | `/qc-run-test {UC-ID}` if APPROVED; fix TCs if NEEDS_FIX |
|
|
623
|
+
| /qc-run-test | `/qc-report {UC-ID}` then `/qc-review {UC-ID}` (script review) |
|
|
624
|
+
| /qc-review (script) | `/qc-report {UC-ID}` then create PR if APPROVED |
|
|
625
|
+
| /qc-report | `/validate-traces {UC-ID}` to refresh Living Docs (qc_status) |
|
|
589
626
|
| /generate-tech-docs | `/review-tech-docs {tech-design-file}` |
|
|
590
627
|
| /review-tech-docs | `/generate-code {feature-file}` if APPROVED; fix doc if NEEDS_FIX |
|
|
591
|
-
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/
|
|
592
|
-
| /
|
|
593
|
-
| /run-
|
|
594
|
-
| /run-
|
|
595
|
-
| /review-code | `/smoke-test {UC-ID}` or create PR |
|
|
596
|
-
| /smoke-test | Create PR and link to ticket |
|
|
597
|
-
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/
|
|
628
|
+
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/dev-gen-test {UC-ID}` |
|
|
629
|
+
| /dev-gen-test | `/dev-run-test {UC-ID}` |
|
|
630
|
+
| /dev-run-test (passing) | `/review-code {UC-ID}` |
|
|
631
|
+
| /dev-run-test (failing) | `/fix-bug {ticket-id}` or `/debug {error}` |
|
|
632
|
+
| /review-code | `/dev-smoke-test {UC-ID}` or create PR |
|
|
633
|
+
| /dev-smoke-test | Create PR and link to ticket |
|
|
634
|
+
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/dev-gen-test {UC-ID}`; all OK → create PR |
|
|
598
635
|
| /fix-bug | Create PR and link to ticket |
|
|
599
636
|
| /debug | `/fix-bug {ticket-id}` if fix needed |
|
|
600
637
|
| /report-bug | Send to dev (`/fix-bug {BUG-ID}`); if coverage gap → `/propose-scenario {UC-ID}` |
|
|
@@ -647,7 +684,7 @@ Gaps:
|
|
|
647
684
|
|
|
648
685
|
Recommendations:
|
|
649
686
|
- /generate-code {UC-ID} SC2
|
|
650
|
-
- /
|
|
687
|
+
- /dev-gen-test {UC-ID}
|
|
651
688
|
- Re-run /generate-code {UC-ID} for drifted scenarios
|
|
652
689
|
```
|
|
653
690
|
|
|
@@ -687,15 +724,22 @@ Suggest the logical next command based on workflow phase:
|
|
|
687
724
|
| /generate-design-spec | Designer review → Figma links confirmed → PO + Designer sign-off → `/generate-bdd {prd-file}` |
|
|
688
725
|
| /generate-bdd | `/review-context {feature-file}` to verify coverage |
|
|
689
726
|
| /review-context (BDD) | `/generate-tech-docs {UC-ID}` if APPROVED; regenerate if NEEDS_FIX |
|
|
727
|
+
| /qc-analyze | `/qc-plan {UC-ID}` (resolve 🔴 blocker gaps first) |
|
|
728
|
+
| /qc-plan | `/qc-design-test {UC-ID}` |
|
|
729
|
+
| /qc-design-test | `/qc-review {UC-ID}` (test-case review) |
|
|
730
|
+
| /qc-review (test-case) | `/qc-run-test {UC-ID}` if APPROVED; fix TCs if NEEDS_FIX |
|
|
731
|
+
| /qc-run-test | `/qc-report {UC-ID}` then `/qc-review {UC-ID}` (script review) |
|
|
732
|
+
| /qc-review (script) | `/qc-report {UC-ID}` then create PR if APPROVED |
|
|
733
|
+
| /qc-report | `/validate-traces {UC-ID}` to refresh Living Docs (qc_status) |
|
|
690
734
|
| /generate-tech-docs | `/review-tech-docs {tech-design-file}` |
|
|
691
735
|
| /review-tech-docs | `/generate-code {feature-file}` if APPROVED; fix doc if NEEDS_FIX |
|
|
692
|
-
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/
|
|
693
|
-
| /
|
|
694
|
-
| /run-
|
|
695
|
-
| /run-
|
|
696
|
-
| /review-code | `/smoke-test {UC-ID}` or create PR |
|
|
697
|
-
| /smoke-test | Create PR and link to ticket |
|
|
698
|
-
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/
|
|
736
|
+
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/dev-gen-test {UC-ID}` |
|
|
737
|
+
| /dev-gen-test | `/dev-run-test {UC-ID}` |
|
|
738
|
+
| /dev-run-test (passing) | `/review-code {UC-ID}` |
|
|
739
|
+
| /dev-run-test (failing) | `/fix-bug {ticket-id}` or `/debug {error}` |
|
|
740
|
+
| /review-code | `/dev-smoke-test {UC-ID}` or create PR |
|
|
741
|
+
| /dev-smoke-test | Create PR and link to ticket |
|
|
742
|
+
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/dev-gen-test {UC-ID}`; all OK → create PR |
|
|
699
743
|
| /fix-bug | Create PR and link to ticket |
|
|
700
744
|
| /debug | `/fix-bug {ticket-id}` if fix needed |
|
|
701
745
|
| /report-bug | Send to dev (`/fix-bug {BUG-ID}`); if coverage gap → `/propose-scenario {UC-ID}` |
|
package/skills/debug/SKILL.tmpl
CHANGED
|
@@ -179,7 +179,7 @@ If `services` section is present:
|
|
|
179
179
|
|
|
180
180
|
**2. Route to service** — if active domain matches a key in `services`:
|
|
181
181
|
- Override `paths.specs_dir` → `services.{domain}.specs_dir`
|
|
182
|
-
- Override `paths.tech_docs_dir` → `services.{domain}.tech_docs_dir`
|
|
182
|
+
- Override `paths.tech_docs_dir` → `services.{domain}.tech_docs_dir` — **only if `setup.spec_source` is NOT set.** When `spec_source` IS set, the tech-design (API contract) is a cross-team artifact and must live in the shared spec repo (handled in step 4), so leave `tech_docs_dir` for step 4 to route — do NOT pin it per-service here.
|
|
183
183
|
- Store `active_service` = `services.{domain}.path`
|
|
184
184
|
- Store `active_service_module` = `services.{domain}.module`
|
|
185
185
|
- If service has its own `module` → use it as `active_module` (overrides `tech_stack.module`)
|
|
@@ -191,7 +191,7 @@ If `services` section is present:
|
|
|
191
191
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
192
192
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
193
193
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
194
|
-
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **
|
|
194
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **always when `spec_source` is set** (step 2 no longer pins tech-docs per-service in this case). The tech-design IS the cross-team API contract: BE authors it here, and FE/App read it from the same spec submodule at `/generate-code --phase=integration`. *(Per-service tech-docs only happen when there is no `spec_source` — a pure multi-service BE repo with no shared spec module.)*
|
|
195
195
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
196
196
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
197
197
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
@@ -222,7 +222,7 @@ When `active_service` has been resolved to a real path in Step 1.5 (e.g., `user-
|
|
|
222
222
|
| `paths.specs_dir` | `{active_service}/{service paths.specs_dir}` (if set in service config, else keep Step 1.5 override) |
|
|
223
223
|
|
|
224
224
|
**3. Store** `service_root = {active_service}` as the working directory anchor for all downstream commands:
|
|
225
|
-
- Shell commands (`/run-
|
|
225
|
+
- Shell commands (`/dev-run-test`, `/dev-gen-test`) run **from within** `service_root`
|
|
226
226
|
- File write operations (test files, trace TSVs) use paths **relative to** `service_root`
|
|
227
227
|
|
|
228
228
|
**4. If service config not found** — keep umbrella defaults, still set `service_root = {active_service}` (path anchor is always needed even without a config override).
|
|
@@ -237,19 +237,41 @@ If the file does not exist → skip silently.
|
|
|
237
237
|
|
|
238
238
|
---
|
|
239
239
|
|
|
240
|
-
## Step 3 — [CRITICAL] Load CLAUDE.md
|
|
240
|
+
## Step 3 — [CRITICAL] Load CLAUDE.md (layered: root + service overlay)
|
|
241
241
|
|
|
242
242
|
*This is the highest-priority context — it defines HOW to write code and documents for this project.*
|
|
243
243
|
|
|
244
|
-
|
|
244
|
+
CLAUDE.md is loaded in **two layers** so umbrella-wide rules and service-specific
|
|
245
|
+
architecture/coding standards compose correctly. The agent always sits at the umbrella
|
|
246
|
+
root, but the implementation code lives in a service submodule with its OWN stack,
|
|
247
|
+
architecture, and conventions — so the service's CLAUDE.md must win for code generation.
|
|
248
|
+
|
|
249
|
+
**Layer 1 — [BASE] Root CLAUDE.md (umbrella-wide).**
|
|
250
|
+
Read `CLAUDE.md` at the repo root. Treat its contents as the **shared baseline** for the
|
|
251
|
+
whole umbrella — git conventions, data-protection posture, cross-cutting rules, and (in
|
|
252
|
+
single-service mode) the project's only architecture + coding standards.
|
|
253
|
+
|
|
254
|
+
**Layer 2 — [OVERLAY] Service CLAUDE.md (umbrella mode only).**
|
|
255
|
+
*Run only if `service_root` was set in Step 1.6 (i.e. a real service was routed to).*
|
|
256
|
+
Read `{service_root}/CLAUDE.md`. This file defines the architecture + coding standards of
|
|
257
|
+
the **actual stack being implemented** (e.g. `user-service` = java-spring, `web` = nextjs).
|
|
258
|
+
Overlay it on top of Layer 1: **on any conflict, the service value WINS** for architecture,
|
|
259
|
+
coding standards, and error handling. Layer-1 values that the service does not redefine
|
|
260
|
+
(e.g. git conventions, banned patterns shared org-wide) remain in effect.
|
|
261
|
+
|
|
262
|
+
From the **merged** result, extract and store:
|
|
245
263
|
|
|
246
264
|
- **§1 Project Overview** → project name, language, framework, build/test commands, domains
|
|
247
|
-
- **§2 Architecture** → layer order (e.g., Controller → Facade → Service → Repository), architectural rules
|
|
248
|
-
- **§3 Coding Standards** → naming conventions (classes, methods), response wrapper type, forbidden patterns
|
|
249
|
-
- **§5 Error Handling** → exception types, HTTP status code mapping, not-found exception class name
|
|
250
|
-
- **§7 Git Conventions** → branch naming pattern, commit message format
|
|
265
|
+
- **§2 Architecture** → layer order (e.g., Controller → Facade → Service → Repository), architectural rules — *service overlay wins*
|
|
266
|
+
- **§3 Coding Standards** → naming conventions (classes, methods), response wrapper type, forbidden patterns — *service overlay wins*
|
|
267
|
+
- **§5 Error Handling** → exception types, HTTP status code mapping, not-found exception class name — *service overlay wins*
|
|
268
|
+
- **§7 Git Conventions** → branch naming pattern, commit message format — *root baseline unless service redefines*
|
|
251
269
|
|
|
252
|
-
|
|
270
|
+
**Resolution rules:**
|
|
271
|
+
- If both layers exist → merge as above; record `claude_md_source = root + {service_root}`.
|
|
272
|
+
- If only the service overlay exists (no root CLAUDE.md) → use the service file alone; `claude_md_source = {service_root}`.
|
|
273
|
+
- If `service_root` is set but `{service_root}/CLAUDE.md` is **missing** → fall back to root CLAUDE.md and flag ⚠️ in the Step 7 recap (the service has no architecture/coding-standards definition — code generation will use umbrella defaults, which may be the wrong stack).
|
|
274
|
+
- If neither exists → note CLAUDE.md as missing and continue with project-context.yaml data only.
|
|
253
275
|
|
|
254
276
|
---
|
|
255
277
|
|
|
@@ -315,7 +337,7 @@ active_module = tech_stack.module (e.g. "java-spring", "react", "flutter")
|
|
|
315
337
|
|
|
316
338
|
If `tech_stack.module` is blank or not recognized → set `platform_type = "unknown"` and flag as ⚠️ in the Step 7 recap.
|
|
317
339
|
|
|
318
|
-
These two variables (`active_module`, `platform_type`) are the canonical source for all branching logic in commands that need platform-specific behavior (
|
|
340
|
+
These two variables (`active_module`, `platform_type`) are the canonical source for all branching logic in commands that need platform-specific behavior (dev-gen-test, debug, fix-bug, dev-smoke-test).
|
|
319
341
|
|
|
320
342
|
---
|
|
321
343
|
|
|
@@ -349,7 +371,8 @@ Output exactly this block:
|
|
|
349
371
|
[CTX LOADED]
|
|
350
372
|
Stack : {language} / {framework} / {database}
|
|
351
373
|
Platform : {active_module} ({platform_type})
|
|
352
|
-
Layers : {layer order from CLAUDE.md §2, e.g., Controller → Facade → Service → Repository}
|
|
374
|
+
Layers : {layer order from merged CLAUDE.md §2, e.g., Controller → Facade → Service → Repository}
|
|
375
|
+
CLAUDE.md : {root + {service_root} | {service_root} only | root only | ⚠️ service overlay MISSING — using root | missing}
|
|
353
376
|
Ticket : {ticket_prefix}-
|
|
354
377
|
Dict : {loaded — N canonical terms, M banned terms | missing}
|
|
355
378
|
Entities : {loaded — EntityA, EntityB, EntityC | missing}
|
|
@@ -471,15 +494,22 @@ Suggest the logical next command based on workflow phase:
|
|
|
471
494
|
| /generate-design-spec | Designer review → Figma links confirmed → PO + Designer sign-off → `/generate-bdd {prd-file}` |
|
|
472
495
|
| /generate-bdd | `/review-context {feature-file}` to verify coverage |
|
|
473
496
|
| /review-context (BDD) | `/generate-tech-docs {UC-ID}` if APPROVED; regenerate if NEEDS_FIX |
|
|
497
|
+
| /qc-analyze | `/qc-plan {UC-ID}` (resolve 🔴 blocker gaps first) |
|
|
498
|
+
| /qc-plan | `/qc-design-test {UC-ID}` |
|
|
499
|
+
| /qc-design-test | `/qc-review {UC-ID}` (test-case review) |
|
|
500
|
+
| /qc-review (test-case) | `/qc-run-test {UC-ID}` if APPROVED; fix TCs if NEEDS_FIX |
|
|
501
|
+
| /qc-run-test | `/qc-report {UC-ID}` then `/qc-review {UC-ID}` (script review) |
|
|
502
|
+
| /qc-review (script) | `/qc-report {UC-ID}` then create PR if APPROVED |
|
|
503
|
+
| /qc-report | `/validate-traces {UC-ID}` to refresh Living Docs (qc_status) |
|
|
474
504
|
| /generate-tech-docs | `/review-tech-docs {tech-design-file}` |
|
|
475
505
|
| /review-tech-docs | `/generate-code {feature-file}` if APPROVED; fix doc if NEEDS_FIX |
|
|
476
|
-
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/
|
|
477
|
-
| /
|
|
478
|
-
| /run-
|
|
479
|
-
| /run-
|
|
480
|
-
| /review-code | `/smoke-test {UC-ID}` or create PR |
|
|
481
|
-
| /smoke-test | Create PR and link to ticket |
|
|
482
|
-
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/
|
|
506
|
+
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/dev-gen-test {UC-ID}` |
|
|
507
|
+
| /dev-gen-test | `/dev-run-test {UC-ID}` |
|
|
508
|
+
| /dev-run-test (passing) | `/review-code {UC-ID}` |
|
|
509
|
+
| /dev-run-test (failing) | `/fix-bug {ticket-id}` or `/debug {error}` |
|
|
510
|
+
| /review-code | `/dev-smoke-test {UC-ID}` or create PR |
|
|
511
|
+
| /dev-smoke-test | Create PR and link to ticket |
|
|
512
|
+
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/dev-gen-test {UC-ID}`; all OK → create PR |
|
|
483
513
|
| /fix-bug | Create PR and link to ticket |
|
|
484
514
|
| /debug | `/fix-bug {ticket-id}` if fix needed |
|
|
485
515
|
| /report-bug | Send to dev (`/fix-bug {BUG-ID}`); if coverage gap → `/propose-scenario {UC-ID}` |
|
|
@@ -84,7 +84,7 @@ If `services` section is present:
|
|
|
84
84
|
|
|
85
85
|
**2. Route to service** — if active domain matches a key in `services`:
|
|
86
86
|
- Override `paths.specs_dir` → `services.{domain}.specs_dir`
|
|
87
|
-
- Override `paths.tech_docs_dir` → `services.{domain}.tech_docs_dir`
|
|
87
|
+
- Override `paths.tech_docs_dir` → `services.{domain}.tech_docs_dir` — **only if `setup.spec_source` is NOT set.** When `spec_source` IS set, the tech-design (API contract) is a cross-team artifact and must live in the shared spec repo (handled in step 4), so leave `tech_docs_dir` for step 4 to route — do NOT pin it per-service here.
|
|
88
88
|
- Store `active_service` = `services.{domain}.path`
|
|
89
89
|
- Store `active_service_module` = `services.{domain}.module`
|
|
90
90
|
- If service has its own `module` → use it as `active_module` (overrides `tech_stack.module`)
|
|
@@ -96,7 +96,7 @@ If `services` section is present:
|
|
|
96
96
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
97
97
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
98
98
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
99
|
-
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **
|
|
99
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **always when `spec_source` is set** (step 2 no longer pins tech-docs per-service in this case). The tech-design IS the cross-team API contract: BE authors it here, and FE/App read it from the same spec submodule at `/generate-code --phase=integration`. *(Per-service tech-docs only happen when there is no `spec_source` — a pure multi-service BE repo with no shared spec module.)*
|
|
100
100
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
101
101
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
102
102
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
@@ -127,7 +127,7 @@ When `active_service` has been resolved to a real path in Step 1.5 (e.g., `user-
|
|
|
127
127
|
| `paths.specs_dir` | `{active_service}/{service paths.specs_dir}` (if set in service config, else keep Step 1.5 override) |
|
|
128
128
|
|
|
129
129
|
**3. Store** `service_root = {active_service}` as the working directory anchor for all downstream commands:
|
|
130
|
-
- Shell commands (`/run-
|
|
130
|
+
- Shell commands (`/dev-run-test`, `/dev-gen-test`) run **from within** `service_root`
|
|
131
131
|
- File write operations (test files, trace TSVs) use paths **relative to** `service_root`
|
|
132
132
|
|
|
133
133
|
**4. If service config not found** — keep umbrella defaults, still set `service_root = {active_service}` (path anchor is always needed even without a config override).
|
|
@@ -142,19 +142,41 @@ If the file does not exist → skip silently.
|
|
|
142
142
|
|
|
143
143
|
---
|
|
144
144
|
|
|
145
|
-
## Step 3 — [CRITICAL] Load CLAUDE.md
|
|
145
|
+
## Step 3 — [CRITICAL] Load CLAUDE.md (layered: root + service overlay)
|
|
146
146
|
|
|
147
147
|
*This is the highest-priority context — it defines HOW to write code and documents for this project.*
|
|
148
148
|
|
|
149
|
-
|
|
149
|
+
CLAUDE.md is loaded in **two layers** so umbrella-wide rules and service-specific
|
|
150
|
+
architecture/coding standards compose correctly. The agent always sits at the umbrella
|
|
151
|
+
root, but the implementation code lives in a service submodule with its OWN stack,
|
|
152
|
+
architecture, and conventions — so the service's CLAUDE.md must win for code generation.
|
|
153
|
+
|
|
154
|
+
**Layer 1 — [BASE] Root CLAUDE.md (umbrella-wide).**
|
|
155
|
+
Read `CLAUDE.md` at the repo root. Treat its contents as the **shared baseline** for the
|
|
156
|
+
whole umbrella — git conventions, data-protection posture, cross-cutting rules, and (in
|
|
157
|
+
single-service mode) the project's only architecture + coding standards.
|
|
158
|
+
|
|
159
|
+
**Layer 2 — [OVERLAY] Service CLAUDE.md (umbrella mode only).**
|
|
160
|
+
*Run only if `service_root` was set in Step 1.6 (i.e. a real service was routed to).*
|
|
161
|
+
Read `{service_root}/CLAUDE.md`. This file defines the architecture + coding standards of
|
|
162
|
+
the **actual stack being implemented** (e.g. `user-service` = java-spring, `web` = nextjs).
|
|
163
|
+
Overlay it on top of Layer 1: **on any conflict, the service value WINS** for architecture,
|
|
164
|
+
coding standards, and error handling. Layer-1 values that the service does not redefine
|
|
165
|
+
(e.g. git conventions, banned patterns shared org-wide) remain in effect.
|
|
166
|
+
|
|
167
|
+
From the **merged** result, extract and store:
|
|
150
168
|
|
|
151
169
|
- **§1 Project Overview** → project name, language, framework, build/test commands, domains
|
|
152
|
-
- **§2 Architecture** → layer order (e.g., Controller → Facade → Service → Repository), architectural rules
|
|
153
|
-
- **§3 Coding Standards** → naming conventions (classes, methods), response wrapper type, forbidden patterns
|
|
154
|
-
- **§5 Error Handling** → exception types, HTTP status code mapping, not-found exception class name
|
|
155
|
-
- **§7 Git Conventions** → branch naming pattern, commit message format
|
|
170
|
+
- **§2 Architecture** → layer order (e.g., Controller → Facade → Service → Repository), architectural rules — *service overlay wins*
|
|
171
|
+
- **§3 Coding Standards** → naming conventions (classes, methods), response wrapper type, forbidden patterns — *service overlay wins*
|
|
172
|
+
- **§5 Error Handling** → exception types, HTTP status code mapping, not-found exception class name — *service overlay wins*
|
|
173
|
+
- **§7 Git Conventions** → branch naming pattern, commit message format — *root baseline unless service redefines*
|
|
156
174
|
|
|
157
|
-
|
|
175
|
+
**Resolution rules:**
|
|
176
|
+
- If both layers exist → merge as above; record `claude_md_source = root + {service_root}`.
|
|
177
|
+
- If only the service overlay exists (no root CLAUDE.md) → use the service file alone; `claude_md_source = {service_root}`.
|
|
178
|
+
- If `service_root` is set but `{service_root}/CLAUDE.md` is **missing** → fall back to root CLAUDE.md and flag ⚠️ in the Step 7 recap (the service has no architecture/coding-standards definition — code generation will use umbrella defaults, which may be the wrong stack).
|
|
179
|
+
- If neither exists → note CLAUDE.md as missing and continue with project-context.yaml data only.
|
|
158
180
|
|
|
159
181
|
---
|
|
160
182
|
|
|
@@ -220,7 +242,7 @@ active_module = tech_stack.module (e.g. "java-spring", "react", "flutter")
|
|
|
220
242
|
|
|
221
243
|
If `tech_stack.module` is blank or not recognized → set `platform_type = "unknown"` and flag as ⚠️ in the Step 7 recap.
|
|
222
244
|
|
|
223
|
-
These two variables (`active_module`, `platform_type`) are the canonical source for all branching logic in commands that need platform-specific behavior (
|
|
245
|
+
These two variables (`active_module`, `platform_type`) are the canonical source for all branching logic in commands that need platform-specific behavior (dev-gen-test, debug, fix-bug, dev-smoke-test).
|
|
224
246
|
|
|
225
247
|
---
|
|
226
248
|
|
|
@@ -254,7 +276,8 @@ Output exactly this block:
|
|
|
254
276
|
[CTX LOADED]
|
|
255
277
|
Stack : {language} / {framework} / {database}
|
|
256
278
|
Platform : {active_module} ({platform_type})
|
|
257
|
-
Layers : {layer order from CLAUDE.md §2, e.g., Controller → Facade → Service → Repository}
|
|
279
|
+
Layers : {layer order from merged CLAUDE.md §2, e.g., Controller → Facade → Service → Repository}
|
|
280
|
+
CLAUDE.md : {root + {service_root} | {service_root} only | root only | ⚠️ service overlay MISSING — using root | missing}
|
|
258
281
|
Ticket : {ticket_prefix}-
|
|
259
282
|
Dict : {loaded — N canonical terms, M banned terms | missing}
|
|
260
283
|
Entities : {loaded — EntityA, EntityB, EntityC | missing}
|
|
@@ -452,15 +475,22 @@ Suggest the logical next command based on workflow phase:
|
|
|
452
475
|
| /generate-design-spec | Designer review → Figma links confirmed → PO + Designer sign-off → `/generate-bdd {prd-file}` |
|
|
453
476
|
| /generate-bdd | `/review-context {feature-file}` to verify coverage |
|
|
454
477
|
| /review-context (BDD) | `/generate-tech-docs {UC-ID}` if APPROVED; regenerate if NEEDS_FIX |
|
|
478
|
+
| /qc-analyze | `/qc-plan {UC-ID}` (resolve 🔴 blocker gaps first) |
|
|
479
|
+
| /qc-plan | `/qc-design-test {UC-ID}` |
|
|
480
|
+
| /qc-design-test | `/qc-review {UC-ID}` (test-case review) |
|
|
481
|
+
| /qc-review (test-case) | `/qc-run-test {UC-ID}` if APPROVED; fix TCs if NEEDS_FIX |
|
|
482
|
+
| /qc-run-test | `/qc-report {UC-ID}` then `/qc-review {UC-ID}` (script review) |
|
|
483
|
+
| /qc-review (script) | `/qc-report {UC-ID}` then create PR if APPROVED |
|
|
484
|
+
| /qc-report | `/validate-traces {UC-ID}` to refresh Living Docs (qc_status) |
|
|
455
485
|
| /generate-tech-docs | `/review-tech-docs {tech-design-file}` |
|
|
456
486
|
| /review-tech-docs | `/generate-code {feature-file}` if APPROVED; fix doc if NEEDS_FIX |
|
|
457
|
-
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/
|
|
458
|
-
| /
|
|
459
|
-
| /run-
|
|
460
|
-
| /run-
|
|
461
|
-
| /review-code | `/smoke-test {UC-ID}` or create PR |
|
|
462
|
-
| /smoke-test | Create PR and link to ticket |
|
|
463
|
-
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/
|
|
487
|
+
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/dev-gen-test {UC-ID}` |
|
|
488
|
+
| /dev-gen-test | `/dev-run-test {UC-ID}` |
|
|
489
|
+
| /dev-run-test (passing) | `/review-code {UC-ID}` |
|
|
490
|
+
| /dev-run-test (failing) | `/fix-bug {ticket-id}` or `/debug {error}` |
|
|
491
|
+
| /review-code | `/dev-smoke-test {UC-ID}` or create PR |
|
|
492
|
+
| /dev-smoke-test | Create PR and link to ticket |
|
|
493
|
+
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/dev-gen-test {UC-ID}`; all OK → create PR |
|
|
464
494
|
| /fix-bug | Create PR and link to ticket |
|
|
465
495
|
| /debug | `/fix-bug {ticket-id}` if fix needed |
|
|
466
496
|
| /report-bug | Send to dev (`/fix-bug {BUG-ID}`); if coverage gap → `/propose-scenario {UC-ID}` |
|
package/skills/prd/SKILL.md
CHANGED
|
@@ -194,15 +194,22 @@ Suggest the logical next command based on workflow phase:
|
|
|
194
194
|
| /generate-design-spec | Designer review → Figma links confirmed → PO + Designer sign-off → `/generate-bdd {prd-file}` |
|
|
195
195
|
| /generate-bdd | `/review-context {feature-file}` to verify coverage |
|
|
196
196
|
| /review-context (BDD) | `/generate-tech-docs {UC-ID}` if APPROVED; regenerate if NEEDS_FIX |
|
|
197
|
+
| /qc-analyze | `/qc-plan {UC-ID}` (resolve 🔴 blocker gaps first) |
|
|
198
|
+
| /qc-plan | `/qc-design-test {UC-ID}` |
|
|
199
|
+
| /qc-design-test | `/qc-review {UC-ID}` (test-case review) |
|
|
200
|
+
| /qc-review (test-case) | `/qc-run-test {UC-ID}` if APPROVED; fix TCs if NEEDS_FIX |
|
|
201
|
+
| /qc-run-test | `/qc-report {UC-ID}` then `/qc-review {UC-ID}` (script review) |
|
|
202
|
+
| /qc-review (script) | `/qc-report {UC-ID}` then create PR if APPROVED |
|
|
203
|
+
| /qc-report | `/validate-traces {UC-ID}` to refresh Living Docs (qc_status) |
|
|
197
204
|
| /generate-tech-docs | `/review-tech-docs {tech-design-file}` |
|
|
198
205
|
| /review-tech-docs | `/generate-code {feature-file}` if APPROVED; fix doc if NEEDS_FIX |
|
|
199
|
-
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/
|
|
200
|
-
| /
|
|
201
|
-
| /run-
|
|
202
|
-
| /run-
|
|
203
|
-
| /review-code | `/smoke-test {UC-ID}` or create PR |
|
|
204
|
-
| /smoke-test | Create PR and link to ticket |
|
|
205
|
-
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/
|
|
206
|
+
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/dev-gen-test {UC-ID}` |
|
|
207
|
+
| /dev-gen-test | `/dev-run-test {UC-ID}` |
|
|
208
|
+
| /dev-run-test (passing) | `/review-code {UC-ID}` |
|
|
209
|
+
| /dev-run-test (failing) | `/fix-bug {ticket-id}` or `/debug {error}` |
|
|
210
|
+
| /review-code | `/dev-smoke-test {UC-ID}` or create PR |
|
|
211
|
+
| /dev-smoke-test | Create PR and link to ticket |
|
|
212
|
+
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/dev-gen-test {UC-ID}`; all OK → create PR |
|
|
206
213
|
| /fix-bug | Create PR and link to ticket |
|
|
207
214
|
| /debug | `/fix-bug {ticket-id}` if fix needed |
|
|
208
215
|
| /report-bug | Send to dev (`/fix-bug {BUG-ID}`); if coverage gap → `/propose-scenario {UC-ID}` |
|
|
@@ -443,15 +450,22 @@ Suggest the logical next command based on workflow phase:
|
|
|
443
450
|
| /generate-design-spec | Designer review → Figma links confirmed → PO + Designer sign-off → `/generate-bdd {prd-file}` |
|
|
444
451
|
| /generate-bdd | `/review-context {feature-file}` to verify coverage |
|
|
445
452
|
| /review-context (BDD) | `/generate-tech-docs {UC-ID}` if APPROVED; regenerate if NEEDS_FIX |
|
|
453
|
+
| /qc-analyze | `/qc-plan {UC-ID}` (resolve 🔴 blocker gaps first) |
|
|
454
|
+
| /qc-plan | `/qc-design-test {UC-ID}` |
|
|
455
|
+
| /qc-design-test | `/qc-review {UC-ID}` (test-case review) |
|
|
456
|
+
| /qc-review (test-case) | `/qc-run-test {UC-ID}` if APPROVED; fix TCs if NEEDS_FIX |
|
|
457
|
+
| /qc-run-test | `/qc-report {UC-ID}` then `/qc-review {UC-ID}` (script review) |
|
|
458
|
+
| /qc-review (script) | `/qc-report {UC-ID}` then create PR if APPROVED |
|
|
459
|
+
| /qc-report | `/validate-traces {UC-ID}` to refresh Living Docs (qc_status) |
|
|
446
460
|
| /generate-tech-docs | `/review-tech-docs {tech-design-file}` |
|
|
447
461
|
| /review-tech-docs | `/generate-code {feature-file}` if APPROVED; fix doc if NEEDS_FIX |
|
|
448
|
-
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/
|
|
449
|
-
| /
|
|
450
|
-
| /run-
|
|
451
|
-
| /run-
|
|
452
|
-
| /review-code | `/smoke-test {UC-ID}` or create PR |
|
|
453
|
-
| /smoke-test | Create PR and link to ticket |
|
|
454
|
-
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/
|
|
462
|
+
| /generate-code | First gen → `/review-code {UC-ID}`; re-gen → `/dev-gen-test {UC-ID}` |
|
|
463
|
+
| /dev-gen-test | `/dev-run-test {UC-ID}` |
|
|
464
|
+
| /dev-run-test (passing) | `/review-code {UC-ID}` |
|
|
465
|
+
| /dev-run-test (failing) | `/fix-bug {ticket-id}` or `/debug {error}` |
|
|
466
|
+
| /review-code | `/dev-smoke-test {UC-ID}` or create PR |
|
|
467
|
+
| /dev-smoke-test | Create PR and link to ticket |
|
|
468
|
+
| /validate-traces | DRIFT/UNTRACKED → `/generate-code {UC-ID}`; GAP → `/dev-gen-test {UC-ID}`; all OK → create PR |
|
|
455
469
|
| /fix-bug | Create PR and link to ticket |
|
|
456
470
|
| /debug | `/fix-bug {ticket-id}` if fix needed |
|
|
457
471
|
| /report-bug | Send to dev (`/fix-bug {BUG-ID}`); if coverage gap → `/propose-scenario {UC-ID}` |
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
---
|
|
2
|
+
version: 1.1
|
|
3
|
+
updated: 2026-06-11
|
|
4
|
+
ported_from: ai-automation-qc-base
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Gap Analysis – <FEATURE>
|
|
8
|
+
|
|
9
|
+
> File ghi lại các **khoảng trống của tài liệu** mà `qa-analyst` phát hiện sau khi
|
|
10
|
+
> phân tích. Là đầu vào để hỏi dev/BA và cho `qa-planner`. Mỗi gap có ID `GAP-xx`
|
|
11
|
+
> để business rule (BR-xx), acceptance criteria (AC-xx) và test case trace ngược về.
|
|
12
|
+
|
|
13
|
+
| Trường | Giá trị |
|
|
14
|
+
|---|---|
|
|
15
|
+
| Feature | `<FEATURE>` |
|
|
16
|
+
| Project / Service | `<project or service name / domain>` |
|
|
17
|
+
| Tài liệu nguồn | `<đường dẫn / link PRD / user story>` |
|
|
18
|
+
| Người phân tích | qa-analyst |
|
|
19
|
+
| Ngày phân tích | `<YYYY-MM-DD>` |
|
|
20
|
+
| Tổng số gap | `<N>` (Blocker: x · High: y · Medium: z · Low: w) |
|
|
21
|
+
| Trạng thái chung | 🔴 Blocked / 🟡 Cần làm rõ / 🟢 Đủ rõ để thiết kế TC |
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
## Bảng Gap
|
|
26
|
+
|
|
27
|
+
| ID | Loại | Mô tả gap | Vị trí (mục/nguồn) | Ảnh hưởng (chức năng / BR / AC) | Mức độ | Người trả lời | Trạng thái | Câu trả lời |
|
|
28
|
+
|---|---|---|---|---|---|---|---|---|
|
|
29
|
+
| GAP-01 | MISSING | … | spec §x | chức năng A / BR-02 | 🔴 Blocker | Dev/BA | Open | — |
|
|
30
|
+
| GAP-02 | AMBIGUOUS | … | mockup màn hình Y | AC-03 | 🟠 High | BA | Open | — |
|
|
31
|
+
| GAP-03 | CONTRADICTORY | … | §2 vs §5 | BR-04 | 🟠 High | BA | Open | — |
|
|
32
|
+
| GAP-04 | ASSUMPTION | … (giả định AI tự đưa, cần xác nhận) | — | chức năng B | 🟡 Medium | Dev | Open | — |
|
|
33
|
+
|
|
34
|
+
### Loại gap
|
|
35
|
+
- **MISSING** – thông tin/chức năng/field/rule chưa được mô tả.
|
|
36
|
+
- **AMBIGUOUS** – mô tả mơ hồ, có ≥ 2 cách hiểu.
|
|
37
|
+
- **CONTRADICTORY** – các phần tài liệu mâu thuẫn nhau.
|
|
38
|
+
- **ASSUMPTION** – giả định do qa-analyst tự suy ra, cần dev/BA xác nhận.
|
|
39
|
+
- **OPEN QUESTION** – câu hỏi mở cần trả lời trước khi thiết kế/triển khai.
|
|
40
|
+
|
|
41
|
+
### Mức độ
|
|
42
|
+
🔴 Blocker (chặn thiết kế TC) · 🟠 High · 🟡 Medium · 🟢 Low
|
|
43
|
+
|
|
44
|
+
---
|
|
45
|
+
|
|
46
|
+
## Quy ước cập nhật
|
|
47
|
+
- `qa-analyst` tạo & điền gap khi phân tích; **không tự bịa câu trả lời** cho gap Blocker.
|
|
48
|
+
- Khi có phản hồi dev/BA: điền cột *Câu trả lời*, đổi *Trạng thái* → `Answered`.
|
|
49
|
+
- Còn gap 🔴 Blocker `Open` ⇒ **chưa** chuyển sang `qa-designer`; đẩy sang `qa-planner`
|
|
50
|
+
(skill `questions-for-dev`) để chốt câu hỏi.
|
|
51
|
+
|
|
52
|
+
---
|
|
53
|
+
|
|
54
|
+
## ⚠️ Checklist bắt buộc trước khi lưu file
|
|
55
|
+
|
|
56
|
+
Trước khi lưu `DOC_GAPS.md`, kiểm tra **từng hàng** trong bảng gap:
|
|
57
|
+
|
|
58
|
+
- [ ] **9 cột đủ** – đúng thứ tự: `ID | Loại | Mô tả gap | Vị trí (mục/nguồn) | Ảnh hưởng (chức năng / BR / AC) | Mức độ | Người trả lời | Trạng thái | Câu trả lời`
|
|
59
|
+
- [ ] **Cột Vị trí không rỗng** – phải có tham chiếu cụ thể đến mục trong tài liệu nguồn (vd `§3 UC4 BR25`, `Appendix B loại 7`, `§4.b Screen 3`). Đây là cột hay bị bỏ thiếu nhất → gây lệch toàn bộ cột sau.
|
|
60
|
+
- [ ] **Cột Ảnh hưởng = BR/AC references** – KHÔNG phải mức độ severity. Ví dụ đúng: `BR25, BR26 / AC-F01-33`. Nếu thấy "Blocker" / "High" ở đây → đang bị lệch cột.
|
|
61
|
+
- [ ] **Cột Mức độ có emoji** – bắt buộc dùng: `🔴 Blocker` / `🟠 High` / `🟡 Medium` / `🟢 Low`. Không được ghi text thuần.
|
|
62
|
+
- [ ] **Cột Người trả lời = vai trò** (PO / BA / Dev / Design / Content / DPO / QC Lead). Nếu thấy "Open" ở đây → đang bị lệch cột.
|
|
63
|
+
- [ ] **Cột Trạng thái = Open / Answered**. Nếu thấy "—" ở đây → đang bị lệch cột.
|