@anhth2/spec-driven-dev-plugin 0.11.0 → 0.12.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 (133) hide show
  1. package/commands/debug.md +5 -0
  2. package/commands/define-product.md +5 -0
  3. package/commands/dev-gen-test.md +5 -0
  4. package/commands/dev-run-test.md +5 -0
  5. package/commands/dev-smoke-test.md +5 -0
  6. package/commands/fix-bug.md +41 -6
  7. package/commands/fix-bug.tmpl +36 -6
  8. package/commands/generate-bdd.md +9 -2
  9. package/commands/generate-bdd.tmpl +4 -2
  10. package/commands/generate-code.md +5 -0
  11. package/commands/generate-design-spec.md +5 -0
  12. package/commands/generate-prd.md +5 -0
  13. package/commands/generate-spec-manifest.md +5 -0
  14. package/commands/generate-tech-docs.md +5 -0
  15. package/commands/learn.md +5 -0
  16. package/commands/propose-scenario.md +36 -11
  17. package/commands/propose-scenario.tmpl +31 -11
  18. package/commands/qc-analyze.md +25 -5
  19. package/commands/qc-analyze.tmpl +20 -5
  20. package/commands/qc-design-test.md +8 -3
  21. package/commands/qc-design-test.tmpl +3 -3
  22. package/commands/qc-plan.md +8 -3
  23. package/commands/qc-plan.tmpl +3 -3
  24. package/commands/qc-report.md +18 -1
  25. package/commands/qc-report.tmpl +13 -1
  26. package/commands/qc-review.md +7 -2
  27. package/commands/qc-review.tmpl +2 -2
  28. package/commands/qc-run-test.md +13 -2
  29. package/commands/qc-run-test.tmpl +8 -2
  30. package/commands/refine-prd.md +5 -0
  31. package/commands/report-bug.md +21 -2
  32. package/commands/report-bug.tmpl +16 -2
  33. package/commands/review-code.md +5 -0
  34. package/commands/review-context.md +5 -0
  35. package/commands/review-tech-docs.md +5 -0
  36. package/commands/sync.md +12 -9
  37. package/commands/sync.tmpl +12 -9
  38. package/commands/validate-traces.md +15 -2
  39. package/commands/validate-traces.tmpl +10 -2
  40. package/core/FRAMEWORK_VERSION +1 -1
  41. package/core/commands/debug.md +5 -0
  42. package/core/commands/define-product.md +5 -0
  43. package/core/commands/dev-gen-test.md +5 -0
  44. package/core/commands/dev-run-test.md +5 -0
  45. package/core/commands/dev-smoke-test.md +5 -0
  46. package/core/commands/fix-bug.md +41 -6
  47. package/core/commands/generate-bdd.md +9 -2
  48. package/core/commands/generate-code.md +5 -0
  49. package/core/commands/generate-design-spec.md +5 -0
  50. package/core/commands/generate-prd.md +5 -0
  51. package/core/commands/generate-spec-manifest.md +5 -0
  52. package/core/commands/generate-tech-docs.md +5 -0
  53. package/core/commands/learn.md +5 -0
  54. package/core/commands/propose-scenario.md +36 -11
  55. package/core/commands/qc-analyze.md +25 -5
  56. package/core/commands/qc-design-test.md +8 -3
  57. package/core/commands/qc-plan.md +8 -3
  58. package/core/commands/qc-report.md +18 -1
  59. package/core/commands/qc-review.md +7 -2
  60. package/core/commands/qc-run-test.md +13 -2
  61. package/core/commands/refine-prd.md +5 -0
  62. package/core/commands/report-bug.md +21 -2
  63. package/core/commands/review-code.md +5 -0
  64. package/core/commands/review-context.md +5 -0
  65. package/core/commands/review-tech-docs.md +5 -0
  66. package/core/commands/sync.md +12 -9
  67. package/core/commands/validate-traces.md +15 -2
  68. package/core/modules/qc-playwright/stack-profile.yaml +3 -3
  69. package/core/skills/code/SKILL.md +5 -0
  70. package/core/skills/debug/SKILL.md +5 -0
  71. package/core/skills/design-spec/SKILL.md +5 -0
  72. package/core/skills/discovery/SKILL.md +5 -0
  73. package/core/skills/qc/qa-analyst/acceptance-criteria.md +5 -1
  74. package/core/skills/qc/qa-analyst/business-rules.md +6 -2
  75. package/core/skills/qc/qa-analyst/data-flow.md +6 -2
  76. package/core/skills/qc/qa-analyst/spec-breakdown.md +7 -3
  77. package/core/skills/qc/qa-designer/e2e/journey.md +1 -1
  78. package/core/skills/qc/qa-designer/exploratory/charter.md +2 -2
  79. package/core/skills/qc/qa-designer/exploratory/explore-to-functional.md +1 -1
  80. package/core/skills/qc/qa-designer/functional/api.md +1 -1
  81. package/core/skills/qc/qa-designer/functional/gui-feature.md +1 -1
  82. package/core/skills/qc/qa-designer/functional/gui-screen.md +1 -1
  83. package/core/skills/qc/qa-designer/integration/api.md +1 -1
  84. package/core/skills/qc/qa-designer/integration/db.md +1 -1
  85. package/core/skills/qc/qa-designer/integration/gui.md +1 -1
  86. package/core/skills/qc/qa-designer/integration/kafka.md +1 -1
  87. package/core/skills/qc/qa-designer/non-functional.md +1 -1
  88. package/core/skills/qc/qa-planner/test-plan.md +4 -4
  89. package/core/skills/qc/qa-runner/exploratory/session.md +2 -2
  90. package/core/skills/test/SKILL.md +10 -0
  91. package/core/steps/context-loader.md +5 -0
  92. package/core/templates/project-context.yaml +19 -1
  93. package/docs/01-getting-started/installation.md +3 -1
  94. package/docs/02-guides/developer/commands.md +1 -1
  95. package/docs/02-guides/developer/workflow.md +2 -0
  96. package/docs/02-guides/qc-automation.md +66 -1
  97. package/docs/02-guides/tester/README.md +2 -0
  98. package/docs/02-guides/tester/bug-reporting.md +1 -1
  99. package/docs/02-guides/tester/workflow.md +4 -3
  100. package/docs/03-concepts/architecture.md +2 -0
  101. package/docs/03-concepts/pipeline.md +19 -6
  102. package/docs/03-concepts/traceability.md +2 -1
  103. package/docs/04-operations/bug-flow.md +45 -4
  104. package/docs/04-operations/sync-and-update.md +38 -1
  105. package/docs/05-reference/commands.md +11 -11
  106. package/docs/05-reference/modules.md +2 -2
  107. package/docs/05-reference/trace-schema.md +18 -12
  108. package/modules/qc-playwright/stack-profile.yaml +3 -3
  109. package/package.json +1 -1
  110. package/skills/code/SKILL.md +5 -0
  111. package/skills/debug/SKILL.md +5 -0
  112. package/skills/design-spec/SKILL.md +5 -0
  113. package/skills/discovery/SKILL.md +5 -0
  114. package/skills/qc/qa-analyst/acceptance-criteria.md +5 -1
  115. package/skills/qc/qa-analyst/business-rules.md +6 -2
  116. package/skills/qc/qa-analyst/data-flow.md +6 -2
  117. package/skills/qc/qa-analyst/spec-breakdown.md +7 -3
  118. package/skills/qc/qa-designer/e2e/journey.md +1 -1
  119. package/skills/qc/qa-designer/exploratory/charter.md +2 -2
  120. package/skills/qc/qa-designer/exploratory/explore-to-functional.md +1 -1
  121. package/skills/qc/qa-designer/functional/api.md +1 -1
  122. package/skills/qc/qa-designer/functional/gui-feature.md +1 -1
  123. package/skills/qc/qa-designer/functional/gui-screen.md +1 -1
  124. package/skills/qc/qa-designer/integration/api.md +1 -1
  125. package/skills/qc/qa-designer/integration/db.md +1 -1
  126. package/skills/qc/qa-designer/integration/gui.md +1 -1
  127. package/skills/qc/qa-designer/integration/kafka.md +1 -1
  128. package/skills/qc/qa-designer/non-functional.md +1 -1
  129. package/skills/qc/qa-planner/test-plan.md +4 -4
  130. package/skills/qc/qa-runner/exploratory/session.md +2 -2
  131. package/skills/test/SKILL.md +10 -0
  132. package/steps/context-loader.md +5 -0
  133. package/templates/project-context.yaml +19 -1
