@anhth2/spec-driven-dev-plugin 0.9.0 → 0.9.2
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/ARCHITECTURE.md +1 -1
- package/bin/index.js +1 -2
- package/commands/debug.md +2 -1
- package/commands/define-product.md +2 -1
- package/commands/fix-bug.md +2 -1
- package/commands/generate-bdd.md +2 -1
- package/commands/generate-code.md +2 -1
- package/commands/generate-design-spec.md +2 -1
- package/commands/generate-prd.md +41 -21
- package/commands/generate-prd.tmpl +39 -20
- package/commands/generate-spec-manifest.md +2 -1
- package/commands/generate-tech-docs.md +53 -12
- package/commands/generate-tech-docs.tmpl +51 -11
- package/commands/generate-tests.md +2 -1
- package/commands/learn.md +2 -1
- package/commands/propose-scenario.md +2 -1
- package/commands/refine-prd.md +11 -2
- package/commands/refine-prd.tmpl +9 -1
- package/commands/report-bug.md +2 -1
- package/commands/review-code.md +2 -1
- package/commands/review-context.md +10 -1
- package/commands/review-context.tmpl +8 -0
- package/commands/review-tech-docs.md +10 -1
- package/commands/review-tech-docs.tmpl +8 -0
- package/commands/run-tests.md +2 -1
- package/commands/smoke-test.md +2 -1
- package/commands/validate-traces.md +2 -1
- package/core/FRAMEWORK_VERSION +1 -1
- package/core/commands/debug.md +2 -1
- package/core/commands/define-product.md +2 -1
- package/core/commands/fix-bug.md +2 -1
- package/core/commands/generate-bdd.md +2 -1
- package/core/commands/generate-code.md +2 -1
- package/core/commands/generate-design-spec.md +2 -1
- package/core/commands/generate-prd.md +41 -21
- package/core/commands/generate-spec-manifest.md +2 -1
- package/core/commands/generate-tech-docs.md +53 -12
- package/core/commands/generate-tests.md +2 -1
- package/core/commands/learn.md +2 -1
- package/core/commands/propose-scenario.md +2 -1
- package/core/commands/refine-prd.md +11 -2
- package/core/commands/report-bug.md +2 -1
- package/core/commands/review-code.md +2 -1
- package/core/commands/review-context.md +10 -1
- package/core/commands/review-tech-docs.md +10 -1
- package/core/commands/run-tests.md +2 -1
- package/core/commands/smoke-test.md +2 -1
- package/core/commands/validate-traces.md +2 -1
- package/core/modules/android-compose/module.yaml +13 -0
- package/core/modules/android-compose/stack-profile.yaml +57 -0
- package/core/modules/flutter/module.yaml +14 -0
- package/core/modules/flutter/stack-profile.yaml +59 -0
- package/core/modules/ios-swiftui/module.yaml +13 -0
- package/core/modules/ios-swiftui/stack-profile.yaml +55 -0
- package/core/modules/nuxt/module.yaml +14 -0
- package/core/modules/nuxt/stack-profile.yaml +58 -0
- package/core/modules/react-native/module.yaml +14 -0
- package/core/modules/react-native/stack-profile.yaml +56 -0
- package/core/modules/vue/module.yaml +14 -0
- package/core/modules/vue/stack-profile.yaml +65 -0
- package/core/skills/code/SKILL.md +2 -1
- package/core/skills/debug/SKILL.md +2 -1
- package/core/skills/design-spec/SKILL.md +2 -1
- package/core/skills/discovery/SKILL.md +2 -1
- package/core/skills/test/SKILL.md +4 -2
- package/core/steps/context-loader.md +2 -1
- package/core/templates/prd.template.md +35 -20
- package/core/templates/product-definition.template.md +3 -3
- package/core/templates/project-context.yaml +4 -1
- package/modules/android-compose/module.yaml +13 -0
- package/modules/android-compose/stack-profile.yaml +57 -0
- package/modules/flutter/module.yaml +14 -0
- package/modules/flutter/stack-profile.yaml +59 -0
- package/modules/ios-swiftui/module.yaml +13 -0
- package/modules/ios-swiftui/stack-profile.yaml +55 -0
- package/modules/nuxt/module.yaml +14 -0
- package/modules/nuxt/stack-profile.yaml +58 -0
- package/modules/react-native/module.yaml +14 -0
- package/modules/react-native/stack-profile.yaml +56 -0
- package/modules/vue/module.yaml +14 -0
- package/modules/vue/stack-profile.yaml +65 -0
- package/package.json +9 -2
- package/skills/code/SKILL.md +2 -1
- package/skills/debug/SKILL.md +2 -1
- package/skills/design-spec/SKILL.md +2 -1
- package/skills/discovery/SKILL.md +2 -1
- package/skills/test/SKILL.md +4 -2
- package/steps/context-loader.md +2 -1
- package/templates/prd.template.md +35 -20
- package/templates/product-definition.template.md +3 -3
- package/templates/project-context.yaml +4 -1
|
@@ -196,13 +196,14 @@ If `services` section is present:
|
|
|
196
196
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
197
197
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
198
198
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
199
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
199
200
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
200
201
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
201
202
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
202
203
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
203
204
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
204
205
|
|
|
205
|
-
> **Why under `spec_source`:**
|
|
206
|
+
> **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.
|
|
206
207
|
|
|
207
208
|
---
|
|
208
209
|
|
|
@@ -453,25 +454,49 @@ Write `{paths.tech_docs_dir}/{domain}/{UC-ID}-tech-design.md`:
|
|
|
453
454
|
---
|
|
454
455
|
|
|
455
456
|
## §1. Overview
|
|
457
|
+
|
|
458
|
+
{Tóm tắt ngắn: UC này implement gì, scope kỹ thuật chính.}
|
|
459
|
+
|
|
456
460
|
## §2. API Endpoints
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
+
|
|
462
|
+
*Greenfield:* endpoints được infer từ BDD scenarios — thiết kế mới.
|
|
463
|
+
*Reverse-document:* mô tả lại API đã tồn tại từ bảng "Existing API Contract" trong PRD. Ghi chú gaps nếu contract thực tế khác với BDD expectations.
|
|
464
|
+
|
|
465
|
+
| Method | Path | Auth/Role | Request | Response |
|
|
466
|
+
|--------|------|-----------|---------|----------|
|
|
467
|
+
| {GET/POST/PUT/DELETE} | {/api/v1/...} | {Bearer / role} | `{ field: type }` | `{ field: type }` |
|
|
468
|
+
|
|
461
469
|
## §3. Data Model
|
|
462
|
-
|
|
470
|
+
|
|
471
|
+
Key entities and relationships.
|
|
472
|
+
|
|
463
473
|
## §4. Service Flow
|
|
464
|
-
|
|
474
|
+
|
|
475
|
+
{Client} → Controller → {Facade/Service} → {Repository}
|
|
476
|
+
|
|
465
477
|
## §5. Business Rules Implementation
|
|
466
|
-
|
|
478
|
+
|
|
479
|
+
| BR-ID | Rule | Implementation approach |
|
|
480
|
+
|-------|------|-------------------------|
|
|
481
|
+
| {UC-ID}-BR1 | {rule} | {approach} |
|
|
482
|
+
|
|
467
483
|
## §6. Error Handling
|
|
468
|
-
|
|
484
|
+
|
|
485
|
+
| Scenario | Exception | HTTP Status |
|
|
486
|
+
|----------|-----------|-------------|
|
|
487
|
+
| {scenario} | {ExceptionClass} | {4xx/5xx} |
|
|
488
|
+
|
|
469
489
|
## §7. Database Changes
|
|
470
|
-
|
|
490
|
+
|
|
491
|
+
Migration scripts or schema changes.
|
|
492
|
+
|
|
471
493
|
## §8. Caching Strategy
|
|
472
|
-
|
|
494
|
+
|
|
495
|
+
What to cache, TTL, invalidation triggers.
|
|
496
|
+
|
|
473
497
|
## §9. Cross-Service Dependencies
|
|
474
|
-
|
|
498
|
+
|
|
499
|
+
External calls, events produced/consumed.
|
|
475
500
|
|
|
476
501
|
## Changelog
|
|
477
502
|
|
|
@@ -480,6 +505,21 @@ Write `{paths.tech_docs_dir}/{domain}/{UC-ID}-tech-design.md`:
|
|
|
480
505
|
| 1 | {YYYY-MM-DD} | Initial generation from {UC-ID}.feature (BDD v{bdd_version}) |
|
|
481
506
|
```
|
|
482
507
|
|
|
508
|
+
## Publish — share the contract (umbrella + shared spec repo)
|
|
509
|
+
|
|
510
|
+
If `paths.tech_docs_dir` resolved **under `setup.spec_source`** (e.g. `{spec_source}/specs/tech-docs`), the tech-doc was just written **inside the spec submodule**. It is the cross-team **API contract** — FE/App read it via their own `/sync`. Publish it so they can (2-layer commit):
|
|
511
|
+
|
|
512
|
+
```bash
|
|
513
|
+
cd {spec_source}
|
|
514
|
+
git add specs/tech-docs/{domain}/{UC-ID}-tech-design.md
|
|
515
|
+
git commit -m "docs({UC-ID}): tech design / API contract"
|
|
516
|
+
git push origin {spec_branch} # the branch FE/App track in .gitmodules
|
|
517
|
+
cd -
|
|
518
|
+
git add {spec_source} && git commit -m "chore: bump spec pointer ({UC-ID} tech design)"
|
|
519
|
+
```
|
|
520
|
+
|
|
521
|
+
If `tech_docs_dir` is **local** (single-service, or per-service routing in a multi-service umbrella), skip this — no cross-repo publish needed.
|
|
522
|
+
|
|
483
523
|
## Output
|
|
484
524
|
|
|
485
525
|
# Report Footer — Standard Command Output Format
|
|
@@ -549,5 +589,6 @@ Next : {suggested command with example arguments}
|
|
|
549
589
|
File: {paths.tech_docs_dir}/{domain}/{UC-ID}-tech-design.md
|
|
550
590
|
Next: /review-tech-docs {paths.tech_docs_dir}/{domain}/{UC-ID}-tech-design.md
|
|
551
591
|
← SA/Lead review required before code generation
|
|
592
|
+
→ if tech-docs live in the shared spec repo: commit + push to the spec submodule (see Publish above) so FE/App `/sync` can read the contract
|
|
552
593
|
→ after approved: /generate-code {paths.specs_dir}/{domain}/{UC-ID}-{slug}.feature
|
|
553
594
|
```
|
|
@@ -175,13 +175,14 @@ If `services` section is present:
|
|
|
175
175
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
176
176
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
177
177
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
178
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
178
179
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
179
180
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
180
181
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
181
182
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
182
183
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
183
184
|
|
|
184
|
-
> **Why under `spec_source`:**
|
|
185
|
+
> **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.
|
|
185
186
|
|
|
186
187
|
---
|
|
187
188
|
|
package/core/commands/learn.md
CHANGED
|
@@ -184,13 +184,14 @@ If `services` section is present:
|
|
|
184
184
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
185
185
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
186
186
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
187
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
187
188
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
188
189
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
189
190
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
190
191
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
191
192
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
192
193
|
|
|
193
|
-
> **Why under `spec_source`:**
|
|
194
|
+
> **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
195
|
|
|
195
196
|
---
|
|
196
197
|
|
|
@@ -184,13 +184,14 @@ If `services` section is present:
|
|
|
184
184
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
185
185
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
186
186
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
187
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
187
188
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
188
189
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
189
190
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
190
191
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
191
192
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
192
193
|
|
|
193
|
-
> **Why under `spec_source`:**
|
|
194
|
+
> **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
195
|
|
|
195
196
|
---
|
|
196
197
|
|
|
@@ -175,13 +175,14 @@ If `services` section is present:
|
|
|
175
175
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
176
176
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
177
177
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
178
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
178
179
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
179
180
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
180
181
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
181
182
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
182
183
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
183
184
|
|
|
184
|
-
> **Why under `spec_source`:**
|
|
185
|
+
> **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.
|
|
185
186
|
|
|
186
187
|
---
|
|
187
188
|
|
|
@@ -389,7 +390,9 @@ findings:
|
|
|
389
390
|
- id: "F001"
|
|
390
391
|
lens: "QA" # QA | DEV | SA | PO
|
|
391
392
|
severity: "major" # critical | major | minor
|
|
392
|
-
section: "§6. Acceptance Criteria"
|
|
393
|
+
section: "§6. Acceptance Criteria" # human-readable heading/section label
|
|
394
|
+
uc_id: "{TICKET-ID}-UC{N}" # UC this finding belongs to; "" if PRD-global (scope, metrics, problem statement)
|
|
395
|
+
quote: "{verbatim snippet copied EXACTLY from the PRD at the issue location, ≤120 chars}"
|
|
393
396
|
finding: "{description of gap or issue}"
|
|
394
397
|
suggestion: "{specific actionable improvement}"
|
|
395
398
|
auto_fixable: false # true = AI applies in --resume; false = human must write decision in note
|
|
@@ -402,6 +405,12 @@ summary:
|
|
|
402
405
|
recommendation: "APPROVED_WITH_MINOR_CHANGES | NEEDS_REVISION | BLOCKED"
|
|
403
406
|
```
|
|
404
407
|
|
|
408
|
+
> **Locator fields (`quote` + `uc_id`) — required for Review Board source-jump.**
|
|
409
|
+
> For every finding, copy a short **verbatim** `quote` straight from the PRD at the exact spot the
|
|
410
|
+
> issue occurs — do NOT paraphrase; it is matched against the document to locate the line. Set
|
|
411
|
+
> `uc_id` to the owning Use Case (or `""` for PRD-global findings). These let a reviewer click a
|
|
412
|
+
> finding in the Review Board and jump straight to the precise location in the source PRD.
|
|
413
|
+
|
|
405
414
|
## Report
|
|
406
415
|
|
|
407
416
|
# Report Footer — Standard Command Output Format
|
|
@@ -184,13 +184,14 @@ If `services` section is present:
|
|
|
184
184
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
185
185
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
186
186
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
187
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
187
188
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
188
189
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
189
190
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
190
191
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
191
192
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
192
193
|
|
|
193
|
-
> **Why under `spec_source`:**
|
|
194
|
+
> **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
195
|
|
|
195
196
|
---
|
|
196
197
|
|
|
@@ -177,13 +177,14 @@ If `services` section is present:
|
|
|
177
177
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
178
178
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
179
179
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
180
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
180
181
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
181
182
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
182
183
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
183
184
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
184
185
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
185
186
|
|
|
186
|
-
> **Why under `spec_source`:**
|
|
187
|
+
> **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.
|
|
187
188
|
|
|
188
189
|
---
|
|
189
190
|
|
|
@@ -182,13 +182,14 @@ If `services` section is present:
|
|
|
182
182
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
183
183
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
184
184
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
185
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
185
186
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
186
187
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
187
188
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
188
189
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
189
190
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
190
191
|
|
|
191
|
-
> **Why under `spec_source`:**
|
|
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.
|
|
192
193
|
|
|
193
194
|
---
|
|
194
195
|
|
|
@@ -563,6 +564,8 @@ findings:
|
|
|
563
564
|
check_id: "P1" # P1-P5 for PRD; B1-B6 for BDD
|
|
564
565
|
severity: "critical" # critical | major | minor
|
|
565
566
|
section: "{section or scenario ID where issue was found}"
|
|
567
|
+
uc_id: "{UC-ID this finding belongs to — PRD: the UC heading; BDD: @trace.id; \"\" if global}"
|
|
568
|
+
quote: "{verbatim snippet copied EXACTLY from the reviewed file at the issue location, ≤120 chars}"
|
|
566
569
|
finding: "{clear description of the issue}"
|
|
567
570
|
suggestion: "{specific actionable fix — AI will apply this in --resume if accepted}"
|
|
568
571
|
auto_fixable: true # true = AI can apply; false = human must write note in Review Board
|
|
@@ -576,6 +579,12 @@ summary:
|
|
|
576
579
|
recommendation: "APPROVED | NEEDS_REVISION | BLOCKED"
|
|
577
580
|
```
|
|
578
581
|
|
|
582
|
+
> **Locator fields (`quote` + `uc_id`) — required for Review Board source-jump.**
|
|
583
|
+
> For every finding, copy a short **verbatim** `quote` straight from the reviewed file at the exact
|
|
584
|
+
> spot the issue occurs — do NOT paraphrase; it is matched against the document to locate the line.
|
|
585
|
+
> Set `uc_id` to the owning Use Case (`@trace.id` for BDD, the UC heading for PRD; `""` if global).
|
|
586
|
+
> These let a reviewer click a finding in the Review Board and jump to the precise source location.
|
|
587
|
+
|
|
579
588
|
## Post-Analysis Routing
|
|
580
589
|
|
|
581
590
|
After running all checks and writing the findings file:
|
|
@@ -179,13 +179,14 @@ If `services` section is present:
|
|
|
179
179
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
180
180
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
181
181
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
182
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
182
183
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
183
184
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
184
185
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
185
186
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
186
187
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
187
188
|
|
|
188
|
-
> **Why under `spec_source`:**
|
|
189
|
+
> **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.
|
|
189
190
|
|
|
190
191
|
---
|
|
191
192
|
|
|
@@ -554,6 +555,8 @@ findings:
|
|
|
554
555
|
check_id: "T1" # T1–T7
|
|
555
556
|
severity: "critical" # critical | major | minor
|
|
556
557
|
section: "{section heading or component name where issue was found}"
|
|
558
|
+
uc_id: "{UC-ID}" # same as top-level uc_id (the UC this tech-doc designs)
|
|
559
|
+
quote: "{verbatim snippet copied EXACTLY from the tech-doc at the issue location, ≤120 chars}"
|
|
557
560
|
finding: "{clear description of the violation or gap}"
|
|
558
561
|
suggestion: "{specific fix — AI applies this in --resume if accepted}"
|
|
559
562
|
auto_fixable: false # true = AI can apply; false = human must write decision in note
|
|
@@ -568,6 +571,11 @@ summary:
|
|
|
568
571
|
sign_off_gate: "{blocked — pending: fe_team, app_team, sa | ready}"
|
|
569
572
|
```
|
|
570
573
|
|
|
574
|
+
> **Locator fields (`quote` + `uc_id`) — required for Review Board source-jump.**
|
|
575
|
+
> For every finding, copy a short **verbatim** `quote` straight from the tech-doc at the exact spot
|
|
576
|
+
> the issue occurs — do NOT paraphrase; it is matched against the document to locate the line.
|
|
577
|
+
> These let a reviewer click a finding in the Review Board and jump to the precise source location.
|
|
578
|
+
|
|
571
579
|
## Report
|
|
572
580
|
|
|
573
581
|
# Report Footer — Standard Command Output Format
|
|
@@ -717,4 +725,5 @@ Sign-off : {✅ All done — status set to approved
|
|
|
717
725
|
Re-run /review-tech-docs {file} to confirm 0 remaining critical findings.
|
|
718
726
|
Next: {/generate-code {feature-file} ← only if status = approved
|
|
719
727
|
| Collect pending sign-offs → update @trace.sign_off → re-run /review-tech-docs}
|
|
728
|
+
→ if the tech-doc lives in the shared spec repo: commit + push it to the spec submodule so FE/App `/sync` the updated contract
|
|
720
729
|
```
|
|
@@ -175,13 +175,14 @@ If `services` section is present:
|
|
|
175
175
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
176
176
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
177
177
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
178
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
178
179
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
179
180
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
180
181
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
181
182
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
182
183
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
183
184
|
|
|
184
|
-
> **Why under `spec_source`:**
|
|
185
|
+
> **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.
|
|
185
186
|
|
|
186
187
|
---
|
|
187
188
|
|
|
@@ -177,13 +177,14 @@ If `services` section is present:
|
|
|
177
177
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
178
178
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
179
179
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
180
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
180
181
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
181
182
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
182
183
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
183
184
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
184
185
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
185
186
|
|
|
186
|
-
> **Why under `spec_source`:**
|
|
187
|
+
> **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.
|
|
187
188
|
|
|
188
189
|
---
|
|
189
190
|
|
|
@@ -177,13 +177,14 @@ If `services` section is present:
|
|
|
177
177
|
**4. Spec source auto-override** — if `setup.spec_source` is set AND the corresponding path was not already explicitly set in `paths:`:
|
|
178
178
|
- Override `paths.prd_dir` → `{spec_source}/specs/prd`
|
|
179
179
|
- Override `paths.design_spec_dir` → `{spec_source}/specs/design-spec`
|
|
180
|
+
- Override `paths.tech_docs_dir` → `{spec_source}/specs/tech-docs` — **only if step 2 did not already route it to a service** (multi-service umbrellas keep per-service tech-docs). This publishes the BE-authored API contract into the shared spec repo so FE/App can read it via the spec submodule at `/generate-code --phase=integration`.
|
|
180
181
|
- Override `paths.domain_knowledge_dir` → `{spec_source}/specs/domain-knowledge`
|
|
181
182
|
- Override `paths.business_dictionary` → `{spec_source}/specs/domain-knowledge/business-dictionary.md`
|
|
182
183
|
- Override `paths.core_entities` → `{spec_source}/specs/domain-knowledge/core-entities.md`
|
|
183
184
|
- Override `paths.bug_reports_dir` → `{spec_source}/feedback/bug-reports`
|
|
184
185
|
- Override `paths.bdd_proposals_dir` → `{spec_source}/feedback/bdd-proposals`
|
|
185
186
|
|
|
186
|
-
> **Why under `spec_source`:**
|
|
187
|
+
> **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.
|
|
187
188
|
|
|
188
189
|
---
|
|
189
190
|
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
name: "Android (Jetpack Compose)"
|
|
2
|
+
version: "1.0.0"
|
|
3
|
+
description: "Native Android development with Jetpack Compose + Kotlin"
|
|
4
|
+
language: "Kotlin"
|
|
5
|
+
framework: "Jetpack Compose"
|
|
6
|
+
stack_type: "mobile"
|
|
7
|
+
default_layer_order:
|
|
8
|
+
- Domain models
|
|
9
|
+
- Repository (data layer)
|
|
10
|
+
- UseCase (domain logic)
|
|
11
|
+
- ViewModel (StateFlow<UiState>)
|
|
12
|
+
- Composable screens (presentation)
|
|
13
|
+
test_framework: "JUnit5 + MockK + Turbine"
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
build:
|
|
2
|
+
compile: "./gradlew assembleRelease"
|
|
3
|
+
test: "./gradlew test"
|
|
4
|
+
run: "./gradlew installDebug / Open in Android Studio → Run"
|
|
5
|
+
lint: "./gradlew lint"
|
|
6
|
+
|
|
7
|
+
architecture:
|
|
8
|
+
style: "MVVM + Clean Architecture (Composable → ViewModel → UseCase → Repository)"
|
|
9
|
+
key_rules:
|
|
10
|
+
- "Composables are pure UI functions — no business logic, no direct suspend calls"
|
|
11
|
+
- "ViewModels expose StateFlow<UiState>; Composables collect via collectAsStateWithLifecycle()"
|
|
12
|
+
- "UseCases are single-responsibility classes injected into ViewModels"
|
|
13
|
+
- "Repositories are interfaces; implementations live in the data layer"
|
|
14
|
+
- "Dependency injection via Hilt"
|
|
15
|
+
- "Never launch coroutines from a Composable directly — use LaunchedEffect or ViewModel"
|
|
16
|
+
folder_structure: |
|
|
17
|
+
src/main/java/{package}/
|
|
18
|
+
├── core/
|
|
19
|
+
│ ├── network/ ← Retrofit instance, interceptors
|
|
20
|
+
│ ├── theme/ ← MaterialTheme, Color, Type, Shape
|
|
21
|
+
│ └── utils/
|
|
22
|
+
├── shared/
|
|
23
|
+
│ └── components/ ← reusable Composables (AppButton, AppTextField...)
|
|
24
|
+
├── features/
|
|
25
|
+
│ └── {domain}/
|
|
26
|
+
│ ├── ui/ ← Composable screens + components
|
|
27
|
+
│ ├── viewmodel/ ← ViewModel + UiState
|
|
28
|
+
│ ├── domain/ ← UseCases, domain models
|
|
29
|
+
│ └── data/ ← Repository impl, data sources
|
|
30
|
+
|
|
31
|
+
coding_standards:
|
|
32
|
+
naming:
|
|
33
|
+
composables: "PascalCase (e.g., OrderListScreen, CreateOrderForm)"
|
|
34
|
+
viewmodels: "PascalCase + ViewModel suffix (e.g., OrderListViewModel)"
|
|
35
|
+
usecases: "PascalCase + UseCase suffix (e.g., CreateOrderUseCase)"
|
|
36
|
+
files:
|
|
37
|
+
screen: "{Feature}Screen.kt"
|
|
38
|
+
viewmodel: "{Feature}ViewModel.kt"
|
|
39
|
+
usecase: "{Feature}UseCase.kt"
|
|
40
|
+
patterns:
|
|
41
|
+
state_management: "StateFlow<UiState> in ViewModel"
|
|
42
|
+
navigation: "Jetpack Navigation Compose"
|
|
43
|
+
networking: "Retrofit + OkHttp"
|
|
44
|
+
serialization: "Kotlinx Serialization or Gson"
|
|
45
|
+
di: "Hilt"
|
|
46
|
+
async: "Kotlin Coroutines + Flow"
|
|
47
|
+
|
|
48
|
+
testing:
|
|
49
|
+
unit: "JUnit5 + MockK + Turbine (Flow testing)"
|
|
50
|
+
ui: "Compose UI Test (composeTestRule)"
|
|
51
|
+
patterns:
|
|
52
|
+
- "Test ViewModel with fake repositories and TestCoroutineDispatcher"
|
|
53
|
+
- "UI tests use semantics matchers — set Modifier.testTag() on Composables"
|
|
54
|
+
|
|
55
|
+
trace_tags:
|
|
56
|
+
implements: "// @trace.implements={UC-ID}-SC{N}"
|
|
57
|
+
source: "// @trace.source=specs/bdd/{domain}/{UC-ID}.feature"
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
name: "Flutter"
|
|
2
|
+
version: "1.0.0"
|
|
3
|
+
description: "Cross-platform mobile (iOS + Android) with Flutter/Dart"
|
|
4
|
+
language: "Dart"
|
|
5
|
+
framework: "Flutter"
|
|
6
|
+
stack_type: "mobile"
|
|
7
|
+
default_layer_order:
|
|
8
|
+
- Models / entities (domain)
|
|
9
|
+
- Repositories (data layer)
|
|
10
|
+
- Use cases (domain logic)
|
|
11
|
+
- BLoC / Cubit or Riverpod providers (state)
|
|
12
|
+
- Widgets (presentation)
|
|
13
|
+
- Pages / screens
|
|
14
|
+
test_framework: "flutter_test + mocktail"
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
build:
|
|
2
|
+
compile: "flutter build apk / flutter build ios"
|
|
3
|
+
test: "flutter test"
|
|
4
|
+
run: "flutter run"
|
|
5
|
+
lint: "flutter analyze"
|
|
6
|
+
|
|
7
|
+
architecture:
|
|
8
|
+
style: "Feature-based (presentation → domain → data)"
|
|
9
|
+
key_rules:
|
|
10
|
+
- "Widget tree is pure UI — business logic lives in BLoC/Cubit or Riverpod providers"
|
|
11
|
+
- "Repositories abstract data sources; services contain domain logic"
|
|
12
|
+
- "State management: BLoC (complex flows) or Riverpod (simple/medium)"
|
|
13
|
+
- "Never call API directly inside a Widget build() method"
|
|
14
|
+
- "Shared UI widgets in lib/shared/widgets/, feature widgets in lib/features/{name}/presentation/"
|
|
15
|
+
- "Use const constructors wherever possible for performance"
|
|
16
|
+
folder_structure: |
|
|
17
|
+
lib/
|
|
18
|
+
├── core/
|
|
19
|
+
│ ├── theme/ ← AppTheme, colors, text styles
|
|
20
|
+
│ ├── router/ ← GoRouter or auto_route
|
|
21
|
+
│ └── utils/
|
|
22
|
+
├── shared/
|
|
23
|
+
│ └── widgets/ ← reusable UI widgets (AppButton, AppInput...)
|
|
24
|
+
├── features/
|
|
25
|
+
│ └── {domain}/
|
|
26
|
+
│ ├── data/ ← repositories, data sources, models
|
|
27
|
+
│ ├── domain/ ← entities, use cases, repo interfaces
|
|
28
|
+
│ └── presentation/ ← pages, widgets, BLoC/Cubit
|
|
29
|
+
└── main.dart
|
|
30
|
+
|
|
31
|
+
coding_standards:
|
|
32
|
+
naming:
|
|
33
|
+
widgets: "PascalCase (e.g., OrderListPage, CreateOrderForm)"
|
|
34
|
+
blocs: "PascalCase + Bloc/Cubit suffix (e.g., OrderListCubit)"
|
|
35
|
+
repositories: "PascalCase + Repository suffix (e.g., OrderRepository)"
|
|
36
|
+
files:
|
|
37
|
+
page: "{feature}_page.dart"
|
|
38
|
+
widget: "{feature}_widget.dart"
|
|
39
|
+
cubit: "{feature}_cubit.dart"
|
|
40
|
+
repository: "{feature}_repository.dart"
|
|
41
|
+
model: "{feature}_model.dart"
|
|
42
|
+
patterns:
|
|
43
|
+
state_management: "BLoC / Cubit (flutter_bloc) or Riverpod"
|
|
44
|
+
navigation: "GoRouter or auto_route"
|
|
45
|
+
networking: "Dio with interceptors"
|
|
46
|
+
serialization: "json_serializable / freezed"
|
|
47
|
+
|
|
48
|
+
testing:
|
|
49
|
+
unit: "flutter_test + mocktail"
|
|
50
|
+
widget: "flutter_test WidgetTester"
|
|
51
|
+
integration: "integration_test package"
|
|
52
|
+
patterns:
|
|
53
|
+
- "Test BLoC/Cubit in isolation with fake repositories"
|
|
54
|
+
- "Widget tests pump the widget tree and find by key or semantics label"
|
|
55
|
+
- "Use goldenFileComparator for snapshot tests of complex widgets"
|
|
56
|
+
|
|
57
|
+
trace_tags:
|
|
58
|
+
implements: "// @trace.implements={UC-ID}-SC{N}"
|
|
59
|
+
source: "// @trace.source=specs/bdd/{domain}/{UC-ID}.feature"
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
name: "iOS (SwiftUI)"
|
|
2
|
+
version: "1.0.0"
|
|
3
|
+
description: "Native iOS development with SwiftUI + Swift"
|
|
4
|
+
language: "Swift"
|
|
5
|
+
framework: "SwiftUI"
|
|
6
|
+
stack_type: "mobile"
|
|
7
|
+
default_layer_order:
|
|
8
|
+
- Models / entities
|
|
9
|
+
- Repository (data sources)
|
|
10
|
+
- UseCase (business operations)
|
|
11
|
+
- ViewModel (ObservableObject state)
|
|
12
|
+
- View (SwiftUI presentation)
|
|
13
|
+
test_framework: "XCTest + Quick/Nimble"
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
build:
|
|
2
|
+
compile: "xcodebuild -scheme {AppName} -configuration Release"
|
|
3
|
+
test: "xcodebuild test -scheme {AppName}"
|
|
4
|
+
run: "Open in Xcode → Run (⌘R)"
|
|
5
|
+
lint: "swiftlint"
|
|
6
|
+
|
|
7
|
+
architecture:
|
|
8
|
+
style: "MVVM + Clean Architecture (View → ViewModel → UseCase → Repository)"
|
|
9
|
+
key_rules:
|
|
10
|
+
- "Views are pure SwiftUI — no business logic, no direct API calls"
|
|
11
|
+
- "ViewModels are ObservableObject classes; bind via @StateObject / @ObservedObject"
|
|
12
|
+
- "UseCases encapsulate single business operations"
|
|
13
|
+
- "Repositories abstract data sources (network, cache, local DB)"
|
|
14
|
+
- "Dependency injection via environment or constructor injection"
|
|
15
|
+
- "Use Combine or async/await for async flows — never DispatchQueue in ViewModel"
|
|
16
|
+
folder_structure: |
|
|
17
|
+
Sources/
|
|
18
|
+
├── Core/
|
|
19
|
+
│ ├── Network/ ← URLSession wrapper, interceptors
|
|
20
|
+
│ ├── Theme/ ← Color, Font, Spacing tokens
|
|
21
|
+
│ └── Utils/
|
|
22
|
+
├── Shared/
|
|
23
|
+
│ └── Components/ ← reusable SwiftUI views (AppButton, AppTextField...)
|
|
24
|
+
├── Features/
|
|
25
|
+
│ └── {Domain}/
|
|
26
|
+
│ ├── Views/
|
|
27
|
+
│ ├── ViewModels/
|
|
28
|
+
│ ├── UseCases/
|
|
29
|
+
│ └── Repository/
|
|
30
|
+
|
|
31
|
+
coding_standards:
|
|
32
|
+
naming:
|
|
33
|
+
views: "PascalCase + View suffix (e.g., OrderListView, CreateOrderView)"
|
|
34
|
+
viewmodels: "PascalCase + ViewModel suffix (e.g., OrderListViewModel)"
|
|
35
|
+
usecases: "PascalCase + UseCase suffix (e.g., CreateOrderUseCase)"
|
|
36
|
+
files:
|
|
37
|
+
view: "{Feature}View.swift"
|
|
38
|
+
viewmodel: "{Feature}ViewModel.swift"
|
|
39
|
+
usecase: "{Feature}UseCase.swift"
|
|
40
|
+
patterns:
|
|
41
|
+
async: "async/await + Combine"
|
|
42
|
+
navigation: "NavigationStack (iOS 16+)"
|
|
43
|
+
persistence: "Core Data or SwiftData"
|
|
44
|
+
networking: "URLSession or Alamofire"
|
|
45
|
+
|
|
46
|
+
testing:
|
|
47
|
+
unit: "XCTest + Quick/Nimble"
|
|
48
|
+
ui: "XCUITest"
|
|
49
|
+
patterns:
|
|
50
|
+
- "Test ViewModel by injecting mock repositories"
|
|
51
|
+
- "UI tests use accessibility identifiers — set .accessibilityIdentifier on Views"
|
|
52
|
+
|
|
53
|
+
trace_tags:
|
|
54
|
+
implements: "// @trace.implements={UC-ID}-SC{N}"
|
|
55
|
+
source: "// @trace.source=specs/bdd/{domain}/{UC-ID}.feature"
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
name: "Nuxt"
|
|
2
|
+
version: "1.0.0"
|
|
3
|
+
description: "Nuxt 3 with SSR/SSG, Composition API, Pinia, and useFetch"
|
|
4
|
+
language: "TypeScript"
|
|
5
|
+
framework: "Nuxt 3"
|
|
6
|
+
stack_type: "frontend"
|
|
7
|
+
default_layer_order:
|
|
8
|
+
- Types / interfaces
|
|
9
|
+
- Server API routes (server/api/)
|
|
10
|
+
- Composables (useFetch / useAsyncData)
|
|
11
|
+
- State store (Pinia)
|
|
12
|
+
- UI components (presentational)
|
|
13
|
+
- Page components (pages/)
|
|
14
|
+
test_framework: "Vitest + Vue Test Utils + @nuxt/test-utils"
|