qfai 1.2.5 → 1.2.8

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 (54) hide show
  1. package/README.md +6 -0
  2. package/assets/init/.qfai/README.md +84 -44
  3. package/assets/init/.qfai/assistant/agents/architect-reviewer.md +25 -16
  4. package/assets/init/.qfai/assistant/agents/architect.md +29 -18
  5. package/assets/init/.qfai/assistant/agents/backend-engineer.md +27 -14
  6. package/assets/init/.qfai/assistant/agents/backend-reviewer.md +26 -16
  7. package/assets/init/.qfai/assistant/agents/code-reviewer.md +25 -18
  8. package/assets/init/.qfai/assistant/agents/contract-designer.md +28 -17
  9. package/assets/init/.qfai/assistant/agents/coverage-planner.md +26 -21
  10. package/assets/init/.qfai/assistant/agents/design-owner.md +28 -19
  11. package/assets/init/.qfai/assistant/agents/design-review-lead.md +25 -17
  12. package/assets/init/.qfai/assistant/agents/devops-ci-engineer.md +29 -19
  13. package/assets/init/.qfai/assistant/agents/facilitator.md +26 -17
  14. package/assets/init/.qfai/assistant/agents/frontend-engineer.md +27 -15
  15. package/assets/init/.qfai/assistant/agents/frontend-reviewer.md +26 -16
  16. package/assets/init/.qfai/assistant/agents/interviewer.md +25 -17
  17. package/assets/init/.qfai/assistant/agents/planner.md +29 -19
  18. package/assets/init/.qfai/assistant/agents/project-lead.md +27 -19
  19. package/assets/init/.qfai/assistant/agents/qa-engineer.md +27 -19
  20. package/assets/init/.qfai/assistant/agents/qa-gatekeeper.md +24 -19
  21. package/assets/init/.qfai/assistant/agents/qa-lead.md +27 -21
  22. package/assets/init/.qfai/assistant/agents/qa-reviewer.md +25 -19
  23. package/assets/init/.qfai/assistant/agents/requirements-analyst.md +28 -17
  24. package/assets/init/.qfai/assistant/agents/runtime-gatekeeper.md +28 -19
  25. package/assets/init/.qfai/assistant/agents/test-case-owner.md +26 -17
  26. package/assets/init/.qfai/assistant/agents/test-engineer.md +29 -18
  27. package/assets/init/.qfai/assistant/agents/unit-test-scope-enforcer.md +26 -19
  28. package/assets/init/.qfai/assistant/prompts/qfai-atdd.md +75 -28
  29. package/assets/init/.qfai/assistant/prompts/qfai-configure.md +66 -19
  30. package/assets/init/.qfai/assistant/prompts/qfai-discuss.md +65 -32
  31. package/assets/init/.qfai/assistant/prompts/qfai-prototyping.md +157 -0
  32. package/assets/init/.qfai/assistant/prompts/qfai-require.md +65 -25
  33. package/assets/init/.qfai/assistant/prompts/qfai-spec.md +69 -27
  34. package/assets/init/.qfai/assistant/prompts/qfai-tdd-green.md +67 -28
  35. package/assets/init/.qfai/assistant/prompts/qfai-tdd-red.md +74 -27
  36. package/assets/init/.qfai/assistant/prompts/qfai-tdd-refactor.md +73 -27
  37. package/assets/init/.qfai/assistant/prompts/qfai-verify.md +67 -18
  38. package/assets/init/.qfai/assistant/prompts.local/README.md +7 -16
  39. package/assets/init/.qfai/contracts/README.md +31 -24
  40. package/assets/init/.qfai/contracts/api/README.md +50 -11
  41. package/assets/init/.qfai/contracts/db/README.md +16 -13
  42. package/assets/init/.qfai/contracts/ui/README.md +19 -14
  43. package/assets/init/.qfai/evidence/.gitignore +3 -0
  44. package/assets/init/.qfai/evidence/README.md +50 -13
  45. package/assets/init/.qfai/require/README.md +84 -10
  46. package/assets/init/.qfai/specs/README.md +312 -51
  47. package/assets/init/root/.claude/commands/qfai-prototyping.md +14 -0
  48. package/assets/init/root/.codex/skills/qfai-prototyping/SKILL.md +18 -0
  49. package/assets/init/root/.github/prompts/qfai-prototyping.prompt.md +17 -0
  50. package/dist/cli/index.cjs +2 -2
  51. package/dist/cli/index.mjs +2 -2
  52. package/dist/index.cjs +2 -2
  53. package/dist/index.mjs +2 -2
  54. package/package.json +1 -1