@@ -127,6 +127,8 @@ Read `.agent/project-context.yaml`. Extract and store:
127
127
  - `paths.specs_dir` → BDD specs root
128
128
  - `paths.prd_dir` → PRD documents root
129
129
  - `paths.refinement_dir` → findings/review output dir
130
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
131
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
130
132
  - `paths.product_definitions_dir` → product definitions root
131
133
  - `paths.domain_knowledge_dir` → domain knowledge root
132
134
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -139,6 +141,8 @@ If `paths` section is absent, use these defaults:
139
141
  - `specs_dir` = `specs/bdd`
140
142
  - `prd_dir` = `specs/prd`
141
143
  - `refinement_dir` = `.agent/review`
144
+ - `qc_dir` = `docs`
145
+ - `qc_skills_dir` = `.agent/skills/qc`
142
146
  - `product_definitions_dir` = `specs/product-definition`
143
147
  - `domain_knowledge_dir` = `specs/domain-knowledge`
144
148
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -183,6 +187,7 @@ If `services` section is present:
183
187
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
184
188
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
185
189
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
190
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
186
191
 
187
192
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
188
193
 
@@ -84,7 +84,7 @@ Wait for explicit "Y" or "N" from the user before continuing.
84
84
  - "N" → stop and ask what the user wants to change.
85
85
 
86
86
 
87
- *Note: For this command, the target in Step 1 is a ticket ID (e.g., `PROJ-123`) or bug description from `$ARGUMENTS`. There is no file to resolve proceed to context loading.*
87
+ *Note: For this command, the target in Step 1 is a ticket ID (e.g., `PROJ-123`), a **filed bug `{BUG-ID}`** (a `{paths.bug_reports_dir}/{BUG-ID}.md` from `/report-bug` — e.g. a QC product-gap), or a bug description from `$ARGUMENTS`. If a `{BUG-ID}` is given, resolve & read that report for spec context; otherwise proceed to context loading.*
88
88
 
89
89
  ## Context
90
90
  # Context Loader — Load All Project Context
@@ -125,6 +125,8 @@ Read `.agent/project-context.yaml`. Extract and store:
125
125
  - `paths.specs_dir` → BDD specs root
126
126
  - `paths.prd_dir` → PRD documents root
127
127
  - `paths.refinement_dir` → findings/review output dir
128
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
129
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
128
130
  - `paths.product_definitions_dir` → product definitions root
129
131
  - `paths.domain_knowledge_dir` → domain knowledge root
130
132
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -137,6 +139,8 @@ If `paths` section is absent, use these defaults:
137
139
  - `specs_dir` = `specs/bdd`
138
140
  - `prd_dir` = `specs/prd`
139
141
  - `refinement_dir` = `.agent/review`
142
+ - `qc_dir` = `docs`
143
+ - `qc_skills_dir` = `.agent/skills/qc`
140
144
  - `product_definitions_dir` = `specs/product-definition`
