qfai 1.4.24 → 1.4.25
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 +2 -2
- package/assets/init/.qfai/assistant/agents/coverage-planner.md +14 -5
- package/assets/init/.qfai/assistant/agents/qa-gatekeeper.md +11 -1
- package/assets/init/.qfai/assistant/agents/test-case-owner.md +12 -4
- package/assets/init/.qfai/assistant/agents/test-volume-estimator.md +15 -11
- package/assets/init/.qfai/assistant/skills/qfai-discuss/SKILL.md +29 -6
- package/assets/init/.qfai/assistant/skills/qfai-discuss/templates/02_Hearing.md +11 -0
- package/assets/init/.qfai/assistant/skills/qfai-discuss/templates/03_Config-Hearing.md +8 -0
- package/assets/init/.qfai/assistant/skills/qfai-discuss/templates/08_Review-Request.md +3 -0
- package/assets/init/.qfai/assistant/skills/qfai-discuss/templates/review/review_request.md +3 -0
- package/assets/init/.qfai/assistant/skills/qfai-require/templates/review/review_request.md +3 -0
- package/assets/init/.qfai/assistant/skills/qfai-sdd/SKILL.md +24 -1
- package/assets/init/.qfai/assistant/steering/review-gate.rules.yml +14 -0
- package/assets/init/.qfai/assistant/templates/rcp_footer.md +17 -0
- package/dist/cli/index.cjs +98 -9
- package/dist/cli/index.cjs.map +1 -1
- package/dist/cli/index.mjs +98 -9
- package/dist/cli/index.mjs.map +1 -1
- package/dist/index.cjs +88 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +88 -6
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -210,7 +210,7 @@ flowchart LR
|
|
|
210
210
|
- Contracts SSOT: `.qfai/contracts/**`
|
|
211
211
|
- Report outputs (`.qfai/report/**`) are derived artifacts and not SSOT.
|
|
212
212
|
|
|
213
|
-
## Minimal tutorial (v1.4.
|
|
213
|
+
## Minimal tutorial (v1.4.25)
|
|
214
214
|
|
|
215
215
|
1. `npx qfai init`
|
|
216
216
|
2. Run `/qfai-discuss` to structure scope and open questions.
|
|
@@ -237,7 +237,7 @@ Release gate behavior:
|
|
|
237
237
|
|
|
238
238
|
## Continuous integration
|
|
239
239
|
|
|
240
|
-
QFAI v1.4.
|
|
240
|
+
QFAI v1.4.25 generates integration wrappers under `.agents/**`, `.claude/**`,
|
|
241
241
|
`.github/**`, and `.codex/**`.
|
|
242
242
|
It does not generate GitHub Actions workflows.
|
|
243
243
|
Configure CI in your own platform and run:
|
|
@@ -3,21 +3,27 @@
|
|
|
3
3
|
## Mission
|
|
4
4
|
|
|
5
5
|
- Define and maintain coverage ledgers to prevent silent gaps.
|
|
6
|
+
- Convert coverage findings into actionable, perspective-based EX/TC planning.
|
|
6
7
|
|
|
7
8
|
## Inputs you must read
|
|
8
9
|
|
|
9
10
|
- .qfai/assistant/instructions/\*
|
|
10
11
|
- .qfai/assistant/steering/\*
|
|
11
|
-
- .qfai/specs/spec-\*/
|
|
12
|
-
- .qfai/specs/spec-\*/
|
|
13
|
-
- .qfai/specs/spec-\*/
|
|
12
|
+
- .qfai/specs/spec-\*/09_delta.md (Decision Records; check rejected)
|
|
13
|
+
- .qfai/specs/spec-\*/04_Business-Rules.md
|
|
14
|
+
- .qfai/specs/spec-\*/05_Examples.md
|
|
15
|
+
- .qfai/specs/spec-\*/06_Test-Cases.md
|
|
16
|
+
- .qfai/report/validate.log
|
|
17
|
+
- .qfai/report/specs-coverage/spec-\*.md
|
|
14
18
|
- Existing coverage ledgers and test files
|
|
15
19
|
|
|
16
20
|
## Deliverables (MANDATORY)
|
|
17
21
|
|
|
18
22
|
- Decision Records referenced (DR-IDs) + rejected check (or RE-OPEN request)
|
|
23
|
+
- Hard-gap list (`QFAI-COV-201/202/203/204/205/206`) with source-layer fixes
|
|
24
|
+
- Density-smell list (for example `QFAI-COV-207`) with perspective-based improvement ideas
|
|
19
25
|
- Scope ledger (what must be tested) with exclusions rationale
|
|
20
|
-
- Coverage ledger mapped to
|
|
26
|
+
- Coverage ledger mapped to BR/EX/TC layers
|
|
21
27
|
- Evidence summary for `.qfai/evidence/` (gitignored; do not commit)
|
|
22
28
|
|
|
23
29
|
## Stop conditions (Blockers)
|
|
@@ -25,7 +31,7 @@
|
|
|
25
31
|
- Rejected option would be reintroduced without RE-OPEN DR
|
|
26
32
|
- Hidden exclusions or silent gaps detected
|
|
27
33
|
- Evidence is missing or incomplete
|
|
28
|
-
-
|
|
34
|
+
- BR/EX/TC mapping is ambiguous
|
|
29
35
|
|
|
30
36
|
## Sign-off checklist (Check Last)
|
|
31
37
|
|
|
@@ -38,7 +44,10 @@
|
|
|
38
44
|
|
|
39
45
|
- Decision Records (DR-IDs) / rejected check
|
|
40
46
|
- Findings
|
|
47
|
+
- Hard gaps (`QFAI-COV-201..206`)
|
|
48
|
+
- Density smells (`QFAI-COV-207` and similar)
|
|
41
49
|
- Coverage ledger
|
|
50
|
+
- Perspective-based EX/TC proposal (boundary, negative, permission, state)
|
|
42
51
|
- Exclusions rationale
|
|
43
52
|
- Evidence summary
|
|
44
53
|
- Open Questions / Risks
|
|
@@ -9,8 +9,13 @@
|
|
|
9
9
|
|
|
10
10
|
- .qfai/assistant/instructions/\*
|
|
11
11
|
- .qfai/assistant/steering/\*
|
|
12
|
-
- .qfai/specs/spec-\*/
|
|
12
|
+
- .qfai/specs/spec-\*/09_delta.md (Decision Records; check rejected)
|
|
13
|
+
- .qfai/specs/spec-\*/04_Business-Rules.md
|
|
14
|
+
- .qfai/specs/spec-\*/05_Examples.md
|
|
15
|
+
- .qfai/specs/spec-\*/06_Test-Cases.md
|
|
13
16
|
- QA evidence summaries under `.qfai/evidence/` (gitignored)
|
|
17
|
+
- .qfai/report/validate.log
|
|
18
|
+
- .qfai/report/specs-coverage/spec-\*.md
|
|
14
19
|
- Coverage ledgers and traceability reports
|
|
15
20
|
- Gate command outputs
|
|
16
21
|
|
|
@@ -19,6 +24,8 @@
|
|
|
19
24
|
- Decision Records referenced (DR-IDs) + rejected check (or RE-OPEN request)
|
|
20
25
|
- DONE declaration check (inputs + DR-IDs + rejected guard)
|
|
21
26
|
- Gate status (PASS/FAIL) with rationale
|
|
27
|
+
- Hard gate result summary (`QFAI-COV-201..206`)
|
|
28
|
+
- Density-smell review notes (`QFAI-COV-207` and related warnings)
|
|
22
29
|
- Explicit gap list and required fixes
|
|
23
30
|
- Evidence presence check summary
|
|
24
31
|
|
|
@@ -27,6 +34,7 @@
|
|
|
27
34
|
- Rejected option would be reintroduced without RE-OPEN DR
|
|
28
35
|
- Evidence is missing or incomplete
|
|
29
36
|
- Coverage ledger is missing or inconsistent
|
|
37
|
+
- Validate gate is missing/failing (`qfai validate --fail-on error --format github`)
|
|
30
38
|
- Runtime or quality gates are not executed
|
|
31
39
|
|
|
32
40
|
## Sign-off checklist (Check Last)
|
|
@@ -41,6 +49,8 @@
|
|
|
41
49
|
- Decision Records (DR-IDs) / rejected check
|
|
42
50
|
- Gate decision (PASS/FAIL)
|
|
43
51
|
- Findings
|
|
52
|
+
- Hard gate status (`QFAI-COV-201..206`)
|
|
53
|
+
- Density-smell review (`QFAI-COV-207`)
|
|
44
54
|
- Required fixes
|
|
45
55
|
- Evidence summary
|
|
46
56
|
- Open Questions / Risks
|
|
@@ -8,15 +8,21 @@
|
|
|
8
8
|
|
|
9
9
|
- .qfai/assistant/instructions/\*
|
|
10
10
|
- .qfai/assistant/steering/\*
|
|
11
|
-
- .qfai/specs/spec-\*/
|
|
12
|
-
- .qfai/specs/spec-\*/
|
|
13
|
-
- .qfai/specs/spec-\*/
|
|
11
|
+
- .qfai/specs/spec-\*/09_delta.md (Decision Records; check rejected)
|
|
12
|
+
- .qfai/specs/spec-\*/03_Acceptance-Criteria.md
|
|
13
|
+
- .qfai/specs/spec-\*/04_Business-Rules.md
|
|
14
|
+
- .qfai/specs/spec-\*/05_Examples.md
|
|
15
|
+
- .qfai/specs/spec-\*/06_Test-Cases.md
|
|
16
|
+
- .qfai/report/validate.log
|
|
17
|
+
- .qfai/report/specs-coverage/spec-\*.md
|
|
14
18
|
- Existing test cases and mappings
|
|
15
19
|
|
|
16
20
|
## Deliverables (MANDATORY)
|
|
17
21
|
|
|
18
22
|
- Decision Records referenced (DR-IDs) + rejected check (or RE-OPEN request)
|
|
23
|
+
- Minimal TC set proposal satisfying AC->TC and EX->TC coverage
|
|
19
24
|
- Test case inventory mapped to requirements/contracts
|
|
25
|
+
- Missing boundary/negative case recommendations (perspective-based)
|
|
20
26
|
- Exclusions rationale for any missing coverage
|
|
21
27
|
- Evidence summary for `.qfai/evidence/` (gitignored; do not commit)
|
|
22
28
|
|
|
@@ -25,7 +31,7 @@
|
|
|
25
31
|
- Rejected option would be reintroduced without RE-OPEN DR
|
|
26
32
|
- Traceability gaps without explicit rationale
|
|
27
33
|
- Evidence is missing or incomplete
|
|
28
|
-
- Test cases cannot be mapped to requirements
|
|
34
|
+
- Test cases cannot be mapped to AC/EX requirements
|
|
29
35
|
|
|
30
36
|
## Sign-off checklist (Check Last)
|
|
31
37
|
|
|
@@ -39,6 +45,8 @@
|
|
|
39
45
|
- Decision Records (DR-IDs) / rejected check
|
|
40
46
|
- Findings
|
|
41
47
|
- Test case mapping
|
|
48
|
+
- Coverage gate status (`QFAI-COV-201..206`)
|
|
49
|
+
- Perspective gaps (boundary, negative, permission, state)
|
|
42
50
|
- Exclusions rationale
|
|
43
51
|
- Evidence summary
|
|
44
52
|
- Open Questions / Risks
|
|
@@ -2,44 +2,48 @@
|
|
|
2
2
|
|
|
3
3
|
## Mission
|
|
4
4
|
|
|
5
|
-
-
|
|
5
|
+
- Estimate test volume as a risk signal and detect thin areas.
|
|
6
6
|
|
|
7
7
|
## Inputs you must read
|
|
8
8
|
|
|
9
9
|
- .qfai/assistant/instructions/\*
|
|
10
10
|
- .qfai/assistant/steering/\*
|
|
11
|
-
- .qfai/specs/spec-\*/
|
|
12
|
-
- .qfai/specs/spec-\*/
|
|
13
|
-
- .qfai/specs/spec-\*/
|
|
14
|
-
- .qfai/specs/spec-\*/
|
|
11
|
+
- .qfai/specs/spec-\*/09_delta.md (Decision Records; check rejected)
|
|
12
|
+
- .qfai/specs/spec-\*/04_Business-Rules.md
|
|
13
|
+
- .qfai/specs/spec-\*/05_Examples.md
|
|
14
|
+
- .qfai/specs/spec-\*/06_Test-Cases.md
|
|
15
|
+
- .qfai/report/specs-coverage/spec-\*.md
|
|
16
|
+
- .qfai/report/validate.log
|
|
15
17
|
- .qfai/contracts/\*\*
|
|
16
18
|
|
|
17
19
|
## Deliverables (MANDATORY)
|
|
18
20
|
|
|
19
21
|
- Decision Records referenced (DR-IDs) + rejected check (or RE-OPEN request)
|
|
20
|
-
-
|
|
21
|
-
-
|
|
22
|
+
- Risk-signal table (Layer / Raw count / Signal / Evidence / Notes)
|
|
23
|
+
- Density-smell findings (for example multi-BR EX rows) and impact summary
|
|
24
|
+
- Improvement proposals by perspective (boundary/negative/permission/state)
|
|
22
25
|
- BLOCKED list when data is missing
|
|
23
26
|
- Evidence summary for `.qfai/evidence/` (gitignored; do not commit)
|
|
24
27
|
|
|
25
28
|
## Stop conditions (Blockers)
|
|
26
29
|
|
|
27
30
|
- Rejected option would be reintroduced without RE-OPEN DR
|
|
28
|
-
-
|
|
31
|
+
- BR/EX/TC source counts cannot be derived and no fallback is available
|
|
29
32
|
- Evidence is missing or incomplete
|
|
30
33
|
|
|
31
34
|
## Sign-off checklist (Check Last)
|
|
32
35
|
|
|
33
36
|
- [ ] Deliverables are complete
|
|
34
37
|
- [ ] Evidence is present (gitignored)
|
|
35
|
-
- [ ]
|
|
38
|
+
- [ ] Risk signals are justified with evidence
|
|
36
39
|
- [ ] BLOCKED items are explicit
|
|
37
40
|
|
|
38
41
|
## Output format (structured)
|
|
39
42
|
|
|
40
43
|
- Decision Records (DR-IDs) / rejected check
|
|
41
|
-
-
|
|
42
|
-
-
|
|
44
|
+
- Risk-signal table
|
|
45
|
+
- Density-smell findings
|
|
46
|
+
- Perspective-based improvement proposals
|
|
43
47
|
- BLOCKED list (if any)
|
|
44
48
|
- Evidence summary
|
|
45
49
|
- Open Questions / Risks
|
|
@@ -88,6 +88,8 @@ Every major artifact in this stage MUST include this table schema:
|
|
|
88
88
|
- RCP wording must be sourced from `.qfai/assistant/templates/rcp_footer.md`.
|
|
89
89
|
- Discuss artifacts are logs/rationale and must not duplicate spec SSOT.
|
|
90
90
|
- If diagrams are written, Mermaid syntax must be in ` ```mermaid ` fences only.
|
|
91
|
+
- Do not enforce fixed EX/BR or TC/EX ratios in this phase.
|
|
92
|
+
- Example Mapping is mandatory and must be captured as `Example Seeds` sections.
|
|
91
93
|
|
|
92
94
|
## Goal
|
|
93
95
|
|
|
@@ -118,12 +120,32 @@ Produce a fixed discuss pack with explicit decisions and OQ states so downstream
|
|
|
118
120
|
|
|
119
121
|
1. Run the core interview for product concept, scope, and policy.
|
|
120
122
|
2. Run config hearing for steering, constraints, and test-layer readiness.
|
|
121
|
-
3. Run
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
123
|
+
3. Run Example Mapping pass for each BR/AC candidate and capture `Example Seeds` in:
|
|
124
|
+
- `02_Hearing.md` (requirements-oriented seeds)
|
|
125
|
+
- `03_Config-Hearing.md` (constraints/policy-oriented seeds)
|
|
126
|
+
4. Run deep dive for risks, boundary conditions, and alternatives.
|
|
127
|
+
5. Update `05_OQ-Register.md` with all identified OQs.
|
|
128
|
+
6. Run OQ resolution hearing repeatedly until open count is zero.
|
|
129
|
+
7. Move deferred items to `07_Deferred.md` with mandatory metadata.
|
|
130
|
+
8. Update `06_OQ-Resolution-Log.md`, `08_Review-Request.md`, and `09_delta.md`.
|
|
131
|
+
9. Request review and record Reviewer result.
|
|
132
|
+
|
|
133
|
+
## Example Mapping Perspectives (Mandatory)
|
|
134
|
+
|
|
135
|
+
For each BR/AC candidate, enumerate concrete example seeds with these perspectives:
|
|
136
|
+
|
|
137
|
+
1. Happy path
|
|
138
|
+
2. Negative path
|
|
139
|
+
3. Edge / boundary
|
|
140
|
+
4. Permission / role
|
|
141
|
+
5. State transition (if stateful)
|
|
142
|
+
6. Idempotency / retry (if external I/O exists)
|
|
143
|
+
|
|
144
|
+
Rules:
|
|
145
|
+
|
|
146
|
+
- Use perspective coverage as the gate, not raw case counts.
|
|
147
|
+
- Mark intentionally skipped perspectives with reason and follow-up.
|
|
148
|
+
- Feed unresolved seeds into OQ items with owner and decision point.
|
|
127
149
|
|
|
128
150
|
## OQ Data Model (Mandatory)
|
|
129
151
|
|
|
@@ -188,6 +210,7 @@ Before declaring completion, you MUST:
|
|
|
188
210
|
- verify all mandatory output files exist and are populated;
|
|
189
211
|
- ensure `Disposition: open` count is zero;
|
|
190
212
|
- ensure every deferred item has full metadata;
|
|
213
|
+
- ensure `Example Seeds` sections are present and perspective coverage is explicit;
|
|
191
214
|
- avoid duplicating finalized spec content in discuss outputs.
|
|
192
215
|
|
|
193
216
|
## Evidence (MANDATORY)
|
|
@@ -16,3 +16,14 @@
|
|
|
16
16
|
- In scope:
|
|
17
17
|
- Out of scope:
|
|
18
18
|
- Key constraints:
|
|
19
|
+
|
|
20
|
+
## Example Seeds (Requirements)
|
|
21
|
+
|
|
22
|
+
| BR/AC Candidate | Perspective | Seed (concrete) | Notes |
|
|
23
|
+
| ----------------- | ------------------- | --------------- | ----- |
|
|
24
|
+
| BR-0001 / AC-0001 | Happy | TBD | TBD |
|
|
25
|
+
| BR-0001 / AC-0001 | Negative | TBD | TBD |
|
|
26
|
+
| BR-0001 / AC-0001 | Edge / Boundary | TBD | TBD |
|
|
27
|
+
| BR-0001 / AC-0001 | Permission / Role | TBD | TBD |
|
|
28
|
+
| BR-0001 / AC-0001 | State transition | TBD | TBD |
|
|
29
|
+
| BR-0001 / AC-0001 | Idempotency / Retry | TBD | TBD |
|
|
@@ -18,3 +18,11 @@
|
|
|
18
18
|
## Open Gaps to Resolve in Discuss
|
|
19
19
|
|
|
20
20
|
- OQ candidate:
|
|
21
|
+
|
|
22
|
+
## Example Seeds (Constraints / Policy)
|
|
23
|
+
|
|
24
|
+
| BR/AC Candidate | Perspective | Constraint-aware seed | Policy / gate note |
|
|
25
|
+
| ----------------- | ------------------- | --------------------- | ------------------ |
|
|
26
|
+
| BR-0001 / AC-0001 | Permission / Role | TBD | TBD |
|
|
27
|
+
| BR-0001 / AC-0001 | State transition | TBD | TBD |
|
|
28
|
+
| BR-0001 / AC-0001 | Idempotency / Retry | TBD | TBD |
|
|
@@ -23,3 +23,6 @@
|
|
|
23
23
|
- OQ state integrity (`open` must be zero at completion)
|
|
24
24
|
- Deferred metadata completeness and risk handling
|
|
25
25
|
- Traceability of decisions and rationale
|
|
26
|
+
- Validate evidence availability (`.qfai/report/validate.log`)
|
|
27
|
+
- Hard gate status (`QFAI-COV-201/202/203/204/205/206` should be zero)
|
|
28
|
+
- Coverage report observations from `.qfai/report/specs-coverage/spec-*.md` (perspective gaps over raw count requests)
|
|
@@ -19,6 +19,9 @@
|
|
|
19
19
|
- Operational and security risks
|
|
20
20
|
- Mermaid diagrams use ` ```mermaid ` fences only (no ` ```text ` or language-less fences)
|
|
21
21
|
- Business Flow artifacts include required `flowchart` or `sequenceDiagram` where applicable
|
|
22
|
+
- Validate hard gate evidence exists (`.qfai/report/validate.log`).
|
|
23
|
+
- Coverage hard gates are clear (`QFAI-COV-201/202/203/204/205/206` = 0).
|
|
24
|
+
- `specs-coverage/spec-*.md` was reviewed and density-smell findings (for example `QFAI-COV-207`) are called out as perspective gaps.
|
|
22
25
|
|
|
23
26
|
## Required Reviewers
|
|
24
27
|
|
|
@@ -19,6 +19,9 @@
|
|
|
19
19
|
- Operational and security risks
|
|
20
20
|
- Mermaid diagrams use ` ```mermaid ` fences only (no ` ```text ` or language-less fences)
|
|
21
21
|
- Business Flow artifacts include required `flowchart` or `sequenceDiagram` where applicable
|
|
22
|
+
- Validate hard gate evidence exists (`.qfai/report/validate.log`).
|
|
23
|
+
- Coverage hard gates are clear (`QFAI-COV-201/202/203/204/205/206` = 0).
|
|
24
|
+
- `specs-coverage/spec-*.md` was reviewed and density-smell findings (for example `QFAI-COV-207`) are called out as perspective gaps.
|
|
22
25
|
|
|
23
26
|
## Required Reviewers
|
|
24
27
|
|
|
@@ -98,6 +98,12 @@ Every major artifact in this stage MUST include a `## Work Orders Summary` secti
|
|
|
98
98
|
- Reviewer checks (minimum):
|
|
99
99
|
- Required roles were delegated (no orchestrator self-authoring).
|
|
100
100
|
- DoD satisfied (coverage ledger, gates, evidence, DR-IDs).
|
|
101
|
+
- Validate gate evidence exists and is fresh:
|
|
102
|
+
- `qfai validate --fail-on error --format github` completed with `error=0`.
|
|
103
|
+
- `.qfai/report/validate.log` and `.qfai/report/specs-coverage/spec-*.md` are present.
|
|
104
|
+
- Layer coverage hard gates are all clear:
|
|
105
|
+
- `QFAI-COV-201/202/203/204/205/206` are `0`.
|
|
106
|
+
- `QFAI-COV-207` warnings are reviewed as density-smell signals.
|
|
101
107
|
- **Drift Protocol enforced**:
|
|
102
108
|
- No upstream artifact edits were made without an explicit user-approved Change Request.
|
|
103
109
|
- If upstream changes exist, the correct owner skill was re-run after approval; downstream did not patch upstream directly.
|
|
@@ -203,6 +209,9 @@ Rules:
|
|
|
203
209
|
- If diagrams are written in discuss/require/spec/evidence artifacts, Mermaid syntax must be inside ` ```mermaid ` fences only.
|
|
204
210
|
- `05_Examples.md` must include `EX-ID` and `BR-Ref` mappings.
|
|
205
211
|
- `06_Test-Cases.md` must include `TC-ID`, `EX-Ref`, and `AC-Refs`.
|
|
212
|
+
- Do not complete this stage until:
|
|
213
|
+
- `qfai validate --fail-on error --format github | tee .qfai/report/validate.log` exits successfully.
|
|
214
|
+
- `.qfai/report/specs-coverage/spec-*.md` has been read for density review.
|
|
206
215
|
- Reference direction rules from `.qfai/specs/README.md` must be enforced:
|
|
207
216
|
- upper-to-lower references are forbidden
|
|
208
217
|
- lower-to-upper references are allowed
|
|
@@ -305,6 +314,11 @@ Before declaring completion, you MUST:
|
|
|
305
314
|
- Deliverable completeness: verify all required artifacts and sections are present.
|
|
306
315
|
- OQ / placeholder scan: remove unresolved placeholders (`TBD`, `TODO`, `???`, `OPEN QUESTION`, etc.) unless explicitly deferred.
|
|
307
316
|
- Run static checks proving the pack is reviewable.
|
|
317
|
+
- Run validate gate and keep evidence:
|
|
318
|
+
- `qfai validate --fail-on error --format github | tee .qfai/report/validate.log`
|
|
319
|
+
- `.qfai/report/specs-coverage/spec-*.md`
|
|
320
|
+
- If validate fails, fix spec-layer sources and rerun validate until `error=0`.
|
|
321
|
+
- Do not patch upstream intent from downstream artifacts (Drift Protocol applies).
|
|
308
322
|
|
|
309
323
|
## Goal
|
|
310
324
|
|
|
@@ -353,7 +367,10 @@ Create or update layered SDD artifacts in one run so downstream execution phases
|
|
|
353
367
|
7. Execute Phase 2 (Slice) for at least one user-story slice and pass slice gate.
|
|
354
368
|
8. Execute Phase 3 (Plan finalize) and make `10_Plan.md` actionable as How-only.
|
|
355
369
|
9. Execute Phase 4 (Delta update) and record adoption/rejection rationale.
|
|
356
|
-
10. Run
|
|
370
|
+
10. Run `qfai validate --fail-on error --format github | tee .qfai/report/validate.log`.
|
|
371
|
+
11. Run Density Review Pass using `.qfai/report/specs-coverage/spec-*.md` and `QFAI-COV-207` warnings.
|
|
372
|
+
12. If any validate error exists, fix the source layer table(s) and repeat steps 10-11 until `error=0`.
|
|
373
|
+
13. Record static checks, validate evidence, and density review outcomes in evidence.
|
|
357
374
|
|
|
358
375
|
## Unified SDD Quality Gate
|
|
359
376
|
|
|
@@ -367,6 +384,8 @@ Run static checks:
|
|
|
367
384
|
- Confirm reference direction follows lower-to-upper only.
|
|
368
385
|
- Confirm required edges `US -> AC -> BR -> EX -> TC`.
|
|
369
386
|
- Confirm BR/Examples/Test-cases contain non-empty IDs and coverage mapping.
|
|
387
|
+
- Confirm `QFAI-COV-201/202/203/204/205/206` are zero.
|
|
388
|
+
- Confirm `.qfai/report/specs-coverage/spec-*.md` was reviewed and `QFAI-COV-207` warnings were triaged.
|
|
370
389
|
- Confirm `10_Plan.md` exists and contains implementation/test strategy as How-only.
|
|
371
390
|
- Confirm `specs/plan.md` does not exist.
|
|
372
391
|
- Confirm `09_delta.md` (or `*_delta.md`) includes rejected guardrails (`DO NOT`, `Temptation`) when rejections exist.
|
|
@@ -384,6 +403,7 @@ Required sections:
|
|
|
384
403
|
- Decisions made (with rationale)
|
|
385
404
|
- Work performed (what changed, where)
|
|
386
405
|
- Commands executed + key outputs
|
|
406
|
+
- Validate evidence paths (`.qfai/report/validate.log`, `.qfai/report/specs-coverage/spec-*.md`)
|
|
387
407
|
- Gaps / Open risks
|
|
388
408
|
- Final status (PASS/FAIL) + who confirmed
|
|
389
409
|
|
|
@@ -411,6 +431,9 @@ When declaring DONE, include:
|
|
|
411
431
|
- [ ] `10_Plan.md` is finalized with implementation/test strategy (How-only).
|
|
412
432
|
- [ ] `specs/plan.md` was not created.
|
|
413
433
|
- [ ] `09_delta.md` (or `*_delta.md`) contains adoption/rejection rationale.
|
|
434
|
+
- [ ] `qfai validate --fail-on error --format github` ran and produced `error=0`.
|
|
435
|
+
- [ ] `QFAI-COV-201/202/203/204/205/206` are all zero.
|
|
436
|
+
- [ ] `.qfai/report/specs-coverage/spec-*.md` was reviewed for density-smell signals (`QFAI-COV-207`).
|
|
414
437
|
- [ ] Unresolved items are tracked in shared/spec Open Questions files.
|
|
415
438
|
- [ ] Quality gate checks are recorded in evidence.
|
|
416
439
|
- [ ] Evidence file exists and is complete.
|
|
@@ -51,6 +51,20 @@ reviewers:
|
|
|
51
51
|
role: Design Review Lead
|
|
52
52
|
- id: runtime-gatekeeper
|
|
53
53
|
role: Runtime Gatekeeper
|
|
54
|
+
|
|
55
|
+
quality_gates:
|
|
56
|
+
validate:
|
|
57
|
+
required_codes:
|
|
58
|
+
- QFAI-COV-201
|
|
59
|
+
- QFAI-COV-202
|
|
60
|
+
- QFAI-COV-203
|
|
61
|
+
- QFAI-COV-204
|
|
62
|
+
- QFAI-COV-205
|
|
63
|
+
- QFAI-COV-206
|
|
64
|
+
coverage_report:
|
|
65
|
+
required_path: .qfai/report/specs-coverage/spec-*.md
|
|
66
|
+
warning_signal:
|
|
67
|
+
- QFAI-COV-207
|
|
54
68
|
defaults:
|
|
55
69
|
- id: qa-lead
|
|
56
70
|
role: Quality Lead
|
|
@@ -36,6 +36,23 @@ For each review cycle, create:
|
|
|
36
36
|
- `.qfai/review/review-<timestamp>/R01_<reviewer>.md`, `R02_<reviewer>.md`, ...
|
|
37
37
|
- `.qfai/review/review-<timestamp>/summary.json`
|
|
38
38
|
|
|
39
|
+
## Validate Hard Gate Checks (Mandatory)
|
|
40
|
+
|
|
41
|
+
- Confirm `qfai validate --fail-on error --format github` ran in the latest cycle.
|
|
42
|
+
- Confirm `.qfai/report/validate.log` exists and corresponds to current artifacts.
|
|
43
|
+
- Confirm hard gates are all zero:
|
|
44
|
+
- `QFAI-COV-201`
|
|
45
|
+
- `QFAI-COV-202`
|
|
46
|
+
- `QFAI-COV-203`
|
|
47
|
+
- `QFAI-COV-204`
|
|
48
|
+
- `QFAI-COV-205`
|
|
49
|
+
- `QFAI-COV-206`
|
|
50
|
+
|
|
51
|
+
## Coverage Report Review (Mandatory)
|
|
52
|
+
|
|
53
|
+
- Review `.qfai/report/specs-coverage/spec-*.md` before marking fixed.
|
|
54
|
+
- Treat `QFAI-COV-207` as a density-smell signal and request perspective-based improvements (boundary/negative/permission/state), not raw count inflation.
|
|
55
|
+
|
|
39
56
|
`summary.json` minimum schema:
|
|
40
57
|
|
|
41
58
|
- `version`
|
package/dist/cli/index.cjs
CHANGED
|
@@ -1589,8 +1589,8 @@ var import_promises7 = require("fs/promises");
|
|
|
1589
1589
|
var import_node_path8 = __toESM(require("path"), 1);
|
|
1590
1590
|
var import_node_url2 = require("url");
|
|
1591
1591
|
async function resolveToolVersion() {
|
|
1592
|
-
if ("1.4.
|
|
1593
|
-
return "1.4.
|
|
1592
|
+
if ("1.4.25".length > 0) {
|
|
1593
|
+
return "1.4.25";
|
|
1594
1594
|
}
|
|
1595
1595
|
try {
|
|
1596
1596
|
const packagePath = resolvePackageJsonPath();
|
|
@@ -7940,7 +7940,7 @@ async function validateDiscussPack(root) {
|
|
|
7940
7940
|
issues.push(
|
|
7941
7941
|
issue(
|
|
7942
7942
|
"QFAI-DISCUSS-028",
|
|
7943
|
-
`legacy discuss pack \u3092\u691C\u51FA\u3057\u307E\u3057\u305F\uFF08v1.4.
|
|
7943
|
+
`legacy discuss pack \u3092\u691C\u51FA\u3057\u307E\u3057\u305F\uFF08v1.4.25 \u306F warning\uFF09: ${legacyPacks.join(", ")}`,
|
|
7944
7944
|
"warning",
|
|
7945
7945
|
discussRoot,
|
|
7946
7946
|
"discussPack.legacy",
|
|
@@ -8438,10 +8438,70 @@ async function validateV1421Coverage(entry) {
|
|
|
8438
8438
|
const acCoverage = buildCoverageCounts(acIds, tcToAcRefs);
|
|
8439
8439
|
const brCoverage = buildCoverageCounts(brIds, exToBrRefs);
|
|
8440
8440
|
const exCoverage = buildCoverageCounts(exIds, tcToExRefs);
|
|
8441
|
+
const brWithoutAcRefs = findSourcesWithEmptyRefs(brToAcRefs);
|
|
8442
|
+
const exWithoutBrRefs = findSourcesWithEmptyRefs(exToBrRefs);
|
|
8443
|
+
const tcWithoutRefs = findTcWithoutAnyRefs(tcToAcRefs, tcToExRefs);
|
|
8444
|
+
const exWithMultipleBrRefs = findSourcesWithMultipleRefs(exToBrRefs);
|
|
8441
8445
|
const missingAc = findUncoveredIds(acCoverage);
|
|
8442
8446
|
const missingBr = findUncoveredIds(brCoverage);
|
|
8443
8447
|
const missingEx = findUncoveredIds(exCoverage);
|
|
8444
8448
|
const issues = [];
|
|
8449
|
+
if (brWithoutAcRefs.length > 0) {
|
|
8450
|
+
issues.push(
|
|
8451
|
+
issue(
|
|
8452
|
+
"QFAI-COV-204",
|
|
8453
|
+
`AC-Refs \u304C\u7A7A\u306E BR \u304C\u3042\u308A\u307E\u3059: ${brWithoutAcRefs.join(", ")}`,
|
|
8454
|
+
"error",
|
|
8455
|
+
entry.businessRulesPath,
|
|
8456
|
+
"layerCoverage.brRequiresAcRefs",
|
|
8457
|
+
brWithoutAcRefs,
|
|
8458
|
+
"change",
|
|
8459
|
+
"04_Business-Rules.md \u306E `AC-Refs` \u306B\u3001\u5404 BR \u304C\u53C2\u7167\u3059\u308B AC \u30921\u4EF6\u4EE5\u4E0A\u8A2D\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002"
|
|
8460
|
+
)
|
|
8461
|
+
);
|
|
8462
|
+
}
|
|
8463
|
+
if (exWithoutBrRefs.length > 0) {
|
|
8464
|
+
issues.push(
|
|
8465
|
+
issue(
|
|
8466
|
+
"QFAI-COV-205",
|
|
8467
|
+
`BR-Ref \u304C\u7A7A\u306E EX \u304C\u3042\u308A\u307E\u3059: ${exWithoutBrRefs.join(", ")}`,
|
|
8468
|
+
"error",
|
|
8469
|
+
entry.examplesPath,
|
|
8470
|
+
"layerCoverage.exRequiresBrRef",
|
|
8471
|
+
exWithoutBrRefs,
|
|
8472
|
+
"change",
|
|
8473
|
+
"05_Examples.md \u306E `BR-Ref` \u306B\u3001\u5404 EX \u304C\u5177\u4F53\u5316\u3059\u308B BR \u30921\u4EF6\u4EE5\u4E0A\u8A2D\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002"
|
|
8474
|
+
)
|
|
8475
|
+
);
|
|
8476
|
+
}
|
|
8477
|
+
if (tcWithoutRefs.length > 0) {
|
|
8478
|
+
issues.push(
|
|
8479
|
+
issue(
|
|
8480
|
+
"QFAI-COV-206",
|
|
8481
|
+
`AC-Refs \u3068 EX-Ref \u304C\u7A7A\u306E TC \u304C\u3042\u308A\u307E\u3059: ${tcWithoutRefs.join(", ")}`,
|
|
8482
|
+
"error",
|
|
8483
|
+
entry.testCasesPath,
|
|
8484
|
+
"layerCoverage.tcRequiresAnyRef",
|
|
8485
|
+
tcWithoutRefs,
|
|
8486
|
+
"change",
|
|
8487
|
+
"06_Test-Cases.md \u306E\u5404 TC \u306B `AC-Refs` \u307E\u305F\u306F `EX-Ref` \u306E\u3069\u3061\u3089\u304B\uFF08\u63A8\u5968: \u4E21\u65B9\uFF09\u3092\u8A2D\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002"
|
|
8488
|
+
)
|
|
8489
|
+
);
|
|
8490
|
+
}
|
|
8491
|
+
if (exWithMultipleBrRefs.length > 0) {
|
|
8492
|
+
issues.push(
|
|
8493
|
+
issue(
|
|
8494
|
+
"QFAI-COV-207",
|
|
8495
|
+
`1\u3064\u306E EX \u304C\u8907\u6570 BR \u3092\u53C2\u7167\u3057\u3066\u3044\u307E\u3059: ${formatMultiRefSignals(exWithMultipleBrRefs)}`,
|
|
8496
|
+
"warning",
|
|
8497
|
+
entry.examplesPath,
|
|
8498
|
+
"layerCoverage.exBroadBrRef",
|
|
8499
|
+
exWithMultipleBrRefs.map(([id]) => id),
|
|
8500
|
+
"change",
|
|
8501
|
+
"05_Examples.md \u306E `BR-Ref` \u306F EX \u3054\u3068\u306B1\u4EF6\u3078\u5206\u5272\u3067\u304D\u308B\u304B\u78BA\u8A8D\u3057\u3066\u304F\u3060\u3055\u3044\uFF08\u8584\u3055/\u66D6\u6627\u3055\u306E\u30B7\u30B0\u30CA\u30EB\uFF09\u3002"
|
|
8502
|
+
)
|
|
8503
|
+
);
|
|
8504
|
+
}
|
|
8445
8505
|
if (missingAc.length > 0) {
|
|
8446
8506
|
issues.push(
|
|
8447
8507
|
issue(
|
|
@@ -8654,6 +8714,28 @@ function buildCoverageCounts(targets, refsBySource) {
|
|
|
8654
8714
|
}
|
|
8655
8715
|
return counts;
|
|
8656
8716
|
}
|
|
8717
|
+
function findSourcesWithEmptyRefs(refsBySource) {
|
|
8718
|
+
return Array.from(refsBySource.entries()).filter(([, refs]) => refs.size === 0).map(([id]) => id).sort((left, right) => left.localeCompare(right));
|
|
8719
|
+
}
|
|
8720
|
+
function findSourcesWithMultipleRefs(refsBySource) {
|
|
8721
|
+
return Array.from(refsBySource.entries()).filter(([, refs]) => refs.size > 1).map(([id, refs]) => {
|
|
8722
|
+
const sortedRefs = Array.from(refs.values()).sort(
|
|
8723
|
+
(left, right) => left.localeCompare(right)
|
|
8724
|
+
);
|
|
8725
|
+
return [id, sortedRefs];
|
|
8726
|
+
}).sort((left, right) => left[0].localeCompare(right[0]));
|
|
8727
|
+
}
|
|
8728
|
+
function findTcWithoutAnyRefs(tcToAcRefs, tcToExRefs) {
|
|
8729
|
+
const ids = /* @__PURE__ */ new Set([...tcToAcRefs.keys(), ...tcToExRefs.keys()]);
|
|
8730
|
+
return Array.from(ids).filter((id) => {
|
|
8731
|
+
const acCount = tcToAcRefs.get(id)?.size ?? 0;
|
|
8732
|
+
const exCount = tcToExRefs.get(id)?.size ?? 0;
|
|
8733
|
+
return acCount === 0 && exCount === 0;
|
|
8734
|
+
}).sort((left, right) => left.localeCompare(right));
|
|
8735
|
+
}
|
|
8736
|
+
function formatMultiRefSignals(signals) {
|
|
8737
|
+
return signals.map(([id, refs]) => `${id}(${refs.join(", ")})`).join(", ");
|
|
8738
|
+
}
|
|
8657
8739
|
function toCoverageRows(counts) {
|
|
8658
8740
|
return Array.from(counts.entries()).map(([id, count]) => ({ id, count })).sort((left, right) => left.id.localeCompare(right.id));
|
|
8659
8741
|
}
|
|
@@ -9979,7 +10061,7 @@ async function validateRequirePackReadiness(root, config) {
|
|
|
9979
10061
|
issues.push(
|
|
9980
10062
|
issue(
|
|
9981
10063
|
"QFAI-RPACK-006",
|
|
9982
|
-
`legacy require-pack \u3092\u691C\u51FA\u3057\u307E\u3057\u305F\uFF08v1.4.
|
|
10064
|
+
`legacy require-pack \u3092\u691C\u51FA\u3057\u307E\u3057\u305F\uFF08v1.4.25 \u306F warning\uFF09: ${readiness.legacyPackNames.join(", ")}`,
|
|
9983
10065
|
"warning",
|
|
9984
10066
|
requireRoot,
|
|
9985
10067
|
"requirePack.legacy",
|
|
@@ -10084,7 +10166,7 @@ async function validateRepositoryHygiene(root, config) {
|
|
|
10084
10166
|
issues.push(
|
|
10085
10167
|
issue(
|
|
10086
10168
|
"QFAI-HYG-001",
|
|
10087
|
-
`legacy \u30C7\u30A3\u30EC\u30AF\u30C8\u30EA\u3092\u691C\u51FA\u3057\u307E\u3057\u305F\uFF08v1.4.
|
|
10169
|
+
`legacy \u30C7\u30A3\u30EC\u30AF\u30C8\u30EA\u3092\u691C\u51FA\u3057\u307E\u3057\u305F\uFF08v1.4.25 \u306F warning\uFF09: .qfai/${rule.legacy}/`,
|
|
10088
10170
|
"warning",
|
|
10089
10171
|
legacyPath,
|
|
10090
10172
|
"hygiene.legacyDirectory",
|
|
@@ -10099,7 +10181,7 @@ async function validateRepositoryHygiene(root, config) {
|
|
|
10099
10181
|
issues.push(
|
|
10100
10182
|
issue(
|
|
10101
10183
|
"QFAI-HYG-002",
|
|
10102
|
-
`specs \u914D\u4E0B\u306B\u30C6\u30F3\u30D7\u30EC\u6DF7\u5165\u7591\u3044\u3092\u691C\u51FA\u3057\u307E\u3057\u305F\uFF08v1.4.
|
|
10184
|
+
`specs \u914D\u4E0B\u306B\u30C6\u30F3\u30D7\u30EC\u6DF7\u5165\u7591\u3044\u3092\u691C\u51FA\u3057\u307E\u3057\u305F\uFF08v1.4.25 \u306F warning\uFF09: ${suspiciousPaths.join(", ")}`,
|
|
10103
10185
|
"warning",
|
|
10104
10186
|
specsRoot,
|
|
10105
10187
|
"hygiene.templateContamination",
|
|
@@ -12517,13 +12599,20 @@ var ISSUE_EXPECTED_BY_CODE = {
|
|
|
12517
12599
|
"QFAI-RPACK-003": "The latest require-pack files contain minimum substantive content.",
|
|
12518
12600
|
"QFAI-RPACK-004": "No blocking OQ remains in 08_OQ.md (Disposition=open with Gate discuss|require|sdd).",
|
|
12519
12601
|
"QFAI-RPACK-005": "require-* naming must be timestamp format only (dangerous names are forbidden).",
|
|
12520
|
-
"QFAI-RPACK-006": "Legacy require-* serial packs are migration warnings in v1.4.
|
|
12602
|
+
"QFAI-RPACK-006": "Legacy require-* serial packs are migration warnings in v1.4.25.",
|
|
12521
12603
|
"QFAI-DISCUSS-023": "Discuss directory naming uses discuss-YYYYMMDDhhmmssSSS for new outputs.",
|
|
12522
12604
|
"QFAI-DISCUSS-024": "Latest discuss pack contains required files (01_Context.md..09_delta.md).",
|
|
12523
12605
|
"QFAI-DISCUSS-025": "No open OQ remains in latest discuss 05_OQ-Register.md.",
|
|
12524
12606
|
"QFAI-DISCUSS-026": "Deferred rows include complete metadata in 07_Deferred.md.",
|
|
12525
12607
|
"QFAI-DISCUSS-027": "Every deferred OQ in 05_OQ-Register.md is listed in 07_Deferred.md.",
|
|
12526
|
-
"QFAI-DISCUSS-028": "Legacy discuss serial packs are migration warnings in v1.4.
|
|
12608
|
+
"QFAI-DISCUSS-028": "Legacy discuss serial packs are migration warnings in v1.4.25.",
|
|
12609
|
+
"QFAI-COV-201": "Every AC must be referenced by at least one TC (`AC-Refs`).",
|
|
12610
|
+
"QFAI-COV-202": "Every BR must be referenced by at least one EX (`BR-Ref`).",
|
|
12611
|
+
"QFAI-COV-203": "Every EX must be referenced by at least one TC (`EX-Ref`).",
|
|
12612
|
+
"QFAI-COV-204": "Every BR row must include at least one AC reference in `AC-Refs`.",
|
|
12613
|
+
"QFAI-COV-205": "Every EX row must include at least one BR reference in `BR-Ref`.",
|
|
12614
|
+
"QFAI-COV-206": "Every TC row must include at least one reference in `AC-Refs` or `EX-Ref`.",
|
|
12615
|
+
"QFAI-COV-207": "EX rows that reference multiple BR IDs should be reviewed as density-smell signals.",
|
|
12527
12616
|
"QFAI-HYG-001": "Legacy directory aliases are warned and should be migrated to canonical names.",
|
|
12528
12617
|
"QFAI-HYG-002": "Template/sample artifacts should not remain under `.qfai/specs/**`.",
|
|
12529
12618
|
"QFAI-REVIEW-001": "`.qfai/review/.gitignore` exists.",
|
|
@@ -12532,7 +12621,7 @@ var ISSUE_EXPECTED_BY_CODE = {
|
|
|
12532
12621
|
"QFAI-REVIEW-004": "Each review pack contains `summary.json`.",
|
|
12533
12622
|
"QFAI-REVIEW-005": "Each review pack contains one or more reviewer files (`Rxx_*.md`).",
|
|
12534
12623
|
"QFAI-REVIEW-006": "Each review summary JSON is parseable.",
|
|
12535
|
-
"QFAI-REVIEW-007": "Each review summary satisfies the v1.4.
|
|
12624
|
+
"QFAI-REVIEW-007": "Each review summary satisfies the v1.4.25 minimum schema.",
|
|
12536
12625
|
"QFAI-CONTRACT-030": "Contract index references must match declared contract IDs in .qfai/contracts/**."
|
|
12537
12626
|
};
|
|
12538
12627
|
function resolveIssueTarget(issue2) {
|