agentic-qe 3.7.18 → 3.7.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/.claude/skills/iterative-loop/SKILL.md +371 -0
  2. package/.claude/skills/skills-manifest.json +36 -8
  3. package/.claude/skills/validation-pipeline/SKILL.md +164 -0
  4. package/.claude/skills/validation-pipeline/evals/validation-pipeline.yaml +544 -0
  5. package/.claude/skills/validation-pipeline/schemas/output.json +193 -0
  6. package/.claude/skills/validation-pipeline/scripts/validate-config.json +34 -0
  7. package/CHANGELOG.md +7 -0
  8. package/README.md +5 -3
  9. package/assets/skills/skills-manifest.json +17 -1
  10. package/assets/skills/validation-pipeline/SKILL.md +164 -0
  11. package/assets/skills/validation-pipeline/evals/validation-pipeline.yaml +544 -0
  12. package/assets/skills/validation-pipeline/schemas/output.json +193 -0
  13. package/assets/skills/validation-pipeline/scripts/validate-config.json +34 -0
  14. package/dist/cli/bundle.js +9 -7
  15. package/dist/context/compiler.js +4 -0
  16. package/dist/context/index.d.ts +2 -0
  17. package/dist/context/index.js +2 -0
  18. package/dist/context/sources/defect-source.d.ts +17 -0
  19. package/dist/context/sources/defect-source.js +102 -0
  20. package/dist/context/sources/index.d.ts +2 -0
  21. package/dist/context/sources/index.js +2 -0
  22. package/dist/context/sources/requirements-source.d.ts +17 -0
  23. package/dist/context/sources/requirements-source.js +119 -0
  24. package/dist/coordination/task-executor.js +7 -1
  25. package/dist/coordination/yaml-pipeline-loader.d.ts +32 -0
  26. package/dist/coordination/yaml-pipeline-loader.js +389 -0
  27. package/dist/coordination/yaml-pipeline-registry.d.ts +61 -0
  28. package/dist/coordination/yaml-pipeline-registry.js +143 -0
  29. package/dist/governance/continue-gate-integration.js +1 -1
  30. package/dist/governance/feature-flags.js +2 -2
  31. package/dist/init/settings-merge.js +2 -0
  32. package/dist/mcp/bundle.js +8674 -1248
  33. package/dist/mcp/entry.js +21 -0
  34. package/dist/mcp/handlers/domain-handler-configs.js +11 -0
  35. package/dist/mcp/handlers/index.d.ts +2 -0
  36. package/dist/mcp/handlers/index.js +4 -0
  37. package/dist/mcp/handlers/pipeline-handlers.d.ts +75 -0
  38. package/dist/mcp/handlers/pipeline-handlers.js +208 -0
  39. package/dist/mcp/handlers/validation-pipeline-handler.d.ts +53 -0
  40. package/dist/mcp/handlers/validation-pipeline-handler.js +118 -0
  41. package/dist/mcp/protocol-server.js +167 -1
  42. package/dist/mcp/server.js +75 -1
  43. package/dist/workers/daemon.js +3 -2
  44. package/dist/workers/index.d.ts +6 -0
  45. package/dist/workers/index.js +6 -0
  46. package/dist/workers/workers/heartbeat-scheduler.d.ts +45 -0
  47. package/dist/workers/workers/heartbeat-scheduler.js +312 -0
  48. package/dist/workers/workers/index.d.ts +2 -1
  49. package/dist/workers/workers/index.js +2 -1
  50. package/package.json +1 -1