141
145
  - `domain_knowledge_dir` = `specs/domain-knowledge`
142
146
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -181,6 +185,7 @@ If `services` section is present:
181
185
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
182
186
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
183
187
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
188
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
184
189
 
185
190
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
186
191
 
@@ -387,8 +392,9 @@ Proceed to the next step of the calling command.
387
392
  ---
388
393
 
389
394
  ## Phase 1 — Gather Info
395
+ If a `{BUG-ID}` was given: read `{paths.bug_reports_dir}/{BUG-ID}.md` for the spec context, AC violated, expected-vs-actual, and the suggested layer — use it as the bug details (no need to re-ask).
390
396
  If ticket: fetch details (or ask user to paste).
391
- If no ticket — CHECKPOINT:
397
+ If no ticket / BUG-ID — CHECKPOINT:
392
398
  1. Where does the bug occur? (module, endpoint, flow)
393
399
  2. Steps to reproduce?
394
400
  3. Expected vs Actual?
@@ -461,7 +467,11 @@ Proceed? (Y/N)
461
467
  ```
462
468
 
463
469
  ## Phase 3 — Fix
470
+
471
+ *Umbrella mode: the buggy code lives in the **service submodule** resolved at context-loader Step 1.6 — create the branch and run every git/build step from **inside** `{service_root}`. Single-service: omit the `cd`.*
472
+
464
473
  ```bash
474
+ cd {service_root} # umbrella: the service submodule; single-service: omit
465
475
  git checkout -b fix/{TICKET_ID}-{description}
466
476
  ```
467
477
  Apply fix. Add trace annotation if file has `@trace.implements`:
@@ -478,13 +488,37 @@ Test: "Regression {TICKET_ID}: {bug description}"
478
488
  ```
479
489
  Run test. If fail → debug and fix (max 3 iterations).
480
490
 
481
- ## Phase 5 — Build & Commit
491
+ ## Phase 5 — Build & Commit (2-layer push in umbrella mode)
482
492
  ```bash
483
- {conventions.build_command} # max 3 retries
493
+ {conventions.build_command} # max 3 retries — runs inside {service_root} in umbrella mode
494
+ # Tầng 1 — push the fix branch in the service submodule (where the code lives):
484
495
  git add {files}
485
496
  git commit -m "fix({TICKET_ID}): {description}"
486
- git push -u origin fix/{TICKET_ID}-{slug}
497
+ git push -u origin fix/{TICKET_ID}-{slug} # then open a PR into the service's tracked branch
487
498
  ```
499
+ > **Umbrella mode — Tầng 2 (bump umbrella pointer):** the umbrella records a *commit* of the service
500
+ > submodule, not a branch. After the fix-branch PR **merges** into the service's tracked branch, bump
501
+ > the pointer so teammates pulling the umbrella don't hit "commit not found":
502
+ > ```bash
503
+ > cd - # back to umbrella root
504
+ > git add {service_root} && git commit -m "chore: bump {service_root} pointer (fix {TICKET_ID})"
505
+ > git push
506
+ > ```
507
+ > Single-service mode: no umbrella pointer — Tầng 1 is the whole push. Full rule: Sync & Update §4.4 (commit 2 tầng).
508
+
509
+ ## Phase 5.5 — Close the bug report (if fixing a filed `{BUG-ID}`)
510
+
511
+ *Skip if the target was a plain ticket/description (no `{BUG-ID}` file).*
512
+
513
+ After the fix is committed, update `{paths.bug_reports_dir}/{BUG-ID}.md`:
514
+ - Set `State` → `🟡 Fixed` and append a short **Resolution** (root cause + commit/PR link).
515
+ - It is **not** `Closed` yet — QC owns verification: when `/qc-run-test` re-runs and `qc_status`
516
+ for the linked SC flips to `pass`, it becomes `🟢 Closed` (and `qc_owner`/`qc_blocked_by` clear).
517
+ - Commit the updated report to the spec repo (same 2-layer push as `/report-bug`) so the PO/PM
518
+ "waiting-on" view reflects it on `/sync`.
519
+
520
+ This is the only write `/fix-bug` makes to the feedback area — it still fixes **code** only,
521
+ never edits PRD/BDD (spec changes are PO/Dev per BUG_FLOW Case 2–4).
488
522
 
489
523
  ## Phase 6 — Offer to Record a Lesson (optional)
490
524
 
@@ -657,7 +691,8 @@ Next : {suggested command with example arguments}
657
691
  Root Cause: {analysis}
658
692
  Changes: {list}
659
693
  ✅ Regression test added | ✅ Build: SUCCESS
694
+ {🐞 BUG-{id} → State: Fixed (pushed) — Closed after /qc-run-test re-verify pass | if fixing a filed bug}
660
695
  {📝 Lesson L-NNN recorded (if captured)}
661
696
  Branch: fix/{TICKET_ID}-{slug}