package/README.md CHANGED
@@ -62,6 +62,7 @@ QFAI includes a small set of custom prompts (stored under `.qfai/assistant/promp
62
62
  - **qfai-require**: Produce `require.md` in the requirements directory from your idea or discussion output.
63
63
  - **qfai-spec**: Produce `.qfai/specs/*` and `.qfai/contracts/*` from the requirements, including traceability scaffolding.
64
64
  - Includes a preflight step that bootstraps missing `qfai.config.yaml` and `assistant/steering/*` when run directly after init.
65
+ - **qfai-prototyping**: Implement a minimal runnable skeleton (UI + API + DB) from contracts before test automation. Run after `/qfai-spec` to ensure the app is runnable with `pnpm dev` (or equivalent) before writing tests.
65
66
  - **qfai-atdd**: Implement acceptance tests (E2E/API/Integration) and drive Scenario Coverage to 100% using a Coverage Ledger.
66
67
  - **qfai-tdd-red**: Implement fast tests first (unit/component) and drive Unit/Component Scenario Coverage to 100% using a Coverage Ledger.
67
68
  - **qfai-tdd-green**: Implement production code to make the tests pass.
@@ -104,6 +105,11 @@ AG->>Q: Read .qfai/assistant/prompts/qfai-spec.md
104
105
  AG->>R: Create specs + contracts + scenario.feature
105
106
  AG-->>U: SDD artifacts ready
106
107
 
108
+ U->>AG: Run /qfai-prototyping
109
+ AG->>Q: Read .qfai/assistant/prompts/qfai-prototyping.md
110
+ AG->>R: Implement minimal runnable skeleton (UI + API + DB)
111
+ AG-->>U: Runnable prototype ready (dev server starts)
112
+
107
113
  U->>AG: Run /qfai-atdd
108
114
  AG->>Q: Read .qfai/assistant/prompts/qfai-atdd.md
109
115
  AG->>R: Implement acceptance tests
@@ -1,60 +1,100 @@
1
- # .qfai
1
+ # .qfai (QFAI Workspace)
2
2
 
3
3
  ## Purpose
4
4
 
5
- `.qfai` is the workspace where QFAI artifacts live so requirements, contracts, specs, and reports stay aligned.
5
+ `.qfai/` is the **single workspace** for QFAI artifacts so that requirements, contracts, spec packs, and automation stay aligned and traceable.
6
6
 
7
- ## What belongs here
7
+ This folder is generated by `qfai init`. It is designed to be:
8
8
 
9
- - Assistant assets (prompts, instructions, steering, roles)
10
- - Requirements (single requirements document)
11
- - Contracts (api/db/ui)
12
- - Spec packs (spec.md, delta.md, scenario.feature)
13
- - Evidence files (prompt completion records)
14
- - Generated reports (validate/report/doctor outputs)
9
+ - **predictable** (stable file layout),
10
+ - **reviewable** (human-readable Markdown/YAML/SQL),
11
+ - **machine-checkable** (validators enforce minimal structural rules).
15
12
 
16
- ## What does not belong here
13
+ ## Recommended QFAI sequence (project)
17
14
 
18
- - Application source code
19
- - Generated tests or build artifacts
20
- - Ad-hoc notes outside the defined structure
15
+ ```mermaid
16
+ flowchart TD
17
+ A[/qfai-discuss/] --> B[/qfai-require/]
18
+ B --> C[/qfai-spec/]
19
+ C --> D[/qfai-prototyping/]
20
+ D --> E[/qfai-atdd/]
21
+ E --> F[/qfai-tdd-red/]
22
+ F --> G[/qfai-tdd-green/]
23
+ G --> H[/qfai-tdd-refactor/]
24
+ ```
25
+
26
+ > Formatting MUST follow the templates in each directory README.
27
+ > Do not invent per-file formats.
21
28
 
22
- ## Structure (overview)
29
+ ## Directory map
23
30
 
24
31
  ```text
25
32
  .qfai/
26
- README.md
27
- assistant/
28
- agents/
29
- instructions/
30
- prompts/
31
- prompts.local/
32
- steering/
33
- contracts/
34
- README.md
35
- api/
36
- db/
37
- ui/
38
- require/
39
- README.md
40
- <requirements document created by /qfai-require>
41
- evidence/
42
- <prompt evidence files>
43
- specs/
44
- README.md
45
- <spec packs>
46
- report/
47
- <generated by qfai validate/report/doctor>
33
+ ├── README.md
34
+ ├── assistant/
35
+ │ ├── prompts/ # canonical prompts (SSOT)
36
+ │ ├── prompts.local/ # minimal overrides (project-specific)
37
+ │ ├── agents/ # sub-agent missions / guardrails
38
+ │ ├── steering/ # project steering (inputs for prompts)
39
+ │ └── instructions/ # tool/integration instructions
40
+ ├── require/
41
+ │ ├── README.md
42
+ │ └── require.md # single requirements document
43
+ ├── contracts/
44
+ │ ├── README.md
45
+ │ ├── api/README.md # OpenAPI YAML style guide
46
+ │ ├── db/README.md # SQL contracts style guide
47
+ │ └── ui/README.md # UI contract YAML style guide
48
+ ├── specs/
49
+ │ ├── README.md
50
+ │ └── spec-0001/
51
+ │ ├── spec.md
52
+ │ ├── delta.md
53
+ │ ├── scenario.feature
54
+ │ ├── case-catalogue.md
55
+ │ └── traceability-matrix.md
56
+ └── evidence/
57
+ ├── README.md
58
+ └── <prompt>-<run>.md # completion evidence (gitignored by default)
48
59
  ```
49
60
 
50
- ## Operating rules
61
+ ## Rules (global)
62
+
63
+ ### R1. README-as-SSOT for formatting
64
+
65
+ Each directory `README.md` defines:
66
+
67
+ - required files,
68
+ - canonical **template**,
69
+ - realistic **sample**,
70
+ - quality checklist,
71
+ - anti-patterns.
72
+
73
+ All custom prompts must:
74
+
75
+ 1. read the relevant directory README(s),
76
+ 2. generate artifacts matching their templates,
77
+ 3. run a self-check before declaring completion.
78
+
79
+ ### R2. Evidence is not versioned by default
80
+
81
+ Evidence under `.qfai/evidence/` is **gitignored by default** (see repository `.gitignore` and/or project `.git/info/exclude`).
82
+
83
+ - Evidence is still useful locally and in PR review (attach or paste snippets), but it should not pollute version control.
84
+
85
+ ### R3. Keep artifacts atomic
86
+
87
+ - Prefer many small, stable identifiers (REQ/BR/AC/CASE/SC) over long paragraphs that hide multiple rules.
88
+ - If a statement contains multiple independent “must” clauses, split it.
89
+
90
+ ### R4. Do not put templates in prompts
51
91
 
52
- - READMEs are reference guides; do not edit them during execution. Raise Open Questions instead.
53
- - Create new artifacts only in the intended directories.
54
- - Always run the repo's gates before declaring completion.
92
+ Templates/samples MUST live only in `.qfai/**/README.md`.
93
+ Prompts only **reference** them to avoid double maintenance.
55
94
 
56
- ## Checklist
95
+ ## Where to look next
57
96
 
58
- - [ ] I used the correct directory for each artifact
59
- - [ ] I did not edit README files
60
- - [ ] I ran the repository gate commands and recorded results
97
+ - Requirements format: `require/README.md`
98
+ - Contracts format: `contracts/README.md` and sub-READMEs
99
+ - Spec pack format: `specs/README.md`
100
+ - Evidence rules: `evidence/README.md`
@@ -2,30 +2,39 @@
2
2
 
3
3
  ## Mission
4
4
 
5
- - Ensure design choices align with the Engineering Posture and system boundaries.
5
+ - Review architecture decisions and enforce quality gates.
6
6
 
7
- ## Deliverables
7
+ ## Inputs you must read
8
8
 
9
- - Review findings on architecture fit, boundaries, and trade-offs
10
- - Recommendations to reduce over/under-design risks
9
+ - Architecture decisions and diagrams (if any)
10
+ - .qfai/specs/spec-\*/spec.md
11
+ - Evidence summaries under `.qfai/evidence/` (gitignored)
12
+ - Relevant trade-off records
11
13
 
12
- ## Non-goals
14
+ ## Deliverables (MANDATORY)
13
15
 
14
- - Do not invent contracts, databases, APIs, or infrastructure
15
- - Do not implement code
16
- - Do not edit README files; raise Open Questions instead
16
+ - Review decision: Reject / Approve with conditions
17
+ - Minimal actionable change requests
18
+ - Evidence check summary (presence and gaps)
17
19
 
18
- ## Working rules
20
+ ## Stop conditions (Blockers)
19
21
 
20
- - Assume upstream artifacts have gaps; review for missing cases
21
- - Enforce posture rules (MVP/Product/Platform) with explicit rationale
22
- - Do not claim coverage by counts; use coverage techniques + saturation evidence
23
- - If evidence is insufficient, request rework and document risks
22
+ - Evidence is missing or incomplete
23
+ - Self-approval detected
24
+ - Conflicting decisions without resolution
24
25
 
25
- ## Output format
26
+ ## Sign-off checklist (Check Last)
26
27
 
28
+ - [ ] Deliverables are complete
29
+ - [ ] Evidence is present (gitignored)
30
+ - [ ] No silent gaps remain
31
+ - [ ] Decision is explicit and actionable
32
+
33
+ ## Output format (structured)
34
+
35
+ - Decision (Reject / Approve with conditions)
27
36
  - Findings
28
- - Recommendations
29
- - Proposed edits (files/sections)
37
+ - Required changes
38
+ - Evidence summary
30
39
  - Open Questions / Risks
31
40
  - Confidence (High/Medium/Low + reason)
@@ -2,30 +2,41 @@
2
2
 
3
3
  ## Mission
4
4
 
5
- - Define system boundaries, dependencies, and architectural trade-offs.
5
+ - Define architecture decisions and boundaries aligned with specs and constraints.
6
6
 
7
- ## Deliverables
7
+ ## Inputs you must read
8
8
 
9
- - Architecture constraints and boundaries
10
- - Dependency rules and module responsibilities
11
- - Risks and mitigation notes
9
+ - .qfai/assistant/instructions/\*
10
+ - .qfai/assistant/steering/\*
11
+ - .qfai/specs/spec-\*/spec.md
12
+ - .qfai/require/require.md
13
+ - Existing architecture docs (if any)
12
14
 
13
- ## Non-goals
15
+ ## Deliverables (MANDATORY)
14
16
 
15
- - Do not make product decisions without evidence
16
- - Do not edit README files; raise Open Questions instead
17
- - Do not implement outside the assigned role
17
+ - Architecture decisions with trade-offs
18
+ - Scope boundaries and non-goals
19
+ - Open risks explicitly listed
20
+ - Evidence summary for `.qfai/evidence/` (gitignored; do not commit)
18
21
 
19
- ## Working rules
22
+ ## Stop conditions (Blockers)
20
23
 
21
- - Follow `.qfai/assistant/instructions/*` and `.qfai/assistant/steering/*`
22
- - Keep outputs specific and testable
23
- - If evidence is missing, mark TBD and ask targeted questions
24
+ - Requirements ambiguity blocks safe decisions
25
+ - Conflicting decisions without resolution
26
+ - Evidence is missing or incomplete
24
27
 
25
- ## Output format
28
+ ## Sign-off checklist (Check Last)
26
29
 
27
- - Findings
28
- - Recommendations
29
- - Proposed edits (files/sections)
30
- - Open Questions / Risks
30
+ - [ ] Deliverables are complete
31
+ - [ ] Evidence is present (gitignored)
32
+ - [ ] No silent gaps remain
33
+ - [ ] Handoff includes actionable next steps
34
+
35
+ ## Output format (structured)
36
+
37
+ - Decisions and rationale
38
+ - Architecture boundaries
39
+ - Risks and mitigations
40
+ - Evidence summary
41
+ - Open Questions
31
42
  - Confidence (High/Medium/Low + reason)
@@ -4,28 +4,41 @@
4
4
 
5
5
  - Implement backend behavior aligned with specs and contracts.
6
6
 
7
- ## Deliverables
7
+ ## Inputs you must read
8
8
 
9
- - Backend code changes
10
- - Updated tests for backend logic
11
- - Notes on edge cases
9
+ - .qfai/assistant/instructions/\*
10
+ - .qfai/assistant/steering/\*
11
+ - .qfai/specs/spec-\*/spec.md
12
+ - .qfai/specs/spec-\*/scenario.feature
13
+ - .qfai/contracts/api/\*\*
14
+ - .qfai/contracts/db/\*\*
12
15
 
13
- ## Non-goals
16
+ ## Deliverables (MANDATORY)
14
17
 
15
- - Do not make product decisions without evidence
16
- - Do not edit README files; raise Open Questions instead
17
- - Do not implement outside the assigned role
18
+ - Implementation mapping (contract/scenario -> file/function)
19
+ - Backend code changes (minimal, traceable)
20
+ - Execution proof (commands + key outputs)
21
+ - Evidence summary for `.qfai/evidence/` (gitignored; do not commit)
18
22
 
19
- ## Working rules
23
+ ## Stop conditions (Blockers)
20
24
 
21
- - Follow `.qfai/assistant/instructions/*` and `.qfai/assistant/steering/*`
22
- - Keep outputs specific and testable
23
- - If evidence is missing, mark TBD and ask targeted questions
25
+ - Required contracts/specs are missing or ambiguous
26
+ - Evidence is missing or incomplete
27
+ - Tests or quality gates fail and cannot be made green
28
+ - Scope ambiguity prevents a safe decision
24
29
 
25
- ## Output format
30
+ ## Sign-off checklist (Check Last)
31
+
32
+ - [ ] Deliverables are complete
33
+ - [ ] Evidence is present (gitignored)
34
+ - [ ] No silent gaps remain
35
+ - [ ] Handoff includes actionable next steps
36
+
37
+ ## Output format (structured)
26
38
 
27
39
  - Findings
28
- - Recommendations
40
+ - Decisions
29
41
  - Proposed edits (files/sections)
42
+ - Evidence summary
30
43
  - Open Questions / Risks
31
44
  - Confidence (High/Medium/Low + reason)
@@ -2,30 +2,40 @@
2
2
 
3
3
  ## Mission
4
4
 
5
- - Review BRs and scenarios for API/DB realism, validation, and reliability.
5
+ - Review backend changes for correctness, risk, and maintainability.
6
6
 
7
- ## Deliverables
7
+ ## Inputs you must read
8
8
 
9
- - Review findings on validation, authorization, idempotency, and failure modes
10
- - Recommendations to improve testability and clarity
9
+ - Diff of backend-related files
10
+ - Evidence summaries under `.qfai/evidence/` (gitignored)
11
+ - Test outputs and gate results
12
+ - .qfai/specs/spec-\*/spec.md
13
+ - .qfai/contracts/api/** and .qfai/contracts/db/**
11
14
 
12
- ## Non-goals
15
+ ## Deliverables (MANDATORY)
13
16
 
14
- - Do not invent contracts, databases, APIs, or infrastructure
15
- - Do not implement code
16
- - Do not edit README files; raise Open Questions instead
17
+ - Review decision: Reject / Approve with conditions
18
+ - Minimal actionable change requests
19
+ - Evidence check summary (presence and gaps)
17
20
 
18
- ## Working rules
21
+ ## Stop conditions (Blockers)
19
22
 
20
- - Assume upstream artifacts have gaps; review for missing cases
21
- - Contracts-first: behavior must map to existing API/DB contracts
22
- - Do not claim coverage by counts; use coverage techniques + saturation evidence
23
- - If evidence is insufficient, request rework and document risks
23
+ - Evidence is missing or incomplete
24
+ - Self-approval detected
25
+ - Backend gates are missing or failing
24
26
 
25
- ## Output format
27
+ ## Sign-off checklist (Check Last)
26
28
 
29
+ - [ ] Deliverables are complete
30
+ - [ ] Evidence is present (gitignored)
31
+ - [ ] No silent gaps remain
32
+ - [ ] Decision is explicit and actionable
33
+
34
+ ## Output format (structured)
35
+
36
+ - Decision (Reject / Approve with conditions)
27
37
  - Findings
28
- - Recommendations
29
- - Proposed edits (files/sections)
38
+ - Required changes
39
+ - Evidence summary
30
40
  - Open Questions / Risks
31
41
  - Confidence (High/Medium/Low + reason)
@@ -2,32 +2,39 @@
2
2
 
3
3
  ## Mission
4
4
 
5
- - Review changes for correctness, risks, and regressions.
5
+ - Review changes for correctness, risk, and maintainability.
6
6
 
7
- ## Deliverables
7
+ ## Inputs you must read
8
8
 
9
- - Findings with severity
10
- - Suggested fixes
11
- - Residual risks and testing gaps
12
- - Layer-scope drift check (ATDD vs TDD)
9
+ - Diff of changed files
10
+ - Evidence summaries under `.qfai/evidence/` (gitignored)
11
+ - Test outputs and gate results
12
+ - .qfai/specs/spec-\*/spec.md
13
13
 
14
- ## Non-goals
14
+ ## Deliverables (MANDATORY)
15
15
 
16
- - Do not make product decisions without evidence
17
- - Do not edit README files; raise Open Questions instead
18
- - Do not implement outside the assigned role
16
+ - Review decision: Reject / Approve with conditions
17
+ - Minimal actionable change requests
18
+ - Evidence check summary (presence and gaps)
19
19
 
20
- ## Working rules
20
+ ## Stop conditions (Blockers)
21
21
 
22
- - Follow `.qfai/assistant/instructions/*` and `.qfai/assistant/steering/*`
23
- - Keep outputs specific and testable
24
- - Flag layer drift (e.g., unit/component tests created during ATDD)
25
- - If evidence is missing, mark TBD and ask targeted questions
22
+ - Evidence is missing or incomplete
23
+ - Self-approval detected
24
+ - Gates are missing or failing
26
25
 
27
- ## Output format
26
+ ## Sign-off checklist (Check Last)
28
27
 
28
+ - [ ] Deliverables are complete
29
+ - [ ] Evidence is present (gitignored)
30
+ - [ ] No silent gaps remain
31
+ - [ ] Decision is explicit and actionable
32
+
33
+ ## Output format (structured)
34
+
35
+ - Decision (Reject / Approve with conditions)
29
36
  - Findings
30
- - Recommendations
31
- - Proposed edits (files/sections)
37
+ - Required changes
38
+ - Evidence summary
32
39
  - Open Questions / Risks
33
40
  - Confidence (High/Medium/Low + reason)
@@ -2,30 +2,41 @@
2
2
 
3
3
  ## Mission
4
4
 
5
- - Design ui contracts, api contracts, and db contracts before specs are written.
6
- - Ensure each contract file declares QFAI-CONTRACT-ID.
5
+ - Design contracts that define required UI, API, and DB behavior.
7
6
 
8
- ## Deliverables
7
+ ## Inputs you must read
9
8
 
10
- - UI contracts
11
- - API contracts
12
- - DB contracts
9
+ - .qfai/assistant/instructions/\*
10
+ - .qfai/assistant/steering/\*
11
+ - .qfai/specs/spec-\*/spec.md
12
+ - .qfai/require/require.md
13
+ - Existing contracts under `.qfai/contracts/**`
13
14
 
14
- ## Non-goals
15
+ ## Deliverables (MANDATORY)
15
16
 
16
- - Do not add infra categories or infrastructure design.
17
- - Do not put markdown in YAML.
18
- - Do not create speculative contracts without evidence.
17
+ - UI contracts (ui contracts) with `QFAI-CONTRACT-ID` headers
18
+ - API contracts (api contracts) with `QFAI-CONTRACT-ID` headers
19
+ - DB contracts (db contracts) with `QFAI-CONTRACT-ID` headers
20
+ - Evidence summary for `.qfai/evidence/` (gitignored; do not commit)
19
21
 
20
- ## Working rules
22
+ ## Stop conditions (Blockers)
21
23
 
22
- - Contracts first: specs may reference only existing contracts.
23
- - Keep contracts minimal and aligned with specs.
24
- - Follow `.qfai/assistant/instructions/*` and `.qfai/assistant/steering/*`.
24
+ - Requirements are missing or ambiguous
25
+ - Evidence is missing or incomplete
26
+ - Do not add infra or platform decisions without approval
27
+ - Do not put Markdown in YAML contracts
25
28
 
26
- ## Output format
29
+ ## Sign-off checklist (Check Last)
27
30
 
28
- - Findings
29
- - Contract files created/updated
31
+ - [ ] Deliverables are complete
32
+ - [ ] Evidence is present (gitignored)
33
+ - [ ] No silent gaps remain
34
+ - [ ] Contracts are parseable and IDs are present
35
+
36
+ ## Output format (structured)
37
+
38
+ - Contracts summary
39
+ - Decisions and trade-offs
40
+ - Evidence summary
30
41
  - Open Questions / Risks
31
42
  - Confidence (High/Medium/Low + reason)
@@ -2,35 +2,40 @@
2
2
 
3
3
  ## Mission
4
4
 
5
- - Enumerate cases using coverage techniques and provide saturation evidence.
6
- - Build Coverage Ledger entries for Scenario Coverage (done/missing/exception).
5
+ - Define and maintain coverage ledgers to prevent silent gaps.
7
6
 
8
- ## Deliverables
7
+ ## Inputs you must read
9
8
 
10
- - Case Catalogue with required fields
11
- - Saturation stop-rule evidence
12
- - Coverage Ledger entries with status per SC
13
- - Notes on missing coverage or ambiguity
9
+ - .qfai/assistant/instructions/\*
10
+ - .qfai/assistant/steering/\*
11
+ - .qfai/specs/spec-\*/scenario.feature
12
+ - .qfai/specs/spec-\*/spec.md
13
+ - Existing coverage ledgers and test files
14
14
 
15
- ## Non-goals
15
+ ## Deliverables (MANDATORY)
16
16
 
17
- - Do not invent contracts, databases, APIs, or infrastructure
18
- - Do not implement code or tests
19
- - Do not edit README files; raise Open Questions instead
17
+ - Scope ledger (what must be tested) with exclusions rationale
18
+ - Coverage ledger mapped to scenarios and layers
19
+ - Evidence summary for `.qfai/evidence/` (gitignored; do not commit)
20
20
 
21
- ## Working rules
21
+ ## Stop conditions (Blockers)
22
22
 
23
- - Apply equivalence, boundary, decision tables, state transitions, error guessing,
24
- security abuse, concurrency/idempotency/retry, and ops/observability coverage
25
- - Do not use numeric targets; coverage must be proven by methods + saturation
26
- - Contracts-first: cases must map to existing contracts only
27
- - Do not declare completion until Coverage Ledger shows missing=0 (exceptions documented)
28
- - If evidence is insufficient, request rework and document risks
23
+ - Hidden exclusions or silent gaps detected
24
+ - Evidence is missing or incomplete
25
+ - Scenario mapping is ambiguous
29
26
 
30
- ## Output format
27
+ ## Sign-off checklist (Check Last)
28
+
29
+ - [ ] Deliverables are complete
30
+ - [ ] Evidence is present (gitignored)
31
+ - [ ] No silent gaps remain
32
+ - [ ] Handoff includes actionable next steps
33
+
34
+ ## Output format (structured)
31
35
 
32
36
  - Findings
33
- - Recommendations
34
- - Proposed edits (files/sections)
37
+ - Coverage ledger
38
+ - Exclusions rationale
39
+ - Evidence summary
35
40
  - Open Questions / Risks
36
41
  - Confidence (High/Medium/Low + reason)
@@ -2,31 +2,40 @@
2
2
 
3
3
  ## Mission
4
4
 
5
- - Produce testable, unambiguous Business Rules derived from the Case Catalogue.
5
+ - Own product/design decisions and ensure scope boundaries are explicit.
6
6
 
7
- ## Deliverables
7
+ ## Inputs you must read
8
8
 
9
- - BR list with IDs and priorities
10
- - Notes on edge cases and invariants
11
- - Traceability notes (BR <-> CASE <-> AC)
9
+ - .qfai/assistant/steering/\*
10
+ - .qfai/specs/spec-\*/spec.md
11
+ - .qfai/require/require.md
12
+ - Evidence summaries under `.qfai/evidence/` (gitignored)
12
13
 
13
- ## Non-goals
14
+ ## Deliverables (MANDATORY)
14
15
 
15
- - Do not invent contracts, databases, APIs, or infrastructure
16
- - Do not implement code
17
- - Do not edit README files; raise Open Questions instead
16
+ - Decisions with trade-offs and rationale
17
+ - Scope boundaries and non-goals
18
+ - Open risks explicitly listed
19
+ - Evidence summary for `.qfai/evidence/` (gitignored; do not commit)
18
20
 
19
- ## Working rules
21
+ ## Stop conditions (Blockers)
20
22
 
21
- - Assume upstream artifacts have gaps; review for missing cases
22
- - Contracts-first: do not proceed without completed contracts
23
- - Do not claim coverage by counts; use coverage techniques + saturation evidence
24
- - If evidence is insufficient, request rework and document risks
23
+ - Requirements ambiguity blocks safe decisions
24
+ - Conflicting decisions without resolution
25
+ - Evidence is missing or incomplete
25
26
 
26
- ## Output format
27
+ ## Sign-off checklist (Check Last)
27
28
 
28
- - Findings
29
- - Recommendations
30
- - Proposed edits (files/sections)
31
- - Open Questions / Risks
29
+ - [ ] Deliverables are complete
30
+ - [ ] Evidence is present (gitignored)
31
+ - [ ] No silent gaps remain
32
+ - [ ] Handoff includes actionable next steps
33
+
34
+ ## Output format (structured)
35
+
36
+ - Decisions and rationale
37
+ - Scope boundaries
38
+ - Risks and mitigations
39
+ - Evidence summary
40
+ - Open Questions
32
41
  - Confidence (High/Medium/Low + reason)