@@ -0,0 +1,371 @@
1
+ ---
2
+ name: "Iterative Loop"
3
+ description: "Implement continuous AI iteration loops for complex development tasks. Use when building features requiring test-driven refinement, implementing tasks with clear success criteria, or automating iterative improvement workflows. Based on the Ralph Wiggum technique from Claude Code plugins."
4
+ ---
5
+
6
+ # Iterative Loop
7
+
8
+ ## Overview
9
+
10
+ The Iterative Loop skill implements **continuous AI-driven development loops** that persist until completion criteria are met. Inspired by the Ralph Wiggum technique, this approach enables autonomous, self-correcting development cycles where the AI sees its previous work in files and git history, iteratively improving until success.
11
+
12
+ ## Core Philosophy
13
+
14
+ 1. **Iteration > Perfection** - Don't aim for perfect on first try; let the loop refine the work
15
+ 2. **Failures Are Data** - Each failure provides information to improve the next attempt
16
+ 3. **Clear Criteria** - Success must be objectively measurable (tests, metrics, validations)
17
+ 4. **Persistence Wins** - Keep trying until success; the loop handles retry logic automatically
18
+
19
+ ## Prerequisites
20
+
21
+ - Claude Code with session management
22
+ - Clear completion criteria (tests, linting, metrics)
23
+ - Version control (git) for tracking iterations
24
+
25
+ ---
26
+
27
+ ## Quick Start
28
+
29
+ ### Basic Iterative Development Pattern
30
+
31
+ ```bash
32
+ # Define task with clear completion criteria
33
+ TASK="Implement user authentication with JWT.
34
+ Success criteria:
35
+ - All unit tests pass
36
+ - Integration tests pass
37
+ - No TypeScript errors
38
+ - Security audit passes
39
+ Output <promise>COMPLETE</promise> when all criteria met."
40
+
41
+ # Execute iterative loop (conceptual)
42
+ while ! task_complete; do
43
+ claude_execute "$TASK"
44
+ check_completion_criteria
45
+ done
46
+ ```
47
+
48
+ ### AQE v3 Integration Example
49
+
50
+ ```bash
51
+ # Using claude-flow hooks for iterative task
52
+ npx @claude-flow/cli@latest hooks pre-task --description "Implement auth with iteration" --taskId "auth-impl"
53
+
54
+ # Store iteration state in memory
55
+ npx @claude-flow/cli@latest memory store \
56
+ --key "iteration-auth" \
57
+ --value '{"iteration": 1, "maxIterations": 20, "criteria": "all tests pass"}' \
58
+ --namespace iterations
59
+ ```
60
+
61
+ ---
62
+
63
+ ## Step-by-Step Guide
64
+
65
+ ### Step 1: Define Clear Success Criteria
66
+
67
+ **Essential**: Every iterative task MUST have objectively measurable completion criteria.
68
+
69
+ **Good Criteria Examples:**
70
+ ```markdown
71
+ ✅ All unit tests pass (npm test returns exit code 0)
72
+ ✅ Coverage > 80% (coverage report shows 80%+)
73
+ ✅ No TypeScript errors (tsc --noEmit returns 0)
74
+ ✅ Linting passes (eslint returns 0)
75
+ ✅ Performance < 100ms (benchmark shows < 100ms)
76
+ ```
77
+
78
+ **Bad Criteria Examples:**
79
+ ```markdown
80
+ ❌ "Code looks good" (subjective)
81
+ ❌ "Works properly" (undefined)
82
+ ❌ "Well-structured" (no measurable check)
83
+ ```
84
+
85
+ ### Step 2: Structure the Task with Phases
86
+
87
+ Break complex tasks into incremental phases:
88
+
89
+ ```markdown
90
+ ## Task: Implement User Authentication
91
+
92
+ ### Phase 1: Data Layer
93
+ - Create User model with Prisma schema
94
+ - Write migration
95
+ - Run tests: `npm test -- --grep "User model"`
96
+ - Criteria: Model tests pass
97
+
98
+ ### Phase 2: Service Layer
99
+ - Implement AuthService with JWT
100
+ - Add token generation/validation
101
+ - Run tests: `npm test -- --grep "AuthService"`
102
+ - Criteria: Service tests pass
103
+
104
+ ### Phase 3: API Layer
105
+ - Create /auth/login endpoint
106
+ - Create /auth/register endpoint
107
+ - Run tests: `npm test -- --grep "auth API"`
108
+ - Criteria: API tests pass
109
+
110
+ ### Phase 4: Integration
111
+ - End-to-end authentication flow
112
+ - Run tests: `npm test`
113
+ - Criteria: ALL tests pass
114
+
115
+ Output <promise>AUTH_COMPLETE</promise> when Phase 4 passes.
116
+ ```
117
+
118
+ ### Step 3: Implement Safety Mechanisms
119
+
120
+ Always include escape conditions:
121
+
122
+ ```markdown
123
+ ## Safety Rules
124
+
125
+ 1. **Max Iterations**: Stop after 20 attempts
126
+ 2. **Stuck Detection**: After 5 iterations without progress:
127
+ - Document what's blocking
128
+ - List attempted approaches
129
+ - Suggest alternative strategies
130
+ 3. **Critical Errors**: Stop immediately if:
131
+ - Database corruption detected
132
+ - Security vulnerability introduced
133
+ - Breaking changes to existing features
134
+ ```
135
+
136
+ ### Step 4: Execute with Verification
137
+
138
+ Each iteration should:
139
+ 1. Make targeted changes
140
+ 2. Run verification (tests, lint, build)
141
+ 3. Analyze results
142
+ 4. Plan next iteration based on feedback
143
+
144
+ ```bash
145
+ # Iteration pattern
146
+ 1. Read previous state (files, git log)
147
+ 2. Identify remaining work
148
+ 3. Implement specific change
149
+ 4. Run verification suite
150
+ 5. If all pass -> output completion promise
151
+ 6. If failures -> analyze and continue iteration
152
+ ```
153
+
154
+ ---
155
+
156
+ ## Iterative Patterns
157
+
158
+ ### Pattern 1: Test-Driven Iteration
159
+
160
+ ```markdown
161
+ ## TDD Iteration Task
162
+
163
+ 1. Write failing test for [feature]
164
+ 2. Implement minimal code to pass test
165
+ 3. Run `npm test`
166
+ 4. If test fails -> debug and fix implementation
167
+ 5. If test passes -> check if more tests needed
168
+ 6. Repeat until all acceptance tests pass
169
+ 7. Refactor if needed
170
+ 8. Output <promise>TDD_COMPLETE</promise>
171
+ ```
172
+
173
+ ### Pattern 2: Bug Fix Iteration
174
+
175
+ ```markdown
176
+ ## Bug Fix Task
177
+
178
+ 1. Write failing test that reproduces bug
179
+ 2. Implement fix
180
+ 3. Run test suite
181
+ 4. If reproduction test fails -> analyze why fix didn't work
182
+ 5. If other tests fail -> fix regressions
183
+ 6. If all tests pass -> output <promise>BUG_FIXED</promise>
184
+
185
+ Max iterations: 10
186
+ After 5 iterations without fix:
187
+ - Document root cause analysis
188
+ - Suggest alternative approaches
189
+ ```
190
+
191
+ ### Pattern 3: Coverage Improvement Iteration
192
+
193
+ ```markdown
194
+ ## Coverage Improvement Task
195
+
196
+ Target: 80% line coverage
197
+
198
+ 1. Run coverage analysis
199
+ 2. Identify uncovered code paths
200
+ 3. Write test for highest-impact uncovered path
201
+ 4. Run tests with coverage
202
+ 5. If coverage >= 80% -> output <promise>COVERAGE_ACHIEVED</promise>
203
+ 6. If coverage < 80% -> continue iteration
204
+
205
+ Max iterations: 30
206
+ Progress check: If coverage doesn't improve for 3 iterations -> analyze blockers
207
+ ```
208
+
209
+ ### Pattern 4: Performance Optimization Iteration
210
+
211
+ ```markdown
212
+ ## Performance Optimization Task
213
+
214
+ Target: Response time < 100ms
215
+
216
+ 1. Run performance benchmark
217
+ 2. Identify slowest operation
218
+ 3. Implement optimization
219
+ 4. Run benchmark again
220
+ 5. If target met -> output <promise>PERF_TARGET_MET</promise>
221
+ 6. If not improved -> try different approach
222
+
223
+ Max iterations: 15
224
+ Record metrics each iteration for trend analysis
225
+ ```
226
+
227
+ ---
228
+
229
+ ## Integration with Claude Flow
230
+
231
+ ### Memory-Enhanced Iteration
232
+
233
+ ```bash
234
+ # Store iteration state
235
+ npx @claude-flow/cli@latest memory store \
236
+ --key "current-iteration" \
237
+ --value '{"task": "auth", "iteration": 5, "lastResult": "2 tests failing"}' \
238
+ --namespace iterations
239
+
240
+ # Search for similar past iterations
241
+ npx @claude-flow/cli@latest memory search \
242
+ --query "auth implementation" \
243
+ --namespace iterations
244
+
245
+ # Learn from successful completions
246
+ npx @claude-flow/cli@latest hooks post-task \
247
+ --taskId "auth-impl" \
248
+ --success true \
249
+ --quality 0.9
250
+ ```
251
+
252
+ ### Swarm-Coordinated Iteration
253
+
254
+ For complex tasks, use multiple agents iterating in parallel:
255
+
256
+ ```bash
257
+ # Initialize swarm for parallel iteration
258
+ npx @claude-flow/cli@latest swarm init --topology mesh --max-agents 5
259
+
260
+ # Spawn specialized iterators
261
+ Task("Iterate on unit tests", "Fix failing unit tests until all pass", "tester")
262
+ Task("Iterate on integration", "Fix integration tests until all pass", "tester")
263
+ Task("Iterate on performance", "Optimize until benchmarks pass", "performance-engineer")
264
+ ```
265
+
266
+ ---
267
+
268
+ ## Best Practices
269
+
270
+ ### Prompt Engineering for Iteration
271
+
272
+ **Include:**
273
+ - Explicit completion criteria with verification commands
274
+ - Phase-based breakdown for complex tasks
275
+ - Safety limits (max iterations)
276
+ - Progress tracking instructions
277
+ - Stuck detection and recovery procedures
278
+
279
+ **Example Well-Structured Prompt:**
280
+ ```markdown
281
+ ## Task: Implement Feature X
282
+
283
+ ### Success Criteria (ALL must pass):
284
+ 1. `npm test` exits with code 0
285
+ 2. `npm run lint` exits with code 0
286
+ 3. `npm run typecheck` exits with code 0
287
+ 4. No console.log statements in production code
288
+
289
+ ### Phases:
290
+ 1. Write failing tests
291
+ 2. Implement feature
292
+ 3. Fix any failures
293
+ 4. Clean up and refactor
294
+
295
+ ### Safety:
296
+ - Max iterations: 20
297
+ - After 10 iterations: summarize blockers
298
+ - Stop if security issues detected
299
+
300
+ ### Completion:
301
+ When ALL success criteria pass, output:
302
+ <promise>FEATURE_X_COMPLETE</promise>
303
+ ```
304
+
305
+ ### When to Use Iterative Loops
306
+
307
+ **Ideal for:**
308
+ - Well-defined tasks with measurable success
309
+ - Test-driven development
310
+ - Bug fixing with reproducible tests
311
+ - Coverage improvement
312
+ - Performance optimization
313
+ - Linting/formatting fixes
314
+
315
+ **Not ideal for:**
316
+ - Tasks requiring human judgment
317
+ - Design decisions
318
+ - Vague or subjective goals
319
+ - One-time operations
320
+ - Production debugging without tests
321
+
322
+ ---
323
+
324
+ ## Troubleshooting
325
+
326
+ ### Issue: Infinite Loop / No Progress
327
+
328
+ **Symptoms**: Same errors repeat without improvement
329
+
330
+ **Solutions**:
331
+ 1. Increase specificity in completion criteria
332
+ 2. Add "stuck detection" with alternative approaches
333
+ 3. Lower max iterations
334
+ 4. Break task into smaller phases
335
+
336
+ ### Issue: False Completion
337
+
338
+ **Symptoms**: Loop ends but task not actually complete
339
+
340
+ **Solutions**:
341
+ 1. Add more verification commands
342
+ 2. Make completion criteria more explicit
343
+ 3. Add integration tests alongside unit tests
344
+
345
+ ### Issue: Regression in Later Iterations
346
+
347
+ **Symptoms**: Previously passing tests fail after new changes
348
+
349
+ **Solutions**:
350
+ 1. Add regression check step
351
+ 2. Use git to compare iterations
352
+ 3. Implement smaller, targeted changes
353
+
354
+ ---
355
+
356
+ ## Related Skills
357
+
358
+ - [tdd-london-chicago](../tdd-london-chicago/) - TDD approaches for iterative development
359
+ - [qe-iterative-loop](../qe-iterative-loop/) - AQE v3 fleet-specific iteration patterns
360
+ - [hooks-automation](../hooks-automation/) - Claude Flow hooks for automation
361
+
362
+ ## Resources
363
+
364
+ - [Ralph Wiggum Technique](https://ghuntley.com/ralph/) - Original methodology
365
+ - [Ralph Orchestrator](https://github.com/mikeyobrien/ralph-orchestrator) - Orchestration tools
366
+ - [Claude Code Plugins](https://github.com/anthropics/claude-code) - Official plugins
367
+
368
+ ---
369
+
370
+ **Origin**: Based on Ralph Wiggum plugin from claude-code repository (anthropics/claude-code)
371
+ **Adapted for**: Agentic QE v3 with Claude Flow integration
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "version": "1.3.0",
3
3
  "generated": "2026-02-04T00:00:00.000Z",
4
- "totalSkills": 46,
5
- "totalQESkills": 78,
6
- "description": "Agentic QE Fleet skills manifest - 46 Tier 3 verified QE skills. Total 78 QE skills on disk (46 Tier 3 + 32 additional including QCSD swarms, n8n testing, enterprise integration, pentest validation, qe-* domains).",
4
+ "totalSkills": 48,
5
+ "totalQESkills": 80,
6
+ "description": "Agentic QE Fleet skills manifest - 48 Tier 3 verified QE skills. Total 80 QE skills on disk (48 Tier 3 + 32 additional including QCSD swarms, n8n testing, enterprise integration, pentest validation, qe-* domains).",
7
7
  "categories": {
8
8
  "qcsd-phases": {
9
9
  "description": "QCSD (Quality Conscious Software Delivery) phase swarms for shift-left quality",
@@ -33,6 +33,7 @@
33
33
  "skills": [
34
34
  "security-testing",
35
35
  "pentest-validation",
36
+ "validation-pipeline",
36
37
  "performance-testing",
37
38
  "accessibility-testing",
38
39
  "a11y-ally",
@@ -822,6 +823,33 @@
822
823
  "dependencies": [],
823
824
  "agents": ["qe-quality-analyzer"]
824
825
  },
826
+ "validation-pipeline": {
827
+ "id": "validation-pipeline",
828
+ "name": "Validation Pipeline",
829
+ "description": "Run structured 13-step requirements validation pipeline with gate enforcement, weighted scoring, and detailed findings. Supports format checking, vague term detection, testability analysis, and more.",
830
+ "category": "specialized-testing",
831
+ "priority": "high",
832
+ "file": "validation-pipeline/SKILL.md",
833
+ "tokenEstimate": 1500,
834
+ "optimizationStatus": "active",
835
+ "optimizationVersion": "1.0",
836
+ "lastOptimized": "2026-03-12",
837
+ "tags": ["validation", "requirements", "pipeline", "gate-enforcement", "scoring", "bmad"],
838
+ "dependencies": ["agentic-quality-engineering"],
839
+ "agents": ["qe-requirements-validator"],
840
+ "relatedSkills": ["verification-quality", "shift-left-testing", "context-driven-testing"],
841
+ "triggers": {
842
+ "patterns": [
843
+ "validate requirements",
844
+ "requirements validation",
845
+ "validation pipeline",
846
+ "run validation",
847
+ "check requirements quality"
848
+ ],
849
+ "autoInvoke": false,
850
+ "enforcementLevel": "standard"
851
+ }
852
+ },
825
853
  "bug-reporting-excellence": {
826
854
  "id": "bug-reporting-excellence",
827
855
  "name": "Bug Reporting Excellence",
@@ -904,7 +932,7 @@
904
932
  },
905
933
  "metadata": {
906
934
  "generatedBy": "Agentic QE Fleet",
907
- "fleetVersion": "3.7.18",
935
+ "fleetVersion": "3.7.20",
908
936
  "manifestVersion": "1.3.0",
909
937
  "lastUpdated": "2026-02-04T00:00:00.000Z",
910
938
  "contributors": [
@@ -914,13 +942,13 @@
914
942
  "url": "https://github.com/fndlalit"
915
943
  }
916
944
  ],
917
- "notes": "This manifest tracks 46 Tier 3 verified QE skills. Total 78 QE skills on disk (46 Tier 3 + 32 additional). Claude Flow platform skills (33) are managed separately.",
945
+ "notes": "This manifest tracks 48 Tier 3 verified QE skills. Total 80 QE skills on disk (48 Tier 3 + 32 additional). Claude Flow platform skills (33) are managed separately.",
918
946
  "skillBreakdown": {
919
- "qeSkillsTier3": 46,
947
+ "qeSkillsTier3": 48,
920
948
  "qeSkillsAdditional": 32,
921
- "totalQESkills": 78,
949
+ "totalQESkills": 80,
922
950
  "platformSkills": 36,
923
- "totalOnDisk": 111
951
+ "totalOnDisk": 113
924
952
  },
925
953
  "excludedCategories": {
926
954
  "reason": "Platform skills are available but not tracked in this QE-focused manifest",
@@ -0,0 +1,164 @@
1
+ ---
2
+ name: "Validation Pipeline"
3
+ description: "Structured step-by-step validation of requirements, code, and artifacts with gate enforcement, per-step scoring, and structured reports."
4
+ trust_tier: 3
5
+ validation:
6
+ schema_path: schemas/output.json
7
+ validator_path: scripts/validate-config.json
8
+ eval_path: evals/validation-pipeline.yaml
9
+
10
+ ---
11
+
12
+ # Validation Pipeline
13
+
14
+ ## Purpose
15
+
16
+ Run structured validation pipelines that execute steps sequentially, enforce gates at blocking failures, and produce scored reports. Uses the `src/validation/pipeline.ts` framework with 13 requirements validation steps (BMAD-003).
17
+
18
+ ## Activation
19
+
20
+ - When validating requirements documents
21
+ - When running structured quality gates
22
+ - When assessing document completeness, testability, or traceability
23
+ - When invoked via `/validation-pipeline`
24
+
25
+ ## Quick Start
26
+
27
+ ```bash
28
+ # Validate a requirements document (all 13 steps)
29
+ /validation-pipeline requirements docs/requirements.md
30
+
31
+ # Validate with specific steps only
32
+ /validation-pipeline requirements docs/requirements.md --steps format-check,completeness-check,invest-criteria
33
+
34
+ # Continue past blocking failures
35
+ /validation-pipeline requirements docs/requirements.md --continue-on-failure
36
+
37
+ # Output as JSON
38
+ /validation-pipeline requirements docs/requirements.md --json
39
+ ```
40
+
41
+ ## Workflow
42
+
43
+ ### Step 1: Read the Target Document
44
+
45
+ Read the file specified by the user. If no file is provided, ask for one.
46
+
47
+ ```
48
+ Read the target document using the Read tool.
49
+ Store the content for pipeline execution.
50
+ ```
51
+
52
+ ### Step 2: Select Pipeline
53
+
54
+ Choose the appropriate pipeline based on the user's request:
55
+
56
+ | Pipeline | Steps | Use Case |
57
+ |----------|-------|----------|
58
+ | `requirements` | 13 | Requirements documents, PRDs, user stories |
59
+
60
+ Additional pipelines can be created by defining new step sets in `src/validation/steps/`.
61
+
62
+ ### Step 3: Execute Pipeline
63
+
64
+ The pipeline framework (`src/validation/pipeline.ts`) handles execution:
65
+
66
+ 1. **Sequential execution** — steps run in order, each receiving results from prior steps
67
+ 2. **Gate enforcement** — blocking steps that fail halt the pipeline (unless `--continue-on-failure`)
68
+ 3. **Per-step scoring** — each step produces a 0-100 score with findings and evidence
69
+ 4. **Weighted rollup** — overall score uses category weights (format=10%, content=30%, quality=25%, traceability=20%, compliance=15%)
70
+
71
+ #### Requirements Pipeline Steps (13 total)
72
+
73
+ | # | Step ID | Category | Severity | What It Checks |
74
+ |---|---------|----------|----------|----------------|
75
+ | 1 | `format-check` | format | blocking | Headings, required sections, document length |
76
+ | 2 | `completeness-check` | content | blocking | Required fields populated, acceptance criteria present |
77
+ | 3 | `invest-criteria` | quality | warning | Independent, Negotiable, Valuable, Estimable, Small, Testable |
78
+ | 4 | `smart-acceptance` | quality | warning | Specific, Measurable, Achievable, Relevant, Time-bound |
79
+ | 5 | `testability-score` | quality | warning | Can each requirement be tested? |
80
+ | 6 | `vague-term-detection` | content | info | Flags "should", "might", "various", "etc." |
81
+ | 7 | `information-density` | content | info | Every sentence carries weight, no filler |
82
+ | 8 | `traceability-check` | traceability | warning | Requirements-to-tests mapping exists |
83
+ | 9 | `implementation-leakage` | quality | warning | Requirements don't prescribe implementation |
84
+ | 10 | `domain-compliance` | compliance | info | Alignment with domain model |
85
+ | 11 | `dependency-analysis` | traceability | info | Cross-requirement dependencies identified |
86
+ | 12 | `bdd-scenario-generation` | quality | warning | Can generate Given/When/Then for each requirement |
87
+ | 13 | `holistic-quality` | compliance | blocking | Overall coherence, no contradictions |
88
+
89
+ ### Step 4: Report Results
90
+
91
+ Format the pipeline result as a structured report:
92
+
93
+ ```markdown
94
+ # Validation Report: Requirements Pipeline
95
+
96
+ **Overall**: PASS/FAIL/WARN | **Score**: 85/100 | **Duration**: 42ms
97
+
98
+ ## Step Results
99
+ | # | Step | Status | Score | Findings | Duration |
100
+ |---|------|--------|-------|----------|----------|
101
+ | 1 | Format Check | PASS | 100 | 0 | 2ms |
102
+ | 2 | Completeness | WARN | 60 | 2 | 5ms |
103
+ ...
104
+
105
+ ## Blockers
106
+ - (blocking findings listed here)
107
+
108
+ ## All Findings
109
+ - [HIGH] Missing acceptance criteria: Requirement US-104 has no AC
110
+ - [MEDIUM] Vague term: "should" used 5 times without specifics
111
+ ...
112
+ ```
113
+
114
+ ### Step 5: Record Learning
115
+
116
+ After pipeline execution, record the outcome for learning:
117
+
118
+ ```typescript
119
+ // Store validation pattern
120
+ memory store --namespace validation-pipeline --key "req-validation-{timestamp}" --value "{score, findings_count, halted}"
121
+ ```
122
+
123
+ ## Parameters
124
+
125
+ | Parameter | Type | Default | Description |
126
+ |-----------|------|---------|-------------|
127
+ | `pipeline` | string | `requirements` | Pipeline type to run |
128
+ | `file` | string | required | Path to document to validate |
129
+ | `--steps` | string[] | all | Specific step IDs to run |
130
+ | `--continue-on-failure` | boolean | false | Skip blocking gates |
131
+ | `--json` | boolean | false | Output as JSON instead of markdown |
132
+ | `--metadata` | object | {} | Additional context for steps |
133
+
134
+ ## Integration Points
135
+
136
+ - **qe-requirements-validator agent** — delegates structured validation to this pipeline
137
+ - **qe-quality-gate agent** — uses pipeline for gate evaluation
138
+ - **YAML Pipelines** — can invoke validation steps as workflow actions
139
+ - **MCP** — accessible via `pipeline_validate` tool
140
+
141
+ ## Output Schema
142
+
143
+ The pipeline produces a `PipelineResult` object (see `schemas/output.json`):
144
+
145
+ ```typescript
146
+ {
147
+ pipelineId: string;
148
+ pipelineName: string;
149
+ overall: 'pass' | 'fail' | 'warn';
150
+ score: number; // 0-100 weighted average
151
+ steps: StepResult[]; // per-step details
152
+ blockers: Finding[]; // blocking findings
153
+ halted: boolean;
154
+ haltedAt?: string; // step ID where halted
155
+ totalDuration: number;
156
+ timestamp: string;
157
+ }
158
+ ```
159
+
160
+ ## Error Handling
161
+
162
+ - **Step throws exception** — captured as a FAIL with critical finding, pipeline continues or halts per severity
163
+ - **File not found** — report error, do not run pipeline
164
+ - **Empty document** — format-check step will catch this as a blocking failure