qfai 2.1.1 → 2.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +56 -36
- package/assets/defaults/agent-routing/qfai-triage.yml +9 -0
- package/assets/defaults/workflows/run-owned-cleanup.yml +12 -0
- package/assets/init/.claude/settings.json +27 -9
- package/assets/init/.codex/hooks.json +20 -8
- package/assets/init/.qfai/assistant/agent/frontend-engineer.md +5 -0
- package/assets/init/.qfai/assistant/agent/product-experience-architect.md +4 -0
- package/assets/init/.qfai/assistant/agent/product-surface-reviewer.md +7 -0
- package/assets/init/.qfai/assistant/agent/requirements-analyst.md +8 -0
- package/assets/init/.qfai/assistant/rule/communication.md +18 -8
- package/assets/init/.qfai/assistant/rule/drift-protocol.md +58 -2
- package/assets/init/.qfai/assistant/rule/references/asset-authoring.md +6 -4
- package/assets/init/.qfai/assistant/rule/references/worker-edit-boundary.md +48 -0
- package/assets/init/.qfai/assistant/rule/shared-skill-delegation-baseline.md +15 -25
- package/assets/init/.qfai/assistant/rule/shared-skill-operating-baseline.md +8 -8
- package/assets/init/.qfai/assistant/rule/ui-definition-protocol.md +6 -1
- package/assets/init/.qfai/assistant/skill/qfai-configure/SKILL.md +3 -3
- package/assets/init/.qfai/assistant/skill/qfai-discussion/references/discussion-completion-matrix.md +3 -7
- package/assets/init/.qfai/assistant/skill/qfai-discussion/references/ui-bearing-playbook.md +2 -4
- package/assets/init/.qfai/assistant/skill/qfai-discussion/references/ui_ux_best_practices.md +1 -6
- package/assets/init/.qfai/assistant/skill/qfai-discussion/templates/uiux/00_index.md +0 -16
- package/assets/init/.qfai/assistant/skill/qfai-implement/SKILL.md +9 -3
- package/assets/init/.qfai/assistant/skill/qfai-implement/references/parallelization-policy.md +9 -1
- package/assets/init/.qfai/assistant/skill/qfai-implement/references/red-admissibility.md +46 -0
- package/assets/init/.qfai/assistant/skill/qfai-implement/references/ui-affecting.md +3 -0
- package/assets/init/.qfai/assistant/skill/qfai-maintain/SKILL.md +3 -3
- package/assets/init/.qfai/assistant/skill/qfai-migration-v1-to-v2/SKILL.md +12 -6
- package/assets/init/.qfai/assistant/skill/qfai-migration-v1-to-v2/references/migration-guide.md +1 -265
- package/assets/init/.qfai/assistant/skill/qfai-migration-v1-to-v2/references/migration-placement.md +273 -0
- package/assets/init/.qfai/assistant/skill/qfai-prototyping/SKILL.md +4 -3
- package/assets/init/.qfai/assistant/skill/qfai-prototyping/references/review-payload-schema.md +2 -3
- package/assets/init/.qfai/assistant/skill/qfai-prototyping/references/reviewer-prompt.md +17 -1
- package/assets/init/.qfai/assistant/skill/qfai-run/SKILL.md +30 -17
- package/assets/init/.qfai/assistant/skill/qfai-run/references/evidence-delivery.md +322 -0
- package/assets/init/.qfai/assistant/skill/qfai-run/references/extraction.md +47 -24
- package/assets/init/.qfai/assistant/skill/qfai-run/references/operator-screens.md +218 -11
- package/assets/init/.qfai/assistant/skill/qfai-run/references/plan.md +4 -3
- package/assets/init/.qfai/assistant/skill/qfai-run/references/stage-points.md +14 -0
- package/assets/init/.qfai/assistant/skill/qfai-sdd/SKILL.md +4 -3
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/contract-artifact-rules.md +1 -0
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/design-anti-patterns.md +23 -5
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/requirements-decomposition.md +8 -0
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/sdd-execution-playbook.md +29 -4
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/sdd-triage.md +132 -4
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/spec-traceability-rules.md +14 -2
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/ui-contract-guide.md +114 -0
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/ui-design-contract-normalization.md +4 -29
- package/assets/init/.qfai/assistant/skill/qfai-sdd/templates/change-request.md +38 -1
- package/assets/init/.qfai/assistant/skill/qfai-sdd/templates/contracts/ui-contract.sample.yaml +52 -5
- package/assets/init/.qfai/assistant/skill/qfai-sdd/templates/spec/decisions.md +3 -0
- package/assets/init/.qfai/assistant/skill/qfai-triage/SKILL.md +29 -19
- package/assets/init/.qfai/assistant/skill/qfai-verify/SKILL.md +5 -4
- package/assets/init/.qfai/assistant/skill/qfai-verify/references/context-load.md +9 -6
- package/assets/init/.qfai/assistant/skill/qfai-verify/references/verify-output-contract.md +72 -7
- package/assets/init/.qfai/assistant/skill/web-research/SKILL.md +35 -21
- package/assets/init/.qfai/assistant/skill/web-research/mcp-templates/brave-search/config.toml +2 -4
- package/assets/init/.qfai/assistant/skill/web-research/mcp-templates/brave-search/mcp-config.json +9 -5
- package/assets/init/.qfai/assistant/skill/web-research/mcp-templates/firecrawl/.mcp.json +1 -2
- package/assets/init/.qfai/assistant/skill/web-research/mcp-templates/firecrawl/config.toml +3 -3
- package/assets/init/.qfai/assistant/skill/web-research/mcp-templates/firecrawl/mcp-config.json +11 -8
- package/assets/init/.qfai/assistant/skill/web-research/mcp-templates/playwright/config.toml +1 -1
- package/assets/init/.qfai/assistant/skill/web-research/mcp-templates/playwright/mcp-config.json +7 -3
- package/assets/init/.qfai/assistant/step/common-design-md/STEP.md +0 -4
- package/assets/init/.qfai/assistant/step/common-gate-run/STEP.md +98 -8
- package/assets/init/.qfai/assistant/step/common-review-cycle/STEP.md +3 -2
- package/assets/init/.qfai/assistant/step/discussion-pack/STEP.md +1 -0
- package/assets/init/.qfai/assistant/step/discussion-research/STEP.md +2 -0
- package/assets/init/.qfai/assistant/step/discussion-uiux/STEP.md +1 -3
- package/assets/init/.qfai/assistant/step/implement-backport/STEP.md +1 -1
- package/assets/init/.qfai/assistant/step/implement-benchmark/STEP.md +7 -4
- package/assets/init/.qfai/assistant/step/implement-dep-bump/STEP.md +4 -1
- package/assets/init/.qfai/assistant/step/implement-diagnose/STEP.md +2 -0
- package/assets/init/.qfai/assistant/step/implement-oracle-parity/STEP.md +2 -2
- package/assets/init/.qfai/assistant/step/implement-quarantine/STEP.md +3 -3
- package/assets/init/.qfai/assistant/step/implement-refactor/STEP.md +2 -2
- package/assets/init/.qfai/assistant/step/implement-regression-fix/STEP.md +4 -3
- package/assets/init/.qfai/assistant/step/implement-retire/STEP.md +6 -3
- package/assets/init/.qfai/assistant/step/implement-revert/STEP.md +4 -3
- package/assets/init/.qfai/assistant/step/implement-seam/STEP.md +6 -5
- package/assets/init/.qfai/assistant/step/implement-stress-harness/STEP.md +1 -1
- package/assets/init/.qfai/assistant/step/implement-sweep/STEP.md +4 -3
- package/assets/init/.qfai/assistant/step/implement-tdd/STEP.md +39 -5
- package/assets/init/.qfai/assistant/step/implement-tooling/STEP.md +22 -2
- package/assets/init/.qfai/assistant/step/maintain-edit/STEP.md +18 -14
- package/assets/init/.qfai/assistant/step/prototyping-grill/STEP.md +4 -3
- package/assets/init/.qfai/assistant/step/prototyping-loop/STEP.md +4 -0
- package/assets/init/.qfai/assistant/step/prototyping-preflight/STEP.md +1 -3
- package/assets/init/.qfai/assistant/step/sdd-contract/STEP.md +11 -0
- package/assets/init/.qfai/assistant/step/sdd-flow/STEP.md +2 -0
- package/assets/init/.qfai/assistant/step/sdd-story/STEP.md +10 -0
- package/assets/init/.qfai/assistant/step/sdd-triage/STEP.md +30 -8
- package/assets/init/.qfai/assistant/step/triage-answer/STEP.md +5 -4
- package/assets/init/.qfai/assistant/step/triage-close/STEP.md +33 -23
- package/assets/init/.qfai/assistant/step/triage-cluster/STEP.md +5 -3
- package/assets/init/.qfai/assistant/step/triage-decompose/STEP.md +2 -0
- package/assets/init/.qfai/assistant/step/triage-dedupe/STEP.md +4 -0
- package/assets/init/.qfai/assistant/step/triage-handoff/STEP.md +13 -4
- package/assets/init/.qfai/assistant/step/triage-investigate/STEP.md +8 -5
- package/assets/init/.qfai/assistant/step/triage-owned-cleanup/STEP.md +86 -0
- package/assets/init/.qfai/assistant/step/triage-request-info/STEP.md +2 -0
- package/assets/init/.qfai/assistant/step/triage-security-intake/STEP.md +6 -3
- package/assets/init/.qfai/assistant/step/verify-change-note/STEP.md +1 -0
- package/assets/init/.qfai/assistant/step/verify-commit/STEP.md +37 -9
- package/assets/init/.qfai/assistant/step/verify-external/STEP.md +5 -2
- package/assets/init/.qfai/assistant/step/verify-qfai-gate/STEP.md +7 -16
- package/assets/init/.qfai/assistant/step/verify-release-notes/STEP.md +1 -0
- package/assets/init/.qfai/assistant/step/verify-repeat-run/STEP.md +6 -4
- package/assets/init/.qfai/assistant/step/verify-repo-gate/STEP.md +121 -30
- package/assets/init/root/.agents/rules/ai-readable-markdown.md +2 -2
- package/assets/init/root/.agents/rules/api-budget.md +187 -8
- package/assets/init/root/.agents/rules/documentation-clarity.md +162 -33
- package/assets/init/root/.agents/rules/minimal-implementation.md +3 -3
- package/assets/init/root/.agents/rules/reminders.json +27 -14
- package/assets/init/root/.agents/rules/session-feedback.md +136 -0
- package/assets/init/root/.agents/rules/temporary-files.md +33 -0
- package/assets/init/root/.agents/rules/user-questions.md +48 -37
- package/assets/init/root/.github/workflows/qfai-docs.yml +1 -1
- package/assets/init/root/AGENTS.md +23 -22
- package/assets/sandbox-templates/default-deny.yaml +9 -3
- package/assets/schemas/workflow/extraction.schema.json +85 -5
- package/assets/uix-rev/comparison-review.md +1 -1
- package/assets/uix-rev/contracts-review.md +1 -2
- package/dist/cli/index.cjs +6697 -8810
- package/dist/cli/index.cjs.map +1 -1
- package/dist/cli/index.mjs +6036 -8152
- package/dist/cli/index.mjs.map +1 -1
- package/dist/index.cjs +4947 -7746
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +18 -658
- package/dist/index.d.ts +18 -658
- package/dist/index.mjs +4866 -7640
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -6
- package/assets/init/root/CLAUDE.md +0 -46
|
@@ -14,11 +14,13 @@ A `SKILL.md` states the contract and points at the file that carries the detail.
|
|
|
14
14
|
- **One topic per file.** Do not replace an oversized `SKILL.md` with an oversized `references/everything.md`; that is the same problem one directory down. Split by topic and keep each file readable on its own — a reader who followed one pointer should not have to scan past three unrelated subjects to reach the one they came for.
|
|
15
15
|
- **Every pointer resolves.** A line that moves detail out must name the file (and anchor, when the file covers more than one topic) so the reader is never left guessing where the rule went.
|
|
16
16
|
|
|
17
|
-
A hard line ceiling backs this up: **800 lines per assistant asset file**, for every `.qfai/assistant/**/*.{md,yml,yaml}` file, counted as `content.split(/\r?\n/).length` — blank lines included.
|
|
18
|
-
|
|
17
|
+
A hard line ceiling backs this up: **500 lines per Markdown assistant asset file** and **800 lines per YAML assistant asset file**, for every `.qfai/assistant/**/*.{md,yml,yaml}` file, counted as `content.split(/\r?\n/).length` — blank lines included.
|
|
18
|
+
`npx qfai doctor` measures it and reports every file over its ceiling as `assets.lineBudget`.
|
|
19
|
+
The ceiling is a backstop, not the rule: a file approaching it is a signal to move a section out, not to raise the number.
|
|
19
20
|
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
The Markdown ceiling is the limit an agent can follow in one file: it follows fewer instructions as its context grows, and follows those in the middle of a long file worst. A Markdown file has a `references/` home to move detail into. A YAML asset is parsed as data and cannot be split that way (see below), which is why its ceiling is higher.
|
|
22
|
+
|
|
23
|
+
A body at its ceiling stops shedding topics and starts packing them into longer lines, and a line count cannot see that. The width ceiling below is what catches it.
|
|
22
24
|
|
|
23
25
|
**A width ceiling makes the count honest: 400 characters per line.** A count of lines bounds reading cost only while a line is a roughly constant unit of reading, and packing broke that — one line in the shipped tree ran 9,104 characters against a median of 118, and cost the budget one unit. The two are read together, because each permits what the other refuses: width alone allows a thin
|
|
24
26
|
file of a thousand short lines, and the count alone allows a packed one.
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# Worker edits and work orders
|
|
2
|
+
|
|
3
|
+
Read when assigning worker write paths or handling a refused edit.
|
|
4
|
+
|
|
5
|
+
## Edit boundary
|
|
6
|
+
|
|
7
|
+
The work order names the checkout assigned to the task by the host, the worker's
|
|
8
|
+
write paths and the permitted edit method. Creating a Git worktree does not
|
|
9
|
+
grant the host's tools permission to edit it. Even an assigned checkout can
|
|
10
|
+
receive a refusal; verify the actual edit result rather than claiming access.
|
|
11
|
+
|
|
12
|
+
If an edit is refused, stop writes to that target. Report the tool, working
|
|
13
|
+
directory, target path and refusal text, omitting secrets. Return the owned
|
|
14
|
+
paths and a reviewable diff that can be prepared within the worker's permitted
|
|
15
|
+
area. Do not bypass the refusal through a shell, script or another tool.
|
|
16
|
+
This does not forbid shell authoring where the host already permits it.
|
|
17
|
+
|
|
18
|
+
The orchestrator checks the diff against the current files in its own permitted
|
|
19
|
+
checkout before applying it. If that edit is refused too, leave the application
|
|
20
|
+
pending and continue only independent work. Follow the existing worktree or
|
|
21
|
+
shared-index mode in `.qfai/assistant/rule/workflow.md#concurrency-stage-independent-mandatory`
|
|
22
|
+
when assigning writers and integrating their paths.
|
|
23
|
+
|
|
24
|
+
## Work order template
|
|
25
|
+
|
|
26
|
+
```text
|
|
27
|
+
Task title: <short>
|
|
28
|
+
Role: <sub-agent role>
|
|
29
|
+
Review series: <reviewed artifact> + <reviewer role> + <replacement ordinal> # review work orders only
|
|
30
|
+
Goal: <what to decide/produce>
|
|
31
|
+
Checkout: <absolute checkout assigned to this task by the host>
|
|
32
|
+
Write paths: <exact owned paths, or none for a read-only task>
|
|
33
|
+
Edit method: <host-permitted tool; worktree creation does not grant access>
|
|
34
|
+
If an edit is refused: stop that target; return tool, cwd, target, refusal text, owned paths and a reviewable diff
|
|
35
|
+
Inputs (refs):
|
|
36
|
+
- <file/section>
|
|
37
|
+
- .qfai/assistant/rule/drift-protocol.md#core-rule <!-- the protected set, in front of the agent -->
|
|
38
|
+
Constraints:
|
|
39
|
+
- must: enforce Drift Protocol
|
|
40
|
+
- must: follow applicable test-layer or validation policy
|
|
41
|
+
- must_not: patch upstream artifacts directly; every upstream change requires
|
|
42
|
+
STOP + Change Request + owner rerun per .qfai/assistant/rule/drift-protocol.md
|
|
43
|
+
Output format:
|
|
44
|
+
- <headings / bullet schema>
|
|
45
|
+
Time budget: none | <seconds> # advisory: nothing stops at it. See .qfai/assistant/rule/stage-cost.md
|
|
46
|
+
Elapsed line: end every message with `elapsed <seconds>s / <budget>s`, or `elapsed <seconds>s` when the budget is none
|
|
47
|
+
Acceptance bar: <accept when ...> | <rework when ...> # never `PASS`/`REVISE`: that is the reviewer's vocabulary and the completion gate matches on it, so a doer told to report in it emits a verdict on its own work
|
|
48
|
+
```
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
# Shared Skill Delegation Baseline
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Skills cite this baseline and add only role, stage or gate overrides.
|
|
4
4
|
|
|
5
5
|
## Sub-agent Delegation (MANDATORY)
|
|
6
6
|
|
|
7
|
-
This section binds every skill and
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
This section binds every skill and step. A skill or step repeats none of it
|
|
8
|
+
and adds no placeholder for a subsection it does not change. State only an
|
|
9
|
+
override, under the subsection it overrides.
|
|
10
10
|
|
|
11
11
|
Delegation is optional. The session agent, called the orchestrator below, may
|
|
12
12
|
author any artifact itself. It uses a sub-agent only for work that runs in
|
|
@@ -40,8 +40,15 @@ classified by the taxonomy below before any response.
|
|
|
40
40
|
- A read-only agent never runs `git checkout` or `git switch` in a worktree it
|
|
41
41
|
shares; it reads other revisions with `git show <rev>:<path>`. Each agent
|
|
42
42
|
writes scratch files only under a path of its own.
|
|
43
|
-
-
|
|
44
|
-
|
|
43
|
+
- Give each reviewer a fixed commit. Leave the checkout alone until reviews
|
|
44
|
+
return. Only read-only fixed-SHA `git show` reviews permit clean switches.
|
|
45
|
+
Writers, local gates and reviews using live files or checkout-dependent
|
|
46
|
+
execution must finish first.
|
|
47
|
+
|
|
48
|
+
### Worker edit boundary
|
|
49
|
+
|
|
50
|
+
Before assigning write paths or handling a refused edit, read
|
|
51
|
+
`.qfai/assistant/rule/references/worker-edit-boundary.md`.
|
|
45
52
|
|
|
46
53
|
### Capability Probe (MUST)
|
|
47
54
|
|
|
@@ -212,25 +219,8 @@ A blocking review that cannot be delegated because the agent budget is spent is
|
|
|
212
219
|
|
|
213
220
|
## Work order template
|
|
214
221
|
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
Role: <sub-agent role>
|
|
218
|
-
Review series: <reviewed artifact> + <reviewer role> + <replacement ordinal> # review work orders only
|
|
219
|
-
Goal: <what to decide/produce>
|
|
220
|
-
Inputs (refs):
|
|
221
|
-
- <file/section>
|
|
222
|
-
- .qfai/assistant/rule/drift-protocol.md#core-rule <!-- the protected set, in front of the agent -->
|
|
223
|
-
Constraints:
|
|
224
|
-
- must: enforce Drift Protocol
|
|
225
|
-
- must: follow applicable test-layer or validation policy
|
|
226
|
-
- must_not: patch upstream artifacts directly; every upstream change requires
|
|
227
|
-
STOP + Change Request + owner rerun per .qfai/assistant/rule/drift-protocol.md
|
|
228
|
-
Output format:
|
|
229
|
-
- <headings / bullet schema>
|
|
230
|
-
Time budget: none | <seconds> # advisory: nothing stops at it. See .qfai/assistant/rule/stage-cost.md
|
|
231
|
-
Elapsed line: end every message with `elapsed <seconds>s / <budget>s`, or `elapsed <seconds>s` when the budget is none
|
|
232
|
-
Acceptance bar: <accept when ...> | <rework when ...> # never `PASS`/`REVISE`: that is the reviewer's vocabulary and the completion gate matches on it, so a doer told to report in it emits a verdict on its own work
|
|
233
|
-
```
|
|
222
|
+
When preparing a delegation, use the template in
|
|
223
|
+
`.qfai/assistant/rule/references/worker-edit-boundary.md#work-order-template`.
|
|
234
224
|
|
|
235
225
|
## Reviewer response template
|
|
236
226
|
|
|
@@ -196,9 +196,9 @@ the policy check. The mode is `workflow.mode` in `qfai.config.yaml`. An absent k
|
|
|
196
196
|
needs the operator's answer.
|
|
197
197
|
- A QFAI work order binds the stage to its target: one business flow, or one
|
|
198
198
|
new-story slot. The stage works on that target and no other.
|
|
199
|
-
- The
|
|
200
|
-
|
|
201
|
-
|
|
199
|
+
- The session report names the agent instance that authored the work and
|
|
200
|
+
each independent reviewer. The author never counts as the work's
|
|
201
|
+
independent reviewer.
|
|
202
202
|
- These statements add to the constitution. They except no article.
|
|
203
203
|
|
|
204
204
|
## Running Steps (Mandatory)
|
|
@@ -268,12 +268,12 @@ writes nothing and states why; the stage's review reads that statement.
|
|
|
268
268
|
|
|
269
269
|
## Default Autopilot Policy inside a run
|
|
270
270
|
|
|
271
|
-
Inside a run,
|
|
272
|
-
satisfied by one kind of authorization the run records:
|
|
271
|
+
Inside a run, record the authorization for each bucket in the session report:
|
|
273
272
|
|
|
274
|
-
- An `ask-user` item is satisfied only by
|
|
275
|
-
|
|
276
|
-
|
|
273
|
+
- An `ask-user` item is satisfied only by the operator's answer to it.
|
|
274
|
+
Name that answer and its source; an agent's choice is not an operator answer.
|
|
275
|
+
- A `hard-required` input is satisfied by the operator's request or by the
|
|
276
|
+
run's binding. Name the request or work order that supplies it.
|
|
277
277
|
- An `auto-decide` item needs no authorization.
|
|
278
278
|
- `--auto` satisfies nothing. It answers no `ask-user` item and supplies no
|
|
279
279
|
`hard-required` input.
|
|
@@ -27,6 +27,8 @@ A downstream skill reads the UI definition in this order.
|
|
|
27
27
|
- primary tasks
|
|
28
28
|
- states
|
|
29
29
|
- actions
|
|
30
|
+
- supplements (the text shown beyond title, group headings and labels, each with
|
|
31
|
+
its reason) and, when written, structure (the groups and headings, in order)
|
|
30
32
|
|
|
31
33
|
3. **Brand SSOT**
|
|
32
34
|
- root `DESIGN.md` (front-matter + `# Brand Philosophy` body), the only
|
|
@@ -36,6 +38,10 @@ A downstream skill reads the UI definition in this order.
|
|
|
36
38
|
prototyping loop ran): the final prototype, procurement and implementation
|
|
37
39
|
notes
|
|
38
40
|
|
|
41
|
+
The supplements and structure are required input: implementation adds no text the
|
|
42
|
+
contract does not declare, and surface review compares the rendered text with them.
|
|
43
|
+
A screen that lacks them is returned to `/qfai-sdd`.
|
|
44
|
+
|
|
39
45
|
The paths that render a user-visible surface are declared by `uiux.surfacePaths`
|
|
40
46
|
in `qfai.config.yaml`, and nowhere else.
|
|
41
47
|
|
|
@@ -51,6 +57,5 @@ in `qfai.config.yaml`, and nowhere else.
|
|
|
51
57
|
## Forbidden Fallbacks
|
|
52
58
|
|
|
53
59
|
- Do not infer downstream UI behavior from discussion-pack sidecars.
|
|
54
|
-
- Do not use retired design contract files.
|
|
55
60
|
- Do not use HTML mock sections as downstream source of truth.
|
|
56
61
|
- Do not treat a competitor reference as a selected design direction.
|
|
@@ -293,7 +293,7 @@ Fill policy templates with repo evidence.
|
|
|
293
293
|
- Keep existing content when already accurate.
|
|
294
294
|
- When evidence is missing, write `TBD` and record what is missing.
|
|
295
295
|
- Do not invent facts.
|
|
296
|
-
- Fill `03_contract/tech.md` in its template's shape: a Stack row for the runtime, the platform and each tool detected, each runtime dependency with its reason, and the quality-gate commands under Standard commands, one labelled item each. It holds no rule and no constraint; a constraint goes to `01_policy/constraint.md`.
|
|
296
|
+
- Fill `03_contract/tech.md` in its template's shape: a Stack row for the runtime, the platform and each tool detected, with one row per test layer whose Choice names the tool, the files it was observed in, and why it fits; each runtime dependency with its reason, and the quality-gate commands under Standard commands, one labelled item each. It holds no rule and no constraint; a constraint goes to `01_policy/constraint.md`.
|
|
297
297
|
- Fill `## Architecture` of `03_contract/tech.md` from the codebase: one row per layer the module layout shows, what it is responsible for, and the layers its imports reach, or `-`. Name layers, never paths. Implementation places new code by this table and reviewers judge a change against it, so write the import directions the code has.
|
|
298
298
|
- A layer is a group of modules whose imports point one way: an upper layer uses the layers below it, and a lower layer never imports an upper one.
|
|
299
299
|
- Draw the layers first, as one `mermaid` `flowchart TD` with a node per layer and an `Upper --> Lower` edge per import direction. Then write the table rows from the uppermost layer down, so each Depends on names only rows below it. `npx qfai validate` reports a diagram and a table that disagree.
|
|
@@ -304,10 +304,10 @@ Edit:
|
|
|
304
304
|
|
|
305
305
|
- `validation.traceability.testFileGlobs`
|
|
306
306
|
- `validation.traceability.testFileExcludeGlobs` (only if needed)
|
|
307
|
-
- `routing` or `reviewProfiles` only when the
|
|
307
|
+
- `routing` or `reviewProfiles` only when the user asks to change one; each matching entry replaces the shipped default as a whole
|
|
308
308
|
- `uiux.surfacePaths`: the repository-relative globs of the paths observed to render a user-visible surface, or `[]` when the repository renders none. Keep an existing value unless the user asks to change it. An absent key leaves the UI impact decision unevaluable.
|
|
309
309
|
|
|
310
|
-
Keep all other config keys unchanged.
|
|
310
|
+
Keep all other config keys unchanged. Add no key the package already defaults, `paths.specsDir` included; a value the project set stays.
|
|
311
311
|
|
|
312
312
|
## Step 5 - Evidence sampling
|
|
313
313
|
|
package/assets/init/.qfai/assistant/skill/qfai-discussion/references/discussion-completion-matrix.md
CHANGED
|
@@ -74,12 +74,9 @@ Completion is blocked until all are true:
|
|
|
74
74
|
ordinary. This is the one visual decision made here, because no later stage asks the user for
|
|
75
75
|
it: `/qfai-sdd`'s `common-design-md` step authors tokens from whatever is recorded. A direction taken without the
|
|
76
76
|
user carries `chosen_by: assumption` and an open entry in `11_OQ-Register.md`.
|
|
77
|
-
6. No forbidden legacy sidecar exists under `uiux/` (see
|
|
78
|
-
`templates/uiux/00_index.md#Forbidden Legacy Files`).
|
|
79
77
|
|
|
80
78
|
Evaluation axes are global constants (4-step ordinal: weak / acceptable / strong /
|
|
81
|
-
exceptional) and are NOT authored as discussion sidecars
|
|
82
|
-
taste-interview, option-comparison or selected-anchor sidecar is required or permitted.
|
|
79
|
+
exceptional) and are NOT authored as discussion sidecars.
|
|
83
80
|
|
|
84
81
|
## CLI Packs
|
|
85
82
|
|
|
@@ -93,9 +90,8 @@ so conditions 1 and 5 above do not apply to it:
|
|
|
93
90
|
`validators/designContractReadiness.ts` skips `QFAI-DCON-030`/`-033`/`-034` for it.
|
|
94
91
|
- No design direction either: nothing downstream reads a theme for a surface that renders
|
|
95
92
|
no tokens.
|
|
96
|
-
- Conditions 2, 3, 4
|
|
97
|
-
full screen-contract schema, unranked exploration directions,
|
|
98
|
-
sidecar, and zero open OQs.
|
|
93
|
+
- Conditions 2, 3, 4 and 7 apply unchanged: all three canonical `uiux/` sidecars, the
|
|
94
|
+
full screen-contract schema, unranked exploration directions, and zero open OQs.
|
|
99
95
|
- `route:` on a `cli` screen contract names the command invocation, not a web path, as the `cli` section of the UI-bearing playbook sets out.
|
|
100
96
|
- No `prototyping.yaml`: `cli` is not a valid prototyping execution surface.
|
|
101
97
|
- `primary_surface: cli` with a visual `secondary_surfaces` entry is NOT a cli-only pack —
|
|
@@ -74,7 +74,5 @@ shadows:
|
|
|
74
74
|
|
|
75
75
|
Trend Scan is **not** a sidecar file. Trend Scan lives at
|
|
76
76
|
`04_Sources.md#Trend Scan` (part of the core nine-file discussion pack).
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
constants and are not authored as discussion sidecars. UI-bearing
|
|
80
|
-
completion checks read Trend Scan from `04_Sources.md`.
|
|
77
|
+
Evaluation axes are global constants and are not authored as discussion
|
|
78
|
+
sidecars. UI-bearing completion checks read Trend Scan from `04_Sources.md`.
|
package/assets/init/.qfai/assistant/skill/qfai-discussion/references/ui_ux_best_practices.md
CHANGED
|
@@ -116,12 +116,7 @@ Those three are the entire canonical sidecar family. Evaluation axes are global
|
|
|
116
116
|
QFAI CLI applies — not by any file in this tree. The reviewer prompt that
|
|
117
117
|
`/qfai-prototyping` ships restates that axis set; editing it does not change the set the CLI accepts. Axes are not
|
|
118
118
|
authored as discussion sidecars. Discussion is planner-first: it carries exploration directions
|
|
119
|
-
unranked and does not select a single visual winner
|
|
120
|
-
override, option-comparison or selected-anchor sidecar. Do NOT create
|
|
121
|
-
`10_implementation_strategy.md`, `11_design_taste_interview.md`, the `20-24`
|
|
122
|
-
design-evaluation family, `30_option_comparison.md`, or `31_selected_anchor_screen.md` —
|
|
123
|
-
those filenames are forbidden, see `templates/uiux/00_index.md#Forbidden Legacy Files`, and
|
|
124
|
-
creating them fails validation.
|
|
119
|
+
unranked and does not select a single visual winner.
|
|
125
120
|
|
|
126
121
|
### What must be explicit in the discussion pack
|
|
127
122
|
|
|
@@ -30,19 +30,3 @@ cli-only pack — `primary_surface: cli` with no visual surface in
|
|
|
30
30
|
`secondary_surfaces` — never gets one: the `common-design-md` step writes none, and
|
|
31
31
|
`/qfai-prototyping` does not run on `cli`. Do not report any pack as
|
|
32
32
|
incomplete for a missing `DESIGN.md`.
|
|
33
|
-
|
|
34
|
-
## Forbidden Legacy Files
|
|
35
|
-
|
|
36
|
-
The following files are NOT part of the canonical family and must NOT be created in new packs:
|
|
37
|
-
|
|
38
|
-
- `10_implementation_strategy.md` — discussion carries directions unranked, so it selects no strategy
|
|
39
|
-
- `11_design_taste_interview.md` — brand signals are recorded in `04_Sources.md`
|
|
40
|
-
- `12_design_system.md` — replaced by root `DESIGN.md`
|
|
41
|
-
- the `20`–`24` design-evaluation family — the evaluator axes are fixed by the CLI, not authored here
|
|
42
|
-
- `30_option_comparison.md` — replaced by root `DESIGN.md`
|
|
43
|
-
- `31_selected_anchor_screen.md` — replaced by root `DESIGN.md`
|
|
44
|
-
- `33_exploration_rubric.md` — replaced by the fixed evaluator axes (`.qfai/assistant/skill/qfai-prototyping/references/reviewer-prompt.md`)
|
|
45
|
-
- `34_evaluator_calibration.md` — replaced by the fixed evaluator axes (`.qfai/assistant/skill/qfai-prototyping/references/reviewer-prompt.md`)
|
|
46
|
-
- `40_contracts.md` — replaced by `40_screen_contracts.md`
|
|
47
|
-
- `50_review_bundle.md` — replaced by `50_review_input_bundle.md`
|
|
48
|
-
- `60_critique_loop.md` — removed (critique integrated into review bundle)
|
|
@@ -86,6 +86,11 @@ design. They are written by the `write-acceptance-tests` route, or by
|
|
|
86
86
|
`implement-acceptance` run alone, and the report says which BF and AC tests
|
|
87
87
|
still have an empty body.
|
|
88
88
|
|
|
89
|
+
For that report or a handoff of unfinished BF/AC bodies, read
|
|
90
|
+
`.qfai/assistant/step/verify-repo-gate/STEP.md#acceptance-evidence-and-follow-up`.
|
|
91
|
+
It separates annotation proof, body states, actual behavior and execution,
|
|
92
|
+
and the remaining work's owner and completion criteria.
|
|
93
|
+
|
|
89
94
|
Each of these runs alone, instead of that order, when the request is not new
|
|
90
95
|
behaviour but a failure, a repair or upkeep:
|
|
91
96
|
|
|
@@ -139,9 +144,10 @@ every finding of its one review is fixed or answered. Invoked by name, it runs
|
|
|
139
144
|
completion; when that fresh validate result has no test-obligation EX finding
|
|
140
145
|
for this BF, the invocation reports "nothing to do", and reads or writes no
|
|
141
146
|
ledger status. Inside a route it runs no validate: the verify stage does.
|
|
142
|
-
|
|
143
|
-
recommended,
|
|
144
|
-
Under a no-question mode, list
|
|
147
|
+
When the next step needs the user's answer, ask a question listing the next
|
|
148
|
+
actions, `/qfai-verify` recommended, per `.agents/rules/user-questions.md` § 6.
|
|
149
|
+
Completion-only reports ask nothing. Under a no-question mode, list remaining
|
|
150
|
+
actions instead.
|
|
145
151
|
|
|
146
152
|
## Default Autopilot Policy
|
|
147
153
|
|
package/assets/init/.qfai/assistant/skill/qfai-implement/references/parallelization-policy.md
CHANGED
|
@@ -10,7 +10,15 @@ For each candidate item, name its production files, test files, contracts, fixtu
|
|
|
10
10
|
|
|
11
11
|
Deny parallel dispatch when two items write the same shared fixture or mock file, or mutate the same fixture instance. A shared fixture module that both items only read as-is does not by itself deny parallel dispatch.
|
|
12
12
|
|
|
13
|
-
Give each worker
|
|
13
|
+
Give each worker an exact file ownership list and a checkout assigned by the host.
|
|
14
|
+
Use separate worktrees when the host supports editing them; otherwise use the
|
|
15
|
+
existing shared-index mode in
|
|
16
|
+
`.qfai/assistant/rule/workflow.md#concurrency-stage-independent-mandatory`.
|
|
17
|
+
Creating a worktree does not grant edit permission. For a refused edit, follow
|
|
18
|
+
`.qfai/assistant/rule/shared-skill-delegation-baseline.md#worker-edit-boundary`.
|
|
19
|
+
Workers do not change another worker's files or the story tree. The orchestrator
|
|
20
|
+
integrates their results and resolves every overlap before judging either item
|
|
21
|
+
complete.
|
|
14
22
|
|
|
15
23
|
## Integration gate
|
|
16
24
|
|
|
@@ -6,6 +6,52 @@ A RED observation belongs to one example and one test selector. The test must lo
|
|
|
6
6
|
|
|
7
7
|
A collection error, import error, syntax error, missing fixture, timeout before the assertion, or unconditional throw is a missing seam. Repair the seam and repeat RED before production behavior is added.
|
|
8
8
|
|
|
9
|
+
### Selected-case execution
|
|
10
|
+
|
|
11
|
+
For each focused Red, Green and Refactor invocation, keep this human receipt
|
|
12
|
+
under the target example in the existing stage report:
|
|
13
|
+
|
|
14
|
+
- The exact command with argument boundaries, cwd, file selection and case
|
|
15
|
+
selector. Preserve the Standard Test command's quoted arguments; a name
|
|
16
|
+
pattern does not select files.
|
|
17
|
+
- The actual runtime version, reporter, input revision and raw output/log
|
|
18
|
+
reference. Explain intentional input changes between invocations.
|
|
19
|
+
- The target EX, test source declaration and full file/parent/case identity.
|
|
20
|
+
Resolve duplicate short names through their full hierarchy; account for the
|
|
21
|
+
runner's actual parent selection rather than assuming a leaf-only pattern
|
|
22
|
+
runs every nesting shape.
|
|
23
|
+
- Evidence that this selected case's body executed, linked to its actual
|
|
24
|
+
terminal result. Retain skip, TODO, cancellation, interruption and any
|
|
25
|
+
expected-failure inversion explicitly.
|
|
26
|
+
- Process exit, aggregate counts and file/container results, apart from that
|
|
27
|
+
case evidence. An annotation and static scanner linkage prove a declaration,
|
|
28
|
+
not runtime execution or a behavioral result.
|
|
29
|
+
|
|
30
|
+
Compare actual TAP start and terminal records, spec named results or JUnit
|
|
31
|
+
nodes with the declared target and its full hierarchy. A TAP label, spec glyph
|
|
32
|
+
or JUnit testcase can belong to a container; none alone proves the selected
|
|
33
|
+
leaf body ran. Dots, coverage and summaries alone are also insufficient. If
|
|
34
|
+
output is unfamiliar, incomplete or cannot identify the selected case, retain
|
|
35
|
+
it, name the missing observation and obtain supported case-level evidence.
|
|
36
|
+
Do not guess a parser or invent a receipt format.
|
|
37
|
+
|
|
38
|
+
Zero selected executions, skip, TODO, cancellation, interruption or missing
|
|
39
|
+
identifiable body evidence cannot close a phase, even with exit zero or a
|
|
40
|
+
passing file/container. Correct selection or observation and repeat the
|
|
41
|
+
focused invocation. Failure of a parent, another case, an import or an
|
|
42
|
+
unconditional throw is not the selected assertion's ordinary RED. An
|
|
43
|
+
expected-failure inversion is recorded separately; its reported pass is not
|
|
44
|
+
ordinary behavior success. Existing approved alternative RED routes remain
|
|
45
|
+
available.
|
|
46
|
+
|
|
47
|
+
Ordinary RED reaches and fails the selected intended assertion or expected
|
|
48
|
+
exception on its stated behavior. GREEN and Refactor must observe that same
|
|
49
|
+
selected behavior succeeding on the intended input. Do not reuse another
|
|
50
|
+
case's result or a prior input revision's result as proof for this invocation.
|
|
51
|
+
The normal verify run establishes full collection coverage; no extra full suite is
|
|
52
|
+
required for each focused cycle. This receipt adds no ledger, JSON field,
|
|
53
|
+
gate status, runtime parser or runner.
|
|
54
|
+
|
|
9
55
|
## Assertion control
|
|
10
56
|
|
|
11
57
|
Temporarily neutralize only the example assertion while keeping the test compilable and runnable. The same command must pass. Capture the changed lines and result, then restore the assertion before recording RED. This control shows that the reported failure came from the assertion.
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
Read the UI surface paths `uiux.surfacePaths` declares in qfai.config.yaml, and resolve paths.contractsDir from the same file. Read every UI contract under its ui/ directory, and the root DESIGN.md if present for the brand tokens.
|
|
6
6
|
When a prototyping loop ran in this checkout, read its handoff at .qfai/prototype/final/handoff.json: the final prototype, its procurement and the implementation notes.
|
|
7
7
|
Read the flow, story, acceptance criterion, and example that the implementation changes.
|
|
8
|
+
For each screen the change renders, read its `supplements` and `structure` in the UI contract before adding text: the screen shows its title, group headings, labels and declared supplements, and no other text.
|
|
8
9
|
|
|
9
10
|
## Routing
|
|
10
11
|
|
|
@@ -22,3 +23,5 @@ product-surface-reviewer. Do not infer that a change has no UI effect from its d
|
|
|
22
23
|
For a UI affecting example, report the screen state, action, expected and observed result, and a capture or rendered artifact. The artifact must identify the source revision. In the stage review, product-surface-reviewer judges each UI affecting example, its UI contracts, and its captured state. The review verdict refers to that revision.
|
|
23
24
|
|
|
24
25
|
If the implementation or capture changes after the verdict, refresh the capture and review. A passing code test cannot substitute for the visual and interaction evidence that the acceptance criterion requires.
|
|
26
|
+
|
|
27
|
+
Capture each declared task at a desktop width and a narrow width, in the normal state and in every declared empty, error, loading and success state the screen has. A text the contract declares that the capture lacks, or a text the capture shows that the contract does not declare, is a finding.
|
|
@@ -57,9 +57,9 @@ Markdown and link checks run over the changed files, each exiting 0. A check the
|
|
|
57
57
|
project does not have is UNRUN, not a pass.
|
|
58
58
|
|
|
59
59
|
The stage returns what `maintain-edit` lists under "What the stage returns".
|
|
60
|
-
|
|
61
|
-
`.agents/rules/user-questions.md` § 6 sets out.
|
|
62
|
-
Under a no-question mode, list
|
|
60
|
+
Ask for the next action only when proceeding requires the user's answer, as
|
|
61
|
+
`.agents/rules/user-questions.md` § 6 sets out. A completion-only report needs
|
|
62
|
+
no question. Under a no-question mode, list any remaining actions instead.
|
|
63
63
|
|
|
64
64
|
## Default Autopilot Policy
|
|
65
65
|
|
|
@@ -24,10 +24,16 @@ Follow `.qfai/assistant/rule/shared-skill-operating-baseline.md#user-questions-a
|
|
|
24
24
|
for every user question. With `--auto`, ask nothing and record
|
|
25
25
|
explicit assumptions in the migration report.
|
|
26
26
|
|
|
27
|
-
Read `references/migration-guide.md` before changing the project.
|
|
28
|
-
|
|
29
|
-
`
|
|
30
|
-
|
|
27
|
+
Read `references/migration-guide.md` before changing the project.
|
|
28
|
+
|
|
29
|
+
Read `references/migration-placement.md` when you write `plan.yaml`, when a
|
|
30
|
+
step reports a retired configuration key, and when a step lists a document that
|
|
31
|
+
does not fit its template's shape. It holds the plan format, the retired keys,
|
|
32
|
+
the contract numbers, the business rules and what each document keeps.
|
|
33
|
+
|
|
34
|
+
Run this skill from the project root, where `qfai.config.yaml` and a locally
|
|
35
|
+
installed `qfai` package are available. The twelve scripts use the installed
|
|
36
|
+
package. They do not add a `qfai` subcommand or make network calls.
|
|
31
37
|
|
|
32
38
|
The skill serves two runs, and the steps tell them apart from the project
|
|
33
39
|
itself:
|
|
@@ -81,7 +87,7 @@ keep authors separate from reviewers.
|
|
|
81
87
|
each old business rule's destination contract. Name that contract by its
|
|
82
88
|
current path under `cli/`, `api/`, `db/`, `ui/` or `design/` of the
|
|
83
89
|
contracts directory: step 3 gives every contract a new ID and file name,
|
|
84
|
-
and later steps find it from that path. Use the format in
|
|
90
|
+
and later steps find it from that path. Use the format in `references/migration-placement.md`. The plan
|
|
85
91
|
may be written before step 1, from the old contract paths.
|
|
86
92
|
2. Before the first real run, tell the person that the migration deletes
|
|
87
93
|
every 1.x file that has no destination and replaces every customised
|
|
@@ -112,7 +118,7 @@ keep authors separate from reviewers.
|
|
|
112
118
|
5. Resolve every reported item with the person responsible for the content.
|
|
113
119
|
Preserve any item the scripts could not place. Before step 4 writes
|
|
114
120
|
`id-map.json`, settle an example that cites several criteria and a rule that
|
|
115
|
-
binds no contract through the plan keys
|
|
121
|
+
binds no contract through the plan keys `references/migration-placement.md` names. After it, do not
|
|
116
122
|
change `plan.yaml` to move a mapped item. Place remaining content in the new
|
|
117
123
|
tree through `/qfai-sdd`, and finish each listed item as the guide's
|
|
118
124
|
"Resolve the reports" section says.
|