sdlc-workflow 1.0.11 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +19 -11
- package/bin/cli.js +331 -120
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -5,13 +5,15 @@ Scaffold SDLC workflow docs and templates into your project. Works with **Cursor
|
|
|
5
5
|
## Flow
|
|
6
6
|
|
|
7
7
|
```
|
|
8
|
-
User Request → PO → Business BA →
|
|
8
|
+
User Request → PO → Business BA → Design (if app/web) → Architect → Technical BA → QE (docs) → Dev → QE (testing + UAT) → Security + PE audit → [fix loop until no issues] → Deploy → Maintenance
|
|
9
9
|
```
|
|
10
10
|
|
|
11
11
|
- **Trigger:** When you send an **idea** or **feature request**, the agent should run the **full pipeline** (PO → … → Deploy) in sequence, one sub-agent/role per phase — not handle everything in one go or stop after one phase. See `docs/sdlc/ORCHESTRATION.md`.
|
|
12
|
-
- **Design (optional):** For app/web projects, after
|
|
12
|
+
- **Design (optional):** For app/web projects, after Business BA → create **design specs** (Markdown) + optional **HTML wireframes**; **PO + Business BA review** until approved; then Architect + Technical BA. UX drives technical decisions.
|
|
13
|
+
- **Security + Principle Engineer:** After implementation and QE testing → security + logic audit; **fix loop** (Dev fixes → re-audit) until all issues resolved; sign-off before Deploy.
|
|
13
14
|
- **Each role runs as a sub-agent** (see `docs/sdlc/agents/`).
|
|
14
15
|
- **After completion** → deploy immediately with **Docker Compose** (local/staging) and **Kubernetes** (production) — `docs/sdlc/deploy/`.
|
|
16
|
+
- **Maintenance:** After Deploy → monitoring, bug fixes, patches, dependency updates, performance tuning — `docs/sdlc/maintenance/`.
|
|
15
17
|
- **QE (docs)**: Test plan, test cases
|
|
16
18
|
- **Dev**: After docs phase → **run implementation immediately**. Tech Lead (review, merge) + Senior Dev (implement, Unit Test ≥90%)
|
|
17
19
|
- **QE (testing)**: QE Lead (15+ yrs automation: strategy, framework, review) + Senior QE (10+ yrs, write automation tests)
|
|
@@ -55,11 +57,11 @@ docs/sdlc/
|
|
|
55
57
|
│ ├── api-spec.template.md
|
|
56
58
|
│ ├── team-breakdown.template.md
|
|
57
59
|
│ └── README.md
|
|
60
|
+
├── design/ # Design (optional, app/web): after BA, before Architect; design specs + wireframes; PO+BA review until approved
|
|
61
|
+
│ └── README.md
|
|
58
62
|
├── architecture/ # Architect
|
|
59
63
|
│ ├── adr.template.md
|
|
60
64
|
│ └── README.md
|
|
61
|
-
├── design/ # Design (optional, app/web): Pencil.dev .pen; PO+BA review until approved
|
|
62
|
-
│ └── README.md
|
|
63
65
|
├── qe/ # QE (one folder per epic: qe/{epic-slug}/)
|
|
64
66
|
│ ├── test-case.template.md
|
|
65
67
|
│ ├── README.md
|
|
@@ -77,15 +79,21 @@ docs/sdlc/
|
|
|
77
79
|
│ ├── embedded/ # Senior Embedded 10+ yrs — firmware, IoT
|
|
78
80
|
│ ├── data-ml/ # Senior Data/ML 10+ yrs
|
|
79
81
|
│ └── platform/ # Senior Platform 10+ yrs — CI/CD, infra
|
|
82
|
+
├── security/ # Security team: audit security risk (after implementation)
|
|
83
|
+
│ └── README.md
|
|
84
|
+
├── principle-engineer/ # Principle engineer: audit logic, architecture (after implementation)
|
|
85
|
+
│ └── README.md
|
|
80
86
|
├── agents/ # Sub-agent specs (each role = sub-agent)
|
|
81
87
|
│ └── README.md
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
88
|
+
├── deploy/ # After Security + PE sign-off (fix loop until no issues) → Docker Compose + K8s
|
|
89
|
+
│ ├── README.md
|
|
90
|
+
│ ├── docker-compose.yml.template
|
|
91
|
+
│ └── k8s/
|
|
92
|
+
│ ├── deployment.yaml.template
|
|
93
|
+
│ ├── service.yaml.template
|
|
94
|
+
│ └── ingress.yaml.template
|
|
95
|
+
└── maintenance/ # After Deploy → monitoring, bug fixes, patches, runbooks
|
|
96
|
+
└── README.md
|
|
89
97
|
|
|
90
98
|
.cursor/rules/
|
|
91
99
|
└── sdlc-workflow.mdc # Cursor rule
|
package/bin/cli.js
CHANGED
|
@@ -172,9 +172,12 @@ async function generateFromInline(cwd) {
|
|
|
172
172
|
join(base, "dev", "embedded"),
|
|
173
173
|
join(base, "dev", "data-ml"),
|
|
174
174
|
join(base, "dev", "platform"),
|
|
175
|
+
join(base, "security"),
|
|
176
|
+
join(base, "principle-engineer"),
|
|
175
177
|
join(base, "agents"),
|
|
176
178
|
join(base, "deploy"),
|
|
177
179
|
join(base, "deploy", "k8s"),
|
|
180
|
+
join(base, "maintenance"),
|
|
178
181
|
];
|
|
179
182
|
|
|
180
183
|
for (const d of dirs) {
|
|
@@ -199,6 +202,7 @@ async function generateFromInline(cwd) {
|
|
|
199
202
|
["qe/qe-lead/README.md", QE_LEAD_README],
|
|
200
203
|
["qe/senior-qe/README.md", QE_SENIOR_README],
|
|
201
204
|
["design/README.md", DESIGN_README],
|
|
205
|
+
["design/design-spec.template.md", DESIGN_SPEC_TEMPLATE],
|
|
202
206
|
["dev/tech-lead/README.md", DEV_TECH_LEAD_README],
|
|
203
207
|
["dev/senior-developer/README.md", DEV_SENIOR_README],
|
|
204
208
|
["dev/implementation-roles.template.md", DEV_IMPLEMENTATION_ROLES_TEMPLATE],
|
|
@@ -208,12 +212,15 @@ async function generateFromInline(cwd) {
|
|
|
208
212
|
["dev/embedded/README.md", DEV_EMBEDDED_README],
|
|
209
213
|
["dev/data-ml/README.md", DEV_DATA_ML_README],
|
|
210
214
|
["dev/platform/README.md", DEV_PLATFORM_README],
|
|
215
|
+
["security/README.md", SECURITY_README],
|
|
216
|
+
["principle-engineer/README.md", PRINCIPLE_ENGINEER_README],
|
|
211
217
|
["agents/README.md", AGENTS_README],
|
|
212
218
|
["deploy/README.md", DEPLOY_README],
|
|
213
219
|
["deploy/docker-compose.yml.template", DOCKER_COMPOSE_TEMPLATE],
|
|
214
220
|
["deploy/k8s/deployment.yaml.template", K8S_DEPLOYMENT_TEMPLATE],
|
|
215
221
|
["deploy/k8s/service.yaml.template", K8S_SERVICE_TEMPLATE],
|
|
216
222
|
["deploy/k8s/ingress.yaml.template", K8S_INGRESS_TEMPLATE],
|
|
223
|
+
["maintenance/README.md", MAINTENANCE_README],
|
|
217
224
|
];
|
|
218
225
|
|
|
219
226
|
for (const [rel, content] of files) {
|
|
@@ -235,15 +242,18 @@ globs: docs/sdlc/**/*, **/*.md
|
|
|
235
242
|
|
|
236
243
|
1. **PO** — PRD, user stories → docs/sdlc/po/{epic-slug}/ (one folder per epic)
|
|
237
244
|
2. **Business BA** — FRS, process flows → docs/sdlc/ba/business/{epic-slug}/ (one folder per epic)
|
|
238
|
-
3. **
|
|
239
|
-
4. **
|
|
240
|
-
5. **
|
|
245
|
+
3. **Design (if app/web)** — Design specs + wireframes → docs/sdlc/design/{epic-slug}/; **PO + BA review** → loop until approved
|
|
246
|
+
4. **Architect** — ADRs, diagrams → docs/sdlc/architecture/
|
|
247
|
+
5. **Technical BA** — API specs, team breakdown → docs/sdlc/ba/technical/
|
|
241
248
|
6. **QE (docs)** — Test plan, test cases → docs/sdlc/qe/{epic-slug}/ (one folder per epic)
|
|
242
249
|
7. **Dev** — After docs phase → **run implementation immediately**. Tech Lead + implementation roles → docs/sdlc/dev/{role}/
|
|
243
|
-
8. **QE (testing)** — QE Lead (15+ yrs automation) + Senior QE (10+ yrs) → docs/sdlc/qe/{epic-slug}/
|
|
244
|
-
9. **
|
|
250
|
+
8. **QE (testing + UAT)** — QE Lead (15+ yrs automation) + Senior QE (10+ yrs) + UAT → docs/sdlc/qe/{epic-slug}/
|
|
251
|
+
9. **Security** — Audit security risk → docs/sdlc/security/
|
|
252
|
+
10. **Principle Engineer** — Audit logic, architecture → docs/sdlc/principle-engineer/
|
|
253
|
+
11. **Deploy** — Docker Compose + K8s → docs/sdlc/deploy/ (after Security + PE sign-off; fix loop until no issues)
|
|
254
|
+
12. **Maintenance** — Monitoring, bug fixes, patches, dependency updates → docs/sdlc/maintenance/
|
|
245
255
|
|
|
246
|
-
**Each role runs as a sub-agent.** Design
|
|
256
|
+
**Each role runs as a sub-agent.** Design before Architect (UX drives tech). See docs/sdlc/agents/
|
|
247
257
|
Full workflow: docs/sdlc/SDLC-WORKFLOW.md
|
|
248
258
|
`;
|
|
249
259
|
|
|
@@ -261,7 +271,7 @@ Sequential workflow; **each role runs as a sub-agent**. Each phase produces docs
|
|
|
261
271
|
**When the user sends an idea, feature request, or new requirement:**
|
|
262
272
|
1. **Trigger the pipeline** and run it **continuously through deployment** (Phase 1 → 2 → … → 7).
|
|
263
273
|
2. **One role per phase.** For each phase, act **only** as that role (e.g. only PO in phase 1, only Business BA in phase 2). Produce that phase's outputs into the correct folder, then **continue to the next phase** without waiting for the user.
|
|
264
|
-
3. **Run in order:** PO → Business BA →
|
|
274
|
+
3. **Run in order:** PO → Business BA → **Design (if app/web, PO+BA review loop)** → Architect → Technical BA → QE (docs) → Dev → QE (testing + UAT) → **Security + Principle Engineer audit → fix loop until all issues resolved** → Deploy → Maintenance. Do not stop after one phase unless the user explicitly asks to stop.
|
|
265
275
|
|
|
266
276
|
**Note:** In Cursor and similar tools there is a single agent per conversation. "Sub-agent" means **one role per phase** — the same agent must adopt exactly one role per phase and run phases in sequence (do not mix roles in one step). If the platform later supports spawning separate agents per phase, use that; otherwise this single agent simulates the pipeline by switching role each phase.
|
|
267
277
|
|
|
@@ -270,7 +280,7 @@ Sequential workflow; **each role runs as a sub-agent**. Each phase produces docs
|
|
|
270
280
|
## Flow Overview
|
|
271
281
|
|
|
272
282
|
\`\`\`
|
|
273
|
-
User Request → PO → Business BA →
|
|
283
|
+
User Request → PO → Business BA → Design (if app/web) → Architect → Technical BA → QE (docs) → Dev → QE (testing + UAT) → Security + PE audit → [fix loop until no issues] → Deploy → Maintenance
|
|
274
284
|
\`\`\`
|
|
275
285
|
|
|
276
286
|
**Determine current phase** before acting. If user sent an idea, assume Phase 0 and start from Phase 1.
|
|
@@ -292,32 +302,34 @@ User Request → PO → Business BA → Architect → Technical BA → Design (i
|
|
|
292
302
|
|
|
293
303
|
**Role**: Break down from business perspective.
|
|
294
304
|
**Deliverables**: Business process flows, functional requirements, use cases, glossary.
|
|
295
|
-
**Output**: \`docs/sdlc/ba/business/{epic-slug}/\` — **one folder per epic** (same slug as PO
|
|
305
|
+
**Output**: \`docs/sdlc/ba/business/{epic-slug}/\` — **one folder per epic** (same slug as PO). Do not merge all epics into one file. **Handoff to Design (if app/web) or Architect.**
|
|
296
306
|
|
|
297
|
-
## Phase 3:
|
|
298
|
-
|
|
299
|
-
**Role**: Design system architecture and technology choices.
|
|
300
|
-
**Deliverables**: System context, container diagram, ADRs, tech stack, cross-cutting concerns.
|
|
301
|
-
**Output**: \`docs/sdlc/architecture/\` — **Handoff to Technical BA.**
|
|
302
|
-
|
|
303
|
-
## Phase 4: Technical BA
|
|
304
|
-
|
|
305
|
-
**Role**: Translate business + architecture into implementable specs.
|
|
306
|
-
**Deliverables**: API specs, DB schema, team breakdown, acceptance criteria per ticket.
|
|
307
|
-
**Output**: \`docs/sdlc/ba/technical/\` — **Handoff to Design (if app/web) or QE + Dev.**
|
|
308
|
-
|
|
309
|
-
## Phase 4b: Design (optional — app/web only)
|
|
307
|
+
## Phase 3: Design (optional — app/web only)
|
|
310
308
|
|
|
311
309
|
**When:** Project has UI (web, mobile app). Skip for API-only, library, CLI, data/ML, platform without UI.
|
|
312
310
|
|
|
313
|
-
**Role**:
|
|
314
|
-
**Output**: \`docs/sdlc/design/{epic-slug}/\` — .
|
|
311
|
+
**Role**: Create UI/UX design specs (Markdown) and optional HTML wireframes from idea + PO + Business BA docs. Design **before** Architect so UX drives technical decisions.
|
|
312
|
+
**Output**: \`docs/sdlc/design/{epic-slug}/\` — design-spec.md + optional wireframes/.
|
|
315
313
|
|
|
316
314
|
**Review loop:**
|
|
317
315
|
1. **PO review**: Design aligns with epic brief, user stories, acceptance criteria?
|
|
318
316
|
2. **Business BA review**: Design matches functional requirements, process flows?
|
|
319
|
-
3. **If not approved**: Capture feedback → redesign
|
|
320
|
-
4. **If approved** → **Handoff to
|
|
317
|
+
3. **If not approved**: Capture feedback → redesign → repeat until PO and BA approve.
|
|
318
|
+
4. **If approved** → **Handoff to Architect.**
|
|
319
|
+
|
|
320
|
+
## Phase 4: Architect
|
|
321
|
+
|
|
322
|
+
**Role**: Design system architecture and technology choices.
|
|
323
|
+
**Deliverables**: System context, container diagram, ADRs, tech stack, cross-cutting concerns.
|
|
324
|
+
**Input**: Business BA + Design (if app/web) — design informs architecture.
|
|
325
|
+
**Output**: \`docs/sdlc/architecture/\` — **Handoff to Technical BA.**
|
|
326
|
+
|
|
327
|
+
## Phase 5: Technical BA
|
|
328
|
+
|
|
329
|
+
**Role**: Translate business + architecture + design into implementable specs.
|
|
330
|
+
**Deliverables**: API specs, DB schema, team breakdown, acceptance criteria per ticket.
|
|
331
|
+
**Input**: Architect + Design (if app/web) — design informs API/screen contracts.
|
|
332
|
+
**Output**: \`docs/sdlc/ba/technical/\` — **Handoff to QE + Dev.**
|
|
321
333
|
|
|
322
334
|
## Phase 5a: QE (Docs phase)
|
|
323
335
|
|
|
@@ -341,7 +353,7 @@ User Request → PO → Business BA → Architect → Technical BA → Design (i
|
|
|
341
353
|
|
|
342
354
|
**Requirements**: Unit Test coverage **≥ 90%**.
|
|
343
355
|
|
|
344
|
-
**Output**: Code + unit tests. **Handoff to QE (testing).**
|
|
356
|
+
**Output**: Code + unit tests. **Handoff to QE (testing + UAT).**
|
|
345
357
|
|
|
346
358
|
## Phase 6: QE (Testing phase — automation)
|
|
347
359
|
|
|
@@ -352,13 +364,22 @@ User Request → PO → Business BA → Architect → Technical BA → Design (i
|
|
|
352
364
|
- **QE Lead (15+ yrs automation)**: Test strategy, framework choice, automation architecture, review test code. Output per epic: \`docs/sdlc/qe/{epic-slug}/\`
|
|
353
365
|
- **Senior QE (10+ yrs)**: Write automation tests per QE Lead's strategy. Output per epic: \`docs/sdlc/qe/{epic-slug}/\` (e.g. automation/ or test files there)
|
|
354
366
|
|
|
355
|
-
**Output**: Automation tests, test report. **Handoff to
|
|
367
|
+
**Output**: Automation tests, test report. **Handoff to Security + Principle Engineer.**
|
|
356
368
|
|
|
357
|
-
## Phase
|
|
369
|
+
## Phase 8: Security + Principle Engineer (audit → fix loop)
|
|
358
370
|
|
|
359
|
-
**Trigger**: After QE sign-off.
|
|
371
|
+
**Trigger**: After QE testing sign-off.
|
|
372
|
+
**Roles** (can run in parallel):
|
|
373
|
+
- **Security team**: Audit security risk (OWASP, auth, secrets, infra). Output: \`docs/sdlc/security/\`
|
|
374
|
+
- **Principle Engineer**: Audit logic, architecture alignment, correctness. Output: \`docs/sdlc/principle-engineer/\`
|
|
375
|
+
|
|
376
|
+
**Fix loop**: If issues found → **Dev fixes** → re-audit by Security + Principle Engineer. **Repeat until all issues resolved.** Only when sign-off → **Handoff to Deploy.**
|
|
377
|
+
|
|
378
|
+
## Phase 9: Deploy
|
|
379
|
+
|
|
380
|
+
**Trigger**: After Security + Principle Engineer sign-off.
|
|
360
381
|
**Role**: Deploy with **Docker Compose** (local/staging) and **Kubernetes** (production).
|
|
361
|
-
**Output**: \`docs/sdlc/deploy/\` — docker-compose.yml, k8s manifests.
|
|
382
|
+
**Output**: \`docs/sdlc/deploy/\` — docker-compose.yml, k8s manifests.
|
|
362
383
|
|
|
363
384
|
## Quick Phase Checklist
|
|
364
385
|
|
|
@@ -367,15 +388,17 @@ User Request → PO → Business BA → Architect → Technical BA → Design (i
|
|
|
367
388
|
| 0 | Discovery | Raw request |
|
|
368
389
|
| 1 | PO | PRD, user stories |
|
|
369
390
|
| 2 | Business BA | FRS, process flows |
|
|
370
|
-
| 3 |
|
|
371
|
-
| 4 |
|
|
372
|
-
|
|
|
373
|
-
|
|
|
374
|
-
|
|
|
375
|
-
|
|
|
376
|
-
|
|
|
377
|
-
|
|
378
|
-
|
|
391
|
+
| 3 | Design (if app/web) | Design specs + wireframes; PO+BA review until approved |
|
|
392
|
+
| 4 | Architect | ADRs, system diagrams |
|
|
393
|
+
| 5 | Technical BA | API specs, tech breakdown |
|
|
394
|
+
| 6 | QE (docs) | Test plan, test cases |
|
|
395
|
+
| 7 | Dev | Code, unit tests (≥90%) |
|
|
396
|
+
| 8 | QE (testing + UAT) | QE Lead (15+ yrs automation) + Senior QE (10+ yrs), automation, UAT, sign-off |
|
|
397
|
+
| 9 | Security + Principle Engineer | Security + logic audit; fix loop until all issues resolved; sign-off → Deploy |
|
|
398
|
+
| 10 | Deploy | Docker Compose + K8s |
|
|
399
|
+
| 11 | Maintenance | Monitoring, bug fixes, patches, dependency updates |
|
|
400
|
+
|
|
401
|
+
**Sub-agents**: Each role = one sub-agent. Design before Architect (UX drives tech). See docs/sdlc/agents/
|
|
379
402
|
See reference.md for templates.
|
|
380
403
|
`;
|
|
381
404
|
|
|
@@ -385,7 +408,7 @@ const CURSOR_REFERENCE_MD = `# SDLC Workflow — Reference
|
|
|
385
408
|
|
|
386
409
|
- **PO**: \`docs/sdlc/po/{epic-slug}/\` — one folder per epic. Files: epic-brief.md, user-stories.md. Do not put all epics in one file.
|
|
387
410
|
- **Business BA**: \`docs/sdlc/ba/business/{epic-slug}/\` — same slug as PO. Files: functional-requirements.md, process-flows.md. Do not merge all epics into one file.
|
|
388
|
-
- **Design (if app/web)**: \`docs/sdlc/design/{epic-slug}/\` — same slug as PO/BA.
|
|
411
|
+
- **Design (if app/web)**: \`docs/sdlc/design/{epic-slug}/\` — same slug as PO/BA. Design specs (Markdown) + optional HTML wireframes; PO+BA review until approved.
|
|
389
412
|
- **QE**: \`docs/sdlc/qe/{epic-slug}/\` — same slug as PO/BA. Files: test-plan.md, test-cases.md, automation artifacts. Do not put all epics in one file.
|
|
390
413
|
|
|
391
414
|
## PO: Epic Brief Template
|
|
@@ -402,7 +425,7 @@ FR-001: [Title] — Description, Trigger, Process Flow, Output, Constraints
|
|
|
402
425
|
POST /api/v1/[resource] — Purpose, Request, Response, Contract
|
|
403
426
|
|
|
404
427
|
## Design (if app/web)
|
|
405
|
-
|
|
428
|
+
Design specs (Markdown) + optional HTML wireframes from idea + PO + BA (before Architect; UX drives tech). Output: docs/sdlc/design/{epic-slug}/. PO + BA review until approved; loop if not aligned. Handoff to Architect.
|
|
406
429
|
|
|
407
430
|
## QE: Test Case
|
|
408
431
|
TC-001: [Scenario] — Precondition, Steps, Expected, Links to AC
|
|
@@ -416,11 +439,16 @@ TC-001: [Scenario] — Precondition, Steps, Expected, Links to AC
|
|
|
416
439
|
- Senior Dev (10+ yrs): implement, Unit Test ≥90% → docs/sdlc/dev/senior-developer/
|
|
417
440
|
- By project (all Senior 10+ yrs): Senior Frontend, Backend, Mobile, Embedded, Data/ML, Platform → docs/sdlc/dev/{role}/
|
|
418
441
|
|
|
419
|
-
##
|
|
420
|
-
|
|
442
|
+
## Security + Principle Engineer (after implementation)
|
|
443
|
+
- Security team: audit security risk → docs/sdlc/security/
|
|
444
|
+
- Principle Engineer: audit logic, architecture → docs/sdlc/principle-engineer/
|
|
445
|
+
- **Fix loop**: If issues → Dev fixes → re-audit; repeat until all resolved. Sign-off → Deploy
|
|
421
446
|
|
|
422
447
|
## Deploy
|
|
423
|
-
After
|
|
448
|
+
After Security + Principle Engineer sign-off → Docker Compose + K8s. See docs/sdlc/deploy/
|
|
449
|
+
|
|
450
|
+
## Maintenance
|
|
451
|
+
After Deploy → ongoing: monitoring, bug fixes, patches, dependency updates, performance tuning. Significant new features → loop back to PO for new epic. See docs/sdlc/maintenance/
|
|
424
452
|
`;
|
|
425
453
|
|
|
426
454
|
const AGENTS_MD_CONTENT = `## SDLC Workflow
|
|
@@ -431,32 +459,36 @@ When working on requirements, features, or handoffs, follow these phases:
|
|
|
431
459
|
|
|
432
460
|
1. **PO** — PRD, user stories → docs/sdlc/po/{epic-slug}/ (one folder per epic)
|
|
433
461
|
2. **Business BA** — FRS, process flows → docs/sdlc/ba/business/{epic-slug}/ (one folder per epic)
|
|
434
|
-
3. **
|
|
435
|
-
4. **
|
|
436
|
-
5. **
|
|
462
|
+
3. **Design (if app/web)** — Design specs + wireframes → docs/sdlc/design/{epic-slug}/; **PO + BA review** until approved
|
|
463
|
+
4. **Architect** — ADRs, diagrams → docs/sdlc/architecture/
|
|
464
|
+
5. **Technical BA** — API specs, team breakdown → docs/sdlc/ba/technical/
|
|
437
465
|
6. **QE (docs)** — Test plan, test cases → docs/sdlc/qe/{epic-slug}/ (one folder per epic)
|
|
438
466
|
7. **Dev** — After docs phase → **run implementation immediately**. Tech Lead + Senior Dev → docs/sdlc/dev/{role}/
|
|
439
|
-
8. **QE (testing)** — QE Lead (15+ yrs automation) + Senior QE (10+ yrs) → docs/sdlc/qe/{epic-slug}/ (same folder per epic)
|
|
440
|
-
9. **
|
|
467
|
+
8. **QE (testing + UAT)** — QE Lead (15+ yrs automation) + Senior QE (10+ yrs) + UAT → docs/sdlc/qe/{epic-slug}/ (same folder per epic)
|
|
468
|
+
9. **Security + Principle Engineer** — Security + logic audit; **fix loop** (Dev fixes → re-audit) until all issues resolved; sign-off before Deploy
|
|
469
|
+
10. **Deploy** — Docker Compose + K8s → docs/sdlc/deploy/
|
|
470
|
+
11. **Maintenance** — Monitoring, bug fixes, patches, dependency updates → docs/sdlc/maintenance/
|
|
441
471
|
|
|
442
|
-
Design
|
|
472
|
+
Design before Architect (UX drives tech). After the docs phase, the Dev team runs implementation immediately. See docs/sdlc/agents/
|
|
443
473
|
`;
|
|
444
474
|
|
|
445
475
|
const CLAUDE_SDLC_CONTENT = `## SDLC Workflow
|
|
446
476
|
|
|
447
|
-
**Trigger on idea:** When the user sends an idea, feature request, or requirement, run the pipeline continuously: Phase 1 (PO) → 2 → … →
|
|
477
|
+
**Trigger on idea:** When the user sends an idea, feature request, or requirement, run the pipeline continuously: Phase 1 (PO) → 2 → … → Deploy → Maintenance. One role per phase (single agent = switch role each phase). Do not stop after one phase unless the user asks.
|
|
448
478
|
|
|
449
|
-
1. **PO** — PRD, user stories → docs/sdlc/po/{epic-slug}/ (one folder per epic)
|
|
450
|
-
2. **Business BA** — FRS, process flows → docs/sdlc/ba/business/{epic-slug}/ (one folder per epic)
|
|
451
|
-
3. **
|
|
452
|
-
4. **
|
|
453
|
-
5. **
|
|
479
|
+
1. **PO** — PRD, user stories, feasibility assessment → docs/sdlc/po/{epic-slug}/ (one folder per epic)
|
|
480
|
+
2. **Business BA** — FRS, NFR, process flows → docs/sdlc/ba/business/{epic-slug}/ (one folder per epic)
|
|
481
|
+
3. **Design (if app/web)** — Design specs + wireframes → docs/sdlc/design/{epic-slug}/; **PO + BA review** until approved
|
|
482
|
+
4. **Architect** — ADRs, diagrams, security by design → docs/sdlc/architecture/
|
|
483
|
+
5. **Technical BA** — API specs, team breakdown → docs/sdlc/ba/technical/
|
|
454
484
|
6. **QE (docs)** — Test plan, test cases → docs/sdlc/qe/{epic-slug}/ (one folder per epic)
|
|
455
|
-
7. **Dev** — After docs phase → **run implementation immediately**. Tech Lead + Senior Dev → docs/sdlc/dev/{role}
|
|
456
|
-
8. **QE (testing)** — QE Lead (15+ yrs automation) + Senior QE (10+ yrs) → docs/sdlc/qe/{epic-slug}/ (same folder per epic)
|
|
457
|
-
9. **
|
|
485
|
+
7. **Dev** — After docs phase → **run implementation immediately**. Tech Lead + Senior Dev → docs/sdlc/dev/{role}/. Security shift-left: OWASP checks, dependency audit in CI
|
|
486
|
+
8. **QE (testing + UAT)** — QE Lead (15+ yrs automation) + Senior QE (10+ yrs) + UAT → docs/sdlc/qe/{epic-slug}/ (same folder per epic)
|
|
487
|
+
9. **Security + Principle Engineer** — Security + logic audit; **fix loop** (Dev fixes → re-audit) until all issues resolved; sign-off before Deploy
|
|
488
|
+
10. **Deploy** — Docker Compose + K8s → docs/sdlc/deploy/
|
|
489
|
+
11. **Maintenance** — Monitoring, bug fixes, patches, dependency updates → docs/sdlc/maintenance/
|
|
458
490
|
|
|
459
|
-
Design
|
|
491
|
+
Design before Architect (UX drives tech). After the docs phase, Dev runs implementation immediately. See docs/sdlc/agents/
|
|
460
492
|
`;
|
|
461
493
|
|
|
462
494
|
const SDLC_WORKFLOW_MD = `# SDLC Workflow (Multi-Role)
|
|
@@ -473,7 +505,7 @@ For Cursor, see .cursor/rules/sdlc-workflow.mdc
|
|
|
473
505
|
## Flow
|
|
474
506
|
|
|
475
507
|
\`\`\`
|
|
476
|
-
User Request → PO → Business BA →
|
|
508
|
+
User Request → PO → Business BA → Design (if app/web) → Architect → Technical BA → QE (docs) → Dev → QE (testing + UAT) → Security + PE audit → [fix loop] → Deploy → Maintenance
|
|
477
509
|
\`\`\`
|
|
478
510
|
|
|
479
511
|
## Phase Checklist
|
|
@@ -483,59 +515,76 @@ User Request → PO → Business BA → Architect → Technical BA → Design (i
|
|
|
483
515
|
| 0 | Discovery | Raw request |
|
|
484
516
|
| 1 | PO | PRD, user stories |
|
|
485
517
|
| 2 | Business BA | FRS, process flows |
|
|
486
|
-
| 3 |
|
|
487
|
-
| 4 |
|
|
488
|
-
|
|
|
489
|
-
|
|
|
490
|
-
|
|
|
491
|
-
|
|
|
492
|
-
|
|
|
493
|
-
|
|
494
|
-
|
|
518
|
+
| 3 | Design (if app/web) | Design specs + wireframes; PO+BA review until approved |
|
|
519
|
+
| 4 | Architect | ADRs, system diagrams |
|
|
520
|
+
| 5 | Technical BA | API specs, tech breakdown |
|
|
521
|
+
| 6 | QE (docs) | Test plan, test cases |
|
|
522
|
+
| 7 | Dev | Code, unit tests (≥90%) |
|
|
523
|
+
| 8 | QE (testing + UAT) | QE Lead (15+ yrs automation) + Senior QE (10+ yrs), automation, UAT, sign-off |
|
|
524
|
+
| 9 | Security + Principle Engineer | Security + logic audit; fix loop until all issues resolved; sign-off → Deploy |
|
|
525
|
+
| 10 | Deploy | Docker Compose + K8s |
|
|
526
|
+
| 11 | Maintenance | Monitoring, bug fixes, patches, dependency updates |
|
|
527
|
+
|
|
528
|
+
**Sub-agents**: Each role runs as a sub-agent. See docs/sdlc/agents/
|
|
495
529
|
|
|
496
530
|
## Phase Details
|
|
497
531
|
|
|
498
532
|
### Phase 1: PO
|
|
499
|
-
-
|
|
533
|
+
- Feasibility study (technical, operational, economic), epic brief, user stories, acceptance criteria
|
|
500
534
|
- Output: \`docs/sdlc/po/{epic-slug}/\` — **one folder per epic**; do not put all epics in one file
|
|
501
535
|
|
|
502
536
|
### Phase 2: Business BA
|
|
503
|
-
- Functional requirements, process flows, use cases
|
|
537
|
+
- Functional requirements (FR), **non-functional requirements (NFR)** (performance, scalability, availability, security, usability), process flows, use cases
|
|
504
538
|
- Output: \`docs/sdlc/ba/business/{epic-slug}/\` — **one folder per epic** (same slug as PO); do not merge into one file
|
|
505
539
|
|
|
506
|
-
### Phase 3:
|
|
507
|
-
-
|
|
540
|
+
### Phase 3: Design (optional — app/web only)
|
|
541
|
+
- Create design specs (Markdown) + optional HTML wireframes based on idea + PO + BA docs. **Design before Architect so UX drives tech.**
|
|
542
|
+
- Output: \`docs/sdlc/design/{epic-slug}/\` — design-spec.md + optional wireframes/
|
|
543
|
+
- **PO + Business BA review**: Both check design vs epic/FRS; if not aligned → feedback → redesign loop until approved
|
|
544
|
+
- When approved → handoff to Architect
|
|
545
|
+
|
|
546
|
+
### Phase 4: Architect
|
|
547
|
+
- System context, container diagram, ADRs, tech stack, **security by design** (threat model, auth architecture, encryption, secrets mgmt). Input: Business BA (FR + NFR) + Design (if app/web)
|
|
508
548
|
- Output: \`docs/sdlc/architecture/\`
|
|
509
549
|
|
|
510
|
-
### Phase
|
|
511
|
-
- API specs, DB schema, team breakdown
|
|
550
|
+
### Phase 5: Technical BA
|
|
551
|
+
- API specs, DB schema, team breakdown. Input: Architect + Design (if app/web)
|
|
512
552
|
- Output: \`docs/sdlc/ba/technical/\`
|
|
513
553
|
|
|
514
|
-
### Phase 4b: Design (optional — app/web only)
|
|
515
|
-
- Invoke **Pencil.dev** (MCP) to design based on idea + PO + BA + Technical BA docs
|
|
516
|
-
- Output: \`docs/sdlc/design/{epic-slug}/\` — .pen designs
|
|
517
|
-
- **PO + Business BA review**: Both check design vs epic/FRS; if not aligned → feedback → redesign loop until approved
|
|
518
|
-
- When approved → handoff to QE + Dev
|
|
519
|
-
|
|
520
554
|
### Phase 5a: QE (Docs)
|
|
521
555
|
- Test plan, test cases
|
|
522
556
|
- Output: \`docs/sdlc/qe/{epic-slug}/\` — **one folder per epic**; do not put all epics in one file
|
|
523
557
|
- **After docs phase → Dev team runs implementation immediately** (no extra gate)
|
|
524
558
|
|
|
525
559
|
### Phase 5b: Dev Teams
|
|
526
|
-
- **Tech Lead (15+ yrs)**: Tech stack, review & merge. Output: \`docs/sdlc/dev/tech-lead/\`
|
|
560
|
+
- **Tech Lead (15+ yrs)**: Tech stack, review & merge, **security review (Shift Left)**: OWASP check, dependency audit, SAST in CI. Output: \`docs/sdlc/dev/tech-lead/\`
|
|
527
561
|
- **Implementation roles** (all Senior 10+ yrs; use only what applies): Senior Dev, Senior Frontend, Senior Backend, Senior Mobile, Senior Embedded, Senior Data/ML, Senior Platform → \`docs/sdlc/dev/{role}/\`. See \`implementation-roles.template.md\`.
|
|
528
|
-
- **Requirement**: Unit Test coverage **≥ 90
|
|
562
|
+
- **Requirement**: Unit Test coverage **≥ 90%**; security practices (input validation, no hardcoded secrets)
|
|
529
563
|
- **Then**: QE starts testing phase
|
|
530
564
|
|
|
531
|
-
### Phase 6: QE (Testing — automation)
|
|
565
|
+
### Phase 6: QE (Testing — automation + UAT)
|
|
532
566
|
- **QE Lead (15+ yrs automation)**: Test strategy, framework choice, automation architecture; review test code. Output per epic: \`docs/sdlc/qe/{epic-slug}/\`
|
|
533
567
|
- **Senior QE (10+ yrs)**: Write automation tests per QE Lead's strategy. Output per epic: \`docs/sdlc/qe/{epic-slug}/\`
|
|
568
|
+
- **UAT (User Acceptance Testing)**: Verify implementation against original user stories and acceptance criteria from PO; confirm business requirements are met from end-user perspective. Output: \`qe/{epic-slug}/uat-results.md\`
|
|
569
|
+
- **Handoff to Security + Principle Engineer**
|
|
570
|
+
|
|
571
|
+
### Phase 7: Security + Principle Engineer (audit → fix loop)
|
|
572
|
+
- **Security team**: Audit security risk (OWASP, auth, secrets, infra). Output: \`docs/sdlc/security/\`
|
|
573
|
+
- **Principle Engineer**: Audit logic, architecture alignment, correctness. Output: \`docs/sdlc/principle-engineer/\`
|
|
574
|
+
- **Fix loop**: If issues found → Dev fixes → Security + PE re-audit. **Repeat until all issues resolved.** Sign-off → **Handoff to Deploy**
|
|
534
575
|
|
|
535
|
-
### Phase
|
|
536
|
-
- After
|
|
576
|
+
### Phase 8: Deploy
|
|
577
|
+
- After Security + Principle Engineer sign-off → deploy with **Docker Compose** (local/staging) and **Kubernetes** (production)
|
|
537
578
|
- Output: \`docs/sdlc/deploy/\` — docker-compose.yml, k8s/
|
|
538
579
|
|
|
580
|
+
### Phase 9: Maintenance
|
|
581
|
+
- **Monitoring**: Health checks, error tracking, alerting, SLA dashboards
|
|
582
|
+
- **Bug fixes**: Triage, fix, test, deploy per severity
|
|
583
|
+
- **Dependency updates**: Regular security patches, library upgrades
|
|
584
|
+
- **Performance tuning**: Monitor vs NFR targets; optimize bottlenecks
|
|
585
|
+
- **Feature iteration**: Small enhancements from feedback; significant scope → new PO epic
|
|
586
|
+
- Output: \`docs/sdlc/maintenance/\` — runbooks, incident logs
|
|
587
|
+
|
|
539
588
|
See [reference.md](./reference.md) for templates.
|
|
540
589
|
`;
|
|
541
590
|
|
|
@@ -545,25 +594,27 @@ const ORCHESTRATION_MD = `# Pipeline orchestration
|
|
|
545
594
|
|
|
546
595
|
When the user sends an **idea**, **feature request**, or **requirement** (e.g. "I want a login page", "We need an API for X"):
|
|
547
596
|
|
|
548
|
-
1. **Trigger the full pipeline** and run **Phase 1 → 2 → … →
|
|
597
|
+
1. **Trigger the full pipeline** and run **Phase 1 → 2 → … → 11 in sequence**.
|
|
549
598
|
2. **One role per phase:** For each phase, act only as that role, write outputs to the correct \`docs/sdlc/...\` folder, then **continue to the next phase** without asking the user to "run next step".
|
|
550
|
-
3. **Run through to
|
|
599
|
+
3. **Run through to Maintenance.** Do not stop after PO, BA, or Dev unless the user explicitly says to stop.
|
|
551
600
|
|
|
552
601
|
## How it runs (Cursor and similar)
|
|
553
602
|
|
|
554
|
-
There is **one agent** per conversation. It simulates the pipeline by **adopting one role per phase** in order: Phase 1 as PO only → Phase 2 as Business BA only → … → Phase
|
|
603
|
+
There is **one agent** per conversation. It simulates the pipeline by **adopting one role per phase** in order: Phase 1 as PO only → Phase 2 as Business BA only → … → Phase 11 as Maintenance. Do not mix roles in one step. If the tool later supports separate agents per phase, use that; otherwise this single-agent simulation is correct.
|
|
555
604
|
|
|
556
605
|
## Checklist per run
|
|
557
606
|
|
|
558
607
|
- [ ] Phase 1 PO: artifacts in \`docs/sdlc/po/{epic-slug}/\` (one folder per epic)
|
|
559
608
|
- [ ] Phase 2 Business BA: \`docs/sdlc/ba/business/{epic-slug}/\` (one folder per epic)
|
|
560
|
-
- [ ] Phase 3
|
|
561
|
-
- [ ] Phase 4
|
|
562
|
-
- [ ] Phase
|
|
563
|
-
- [ ] Phase
|
|
564
|
-
- [ ] Phase
|
|
565
|
-
- [ ] Phase
|
|
566
|
-
- [ ] Phase
|
|
609
|
+
- [ ] Phase 3 Design (if app/web): design specs + wireframes in \`docs/sdlc/design/{epic-slug}/\`; PO+BA review until approved
|
|
610
|
+
- [ ] Phase 4 Architect: \`docs/sdlc/architecture/\`
|
|
611
|
+
- [ ] Phase 5 Technical BA: \`docs/sdlc/ba/technical/\`
|
|
612
|
+
- [ ] Phase 6 QE docs: \`docs/sdlc/qe/{epic-slug}/\` (one folder per epic)
|
|
613
|
+
- [ ] Phase 7 Dev: code + unit tests, \`docs/sdlc/dev/\`
|
|
614
|
+
- [ ] Phase 8 QE testing + UAT: automation, UAT against user stories, sign-off → \`docs/sdlc/qe/{epic-slug}/\`
|
|
615
|
+
- [ ] Phase 9 Security + Principle Engineer: \`docs/sdlc/security/\`, \`docs/sdlc/principle-engineer/\`; fix loop until no issues; sign-off
|
|
616
|
+
- [ ] Phase 10 Deploy: \`docs/sdlc/deploy/\`, Docker Compose + K8s
|
|
617
|
+
- [ ] Phase 11 Maintenance: monitoring, bug fixes, patches, dependency updates → \`docs/sdlc/maintenance/\`
|
|
567
618
|
`;
|
|
568
619
|
|
|
569
620
|
const REFERENCE_MD = `# SDLC Workflow — Reference
|
|
@@ -577,8 +628,11 @@ Deploy: docs/sdlc/deploy/ (Docker Compose + K8s)
|
|
|
577
628
|
|
|
578
629
|
- **PO**: \`docs/sdlc/po/{epic-slug}/\` — one folder per epic. Files: epic-brief.md, user-stories.md. Do not put all epics in one file.
|
|
579
630
|
- **Business BA**: \`docs/sdlc/ba/business/{epic-slug}/\` — same slug as PO. Files: functional-requirements.md, process-flows.md. Do not merge all epics into one file.
|
|
580
|
-
- **Design (if app/web)**: \`docs/sdlc/design/{epic-slug}/\` —
|
|
631
|
+
- **Design (if app/web)**: \`docs/sdlc/design/{epic-slug}/\` — design specs (Markdown) + optional HTML wireframes; PO+BA review until approved.
|
|
581
632
|
- **QE**: \`docs/sdlc/qe/{epic-slug}/\` — same slug as PO/BA. Files: test-plan.md, test-cases.md, automation. Do not put all epics in one file.
|
|
633
|
+
- **Security**: \`docs/sdlc/security/\` — security audit; fix loop until no issues
|
|
634
|
+
- **Principle Engineer**: \`docs/sdlc/principle-engineer/\` — logic audit; fix loop until no issues
|
|
635
|
+
- **Maintenance**: \`docs/sdlc/maintenance/\` — monitoring, bug fixes, patches, runbooks
|
|
582
636
|
`;
|
|
583
637
|
|
|
584
638
|
const AGENTS_README = `# Sub-Agents
|
|
@@ -589,9 +643,9 @@ Every role in the SDLC runs as a **sub-agent**. Each phase is assigned to a corr
|
|
|
589
643
|
|------|-----------|--------|--------|
|
|
590
644
|
| PO | po | User request | docs/sdlc/po/{epic-slug}/ (one folder per epic) |
|
|
591
645
|
| Business BA | business-ba | docs/sdlc/po/{epic-slug}/ | docs/sdlc/ba/business/{epic-slug}/ (one folder per epic) |
|
|
592
|
-
|
|
|
593
|
-
|
|
|
594
|
-
|
|
|
646
|
+
| Design (if app/web) | design | docs/sdlc/po + docs/sdlc/ba/business/ | docs/sdlc/design/{epic-slug}/; PO+BA review until approved |
|
|
647
|
+
| Architect | architect | docs/sdlc/ba/business/ + design (if any) | docs/sdlc/architecture/ |
|
|
648
|
+
| Technical BA | technical-ba | docs/sdlc/architecture/ + design (if any) | docs/sdlc/ba/technical/ |
|
|
595
649
|
| QE (docs) | qe-docs | docs/sdlc/ba/technical/ (+ design if any) | docs/sdlc/qe/{epic-slug}/ (one folder per epic) |
|
|
596
650
|
| Tech Lead | tech-lead | Technical spec | Review, merge, docs/sdlc/dev/tech-lead/ |
|
|
597
651
|
| Senior Dev | senior-dev | Spec + test plan | After docs → run implementation immediately. Code, unit tests (≥90%) |
|
|
@@ -603,16 +657,55 @@ Every role in the SDLC runs as a **sub-agent**. Each phase is assigned to a corr
|
|
|
603
657
|
| Senior Platform | platform | Infra spec | CI/CD, observability, docs/sdlc/dev/platform/ |
|
|
604
658
|
| QE Lead | qe-lead | Test plan | 15+ yrs automation: strategy, framework, review → docs/sdlc/qe/{epic-slug}/ |
|
|
605
659
|
| Senior QE | senior-qe | Test plan + framework | Automation tests → docs/sdlc/qe/{epic-slug}/ |
|
|
606
|
-
|
|
|
660
|
+
| Security | security | Code, infra | Security audit → docs/sdlc/security/; fix loop until no issues |
|
|
661
|
+
| Principle Engineer | principle-engineer | Code, architecture | Logic audit → docs/sdlc/principle-engineer/; fix loop until no issues |
|
|
662
|
+
| Deploy | deploy | Security + PE sign-off (after fix loop) | Docker Compose + K8s, docs/sdlc/deploy/ |
|
|
663
|
+
| Maintenance | maintenance | Live application | Monitoring, bug fixes, patches, docs/sdlc/maintenance/ |
|
|
607
664
|
|
|
608
665
|
Orchestrator: run each sub-agent in order; hand off output → input of the next sub-agent.
|
|
609
666
|
|
|
610
667
|
**Trigger:** On user idea/request, run the full pipeline (see docs/sdlc/ORCHESTRATION.md). One role per phase; single agent simulates by switching role each phase. Do not stop after one phase until Deploy unless the user asks.
|
|
611
668
|
`;
|
|
612
669
|
|
|
670
|
+
const SECURITY_README = `# Security Team
|
|
671
|
+
|
|
672
|
+
**When:** After implementation (Dev) and QE testing. **Before** Deploy.
|
|
673
|
+
|
|
674
|
+
**Role:** Audit security risk in code, APIs, infra, and configuration. Identify vulnerabilities and recommend mitigations.
|
|
675
|
+
|
|
676
|
+
**Fix loop:** If issues found → Dev fixes → re-audit. Repeat until all issues resolved; then sign-off to Deploy.
|
|
677
|
+
|
|
678
|
+
## Detailed tasks
|
|
679
|
+
|
|
680
|
+
- [ ] **Read implementation**: Code, API specs, infra configs (docker-compose, k8s)
|
|
681
|
+
- [ ] **Security audit**: OWASP Top 10, auth/authz, injection, XSS, CSRF, secrets exposure, dependency vulns
|
|
682
|
+
- [ ] **Infra/ops security**: Network, TLS, RBAC, secrets management
|
|
683
|
+
- [ ] **Report**: Findings, severity, remediation; output to \`docs/sdlc/security/\`
|
|
684
|
+
- [ ] **Fix loop**: If critical/high issues found → Dev fixes → re-audit. **Repeat until all issues resolved**; then sign-off to Deploy.
|
|
685
|
+
`;
|
|
686
|
+
|
|
687
|
+
const PRINCIPLE_ENGINEER_README = `# Principle Engineer
|
|
688
|
+
|
|
689
|
+
**When:** After implementation (Dev) and QE testing. **Before** Deploy.
|
|
690
|
+
|
|
691
|
+
**Role:** Audit logic, architecture alignment, design decisions, and technical quality. Ensure correctness and consistency with specs.
|
|
692
|
+
|
|
693
|
+
**Fix loop:** If issues found → Dev fixes → re-audit. Repeat until all issues resolved; then sign-off to Deploy.
|
|
694
|
+
|
|
695
|
+
## Detailed tasks
|
|
696
|
+
|
|
697
|
+
- [ ] **Read implementation**: Code, architecture ADRs, Technical BA spec
|
|
698
|
+
- [ ] **Logic audit**: Business logic correctness, edge cases, error handling, data flow
|
|
699
|
+
- [ ] **Architecture audit**: Alignment with ADRs, patterns, scalability, maintainability
|
|
700
|
+
- [ ] **Report**: Findings, recommendations; output to \`docs/sdlc/principle-engineer/\`
|
|
701
|
+
- [ ] **Fix loop**: If critical logic/arch issues found → Dev fixes → re-audit. **Repeat until all issues resolved**; then sign-off to Deploy.
|
|
702
|
+
`;
|
|
703
|
+
|
|
613
704
|
const DEPLOY_README = `# Deploy
|
|
614
705
|
|
|
615
|
-
After the pipeline completes (
|
|
706
|
+
After the pipeline completes (Security + Principle Engineer sign-off, after fix loop until no issues), deploy immediately with:
|
|
707
|
+
|
|
708
|
+
**After Deploy → Maintenance phase**: monitoring, bug fixes, patches, dependency updates.
|
|
616
709
|
|
|
617
710
|
- **Docker Compose** — local / staging: \`docker compose up -d\`
|
|
618
711
|
- **Kubernetes** — production: \`kubectl apply -f k8s/\`
|
|
@@ -724,6 +817,12 @@ const PO_EPIC_TEMPLATE = `# Epic: [Name]
|
|
|
724
817
|
## Priority
|
|
725
818
|
Must have / Should have / Could have
|
|
726
819
|
|
|
820
|
+
## Feasibility Assessment
|
|
821
|
+
- **Technical**: [Can we build this with current tech/team? Any unknowns?]
|
|
822
|
+
- **Operational**: [Can we deploy, run, and support this? Any ops constraints?]
|
|
823
|
+
- **Economic**: [ROI justification; cost vs. value]
|
|
824
|
+
- **Go / No-go**: [Recommended | Needs further investigation | Not recommended]
|
|
825
|
+
|
|
727
826
|
## Dependencies & Risks
|
|
728
827
|
- ...
|
|
729
828
|
`;
|
|
@@ -738,6 +837,7 @@ const PO_README = `# PO (Product Owner)
|
|
|
738
837
|
|
|
739
838
|
## Detailed tasks
|
|
740
839
|
|
|
840
|
+
- [ ] **Feasibility study**: Assess technical feasibility (can we build it?), operational feasibility (can we run it?), economic feasibility (is the ROI worth it?). Document go/no-go recommendation
|
|
741
841
|
- [ ] **Clarify vision**: Capture business problem, goals, success metrics
|
|
742
842
|
- [ ] **Define scope**: Boundaries, in/out of scope, MVP vs later
|
|
743
843
|
- [ ] **Write epic brief**: Problem, success metrics, high-level approach, project type
|
|
@@ -767,6 +867,18 @@ const BA_FR_TEMPLATE = `## FR-001: [Title]
|
|
|
767
867
|
|
|
768
868
|
**Constraints**: [Compliance, SLA, etc.]
|
|
769
869
|
|
|
870
|
+
---
|
|
871
|
+
|
|
872
|
+
## NFR-001: [Title]
|
|
873
|
+
|
|
874
|
+
**Category**: [Performance | Scalability | Availability | Security | Usability | Accessibility | Compliance — pick one]
|
|
875
|
+
|
|
876
|
+
**Description**: [What quality attribute the system must meet]
|
|
877
|
+
|
|
878
|
+
**Metric / Target**: [e.g. response time < 200ms p95, 99.9% uptime, WCAG 2.1 AA]
|
|
879
|
+
|
|
880
|
+
**Measurement**: [How to verify — load test, monitoring, audit]
|
|
881
|
+
|
|
770
882
|
---
|
|
771
883
|
*Use for any project type: product feature (UI/API), library behaviour, CLI behaviour, data pipeline, or platform capability.*
|
|
772
884
|
`;
|
|
@@ -790,13 +902,14 @@ docs/sdlc/ba/business/
|
|
|
790
902
|
|
|
791
903
|
## Detailed tasks
|
|
792
904
|
|
|
793
|
-
- [ ] **Read PO outputs**: Epic brief, user stories, acceptance criteria
|
|
905
|
+
- [ ] **Read PO outputs**: Epic brief, user stories, acceptance criteria, feasibility assessment
|
|
794
906
|
- [ ] **Define functional requirements**: For each requirement: type, description, trigger, process flow, output, constraints (use FR-001, FR-002...)
|
|
907
|
+
- [ ] **Define non-functional requirements (NFR)**: Performance (response time, throughput), scalability (load targets), availability (SLA/uptime), security (auth, encryption, compliance), usability, accessibility. Use NFR-001, NFR-002...
|
|
795
908
|
- [ ] **Document process flows**: Step-by-step business flows (e.g. BPMN, flowcharts, numbered lists)
|
|
796
909
|
- [ ] **Write use cases**: Actor, goal, preconditions, main/alternate flows, postconditions
|
|
797
910
|
- [ ] **Maintain glossary**: Business terms, definitions, acronyms
|
|
798
|
-
- [ ] **Map to user stories**: Trace FRs to user stories / AC
|
|
799
|
-
- [ ] **Handoff to Architect**: Deliverables in \`ba/business/{epic-slug}/\`
|
|
911
|
+
- [ ] **Map to user stories**: Trace FRs + NFRs to user stories / AC
|
|
912
|
+
- [ ] **Handoff to Design (if app/web) or Architect**: Deliverables in \`ba/business/{epic-slug}/\`
|
|
800
913
|
|
|
801
914
|
Use functional-requirement.template.md for FRS items.
|
|
802
915
|
`;
|
|
@@ -903,6 +1016,7 @@ Templates support: HTTP API, library/SDK, CLI, and all project types (see api-sp
|
|
|
903
1016
|
## Detailed tasks
|
|
904
1017
|
|
|
905
1018
|
- [ ] **Read Architect outputs**: ADRs, context/container diagrams, tech stack
|
|
1019
|
+
- [ ] **Read Design (if app/web)**: design-spec.md + wireframes — design informs API contracts, screen specs
|
|
906
1020
|
- [ ] **API/interface spec**: For each endpoint/class/command: purpose, request/response, contract (OpenAPI, TS types, CLI help)
|
|
907
1021
|
- [ ] **DB schema**: Tables, columns, indexes, constraints; migrations approach
|
|
908
1022
|
- [ ] **Team breakdown**: Map scope to teams (Backend, Frontend, Mobile, etc.) per project type; dependencies
|
|
@@ -937,11 +1051,13 @@ Use adr.template.md for new ADRs.
|
|
|
937
1051
|
## Detailed tasks
|
|
938
1052
|
|
|
939
1053
|
- [ ] **Read Business BA outputs**: Functional requirements, process flows, use cases
|
|
1054
|
+
- [ ] **Read Design (if app/web)**: design-spec.md in \`design/{epic-slug}/\` — design informs architecture
|
|
940
1055
|
- [ ] **Context diagram**: System boundary, external actors, integrations
|
|
941
1056
|
- [ ] **Container diagram**: Main components/services and their responsibilities
|
|
942
1057
|
- [ ] **Tech stack decisions**: Languages, frameworks, databases; document in ADRs
|
|
943
1058
|
- [ ] **ADR per decision**: Context, decision, consequences (scope: backend, frontend, mobile, etc.)
|
|
944
|
-
- [ ] **Non-functional alignment**: Performance, security, scalability, compliance
|
|
1059
|
+
- [ ] **Non-functional alignment**: Performance, security, scalability, compliance — reference NFRs from Business BA
|
|
1060
|
+
- [ ] **Security by design (Shift Left)**: Threat model (STRIDE/attack surface), auth/authz architecture, data encryption at rest/transit, secrets management approach, dependency security policy. Document in ADR
|
|
945
1061
|
- [ ] **Handoff to Technical BA**: Architecture docs, ADRs in \`architecture/\`
|
|
946
1062
|
`;
|
|
947
1063
|
|
|
@@ -982,7 +1098,8 @@ const QE_README = `# QE (Quality Engineering)
|
|
|
982
1098
|
|
|
983
1099
|
- [ ] **QE Lead**: Test strategy, framework, review test code
|
|
984
1100
|
- [ ] **Senior QE**: Write automation tests per test plan
|
|
985
|
-
- [ ] **
|
|
1101
|
+
- [ ] **UAT (User Acceptance Testing)**: Verify against original user stories and acceptance criteria from PO; confirm business requirements are met from end-user perspective. Document UAT results in \`qe/{epic-slug}/uat-results.md\`
|
|
1102
|
+
- [ ] **Sign-off**: Regression, coverage, UAT pass, release readiness in \`qe/{epic-slug}/\`
|
|
986
1103
|
|
|
987
1104
|
Example:
|
|
988
1105
|
\`\`\`
|
|
@@ -998,7 +1115,7 @@ docs/sdlc/qe/
|
|
|
998
1115
|
|
|
999
1116
|
Two phases:
|
|
1000
1117
|
1. **Docs phase** — Test plan, test cases per epic in \`qe/{epic-slug}/\`. Done → **Dev runs implementation immediately**.
|
|
1001
|
-
2. **Testing phase** — After Dev completes unit tests: QE Lead (15+ yrs automation: strategy, framework, review) + Senior QE (automation) output to the same \`qe/{epic-slug}/\` (or subfolders there).
|
|
1118
|
+
2. **Testing phase** — After Dev completes unit tests: QE Lead (15+ yrs automation: strategy, framework, review) + Senior QE (automation) + **UAT** (verify against user stories/AC) output to the same \`qe/{epic-slug}/\` (or subfolders there).
|
|
1002
1119
|
|
|
1003
1120
|
Use test-case.template.md for test cases.
|
|
1004
1121
|
`;
|
|
@@ -1045,25 +1162,99 @@ const QE_SENIOR_README = `# Senior QE (10+ years exp)
|
|
|
1045
1162
|
|
|
1046
1163
|
const DESIGN_README = `# Design (optional — app/web projects only)
|
|
1047
1164
|
|
|
1048
|
-
**When:** After
|
|
1165
|
+
**When:** After Business BA, **before** Architect and Technical BA. **Skip** for API-only, library, CLI, data/ML, platform projects without UI.
|
|
1166
|
+
|
|
1167
|
+
**Why before Architect:** UX drives technical decisions — design informs architecture and API specs.
|
|
1168
|
+
|
|
1169
|
+
**One folder per epic:** \`docs/sdlc/design/{epic-slug}/\` — same slug as PO/BA. Store design specs and wireframes there.
|
|
1170
|
+
|
|
1171
|
+
## Output format
|
|
1049
1172
|
|
|
1050
|
-
**
|
|
1173
|
+
- **design-spec.md** — Markdown design spec: screen inventory, component hierarchy, user flows, responsive breakpoints, interaction notes.
|
|
1174
|
+
- **wireframes/*.html** (optional) — Static HTML/CSS wireframes; open in any browser, no external tools needed. Keep them simple (layout + structure, not pixel-perfect).
|
|
1051
1175
|
|
|
1052
1176
|
## Flow
|
|
1053
1177
|
|
|
1054
|
-
1. **Design sub-agent
|
|
1055
|
-
2. **PO + Business BA review**: Both roles review the design against epic brief, user stories, functional requirements.
|
|
1178
|
+
1. **Design sub-agent**: Create UI/UX design specs based on idea + PO docs + Business BA FRS. Write \`design-spec.md\` describing every screen, component, and user flow. Optionally generate HTML wireframes for key screens.
|
|
1179
|
+
2. **PO + Business BA review**: Both roles review the design spec against epic brief, user stories, functional requirements.
|
|
1056
1180
|
3. **Loop until approved**: If design does not match idea/docs → return to step 1 with feedback; redesign. Repeat until PO and BA approve.
|
|
1057
|
-
4. **Handoff to
|
|
1181
|
+
4. **Handoff to Architect**: Once approved → proceed to Architect (design informs architecture and Technical BA).
|
|
1058
1182
|
|
|
1059
1183
|
## Detailed tasks
|
|
1060
1184
|
|
|
1061
|
-
- [ ] **
|
|
1062
|
-
- [ ] **
|
|
1185
|
+
- [ ] **Gather context**: Read PO epic brief, BA FRS, user stories as input
|
|
1186
|
+
- [ ] **Screen inventory**: List all screens/pages with purpose and key elements
|
|
1187
|
+
- [ ] **Component hierarchy**: Define reusable components, layout structure, navigation
|
|
1188
|
+
- [ ] **User flows**: Document step-by-step flows for each user story (include happy path + error states)
|
|
1189
|
+
- [ ] **Responsive breakpoints**: Define mobile / tablet / desktop behavior
|
|
1190
|
+
- [ ] **Write design-spec.md**: Full design spec in Markdown; output to \`design/{epic-slug}/\`
|
|
1191
|
+
- [ ] **HTML wireframes** (optional): Generate static HTML/CSS wireframes for key screens in \`design/{epic-slug}/wireframes/\`
|
|
1063
1192
|
- [ ] **PO review**: Check design aligns with epic brief, user stories, acceptance criteria
|
|
1064
1193
|
- [ ] **Business BA review**: Check design matches functional requirements, process flows
|
|
1065
1194
|
- [ ] **If not approved**: Capture feedback; loop back to design step with specific changes
|
|
1066
|
-
- [ ] **If approved**: Handoff to
|
|
1195
|
+
- [ ] **If approved**: Handoff to Architect; design in \`design/{epic-slug}/\`
|
|
1196
|
+
`;
|
|
1197
|
+
|
|
1198
|
+
const DESIGN_SPEC_TEMPLATE = `# Design Spec: [Epic Name]
|
|
1199
|
+
|
|
1200
|
+
## Overview
|
|
1201
|
+
[Brief description of what this design covers and the problem it solves]
|
|
1202
|
+
|
|
1203
|
+
## Screen Inventory
|
|
1204
|
+
|
|
1205
|
+
| # | Screen / Page | Purpose | Key Elements |
|
|
1206
|
+
|---|--------------|---------|--------------|
|
|
1207
|
+
| 1 | | | |
|
|
1208
|
+
|
|
1209
|
+
## User Flows
|
|
1210
|
+
|
|
1211
|
+
### Flow 1: [Flow Name]
|
|
1212
|
+
1. User lands on [screen]
|
|
1213
|
+
2. User [action] → [result]
|
|
1214
|
+
3. ...
|
|
1215
|
+
|
|
1216
|
+
**Happy path:** ...
|
|
1217
|
+
**Error states:** ...
|
|
1218
|
+
|
|
1219
|
+
## Component Hierarchy
|
|
1220
|
+
|
|
1221
|
+
\`\`\`
|
|
1222
|
+
App
|
|
1223
|
+
├── Layout
|
|
1224
|
+
│ ├── Header (nav, user menu)
|
|
1225
|
+
│ ├── Sidebar (optional)
|
|
1226
|
+
│ └── Main Content
|
|
1227
|
+
│ ├── [Component A]
|
|
1228
|
+
│ └── [Component B]
|
|
1229
|
+
└── Footer
|
|
1230
|
+
\`\`\`
|
|
1231
|
+
|
|
1232
|
+
## Screen Details
|
|
1233
|
+
|
|
1234
|
+
### Screen: [Name]
|
|
1235
|
+
- **URL / Route:** \`/path\`
|
|
1236
|
+
- **Purpose:** ...
|
|
1237
|
+
- **Layout:** [description or ASCII wireframe]
|
|
1238
|
+
- **Components:** [list key components]
|
|
1239
|
+
- **Interactions:** [click, hover, form submit behaviors]
|
|
1240
|
+
- **Data:** [what data is displayed / submitted]
|
|
1241
|
+
|
|
1242
|
+
## Responsive Breakpoints
|
|
1243
|
+
|
|
1244
|
+
| Breakpoint | Width | Layout Changes |
|
|
1245
|
+
|-----------|-------|---------------|
|
|
1246
|
+
| Mobile | < 768px | Single column, hamburger nav |
|
|
1247
|
+
| Tablet | 768–1024px | ... |
|
|
1248
|
+
| Desktop | > 1024px | Full layout |
|
|
1249
|
+
|
|
1250
|
+
## Design Tokens (optional)
|
|
1251
|
+
|
|
1252
|
+
- **Primary color:** ...
|
|
1253
|
+
- **Typography:** ...
|
|
1254
|
+
- **Spacing:** ...
|
|
1255
|
+
|
|
1256
|
+
## Notes
|
|
1257
|
+
[Any additional context, constraints, or decisions]
|
|
1067
1258
|
`;
|
|
1068
1259
|
|
|
1069
1260
|
const DEV_TECH_LEAD_README = `# Tech Lead (15+ years exp)
|
|
@@ -1079,7 +1270,8 @@ const DEV_TECH_LEAD_README = `# Tech Lead (15+ years exp)
|
|
|
1079
1270
|
- [ ] **Tech stack decision**: Languages, frameworks, libraries; document in ADR
|
|
1080
1271
|
- [ ] **Project setup**: Repo structure, tooling, lint, format, CI baseline
|
|
1081
1272
|
- [ ] **Code review**: Architecture alignment, patterns, test coverage, security
|
|
1082
|
-
- [ ] **
|
|
1273
|
+
- [ ] **Security review (Shift Left)**: OWASP Top 10 check, input validation, auth/authz, secrets not hardcoded, dependency audit (npm audit / pip audit / etc.), SAST scan in CI
|
|
1274
|
+
- [ ] **Merge approval**: Enforce quality gates before merge (tests, coverage, security scan pass)
|
|
1083
1275
|
- [ ] **Tech guidance**: Resolve technical disputes; mentor team
|
|
1084
1276
|
- [ ] **Output**: ADRs, review checklist in \`dev/tech-lead/\`
|
|
1085
1277
|
`;
|
|
@@ -1095,8 +1287,9 @@ const DEV_SENIOR_README = `# Senior Developer (10+ years exp)
|
|
|
1095
1287
|
|
|
1096
1288
|
- [ ] **Read Technical BA spec**: API, schema, team breakdown
|
|
1097
1289
|
- [ ] **Implement feature**: Code per spec; follow Tech Lead stack
|
|
1290
|
+
- [ ] **Security practices (Shift Left)**: Input validation, parameterized queries, no hardcoded secrets, follow Architect's security ADR
|
|
1098
1291
|
- [ ] **Unit tests**: Coverage **≥ 90%**; edge cases, error paths
|
|
1099
|
-
- [ ] **PR**: Lint, tests passing; request Tech Lead review
|
|
1292
|
+
- [ ] **PR**: Lint, tests, security scan passing; request Tech Lead review
|
|
1100
1293
|
- [ ] **Output**: Code + implementation notes in \`dev/senior-developer/\`
|
|
1101
1294
|
`;
|
|
1102
1295
|
|
|
@@ -1230,4 +1423,22 @@ const DEV_PLATFORM_README = `# Senior Platform (10+ years exp) — infra, CI/CD
|
|
|
1230
1423
|
- [ ] **Output**: Pipelines, infra code, runbooks in \`dev/platform/\`
|
|
1231
1424
|
`;
|
|
1232
1425
|
|
|
1426
|
+
const MAINTENANCE_README = `# Maintenance
|
|
1427
|
+
|
|
1428
|
+
**When:** After Deploy — ongoing throughout the product lifecycle.
|
|
1429
|
+
|
|
1430
|
+
**Role:** Monitor production health, fix bugs, apply patches, upgrade dependencies, and evolve features based on user feedback.
|
|
1431
|
+
|
|
1432
|
+
## Detailed tasks
|
|
1433
|
+
|
|
1434
|
+
- [ ] **Monitoring setup**: Health checks, error tracking (Sentry, Datadog, etc.), alerting, SLA dashboards
|
|
1435
|
+
- [ ] **Bug triage**: Prioritize production bugs; severity classification (P0–P3)
|
|
1436
|
+
- [ ] **Bug fixes**: Follow Dev workflow (branch → fix → unit test → PR → review → deploy)
|
|
1437
|
+
- [ ] **Dependency updates**: Regular security patches, library upgrades; run audit tools
|
|
1438
|
+
- [ ] **Performance tuning**: Monitor metrics vs NFR targets; optimize bottlenecks
|
|
1439
|
+
- [ ] **Feature iteration**: Small enhancements from user feedback → loop back to PO for new epics if scope is significant
|
|
1440
|
+
- [ ] **Documentation**: Keep runbooks, incident logs, and post-mortems up to date
|
|
1441
|
+
- [ ] **Output**: Patches, updates, runbooks in \`docs/sdlc/maintenance/\`
|
|
1442
|
+
`;
|
|
1443
|
+
|
|
1233
1444
|
main();
|