qfai 2.1.2 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/defaults/agent-routing/qfai-implement.yml +9 -0
- package/assets/defaults/agent-routing/qfai-triage.yml +9 -0
- package/assets/defaults/workflows/answer-in-session.yml +8 -0
- package/assets/defaults/workflows/quarantine-flaky.yml +3 -0
- package/assets/defaults/workflows/repair-consistency.yml +1 -0
- package/assets/defaults/workflows/run-operation.yml +11 -0
- package/assets/defaults/workflows/write-procedure.yml +18 -0
- package/assets/graph/codegraph-native.mjs +174 -0
- package/assets/graph/graphify-native.py +72 -0
- package/assets/init/.claude/settings.json +2 -20
- package/assets/init/.codex/hooks.json +0 -12
- package/assets/init/.qfai/assistant/rule/constitution.md +31 -15
- package/assets/init/.qfai/assistant/rule/drift-protocol.md +62 -1
- package/assets/init/.qfai/assistant/rule/references/codex-delegation.md +27 -0
- package/assets/init/.qfai/assistant/rule/references/griller-recommendations.md +21 -9
- package/assets/init/.qfai/assistant/rule/review-convergence.md +25 -12
- package/assets/init/.qfai/assistant/rule/shared-skill-delegation-baseline.md +1 -0
- package/assets/init/.qfai/assistant/rule/shared-skill-operating-baseline.md +8 -3
- package/assets/init/.qfai/assistant/rule/workflow.md +2 -1
- package/assets/init/.qfai/assistant/skill/qfai-discussion/SKILL.md +6 -0
- package/assets/init/.qfai/assistant/skill/qfai-discussion/references/discussion-completion-matrix.md +18 -9
- package/assets/init/.qfai/assistant/skill/qfai-grilling/SKILL.md +30 -20
- package/assets/init/.qfai/assistant/skill/qfai-grilling/references/delegated-session.md +4 -3
- package/assets/init/.qfai/assistant/skill/qfai-grilling/references/session-record.md +8 -2
- package/assets/init/.qfai/assistant/skill/qfai-implement/SKILL.md +7 -0
- package/assets/init/.qfai/assistant/skill/qfai-implement/references/ui-affecting.md +2 -2
- package/assets/init/.qfai/assistant/skill/qfai-run/SKILL.md +41 -39
- package/assets/init/.qfai/assistant/skill/qfai-run/references/codex-cloud-install.md +80 -0
- package/assets/init/.qfai/assistant/skill/qfai-run/references/extraction.md +36 -25
- package/assets/init/.qfai/assistant/skill/qfai-run/references/operator-screens.md +9 -1
- package/assets/init/.qfai/assistant/skill/qfai-run/references/plan.md +2 -0
- package/assets/init/.qfai/assistant/skill/qfai-run/references/reached-step-observations.md +132 -0
- package/assets/init/.qfai/assistant/skill/qfai-run/scripts/codex-cloud-install.mjs +117 -0
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/design-md-authoring.md +20 -7
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/sdd-phase-checklists.md +1 -1
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/sdd-pre-draft-grilling.md +4 -1
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/sdd-quality-gate.md +1 -1
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/sdd-triage.md +29 -2
- package/assets/init/.qfai/assistant/skill/qfai-sdd/references/ui-contract-guide.md +36 -4
- package/assets/init/.qfai/assistant/skill/qfai-sdd/templates/spec/decisions.md +9 -0
- package/assets/init/.qfai/assistant/skill/qfai-triage/SKILL.md +10 -7
- package/assets/init/.qfai/assistant/skill/qfai-verify/references/verify-output-contract.md +7 -7
- package/assets/init/.qfai/assistant/step/common-design-md/STEP.md +33 -16
- package/assets/init/.qfai/assistant/step/common-gate-run/STEP.md +26 -0
- package/assets/init/.qfai/assistant/step/common-grilling-record/STEP.md +10 -2
- package/assets/init/.qfai/assistant/step/common-policy-check/STEP.md +1 -0
- package/assets/init/.qfai/assistant/step/common-review-cycle/STEP.md +23 -7
- package/assets/init/.qfai/assistant/step/discussion-interview/STEP.md +15 -8
- package/assets/init/.qfai/assistant/step/discussion-oq/STEP.md +5 -1
- package/assets/init/.qfai/assistant/step/discussion-pack/STEP.md +5 -1
- package/assets/init/.qfai/assistant/step/discussion-uiux/STEP.md +5 -1
- package/assets/init/.qfai/assistant/step/implement-dep-bump/STEP.md +8 -2
- package/assets/init/.qfai/assistant/step/implement-procedure/STEP.md +69 -0
- package/assets/init/.qfai/assistant/step/implement-quarantine/STEP.md +21 -4
- package/assets/init/.qfai/assistant/step/implement-regression-fix/STEP.md +3 -3
- package/assets/init/.qfai/assistant/step/implement-stress-harness/STEP.md +33 -2
- package/assets/init/.qfai/assistant/step/prototyping-preflight/STEP.md +8 -0
- package/assets/init/.qfai/assistant/step/sdd-triage/STEP.md +4 -2
- package/assets/init/.qfai/assistant/step/triage-answer/STEP.md +2 -2
- package/assets/init/.qfai/assistant/step/triage-operate/STEP.md +50 -0
- package/assets/init/.qfai/assistant/step/verify-qfai-gate/STEP.md +8 -1
- package/assets/init/.qfai/assistant/step/verify-repeat-run/STEP.md +40 -0
- package/assets/init/.qfai/assistant/step/verify-repo-gate/STEP.md +12 -0
- package/assets/init/root/.agents/rules/document-schema.md +17 -0
- package/assets/init/root/.agents/rules/documentation-clarity.md +1 -1
- package/assets/init/root/.agents/rules/graph-exploration.md +150 -0
- package/assets/init/root/.agents/rules/grilling.md +100 -43
- package/assets/init/root/.agents/rules/reminders.json +14 -18
- package/assets/init/root/.agents/rules/session-feedback.md +6 -11
- package/assets/init/root/.agents/rules/untrusted-content.md +2 -2
- package/assets/init/root/.agents/rules/user-questions.md +3 -3
- package/assets/init/root/.github/workflows/qfai-docs.yml +2 -2
- package/assets/init/root/.github/workflows/qfai-tests.yml +88 -35
- package/assets/init/root/.github/workflows/qfai-validate.yml +2 -2
- package/assets/init/root/AGENTS.md +1 -0
- package/assets/schemas/workflow/extraction.schema.json +6 -2
- package/assets/scripts/check-mdschema.mjs +77 -8
- package/dist/cli/index.cjs +2616 -1130
- package/dist/cli/index.cjs.map +1 -1
- package/dist/cli/index.mjs +2617 -1121
- package/dist/cli/index.mjs.map +1 -1
- package/dist/graph/cli.cjs +1568 -0
- package/dist/graph/cli.cjs.map +1 -0
- package/dist/graph/cli.d.cts +9 -0
- package/dist/graph/cli.d.ts +9 -0
- package/dist/graph/cli.mjs +1541 -0
- package/dist/graph/cli.mjs.map +1 -0
- package/dist/graph/hook.cjs +817 -0
- package/dist/graph/hook.cjs.map +1 -0
- package/dist/graph/hook.d.cts +9 -0
- package/dist/graph/hook.d.ts +9 -0
- package/dist/graph/hook.mjs +792 -0
- package/dist/graph/hook.mjs.map +1 -0
- package/dist/index.cjs +2734 -818
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +129 -1
- package/dist/index.d.ts +129 -1
- package/dist/index.mjs +2707 -789
- package/dist/index.mjs.map +1 -1
- package/dist/process-C21nTvkT.d.cts +12 -0
- package/dist/process-C21nTvkT.d.ts +12 -0
- package/package.json +1 -1
|
@@ -13,7 +13,10 @@ which owns the delegation rules these sit beside.
|
|
|
13
13
|
answered, the work proceeds.
|
|
14
14
|
- A finding the author cannot fix is reported in the stage's final report, with
|
|
15
15
|
the finding and why it stays open.
|
|
16
|
-
- A critical decision
|
|
16
|
+
- A critical decision requires actual user authority under
|
|
17
|
+
`.agents/rules/grilling.md#explicit-delegation-for-a-discussion`.
|
|
18
|
+
Without an actual answer or recorded applicable authorization, it goes to
|
|
19
|
+
the user when questions are permitted: one that contradicts a spec, a
|
|
17
20
|
contract or a recorded decision, one whose effect cannot be taken back, or one
|
|
18
21
|
that rests on product intent nothing written states. So does a finding that
|
|
19
22
|
names a concrete security defect, data loss or corruption, or a correctness
|
|
@@ -37,7 +40,8 @@ Close a repeat by citing its recorded answer. This bounds what a reviewer may
|
|
|
37
40
|
require, not what a reviewer may report.
|
|
38
41
|
|
|
39
42
|
A report of a new defect or evidence that an answer no longer applies must
|
|
40
|
-
state what changed. A critical decision in it still
|
|
43
|
+
state what changed. A critical decision in it still requires actual applicable
|
|
44
|
+
user authority; uncovered authority is never supplied by the review.
|
|
41
45
|
|
|
42
46
|
## Discussion review precision
|
|
43
47
|
|
|
@@ -94,7 +98,10 @@ status is not permission to pass those.
|
|
|
94
98
|
|
|
95
99
|
A grilling session between agents is a **delegated session**
|
|
96
100
|
(`.agents/rules/grilling.md`): a griller interviews the authors, and the user is
|
|
97
|
-
asked only
|
|
101
|
+
asked only an uncovered critical decision when questions are permitted.
|
|
102
|
+
Actual scoped user delegation may authorize reversible requested judgment
|
|
103
|
+
without an individual option answer; record the agents' adoption and authority
|
|
104
|
+
separately. These rules bound its rounds and say what
|
|
98
105
|
settles each decision when they run out.
|
|
99
106
|
|
|
100
107
|
**Two rounds.** After the second round **every
|
|
@@ -108,8 +115,9 @@ position is recorded beside it with whose it is. The stage reports every adopted
|
|
|
108
115
|
decision at its end without waiting for an answer. A user who disagrees
|
|
109
116
|
overturns one through a change request or a rerun.
|
|
110
117
|
|
|
111
|
-
**A critical decision
|
|
112
|
-
|
|
118
|
+
**A critical decision without an actual answer or recorded applicable user
|
|
119
|
+
authority goes to the user at once when asking is permitted**, without spending
|
|
120
|
+
a round. Agent agreement and round exhaustion supply no authority.
|
|
113
121
|
|
|
114
122
|
| Critical decision | Why it goes to the user |
|
|
115
123
|
| --------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------- |
|
|
@@ -121,15 +129,20 @@ A discussion pack answers product intent for this test. It is non-normative for
|
|
|
121
129
|
the Drift Protocol, but it is where the user already answered these questions in
|
|
122
130
|
a user session, and asking them again spends that session twice.
|
|
123
131
|
|
|
124
|
-
Each critical decision goes to the user with every position and a
|
|
125
|
-
recommendation
|
|
132
|
+
Each uncovered critical decision goes to the user with every position and a
|
|
133
|
+
recommendation when asking is permitted. The work stays where it is while the
|
|
126
134
|
user accepts, decides, or drops the item.
|
|
127
135
|
|
|
128
136
|
**The budget does not end the session while a critical decision is open.** The
|
|
129
|
-
session ends `adopted`
|
|
137
|
+
session ends `adopted` only with no open node or running lookup, all required
|
|
138
|
+
consumed inputs present, and every critical decision supported by an actual
|
|
139
|
+
user answer or recorded applicable authorization under the master's conditions.
|
|
130
140
|
|
|
131
|
-
Under a no-question mode
|
|
132
|
-
|
|
133
|
-
complete over it (`.qfai/assistant/rule/constitution.md` Article X,
|
|
141
|
+
Under a no-question mode no escalation is sent to the user. A critical decision
|
|
142
|
+
without that authority is opened in the register the stage reads, so the stage
|
|
143
|
+
cannot complete over it (`.qfai/assistant/rule/constitution.md` Article X,
|
|
134
144
|
rule 6), and that write ends the session `no-question`. Non-critical decisions
|
|
135
|
-
are adopted as they are in any delegated session.
|
|
145
|
+
are adopted as they are in any delegated session. A qualifying explicitly
|
|
146
|
+
delegated session with every node settled ends `adopted`; no-question mode
|
|
147
|
+
alone does not qualify it. Unknown facts and missing undefaultable consumed
|
|
148
|
+
inputs retain the ordinary open/stop behavior.
|
|
@@ -34,6 +34,7 @@ classified by the taxonomy below before any response.
|
|
|
34
34
|
`.qfai/assistant/skill/qfai-implement/references/parallelization-policy.md`.
|
|
35
35
|
Where the stage's ledger or a seam makes an ordering mandatory, carrying on
|
|
36
36
|
does not override it.
|
|
37
|
+
- On Codex, read `.qfai/assistant/rule/references/codex-delegation.md` before delegating.
|
|
37
38
|
- A review is done by an agent that did not author what it reviews. The
|
|
38
39
|
orchestrator never reviews its own work and never approves it for
|
|
39
40
|
convenience.
|
|
@@ -43,7 +43,7 @@ asks nothing and records explicit assumptions in its stage report.
|
|
|
43
43
|
asked for nor a blocker. Neither exhaustion nor a user's `proceed` / `done` answer is `--auto`, so these questions survive both. Under an explicit `--auto` the question is not asked at all — that run stops and names the missing input instead of inventing one. See `.qfai/assistant/rule/constitution.md` Article VI.
|
|
44
44
|
- **Grilling questions are exempt too, and unbounded.** A question asked inside the interview `.agents/rules/grilling.md` defines spends no budget, and a session runs to its own end condition — for a user session an empty frontier and the user's confirmation, which is itself in the exempt class, and for a delegated one no open node and an answer to every critical decision — rather than to a count.
|
|
45
45
|
An exhausted budget does not close one, because its questions never opened it. A
|
|
46
|
-
session is entered deliberately
|
|
46
|
+
session is entered deliberately, only as that rule's § Scope says, so a question asked outside a declared session is an ordinary clarification and spends a unit, whatever its subject.
|
|
47
47
|
Under an explicit `--auto` the session asks nothing, a delegated one still adopts every decision that is not critical, and each node it could not settle is opened as a question in the register the stage reads. Each node, not each decision: a fact only
|
|
48
48
|
the user holds cannot be settled from evidence either, and a fact declared undefaultable stops the run rather than taking a value nobody has. Where a document requires the field to hold something, write the defaulted value and label it an assumption beside that open question; what is forbidden is the assumption with no open question against it (Article X, rule 6).
|
|
49
49
|
|
|
@@ -168,8 +168,8 @@ The `common-gate-run` step runs a gate from this section and records it.
|
|
|
168
168
|
|
|
169
169
|
## Policy check (mandatory)
|
|
170
170
|
|
|
171
|
-
A run starts with the policy check
|
|
172
|
-
on stale policy. The contract is
|
|
171
|
+
A run, an exempt route aside, starts with the policy check once and does not
|
|
172
|
+
continue affected work on stale policy. The contract is
|
|
173
173
|
`.qfai/assistant/rule/workflow.md#policy-check-mandatory`.
|
|
174
174
|
The procedure — which files, what counts as incomplete, how a fact is filled
|
|
175
175
|
and where an unverifiable one goes — is the `common-policy-check` step. A
|
|
@@ -255,6 +255,11 @@ stage, and no other.
|
|
|
255
255
|
4. A finding another owner must repair is reported with that owner, not an
|
|
256
256
|
edit made here.
|
|
257
257
|
|
|
258
|
+
At each existing stage boundary, read
|
|
259
|
+
`.qfai/assistant/skill/qfai-run/references/reached-step-observations.md`
|
|
260
|
+
for the reached-step comparison in the existing stage report. Preserve the
|
|
261
|
+
plan's scope, termination, pass-through and planned review.
|
|
262
|
+
|
|
258
263
|
### A pass-through step
|
|
259
264
|
|
|
260
265
|
A step the plan marks `passThrough` always runs. It first reads what its
|
|
@@ -132,7 +132,8 @@ from the skills and baselines that cite it.
|
|
|
132
132
|
### Policy check (mandatory)
|
|
133
133
|
|
|
134
134
|
Once per run, at the start, before the first stage. A stage invoked by name on
|
|
135
|
-
its own is a run of its own.
|
|
135
|
+
its own is a run of its own. The ultra-light routes `answer-in-session` and
|
|
136
|
+
`run-operation`, each one step that changes no tracked file, run without it.
|
|
136
137
|
|
|
137
138
|
1. Check the current story-tree policy files under `<paths.specsDir>`:
|
|
138
139
|
- `01_policy/objective.md` and `01_policy/initiative.md`
|
|
@@ -120,6 +120,12 @@ End the turn with a question listing the next actions, `/qfai-sdd` recommended,
|
|
|
120
120
|
|
|
121
121
|
## Default Autopilot Policy
|
|
122
122
|
|
|
123
|
+
The entries below govern the default user interview. Only an actual user
|
|
124
|
+
delegation recorded under
|
|
125
|
+
`.agents/rules/grilling.md#explicit-delegation-for-a-discussion` enables the
|
|
126
|
+
delegated `adopted` path. No-question mode alone does not enable it; missing
|
|
127
|
+
inputs and uncovered human decisions retain their ordinary blocking behavior.
|
|
128
|
+
|
|
123
129
|
- ask-user:
|
|
124
130
|
- every decision the interview puts on the frontier, over every topic in `references/discussion-coverage-checklist.md`. Running the interview is what this skill performs, so these are its own operations
|
|
125
131
|
- the confirmation that closes the session
|
package/assets/init/.qfai/assistant/skill/qfai-discussion/references/discussion-completion-matrix.md
CHANGED
|
@@ -22,13 +22,14 @@ Blocking for every pack, UI-bearing or not:
|
|
|
22
22
|
resolves to a `sources[].id`, and at least one `reflection[]` entry records an apply decision.
|
|
23
23
|
`npx qfai validate --profile discussion --fail-on error` reports `QFAI-RESEARCH-*` until it is.
|
|
24
24
|
2. The stage report's `## Grilling Session` row shows the session ended before authoring began,
|
|
25
|
-
with `Ended` reading
|
|
25
|
+
with `Ended` reading an authoring ending and its conditions met:
|
|
26
26
|
|
|
27
|
-
| Ended | Also required
|
|
28
|
-
| ------------- |
|
|
29
|
-
| `confirmed` | No node open — the frontier empty **and** no fact lookup still running
|
|
30
|
-
| `user-closed` | Lookups finished, and every decision still open recorded as a labelled assumption
|
|
31
|
-
| `
|
|
27
|
+
| Ended | Also required |
|
|
28
|
+
| ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
29
|
+
| `confirmed` | No node open — the frontier empty **and** no fact lookup still running |
|
|
30
|
+
| `user-closed` | Lookups finished, and every decision still open recorded as a labelled assumption |
|
|
31
|
+
| `adopted` | Recorded explicit delegation, actual author rounds, no open node or lookup, all required inputs and applicable human authority; see `.agents/rules/grilling.md#explicit-delegation-for-a-discussion` |
|
|
32
|
+
| `no-question` | Every node still open registered — a decision, and a fact only the user holds — so item 3 below is what blocks |
|
|
32
33
|
|
|
33
34
|
`stopped` never completes: the user ended the run, and a pack authored after that is the run
|
|
34
35
|
doing what they told it not to.
|
|
@@ -44,6 +45,10 @@ Blocking for every pack, UI-bearing or not:
|
|
|
44
45
|
covered, every open question registered. What is missing is that someone agreed to what is in
|
|
45
46
|
them, and nothing downstream can tell.
|
|
46
47
|
|
|
48
|
+
Delegation is not a human confirmation or a completion receipt. The
|
|
49
|
+
ordinary research, pack, OQ, UI, schema, validation and independent-review
|
|
50
|
+
gates remain blocking. No reserved decision or missing fact is forced closed.
|
|
51
|
+
|
|
47
52
|
The no-question row is the one to read carefully: `--auto` can reach nobody, so waiting for a
|
|
48
53
|
confirmation would stop the run before it could write the open questions that are what block it.
|
|
49
54
|
Item 3 below does that work instead — an open count above zero closes nothing.
|
|
@@ -53,7 +58,7 @@ Blocking for every pack, UI-bearing or not:
|
|
|
53
58
|
Here rather than under one pack shape. It is what a no-question run is blocked by, and a run is
|
|
54
59
|
`--auto` or not independently of whether it has a surface — listed only under `## UI-bearing
|
|
55
60
|
Packs`, it let a non-UI `--auto` pack complete with its decisions still open.
|
|
56
|
-
|
|
61
|
+
All Packs item 3 does that work — an open count above zero closes nothing.
|
|
57
62
|
|
|
58
63
|
## UI-bearing Packs
|
|
59
64
|
|
|
@@ -73,7 +78,11 @@ Completion is blocked until all are true:
|
|
|
73
78
|
5. `01_Context.md#Design Direction` names an adopted theme, what departs from it, and what stays
|
|
74
79
|
ordinary. This is the one visual decision made here, because no later stage asks the user for
|
|
75
80
|
it: `/qfai-sdd`'s `common-design-md` step authors tokens from whatever is recorded. A direction taken without the
|
|
76
|
-
user carries `chosen_by: assumption`
|
|
81
|
+
user carries `chosen_by: assumption`, never `user`. Its OQ stays open unless
|
|
82
|
+
an actual specifically applicable user instruction overrides the human-choice
|
|
83
|
+
requirement under the master's conditions; record that authority and the agents'
|
|
84
|
+
choice without falsifying the schema. General delegation alone does not waive
|
|
85
|
+
a genuinely reserved human input.
|
|
77
86
|
|
|
78
87
|
Evaluation axes are global constants (4-step ordinal: weak / acceptable / strong /
|
|
79
88
|
exceptional) and are NOT authored as discussion sidecars.
|
|
@@ -90,7 +99,7 @@ so conditions 1 and 5 above do not apply to it:
|
|
|
90
99
|
`validators/designContractReadiness.ts` skips `QFAI-DCON-030`/`-033`/`-034` for it.
|
|
91
100
|
- No design direction either: nothing downstream reads a theme for a surface that renders
|
|
92
101
|
no tokens.
|
|
93
|
-
-
|
|
102
|
+
- UI-bearing items 2, 3 and 4 and All Packs item 3 apply unchanged: all three canonical `uiux/` sidecars, the
|
|
94
103
|
full screen-contract schema, unranked exploration directions, and zero open OQs.
|
|
95
104
|
- `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.
|
|
96
105
|
- No `prototyping.yaml`: `cli` is not a valid prototyping execution surface.
|
|
@@ -24,11 +24,15 @@ shared, closes the asking, or stops the session, a delegated session adopts the
|
|
|
24
24
|
griller's recommendations, or a run that may not ask writes every node left
|
|
25
25
|
where its stage's gate reads it.
|
|
26
26
|
|
|
27
|
-
**
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
27
|
+
**The invoking stage picks the session.** A stage whose work is the
|
|
28
|
+
interview holds a user session; any other holds a delegated one, where a griller
|
|
29
|
+
interviews the authors and only a critical decision reaches the user, and only
|
|
30
|
+
for a decision the repository cannot settle (`.agents/rules/grilling.md` § When
|
|
31
|
+
a session is held). Without one, no griller starts. A stage that says nothing
|
|
32
|
+
holds a delegated session where one is held. Read
|
|
33
|
+
`.agents/rules/grilling.md#explicit-delegation-for-a-discussion` before
|
|
34
|
+
delegating a user discussion; record actual authority. No-question alone is not
|
|
35
|
+
delegation.
|
|
32
36
|
|
|
33
37
|
**The request bounds the tree** (`.agents/rules/grilling.md`). A decision whose
|
|
34
38
|
only outcome is whether to add something the request did not ask for is left
|
|
@@ -53,7 +57,8 @@ least beyond the request.
|
|
|
53
57
|
| A no-question mode is active | Run without asking; open every node left over as a question |
|
|
54
58
|
| An ambiguity met while implementing | Not a session — stop under Article IX of the constitution |
|
|
55
59
|
|
|
56
|
-
**A no-question mode silences
|
|
60
|
+
**A no-question mode silences user questions, not the session.** The master's
|
|
61
|
+
explicit-delegation conditions permit author rounds. Otherwise, an invocation
|
|
57
62
|
told not to ask — `--auto`, or whatever the host spells it as — settles what the
|
|
58
63
|
evidence settles, dispatches the lookups, and opens every node left over as
|
|
59
64
|
a question in the register the stage reads, so the stage cannot complete over
|
|
@@ -115,19 +120,17 @@ re-opens it.
|
|
|
115
120
|
1. Recompute the frontier from what is now settled.
|
|
116
121
|
2. Dispatch the fact lookups the remaining decisions wait on. Do not block the
|
|
117
122
|
round on them.
|
|
118
|
-
3. Put the whole frontier at once
|
|
119
|
-
|
|
123
|
+
3. Put the whole frontier at once to the session's answerer: the user by
|
|
124
|
+
default, or authors in a qualifying delegated session.
|
|
120
125
|
4. Read the answers, then return to step 1.
|
|
121
126
|
|
|
122
127
|
Two questions never share a round when one depends on the other; the dependent
|
|
123
128
|
one belongs to a later round. The next round is never written ahead of the
|
|
124
129
|
answers it is computed from.
|
|
125
130
|
|
|
126
|
-
**A no-question mode is read before any of this.**
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
that withholds the tool while still permitting questions is a different thing,
|
|
130
|
-
and is the fallback's case.
|
|
131
|
+
**A no-question mode is read before any of this.** Agent rounds require
|
|
132
|
+
explicit delegation; otherwise the section above governs. A withheld tool with questions still
|
|
133
|
+
permitted uses the fallback.
|
|
131
134
|
|
|
132
135
|
**Three things send a round to plain text**: the host has no structured question
|
|
133
136
|
tool, the current mode withholds it while still permitting questions, or the
|
|
@@ -214,18 +217,22 @@ simple.
|
|
|
214
217
|
**A delegated session has no condition 2**, because no user is there to
|
|
215
218
|
confirm. A budget bounds its rounds: two, then every decision that is not
|
|
216
219
|
critical takes the griller's recommendation — the ones the agents agreed on and
|
|
217
|
-
the ones still open alike
|
|
218
|
-
|
|
220
|
+
the ones still open alike. An uncovered critical decision goes to the user
|
|
221
|
+
when asking is permitted, without spending a round
|
|
219
222
|
(`.qfai/assistant/rule/review-convergence.md`). It ends `adopted` once
|
|
220
|
-
|
|
223
|
+
the master's conditions hold: no open node or lookup, required inputs present,
|
|
224
|
+
and actual authority for critical decisions. Record agent choices as agents'.
|
|
221
225
|
|
|
222
|
-
**The budget ends the rounds, not the session.** While a critical decision
|
|
223
|
-
|
|
226
|
+
**The budget ends the rounds, not the session.** While a critical decision
|
|
227
|
+
lacks an actual answer or applicable recorded authorization, it stays open: the user answers it, or ends the session
|
|
224
228
|
another way — or, under a no-question mode, the register write ends it
|
|
225
229
|
`no-question`. How many went is a count a record carries, never an ending.
|
|
226
230
|
|
|
227
|
-
**
|
|
228
|
-
|
|
231
|
+
**Only a no-question session meeting the master's explicit-delegation
|
|
232
|
+
conditions ends `adopted`.**
|
|
233
|
+
|
|
234
|
+
**Any other session under a no-question mode cannot reach condition 2
|
|
235
|
+
either**, because the mode forbids asking the user. It ends when nothing on the
|
|
229
236
|
frontier is still waiting: every decision the evidence settled is settled, and
|
|
230
237
|
every one it did not is opened as a question where the stage's own gate reads it
|
|
231
238
|
(`.qfai/assistant/rule/constitution.md` Article X, rule 6). The register
|
|
@@ -350,6 +357,9 @@ Every decision this skill meets falls in one of three named buckets.
|
|
|
350
357
|
- grilling subject (the design to interrogate; a session has no default for
|
|
351
358
|
what it is about)
|
|
352
359
|
|
|
360
|
+
Explicit delegation is not `auto-decide` or a fact or human answer.
|
|
361
|
+
These user-session entries remain the default.
|
|
362
|
+
|
|
353
363
|
The asking is what this skill performs, so its `ask-user` entries are its own operations
|
|
354
364
|
rather than an entry added to the prototype.
|
|
355
365
|
|
|
@@ -53,6 +53,7 @@ decisions belonging to different drafting roles.
|
|
|
53
53
|
report lists it; nothing waits for the user to read it.
|
|
54
54
|
|
|
55
55
|
A critical decision is the exception: agreement closes its node for the
|
|
56
|
-
round,
|
|
57
|
-
|
|
58
|
-
|
|
56
|
+
round, but only an actual user answer or an explicit applicable authorization
|
|
57
|
+
under `.agents/rules/grilling.md#explicit-delegation-for-a-discussion` settles
|
|
58
|
+
it. Record that authority separately from the agents' positions. Agreement
|
|
59
|
+
alone does not settle it, and an unknown user-held fact still stays open.
|
|
@@ -18,7 +18,9 @@ Use the shared schema from
|
|
|
18
18
|
The invoking stage's reviewer confirms this about the session:
|
|
19
19
|
|
|
20
20
|
- no decision was recorded as the user's that the user did not answer, no
|
|
21
|
-
critical decision was adopted without
|
|
21
|
+
critical decision was adopted without an actual user answer or an explicit
|
|
22
|
+
applicable human authorization under the master's delegation conditions,
|
|
23
|
+
and none was assumed that the
|
|
22
24
|
assumption path excludes;
|
|
23
25
|
- every adopted decision has its `agents` row, and none of them adds what the
|
|
24
26
|
request did not need;
|
|
@@ -27,7 +29,11 @@ The invoking stage's reviewer confirms this about the session:
|
|
|
27
29
|
five endings `.agents/rules/grilling.md` names. Between agents a round budget
|
|
28
30
|
bounds the rounds (`.qfai/assistant/rule/review-convergence.md`), and
|
|
29
31
|
a session recorded as ended while a critical decision it escalated is still
|
|
30
|
-
unanswered is the finding
|
|
32
|
+
unanswered and lacks that recorded authority is the finding;
|
|
33
|
+
- for an explicitly delegated discussion, the actual user instruction, its
|
|
34
|
+
scope and authority, actual author rounds and dissent, no open node or
|
|
35
|
+
running lookup, all required consumed inputs, and actual end/authoring times
|
|
36
|
+
are evidenced. `adopted` without these is not a passing session.
|
|
31
37
|
|
|
32
38
|
The reviewer works under these rules:
|
|
33
39
|
|
|
@@ -40,6 +40,7 @@ steps:
|
|
|
40
40
|
- implement-tooling
|
|
41
41
|
- implement-backport
|
|
42
42
|
- implement-acceptance
|
|
43
|
+
- implement-procedure
|
|
43
44
|
requires: [common-review-cycle]
|
|
44
45
|
mode: approval-gated
|
|
45
46
|
---
|
|
@@ -136,6 +137,12 @@ and reporting requirement, and states any assumption it built on
|
|
|
136
137
|
(`.qfai/assistant/rule/test-layers.md#test-suite-sizing`,
|
|
137
138
|
`.agents/rules/minimal-implementation.md` § 4).
|
|
138
139
|
|
|
140
|
+
## Route-only procedure authoring
|
|
141
|
+
|
|
142
|
+
When the plan names `implement-procedure`, follow
|
|
143
|
+
`.qfai/assistant/step/implement-procedure/STEP.md`.
|
|
144
|
+
Business-flow invocations skip it; existing flow steps apply.
|
|
145
|
+
|
|
139
146
|
## Completion
|
|
140
147
|
|
|
141
148
|
The invocation completes on the gate of its last step once
|
|
@@ -20,8 +20,8 @@ product-surface-reviewer. Do not infer that a change has no UI effect from its d
|
|
|
20
20
|
|
|
21
21
|
## Evidence
|
|
22
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
|
|
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 review that reads the change, product-surface-reviewer judges each UI affecting example, its UI contracts, and its captured state. The review verdict refers to that revision.
|
|
24
24
|
|
|
25
|
-
|
|
25
|
+
A fix made for a finding of that review refreshes the capture it changes and is not reviewed again (`.qfai/assistant/rule/review-convergence.md#one-review`). A passing code test cannot substitute for the visual and interaction evidence that the acceptance criterion requires.
|
|
26
26
|
|
|
27
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.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: qfai-run
|
|
3
3
|
title: QFAI Run (Change request entry)
|
|
4
|
-
description: "Use when the user asks for a change, a fix, an investigation of the codebase
|
|
4
|
+
description: "Use when the user asks for a change, a fix, an investigation of the codebase, a question about the project or an operation on finished work in plain words and names no stage skill. Plans every such request, the lightest included, with `npx qfai workflow plan` and runs the plan's steps in order to its end."
|
|
5
5
|
argument-hint: "<the change, in your own words>"
|
|
6
6
|
allowed-tools: [Read, Glob, Grep, Write, Edit, Bash, TodoWrite, Task, Agent]
|
|
7
7
|
roles: [orchestrator]
|
|
@@ -14,14 +14,15 @@ mode: execution-focused
|
|
|
14
14
|
|
|
15
15
|
[DRIFT-PROTOCOL:REQUIRED]
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
Follow the CLI plan's steps in order. Read no reference up front; each line says when.
|
|
18
18
|
|
|
19
|
-
-
|
|
20
|
-
-
|
|
21
|
-
-
|
|
22
|
-
-
|
|
19
|
+
- `references/extraction.md`: for an extraction step 1 does not give.
|
|
20
|
+
- `references/plan.md`: for a plan field this file does not name, or a refused plan.
|
|
21
|
+
- `references/operator-screens.md`: when a line below or a step names it, such as to ask or report.
|
|
22
|
+
- `references/stage-points.md`: at a step the plan marks with a point.
|
|
23
23
|
- Run preflight before planning, as `.qfai/assistant/rule/shared-skill-operating-baseline.md#canonical-qfai-launcher-mandatory` says.
|
|
24
24
|
If the launcher is missing or preflight fails, read `references/operator-screens.md` for recovery.
|
|
25
|
+
- Read `references/codex-cloud-install.md` before configuring an environment-owned Install script or Start skill, or preparing dependencies for a fresh checkout. Use the reviewed target's successful preparation and canonical proof before planning.
|
|
25
26
|
|
|
26
27
|
## What this skill never does
|
|
27
28
|
|
|
@@ -34,8 +35,8 @@ The CLI plans; this skill follows its steps in order.
|
|
|
34
35
|
|
|
35
36
|
## Mode
|
|
36
37
|
|
|
37
|
-
Read `workflow.mode` in `qfai.config.yaml` first. No key means `active`;
|
|
38
|
-
|
|
38
|
+
Read `workflow.mode` in `qfai.config.yaml` first. No key means `active`; unlisted
|
|
39
|
+
values plan nothing.
|
|
39
40
|
|
|
40
41
|
| Mode | What this skill does |
|
|
41
42
|
| -------- | ------------------------------------------------------------------------------------ |
|
|
@@ -47,52 +48,52 @@ value but the three below plans nothing.
|
|
|
47
48
|
|
|
48
49
|
- For independent targets under one goal, read `references/operator-screens.md`
|
|
49
50
|
before planning or switching during a wait.
|
|
50
|
-
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
`references/operator-screens.md` for replies.
|
|
51
|
+
- Plan changes, questions, proposals to decide and reports to close.
|
|
52
|
+
Questions plan answers without changes; nonrequests get no plan.
|
|
53
|
+
- Replies with a requested answer or result, including failure, resume the same step without
|
|
54
|
+
a new invocation. An independent new request is planned; read `references/operator-screens.md`
|
|
55
|
+
for replies.
|
|
56
56
|
- `stop`: end the work at once and list every open decision as open.
|
|
57
57
|
- A request naming a stage skill: invoke that skill by name.
|
|
58
58
|
|
|
59
59
|
## The work
|
|
60
60
|
|
|
61
|
-
1. **Extract.**
|
|
62
|
-
`
|
|
63
|
-
|
|
64
|
-
`
|
|
61
|
+
1. **Extract.** A question one read answers is `{ intent: question-why, qualifiers: [session-answerable] }`
|
|
62
|
+
(or `question-how`, `question-help`); an operation on finished work that the session runs itself and
|
|
63
|
+
that deletes nothing is `{ intent: order, artifacts: [] }`. Every other field is empty, with
|
|
64
|
+
`confidence: high`; neither needs a reference. Read any other request as `references/extraction.md`
|
|
65
|
+
sets out, and pass the extraction to `npx qfai workflow plan --in <file>`, or `--in -`.
|
|
65
66
|
2. **Candidates.** When `plan` returns `candidates`, put one single-select
|
|
66
67
|
question, each option saying in the user's words what that route will do,
|
|
67
68
|
then run `npx qfai workflow plan --route <route>` for the chosen one.
|
|
68
|
-
3. **Scope.** With two or more scopes, ask which to run as
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
`common-policy-check` once. On a route that changes no file, one that
|
|
69
|
+
3. **Scope.** With two or more scopes, ask which to run as `references/operator-screens.md` says,
|
|
70
|
+
and run only its stages. With one scope, no scopes, or a branch destination's plan, ask
|
|
71
|
+
nothing and run every stage.
|
|
72
|
+
4. **Announce.** Before the first stage, give the goal, the chosen stages in order in plain words,
|
|
73
|
+
and the files the work may change. Ask nothing. Then run `common-policy-check` once, unless the
|
|
74
|
+
plan's one step is `triage-answer` or `triage-operate`. On a route that changes no file, one that
|
|
75
75
|
closes, answers or asks, it reads and reports and writes nothing.
|
|
76
76
|
5. **Run the stages.** Run each stage in plan order, and each of its steps in
|
|
77
77
|
order, as `.qfai/assistant/rule/shared-skill-operating-baseline.md#running-steps-mandatory` says.
|
|
78
78
|
When a step is short or passes without edits, read `references/operator-screens.md`.
|
|
79
79
|
Write artifacts yourself or delegate independent parallel work or review.
|
|
80
|
-
At
|
|
80
|
+
At a step the plan marks with a point, follow `references/stage-points.md`:
|
|
81
81
|
- **Release point.** Ask the user to approve the release before the step `releasePoint` names.
|
|
82
82
|
- **Decision point.** Put each critical decision at a step `decisionPoints` names to the user.
|
|
83
83
|
- **Branch point.** Move to the destination a step `branchPoints` names, and plan it at once.
|
|
84
|
-
6. **Review.** After a stage whose `review` is `spec`, `requirements-reviewer`
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
once, with no re-review.
|
|
84
|
+
6. **Review.** After a stage whose `review` is `spec`, `requirements-reviewer` reviews; for `code`,
|
|
85
|
+
`implementation-reviewer`. Only a contract or screen change no earlier review read adds
|
|
86
|
+
`architecture-reviewer` or `product-surface-reviewer`, as `common-review-cycle` lists; no one else
|
|
87
|
+
joins. A review whose target's only edits resolve the conflicts of a merge or branch update between
|
|
88
|
+
reviewed sides gets no reviewer.
|
|
89
|
+
No agent reviews its own work; no step adds a review. Each returns PASS or REVISE.
|
|
90
|
+
Fix or answer each finding once, with no re-review. Stop a step that exceeds the request.
|
|
91
91
|
7. **Approvals.** Each approval of a specification change, a critical decision
|
|
92
92
|
or a release is one `decisions.md` row: what was approved, who approved it,
|
|
93
|
-
when, and the chosen option's label. A decision you took appends no row.
|
|
93
|
+
when, and the chosen option's label, in the `qfai-sdd` decisions template's form. A decision you took appends no row.
|
|
94
94
|
8. **A finding no stage serves.** Stop, and name the finding, its owner and the stage skill to invoke by name.
|
|
95
95
|
9. **Commit.** `verify-commit` runs last, after any release point; never pushes.
|
|
96
|
+
10. **Session feedback.** When the final report closes the user's last task and nothing waits on them, follow `.agents/rules/session-feedback.md` once.
|
|
96
97
|
|
|
97
98
|
## Under a no-question mode
|
|
98
99
|
|
|
@@ -135,12 +136,13 @@ When parts ran in parallel, use the summary in `references/operator-screens.md`.
|
|
|
135
136
|
|
|
136
137
|
## Completion Contract (Shared)
|
|
137
138
|
|
|
138
|
-
Follow `.qfai/assistant/rule/shared-skill-operating-baseline.md#completion-contract-shared`. **Smallest applicable smoke check
|
|
139
|
+
Follow `.qfai/assistant/rule/shared-skill-operating-baseline.md#completion-contract-shared`. **Smallest applicable smoke check**: the chosen scope's `verify-qfai-gate` and `verify-repo-gate` gates. With none, run no gate and report it. Unavailable gates are UNRUN, never PASS.
|
|
139
140
|
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
141
|
+
At stage boundaries, follow `references/reached-step-observations.md` in the existing report.
|
|
142
|
+
|
|
143
|
+
If requested evidence handover must precede archive, read `references/evidence-delivery.md`
|
|
144
|
+
and complete receiving proof first. Missing access leaves handover pending and originals
|
|
145
|
+
retained; ordinary completion requires no unsolicited upload.
|
|
144
146
|
|
|
145
147
|
project_memory:
|
|
146
148
|
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
# Codex Cloud dependency preparation
|
|
2
|
+
|
|
3
|
+
Read before configuring an environment-owned Install script or Start skill, or
|
|
4
|
+
when a fresh checkout cannot pass the canonical launcher preflight. Init writes
|
|
5
|
+
the preparation entry and this guide; it performs no installation or host setup.
|
|
6
|
+
|
|
7
|
+
## Before execution
|
|
8
|
+
|
|
9
|
+
Review the project-declared executable, separate argv and absolute checkout cwd.
|
|
10
|
+
Read the declared Install command from the project's Standard commands; translate
|
|
11
|
+
it into a reviewed native executable and arguments before configuration. The entry
|
|
12
|
+
does not parse Markdown, shell text or choose a package manager.
|
|
13
|
+
|
|
14
|
+
Covered authority for the command and its lifecycle scripts must already exist.
|
|
15
|
+
Preserve network, secret, trust and publication permissions. A generated file,
|
|
16
|
+
invocation or flag grants no authority. Missing authority blocks execution.
|
|
17
|
+
Review argument and output contents before retaining or sharing them.
|
|
18
|
+
|
|
19
|
+
## Install script
|
|
20
|
+
|
|
21
|
+
Use the generated entry with the reviewed tuple:
|
|
22
|
+
|
|
23
|
+
```text
|
|
24
|
+
node .qfai/assistant/skill/qfai-run/scripts/codex-cloud-install.mjs --cwd <absolute-checkout> -- <executable> [argument...]
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
Replace the placeholders with the reviewed values and configure the host's
|
|
28
|
+
supported Install script. The executable and arguments are passed with no shell
|
|
29
|
+
parsing at the explicit cwd. Do not supply an entire shell command as one argument.
|
|
30
|
+
Do not use a parent, remote or cached command as a substitute.
|
|
31
|
+
|
|
32
|
+
Missing inputs, an unknown option, a relative cwd or an unreadable target directory
|
|
33
|
+
fail before installation. Unavailable tools, spawn errors, signals, nonzero exit
|
|
34
|
+
and observed timeout remain failed preparation. Retain the actual reason; there
|
|
35
|
+
is no automatic retry, extra timeout option or new deadline.
|
|
36
|
+
|
|
37
|
+
After successful installation the entry checks the same cwd for its local
|
|
38
|
+
`node_modules/.bin/qfai`, or a root `.pnp.cjs` / `.pnp.loader.mjs` marker with a
|
|
39
|
+
declared qfai dependency and native `yarn exec qfai --help` exiting 0. A failed
|
|
40
|
+
installation stays failed even if a launcher already exists. A Windows wrapper
|
|
41
|
+
that cannot start natively remains a tool failure; no shell fallback is added.
|
|
42
|
+
|
|
43
|
+
## Start skill
|
|
44
|
+
|
|
45
|
+
Check successful preparation and the canonical proof at the same reviewed cwd
|
|
46
|
+
before dependent planning. Failure or missing covered authority blocks planning;
|
|
47
|
+
report the actual blocker and owner required to resume. The entry starts no plan.
|
|
48
|
+
Use the launcher that the existing canonical preflight established for that target.
|
|
49
|
+
Preparation is neither global validation nor formal workflow completion.
|
|
50
|
+
|
|
51
|
+
## Environment setup
|
|
52
|
+
|
|
53
|
+
Confirm current environment support for the Install script and Start skill before
|
|
54
|
+
real configuration. The operator performs authorized setup and publication;
|
|
55
|
+
init and the generated entry do not register an account or configure the host.
|
|
56
|
+
|
|
57
|
+
Saving configuration, preparing and publishing a filesystem for new tasks are
|
|
58
|
+
distinct operations. A refresh does not rerun installation or startup. Existing
|
|
59
|
+
tasks retain their own state. Confirm the actual host behavior before claiming
|
|
60
|
+
that preparation or a Start skill ran for a task; changing a local file is not
|
|
61
|
+
evidence of a published environment or a new task using it.
|
|
62
|
+
|
|
63
|
+
## Reminders and trust
|
|
64
|
+
|
|
65
|
+
Existing reminder-only exit-0 behavior stays unchanged. Project-edited hook groups
|
|
66
|
+
keep their existing merge behavior. Keep linked-path refusals, unreadable-file warnings and hook
|
|
67
|
+
review. Preparation does not grant hook trust. No universal SessionStart installer
|
|
68
|
+
is added, and reminder hooks do not perform this installation.
|
|
69
|
+
|
|
70
|
+
## Evidence limits
|
|
71
|
+
|
|
72
|
+
Distinguish generated assets, controlled native CI and actual Cloud configuration,
|
|
73
|
+
publication or task execution. Retain reviewed command and argv, cwd, actual exit
|
|
74
|
+
or signal, and canonical result without exposing secrets. A failed or interrupted
|
|
75
|
+
run is not ready; missing outcomes remain unknown.
|
|
76
|
+
|
|
77
|
+
Controlled native fixtures cannot prove host lifecycle or startup execution.
|
|
78
|
+
Actual Cloud setup and execution remain unobserved without their own receipts.
|
|
79
|
+
Keep existing workflow gates, trust and independent review; preparation replaces
|
|
80
|
+
none of them.
|