662
- Next: Create PR and link to ticket.
697
+ Next: Create PR and link to ticket. {QC: re-run /qc-run-test {UC-ID} to verify + close the bug | if applicable}
663
698
  ```
@@ -123,6 +123,8 @@ Read `.agent/project-context.yaml`. Extract and store:
123
123
  - `paths.specs_dir` → BDD specs root
124
124
  - `paths.prd_dir` → PRD documents root
125
125
  - `paths.refinement_dir` → findings/review output dir
126
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
127
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
126
128
  - `paths.product_definitions_dir` → product definitions root
127
129
  - `paths.domain_knowledge_dir` → domain knowledge root
128
130
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -135,6 +137,8 @@ If `paths` section is absent, use these defaults:
135
137
  - `specs_dir` = `specs/bdd`
136
138
  - `prd_dir` = `specs/prd`
137
139
  - `refinement_dir` = `.agent/review`
140
+ - `qc_dir` = `docs`
141
+ - `qc_skills_dir` = `.agent/skills/qc`
138
142
  - `product_definitions_dir` = `specs/product-definition`
139
143
  - `domain_knowledge_dir` = `specs/domain-knowledge`
140
144
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -179,6 +183,7 @@ If `services` section is present:
179
183
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
180
184
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
181
185
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
186
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
182
187
 
183
188
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
184
189
 
@@ -834,7 +839,7 @@ After generating all `.feature` files, create or update `{paths.trace_dir}/{UC-I
834
839
 
835
840
  **TSV columns (tab-separated, one header row + one data row per scenario):**
836
841
  ```
837
- sc_id\tsc_title\tspec_ver\tgen_ver\timplemented_by\ttest_count\ttest_classes\tdev_selftest\tdev_selftest_at\tqc_status\tqc_run_at\tprd_version\tbdd_version\ttech_doc_revision\tprd_status\tuc_status\tfe_phase\tstatus\tlast_updated
842
+ sc_id\tsc_title\tspec_ver\tgen_ver\timplemented_by\ttest_count\ttest_classes\tdev_selftest\tdev_selftest_at\tqc_status\tqc_run_at\tqc_owner\tqc_blocked_by\tprd_version\tbdd_version\ttech_doc_revision\tprd_status\tuc_status\tfe_phase\tstatus\tlast_updated
838
843
  ```
839
844
 
840
845
  **Rules:**
@@ -842,7 +847,7 @@ sc_id\tsc_title\tspec_ver\tgen_ver\timplemented_by\ttest_count\ttest_classes\tde
842
847
  - If file exists (re-generation) → for each SC in the new `.feature`:
843
848
  - SC already in `.tsv` AND `spec_ver` is unchanged → update only: `sc_title`, `prd_version`, `bdd_version`, `prd_status`, `uc_status`, `last_updated`. Leave all other columns unchanged.
844
849
  - SC already in `.tsv` AND `spec_ver` changed (scenario was modified) → update: `sc_title`, `spec_ver`, `prd_version`, `bdd_version`, `prd_status`, `uc_status`, `last_updated` AND set `status = DRIFT` immediately (so the TSV reflects drift without waiting for `/validate-traces`). Leave `gen_ver`, `implemented_by`, `test_count`, `test_classes`, `tech_doc_revision` unchanged.
845
- - SC is new (added in this re-gen) → append new row with `gen_ver`, `implemented_by`, `test_count`, `test_classes`, `dev_selftest`, `dev_selftest_at`, `qc_status`, `qc_run_at`, `tech_doc_revision` all set to `—`.
850
+ - SC is new (added in this re-gen) → append new row with `gen_ver`, `implemented_by`, `test_count`, `test_classes`, `dev_selftest`, `dev_selftest_at`, `qc_status`, `qc_run_at`, `qc_owner`, `qc_blocked_by`, `tech_doc_revision` all set to `—`.
846
851
  - SC no longer in `.feature` (removed) → delete its row.
847
852
 
848
853
  **Values to write for each scenario:**
@@ -860,6 +865,8 @@ sc_id\tsc_title\tspec_ver\tgen_ver\timplemented_by\ttest_count\ttest_classes\tde
860
865
  | `dev_selftest_at` | `—` |
861
866
  | `qc_status` | `—` (official QC automation result — set by `/qc-run-test`) |
862
867
  | `qc_run_at` | `—` |
868
+ | `qc_owner` | `—` (who a non-passing SC waits on: `dev` / `po` — set by `/qc-run-test` + `/report-bug`) |
869
+ | `qc_blocked_by` | `—` (linked `BUG-{id}` / `GAP-{id}` — set by `/qc-run-test` + `/report-bug`) |
863
870
  | `prd_version` | `@trace.prd_version` from `.feature` header |
864
871
  | `bdd_version` | `@trace.bdd_version` from `.feature` header |
865
872
  | `tech_doc_revision` | `—` |
@@ -125,6 +125,8 @@ Read `.agent/project-context.yaml`. Extract and store:
125
125
  - `paths.specs_dir` → BDD specs root
126
126
  - `paths.prd_dir` → PRD documents root
127
127
  - `paths.refinement_dir` → findings/review output dir
128
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
129
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
128
130
  - `paths.product_definitions_dir` → product definitions root
129
131
  - `paths.domain_knowledge_dir` → domain knowledge root
130
132
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -137,6 +139,8 @@ If `paths` section is absent, use these defaults:
137
139
  - `specs_dir` = `specs/bdd`
138
140
  - `prd_dir` = `specs/prd`
139
141
  - `refinement_dir` = `.agent/review`
142
+ - `qc_dir` = `docs`
143
+ - `qc_skills_dir` = `.agent/skills/qc`
140
144
  - `product_definitions_dir` = `specs/product-definition`
141
145
  - `domain_knowledge_dir` = `specs/domain-knowledge`
142
146
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -181,6 +185,7 @@ If `services` section is present:
181
185
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
182
186
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
183
187
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
188
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
184
189
 
185
190
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
186
191
 
@@ -125,6 +125,8 @@ Read `.agent/project-context.yaml`. Extract and store:
125
125
  - `paths.specs_dir` → BDD specs root
126
126
  - `paths.prd_dir` → PRD documents root
127
127
  - `paths.refinement_dir` → findings/review output dir
128
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
129
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
128
130
  - `paths.product_definitions_dir` → product definitions root
129
131
  - `paths.domain_knowledge_dir` → domain knowledge root
130
132
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -137,6 +139,8 @@ If `paths` section is absent, use these defaults:
137
139
  - `specs_dir` = `specs/bdd`
138
140
  - `prd_dir` = `specs/prd`
139
141
  - `refinement_dir` = `.agent/review`
142
+ - `qc_dir` = `docs`
143
+ - `qc_skills_dir` = `.agent/skills/qc`
140
144
  - `product_definitions_dir` = `specs/product-definition`
141
145
  - `domain_knowledge_dir` = `specs/domain-knowledge`
142
146
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -181,6 +185,7 @@ If `services` section is present:
181
185
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
182
186
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
183
187
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
188
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
184
189
 
185
190
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
186
191
 
@@ -125,6 +125,8 @@ Read `.agent/project-context.yaml`. Extract and store:
125
125
  - `paths.specs_dir` → BDD specs root
126
126
  - `paths.prd_dir` → PRD documents root
127
127
  - `paths.refinement_dir` → findings/review output dir
128
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
129
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
128
130
  - `paths.product_definitions_dir` → product definitions root
129
131
  - `paths.domain_knowledge_dir` → domain knowledge root
130
132
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -137,6 +139,8 @@ If `paths` section is absent, use these defaults:
137
139
  - `specs_dir` = `specs/bdd`
138
140
  - `prd_dir` = `specs/prd`
139
141
  - `refinement_dir` = `.agent/review`
142
+ - `qc_dir` = `docs`
143
+ - `qc_skills_dir` = `.agent/skills/qc`
140
144
  - `product_definitions_dir` = `specs/product-definition`
141
145
  - `domain_knowledge_dir` = `specs/domain-knowledge`
142
146
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -181,6 +185,7 @@ If `services` section is present:
181
185
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
182
186
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
183
187
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
188
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
184
189
 
185
190
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
186
191
 
@@ -130,6 +130,8 @@ Read `.agent/project-context.yaml`. Extract and store:
130
130
  - `paths.specs_dir` → BDD specs root
131
131
  - `paths.prd_dir` → PRD documents root
132
132
  - `paths.refinement_dir` → findings/review output dir
133
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
134
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
133
135
  - `paths.product_definitions_dir` → product definitions root
134
136
  - `paths.domain_knowledge_dir` → domain knowledge root
135
137
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -142,6 +144,8 @@ If `paths` section is absent, use these defaults:
142
144
  - `specs_dir` = `specs/bdd`
143
145
  - `prd_dir` = `specs/prd`
144
146
  - `refinement_dir` = `.agent/review`
147
+ - `qc_dir` = `docs`
148
+ - `qc_skills_dir` = `.agent/skills/qc`
145
149
  - `product_definitions_dir` = `specs/product-definition`
146
150
  - `domain_knowledge_dir` = `specs/domain-knowledge`
147
151
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -186,6 +190,7 @@ If `services` section is present:
186
190
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
187
191
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
188
192
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
193
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
189
194
 
190
195
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
191
196
 
@@ -146,6 +146,8 @@ Read `.agent/project-context.yaml`. Extract and store:
146
146
  - `paths.specs_dir` → BDD specs root
147
147
  - `paths.prd_dir` → PRD documents root
148
148
  - `paths.refinement_dir` → findings/review output dir
149
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
150
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
149
151
  - `paths.product_definitions_dir` → product definitions root
150
152
  - `paths.domain_knowledge_dir` → domain knowledge root
151
153
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -158,6 +160,8 @@ If `paths` section is absent, use these defaults:
158
160
  - `specs_dir` = `specs/bdd`
159
161
  - `prd_dir` = `specs/prd`
160
162
  - `refinement_dir` = `.agent/review`
163
+ - `qc_dir` = `docs`
164
+ - `qc_skills_dir` = `.agent/skills/qc`
161
165
  - `product_definitions_dir` = `specs/product-definition`
162
166
  - `domain_knowledge_dir` = `specs/domain-knowledge`
163
167
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -202,6 +206,7 @@ If `services` section is present:
202
206
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
203
207
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
204
208
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
209
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
205
210
 
206
211
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
207
212
 
@@ -134,6 +134,8 @@ Read `.agent/project-context.yaml`. Extract and store:
134
134
  - `paths.specs_dir` → BDD specs root
135
135
  - `paths.prd_dir` → PRD documents root
136
136
  - `paths.refinement_dir` → findings/review output dir
137
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
138
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
137
139
  - `paths.product_definitions_dir` → product definitions root
138
140
  - `paths.domain_knowledge_dir` → domain knowledge root
139
141
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -146,6 +148,8 @@ If `paths` section is absent, use these defaults:
146
148
  - `specs_dir` = `specs/bdd`
147
149
  - `prd_dir` = `specs/prd`
148
150
  - `refinement_dir` = `.agent/review`
151
+ - `qc_dir` = `docs`
152
+ - `qc_skills_dir` = `.agent/skills/qc`
149
153
  - `product_definitions_dir` = `specs/product-definition`
150
154
  - `domain_knowledge_dir` = `specs/domain-knowledge`
151
155
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -190,6 +194,7 @@ If `services` section is present:
190
194
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
191
195
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
192
196
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
197
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
193
198
 
194
199
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
195
200
 
@@ -1,7 +1,8 @@
1
- # /propose-scenario — Propose a New BDD Scenario (Tester-Facing)
1
+ # /propose-scenario — Propose a New BDD Scenario (Tester & QC-Facing)
2
2
 
3
- For **testers** who discover an edge case not covered by existing BDD. Drafts a Gherkin scenario
4
- into a **proposals area** for PO/Dev to review and promote.
3
+ For **testers and QC** who discover an edge case not covered by existing BDD (e.g. a `DOC_GAPS`
4
+ missing-coverage gap from `/qc-analyze`). Drafts a Gherkin scenario into a **proposals area** for
5
+ PO/Dev to review and promote.
5
6
 
6
7
  **Does NOT edit the canonical `.feature` file.** BDD is owned by PO/Dev — this command only writes
7
8
  a proposal. Promotion into the real BDD is a PO/Dev action.
@@ -134,6 +135,8 @@ Read `.agent/project-context.yaml`. Extract and store:
134
135
  - `paths.specs_dir` → BDD specs root
135
136
  - `paths.prd_dir` → PRD documents root
136
137
  - `paths.refinement_dir` → findings/review output dir
138
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
139
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
137
140
  - `paths.product_definitions_dir` → product definitions root
138
141
  - `paths.domain_knowledge_dir` → domain knowledge root
139
142
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -146,6 +149,8 @@ If `paths` section is absent, use these defaults:
146
149
  - `specs_dir` = `specs/bdd`
147
150
  - `prd_dir` = `specs/prd`
148
151
  - `refinement_dir` = `.agent/review`
152
+ - `qc_dir` = `docs`
153
+ - `qc_skills_dir` = `.agent/skills/qc`
149
154
  - `product_definitions_dir` = `specs/product-definition`
150
155
  - `domain_knowledge_dir` = `specs/domain-knowledge`
151
156
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -190,6 +195,7 @@ If `services` section is present:
190
195
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
191
196
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
192
197
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
198
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
193
199
 
194
200
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
195
201
 
@@ -410,15 +416,28 @@ A BDD scenario must trace to a PRD acceptance criterion. Determine which case ap
410
416
  → This is a coverage gap. Proceed to draft the scenario (Step 3), mapped to that AC.
411
417
 
412
418
  **Case B — behavior is NOT in any AC** (genuinely new requirement):
413
- STOP. A scenario here would have nothing to trace to. Do **not** draft it as a BDD proposal.
414
- Instead output a **PRD change request** for the PO:
419
+ Do **not** draft a BDD proposal (a scenario would have nothing to trace to). Instead **write a
420
+ PRD change request file** so the PO actually sees it on `/sync` (do not just print it):
421
+
422
+ Write to `{paths.prd_change_requests_dir}/{UC-ID}-{slug}.md` (resolved to
423
+ `{spec_source}/feedback/prd-change-requests/` in umbrella mode; create dir if needed):
415
424
  ```
416
- ⚠️ Not covered by any PRD AC this is a new requirement, not a coverage gap.
417
- Route to PO: add/extend an AC in {prd_path}, then re-run /generate-bdd.
418
- Requested behavior: {description}
419
- Suggested AC: "{draft AC text}"
425
+ # PRD Change Request{UC-ID}: {short title}
426
+
427
+ > ⚠️ New requirement found in test — NOT covered by any PRD AC (not a coverage gap).
428
+ | Field | Value |
429
+ |---|---|
430
+ | UC / Ticket | {UC-ID} |
431
+ | PRD | {prd_path} (v{prd_version}) |
432
+ | Source | {BUG-ID if any | tester/QC observation} |
433
+ | Requested by | tester/QC |
434
+ | Status | Open |
435
+
436
+ **Requested behavior:** {description}
437
+ **Suggested AC (draft for PO):** "{draft AC text}"
438
+ **Route to PO:** add/extend an AC in {prd_path} → `/refine-prd` → re-run `/generate-bdd` → dev `/generate-code`.
420
439
  ```
421
- Then end (no proposal file written for BDD).
440
+ Then go to Step 5 (handoff applies to this file too). Skip Step 3–4 (no BDD scenario for Case B).
422
441
 
423
442
  If unsure which case → show the AC list and ask the tester which AC this maps to, or confirm it's new.
424
443
 
@@ -447,7 +466,13 @@ git push # → PO/Dev see it on their next /sync
447
466
  ```
448
467
 
449
468
  - No push rights to the spec repo → open a PR / MR instead. Print this fallback.
450
- - For a **PRD change request** (Case B), the same handoff applies — commit the request doc so the PO sees it.
469
+ - For a **PRD change request** (Case B), commit the request file instead:
470
+ ```bash
471
+ cd {spec_source}
472
+ git add feedback/prd-change-requests/{UC-ID}-{slug}.md
473
+ git commit -m "qa(prd-change): {UC-ID} — {title}"
474
+ git push
475
+ ```
451
476
 
452
477
  > PO/Dev are notified through their normal routine: `/sync` lists newly-pulled proposals.
453
478
 
@@ -133,6 +133,8 @@ Read `.agent/project-context.yaml`. Extract and store:
133
133
  - `paths.specs_dir` → BDD specs root
134
134
  - `paths.prd_dir` → PRD documents root
135
135
  - `paths.refinement_dir` → findings/review output dir
136
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
137
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
136
138
  - `paths.product_definitions_dir` → product definitions root
137
139
  - `paths.domain_knowledge_dir` → domain knowledge root
138
140
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -145,6 +147,8 @@ If `paths` section is absent, use these defaults:
145
147
  - `specs_dir` = `specs/bdd`
146
148
  - `prd_dir` = `specs/prd`
147
149
  - `refinement_dir` = `.agent/review`
150
+ - `qc_dir` = `docs`
151
+ - `qc_skills_dir` = `.agent/skills/qc`
148
152
  - `product_definitions_dir` = `specs/product-definition`
149
153
  - `domain_knowledge_dir` = `specs/domain-knowledge`
150
154
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -189,6 +193,7 @@ If `services` section is present:
189
193
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
190
194
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
191
195
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
196
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
192
197
 
193
198
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
194
199
 
@@ -405,7 +410,7 @@ Boundary vs `/qc-plan`: you answer *"what is the requirement?"*; qc-plan answers
405
410
  the risk, what to ask dev?"*. When something is ambiguous/missing, record it as a gap and
406
411
  hand off to qc-plan — never invent an answer.
407
412
 
408
- ## Skills (`skills/qc/qa-analyst/`)
413
+ ## Skills (`{paths.qc_skills_dir}/qa-analyst/`)
409
414
 
410
415
  Load only the file for the step you are doing (each is self-contained):
411
416
  - `spec-breakdown.md` — break a spec/PRD/user story into structure.
@@ -424,15 +429,29 @@ tests with `@trace.verifies` and write `qc_status` per scenario.
424
429
 
425
430
  ## DOC_GAPS (mandatory)
426
431
 
427
- Always produce a gaps file following `skills/qc/qa-analyst/DOC_GAPS.template.md`:
432
+ Always produce a gaps file following `{paths.qc_skills_dir}/qa-analyst/DOC_GAPS.template.md`:
428
433
  - Each gap `GAP-xx`, classified MISSING / AMBIGUOUS / CONTRADICTORY / ASSUMPTION / OPEN QUESTION, with severity (🔴 Blocker → 🟢 Low) and the affected function/BR/AC.
429
434
  - Never fabricate answers; mark assumptions as `ASSUMPTION` for PO/dev to confirm.
430
435
  - Any `🔴 Blocker` still `Open` ⇒ the UC is not ready for qc-design-test — hand off to qc-plan.
436
+ - **Push genuine SPEC defects to the PO (not just keep them local).** A blocker that is a real
437
+ flaw in the official spec — `AMBIGUOUS` / `CONTRADICTORY` / `MISSING` in PRD/BDD — must reach
438
+ the PO via the feedback flow, not sit only in `DOC_GAPS.md`: file `/report-bug {UC-ID} {desc}`
439
+ (its BUG_FLOW classifies PRD vs BDD), or `/propose-scenario {UC-ID}` if the gap is missing test
440
+ coverage. `ASSUMPTION` / `OPEN QUESTION` gaps are confirmed via qc-plan's questions-for-dev — not filed as bugs.
431
441
 
432
442
  ## Output
433
443
 
434
- Write the analysis artifacts under `{paths.refinement_dir}/qc/{UC-ID}/` (requirement
435
- breakdown, BR table, data-flow, AC list with SC mapping, and `DOC_GAPS.md`).
444
+ Write **exactly TWO files** under `{paths.qc_dir}/{UC-ID}/` — do **not** split the analysis
445
+ into one-file-per-step (no separate spec-breakdown / business-rules / data-flow / AC files):
446
+
447
+ 1. **`{paths.qc_dir}/{UC-ID}/REQUIREMENT_ANALYSIS.md`** — the single consolidated analysis.
448
+ Sections in order: requirement breakdown → business-rule table (`BR-xx`) → data-flow →
449
+ acceptance-criteria (`AC-xx`), each `BR`/`AC` mapped to its owning `{UC-ID}-SC{N}`.
450
+ 2. **`{paths.qc_dir}/{UC-ID}/DOC_GAPS.md`** — the gaps file (per `{paths.qc_skills_dir}/qa-analyst/DOC_GAPS.template.md`).
451
+
452
+ `{paths.qc_dir}` is a VISIBLE top-level folder in the QC repo (default `docs/`, **not** the
453
+ hidden `.agent/review/`) so the QC team can open and process the output easily. The official
454
+ spec stays in the PO spec submodule — do not write analysis there.
436
455
 
437
456
  ## Report
438
457
 
@@ -507,7 +526,8 @@ Next : {suggested command with example arguments}
507
526
 
508
527
  ```
509
528
  /qc-analyze Complete — {UC-ID}
510
- Gaps: {N} ({blockers} blocker)
529
+ Files: {paths.qc_dir}/{UC-ID}/REQUIREMENT_ANALYSIS.md + DOC_GAPS.md (2 files)
530
+ Gaps: {N} ({blockers} blocker) ← spec-defect blocker? → /report-bug {UC-ID} | coverage gap → /propose-scenario {UC-ID}
511
531
  SC mapping: {M} BR/AC mapped to {K} scenarios
512
532
  Next: /qc-plan {UC-ID} ← risk / what-if / questions-for-dev
513
533
  (resolve 🔴 Blocker gaps with PO/Dev first)
@@ -92,7 +92,7 @@ Wait for explicit "Y" or "N" from the user before continuing.
92
92
  - "N" → stop and ask what the user wants to change.
93
93
 
94
94
 
95
- *Note: For this command, the target in Step 1 is a UC-ID. Read the qc-analyze + qc-plan outputs from `{paths.refinement_dir}/qc/{UC-ID}/` and the official `.feature` (with `@trace.scenario` per scenario).*
95
+ *Note: For this command, the target in Step 1 is a UC-ID. Read the qc-analyze + qc-plan outputs (`REQUIREMENT_ANALYSIS.md`, `DOC_GAPS.md`, `TEST_PLAN.md`) from `{paths.qc_dir}/{UC-ID}/` and the official `.feature` (with `@trace.scenario` per scenario).*
96
96
 
97
97
  ## Context
98
98
  # Context Loader — Load All Project Context
@@ -133,6 +133,8 @@ Read `.agent/project-context.yaml`. Extract and store:
133
133
  - `paths.specs_dir` → BDD specs root
134
134
  - `paths.prd_dir` → PRD documents root
135
135
  - `paths.refinement_dir` → findings/review output dir
136
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
137
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
136
138
  - `paths.product_definitions_dir` → product definitions root
137
139
  - `paths.domain_knowledge_dir` → domain knowledge root
138
140
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -145,6 +147,8 @@ If `paths` section is absent, use these defaults:
145
147
  - `specs_dir` = `specs/bdd`
146
148
  - `prd_dir` = `specs/prd`
147
149
  - `refinement_dir` = `.agent/review`
150
+ - `qc_dir` = `docs`
151
+ - `qc_skills_dir` = `.agent/skills/qc`
148
152
  - `product_definitions_dir` = `specs/product-definition`
149
153
  - `domain_knowledge_dir` = `specs/domain-knowledge`
150
154
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -189,6 +193,7 @@ If `services` section is present:
189
193
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
190
194
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
191
195
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
196
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
192
197
 
193
198
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
194
199
 
@@ -400,7 +405,7 @@ You are the **QC Designer** — stage 3. Produce/maintain test-case Markdown fil
400
405
  (`.Test.md`) from the analyzed requirement + plan. Output feeds qc-run-test (Python) and
401
406
  qc-review. You do **not** write Python.
402
407
 
403
- ## Skills — pick the layer, load ONE file (`skills/qc/qa-designer/`)
408
+ ## Skills — pick the layer, load ONE file (`{paths.qc_skills_dir}/qa-designer/`)
404
409
 
405
410
  | Layer | File |
406
411
  |---|---|
@@ -429,7 +434,7 @@ qc-run-test write `qc_status` per scenario.
429
434
 
430
435
  ## Output
431
436
 
432
- Write `.Test.md` files under `{paths.refinement_dir}/qc/{UC-ID}/test-cases/`.
437
+ Write `.Test.md` files under `{paths.qc_dir}/{UC-ID}/test-cases/`.
433
438
 
434
439
  ## Report
435
440
 
@@ -92,7 +92,7 @@ Wait for explicit "Y" or "N" from the user before continuing.
92
92
  - "N" → stop and ask what the user wants to change.
93
93
 
94
94
 
95
- *Note: For this command, the target in Step 1 is a UC-ID. Read the qc-analyze output (requirement breakdown + `DOC_GAPS.md`) from `{paths.refinement_dir}/qc/{UC-ID}/` and the official `.feature` for the UC.*
95
+ *Note: For this command, the target in Step 1 is a UC-ID. Read the qc-analyze output (`REQUIREMENT_ANALYSIS.md` + `DOC_GAPS.md`) from `{paths.qc_dir}/{UC-ID}/` and the official `.feature` for the UC.*
96
96
 
97
97
  ## Context
98
98
  # Context Loader — Load All Project Context
@@ -133,6 +133,8 @@ Read `.agent/project-context.yaml`. Extract and store:
133
133
  - `paths.specs_dir` → BDD specs root
134
134
  - `paths.prd_dir` → PRD documents root
135
135
  - `paths.refinement_dir` → findings/review output dir
136
+ - `paths.qc_dir` → QC automation artifacts root (visible top-level, one subfolder per UC: `{qc_dir}/{UC-ID}/`)
137
+ - `paths.qc_skills_dir` → where qc-* commands load QC skills from (default bundled `.agent/skills/qc`; override to the QC team's own repo/submodule so framework upgrade won't overwrite them)
136
138
  - `paths.product_definitions_dir` → product definitions root
137
139
  - `paths.domain_knowledge_dir` → domain knowledge root
138
140
  - `paths.business_dictionary` → path to business-dictionary.md
@@ -145,6 +147,8 @@ If `paths` section is absent, use these defaults:
145
147
  - `specs_dir` = `specs/bdd`
146
148
  - `prd_dir` = `specs/prd`
147
149
  - `refinement_dir` = `.agent/review`
150
+ - `qc_dir` = `docs`
151
+ - `qc_skills_dir` = `.agent/skills/qc`
148
152
  - `product_definitions_dir` = `specs/product-definition`
149
153
  - `domain_knowledge_dir` = `specs/domain-knowledge`
150
154
  - `business_dictionary` = `specs/domain-knowledge/business-dictionary.md`
@@ -189,6 +193,7 @@ If `services` section is present:
189
193
  - Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
190
194
  - Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
191
195
  - Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
196
+ - Override `paths.prd_change_requests_dir` → `{spec_source}/feedback/prd-change-requests`
192
197
 
193
198
  > **Why under `spec_source`:** PRD, design-spec, domain knowledge, the **API contract (tech-docs)**, and tester feedback are all **cross-team artifacts** — they must live in the **shared spec repo** so every umbrella (FE/App/BE) reads the same source via `/sync`. Tech-docs specifically: BE authors the tech-design (API contract), commits + pushes it into the spec submodule (2-layer commit), and FE/App pull it on their next `/sync` to wire the real API in `/generate-code --phase=integration`. In single-service mode (no `spec_source`), these default under the repo root — still shared, same repo.
194
199
 
@@ -401,7 +406,7 @@ risk analysis, what-if scenarios, test scope/strategy per layer, and `questions-
401
406
  for any open/blocker gaps. You answer *"where is the risk, what must we ask?"* — you do not
402
407
  design concrete test cases (that is qc-design-test).
403
408
 
404
- ## Skills (`skills/qc/qa-planner/`)
409
+ ## Skills (`{paths.qc_skills_dir}/qa-planner/`)
405
410
 
406
411
  - `test-plan.md` — self-contained: risk matrix, what-if, scope by test layer
407
412
  (functional / integration / e2e / non-functional), entry/exit criteria, and the
@@ -409,7 +414,7 @@ design concrete test cases (that is qc-design-test).
409
414
 
410
415
  ## Output
411
416
 
412
- Write the test plan to `{paths.refinement_dir}/qc/{UC-ID}/TEST_PLAN.md`. Scope the plan to
417
+ Write the test plan to `{paths.qc_dir}/{UC-ID}/TEST_PLAN.md`. Scope the plan to
413
418
  the UC's scenarios (`{UC-ID}-SC{N}` from the `.feature`) so qc-design-test can design
414
419
  cases per scenario.
415
420