devrites 7.3.4 → 7.3.6
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/CHANGELOG.md +34 -0
- package/README.md +1 -1
- package/docs/adr/0039-autocomplete-structural-admission.md +87 -0
- package/docs/adr/0040-early-preparation-admission.md +76 -0
- package/docs/adr/README.md +2 -0
- package/docs/cli.md +103 -5
- package/docs/engine/commands.md +88 -1
- package/engine/internal/lib/claims.go +65 -8
- package/engine/internal/lib/context.go +50 -2
- package/engine/internal/lib/continuation.go +8 -1
- package/engine/internal/lib/dispatch.go +147 -46
- package/engine/internal/lib/frontier.go +139 -59
- package/engine/internal/lib/frontier_controller.go +667 -0
- package/engine/internal/lib/frontier_preparation.go +210 -0
- package/engine/internal/lib/frontier_roadmap.go +168 -0
- package/engine/internal/lib/next.go +14 -2
- package/engine/internal/lib/triggers.go +9 -0
- package/engine/internal/parallel/repository.go +10 -0
- package/pack/.claude/skills/devrites-lib/SKILL.md +2 -0
- package/pack/.claude/skills/devrites-lib/reference/parallel-workspaces.md +108 -115
- package/pack/.claude/skills/devrites-lib/reference/standards/afk-hitl.md +18 -17
- package/pack/.claude/skills/devrites-lib/reference/workspace-artifact-schema.md +41 -38
- package/pack/.claude/skills/rite-autocomplete/SKILL.md +35 -38
- package/pack/.claude/skills/rite-autocomplete/reference/loop.md +66 -59
- package/pack/.claude/skills/rite-autocomplete/reference/stop-conditions.md +28 -28
- package/pack/.claude/skills/rite-build/reference/parallel-batch.md +17 -15
- package/pack/generated/claude/skills/devrites-lib/SKILL.md +2 -0
- package/pack/generated/claude/skills/devrites-lib/reference/parallel-workspaces.md +108 -115
- package/pack/generated/claude/skills/devrites-lib/reference/standards/afk-hitl.md +18 -17
- package/pack/generated/claude/skills/devrites-lib/reference/workspace-artifact-schema.md +41 -38
- package/pack/generated/claude/skills/rite-autocomplete/SKILL.md +35 -38
- package/pack/generated/claude/skills/rite-autocomplete/reference/loop.md +66 -59
- package/pack/generated/claude/skills/rite-autocomplete/reference/stop-conditions.md +28 -28
- package/pack/generated/claude/skills/rite-build/reference/parallel-batch.md +17 -15
- package/pack/generated/codex/skills/devrites-lib/SKILL.md +2 -0
- package/pack/generated/codex/skills/devrites-lib/reference/parallel-workspaces.md +108 -115
- package/pack/generated/codex/skills/devrites-lib/reference/standards/afk-hitl.md +18 -17
- package/pack/generated/codex/skills/devrites-lib/reference/workspace-artifact-schema.md +41 -38
- package/pack/generated/codex/skills/rite-autocomplete/SKILL.md +35 -38
- package/pack/generated/codex/skills/rite-autocomplete/reference/loop.md +66 -59
- package/pack/generated/codex/skills/rite-autocomplete/reference/stop-conditions.md +28 -28
- package/pack/generated/codex/skills/rite-build/reference/parallel-batch.md +17 -15
- package/pack/generated/devin/skills/devrites-lib/SKILL.md +2 -0
- package/pack/generated/devin/skills/devrites-lib/reference/parallel-workspaces.md +108 -115
- package/pack/generated/devin/skills/devrites-lib/reference/standards/afk-hitl.md +18 -17
- package/pack/generated/devin/skills/devrites-lib/reference/workspace-artifact-schema.md +41 -38
- package/pack/generated/devin/skills/rite-autocomplete/SKILL.md +35 -38
- package/pack/generated/devin/skills/rite-autocomplete/reference/loop.md +66 -59
- package/pack/generated/devin/skills/rite-autocomplete/reference/stop-conditions.md +28 -28
- package/pack/generated/devin/skills/rite-build/reference/parallel-batch.md +17 -15
- package/pack/generated/dsh/skills/devrites-lib/SKILL.md +2 -0
- package/pack/generated/dsh/skills/devrites-lib/reference/parallel-workspaces.md +108 -115
- package/pack/generated/dsh/skills/devrites-lib/reference/standards/afk-hitl.md +18 -17
- package/pack/generated/dsh/skills/devrites-lib/reference/workspace-artifact-schema.md +41 -38
- package/pack/generated/dsh/skills/rite-autocomplete/SKILL.md +35 -38
- package/pack/generated/dsh/skills/rite-autocomplete/reference/loop.md +66 -59
- package/pack/generated/dsh/skills/rite-autocomplete/reference/stop-conditions.md +28 -28
- package/pack/generated/dsh/skills/rite-build/reference/parallel-batch.md +17 -15
- package/pack/generated/omp/skills/devrites-lib/SKILL.md +2 -0
- package/pack/generated/omp/skills/devrites-lib/reference/parallel-workspaces.md +108 -115
- package/pack/generated/omp/skills/devrites-lib/reference/standards/afk-hitl.md +18 -17
- package/pack/generated/omp/skills/devrites-lib/reference/workspace-artifact-schema.md +41 -38
- package/pack/generated/omp/skills/rite-autocomplete/SKILL.md +35 -38
- package/pack/generated/omp/skills/rite-autocomplete/reference/loop.md +66 -59
- package/pack/generated/omp/skills/rite-autocomplete/reference/stop-conditions.md +28 -28
- package/pack/generated/omp/skills/rite-build/reference/parallel-batch.md +17 -15
- package/pack/generated/pi/skills/devrites-lib/SKILL.md +2 -0
- package/pack/generated/pi/skills/devrites-lib/reference/parallel-workspaces.md +108 -115
- package/pack/generated/pi/skills/devrites-lib/reference/standards/afk-hitl.md +18 -17
- package/pack/generated/pi/skills/devrites-lib/reference/workspace-artifact-schema.md +41 -38
- package/pack/generated/pi/skills/rite-autocomplete/SKILL.md +35 -38
- package/pack/generated/pi/skills/rite-autocomplete/reference/loop.md +66 -59
- package/pack/generated/pi/skills/rite-autocomplete/reference/stop-conditions.md +28 -28
- package/pack/generated/pi/skills/rite-build/reference/parallel-batch.md +17 -15
- package/package.json +1 -1
|
@@ -51,6 +51,7 @@ time. No `state.md` run-mode field can drift out of sync.
|
|
|
51
51
|
Presence = AFK active. The file body is optional YAML:
|
|
52
52
|
|
|
53
53
|
```yaml
|
|
54
|
+
mode: autocomplete # optional controller identity; absent = standalone AFK
|
|
54
55
|
max_slices: 10 # whole-workspace writer budget; seeds state.md remaining count
|
|
55
56
|
max_agents: 32 # native agent dispatches in one host activation
|
|
56
57
|
max_minutes: 120 # min; /rite-autocomplete: not a ceiling
|
|
@@ -61,10 +62,13 @@ notify: 'curl -fsS -m 10 -d "$DEVRITES_QID: $DEVRITES_QUESTION" ntfy.sh/my-topic
|
|
|
61
62
|
allow_gates: [advisory, validating] # gate severities AFK auto-handles (auto-picks the recommended option)
|
|
62
63
|
continue_sequence: true # after Seal GO, open the next recorded continuation
|
|
63
64
|
max_workspaces: 5 # workspaces one armed sequence may open
|
|
64
|
-
max_parallel: 10 #
|
|
65
|
+
max_parallel: 10 # global writer cap; explicit --parallel N wins
|
|
65
66
|
```
|
|
66
67
|
|
|
67
|
-
|
|
68
|
+
AFK is read-only after entry. Explicit `/rite-autocomplete` upserts only
|
|
69
|
+
`mode: autocomplete` and, with `--parallel N`, `max_parallel: N`; preserve other
|
|
70
|
+
fields. Missing mode keeps standalone behavior; invalid/duplicate mode fails
|
|
71
|
+
closed. Mode identifies scheduling, never grants phase, safety or Git authority.
|
|
68
72
|
|
|
69
73
|
Outside active `/rite-autocomplete`, the following slice-budget rules apply:
|
|
70
74
|
`max_slices` seeds root-owned `state.md` cursor `afk_slices_remaining`
|
|
@@ -103,10 +107,9 @@ malformed values fail closed; `0` opens nothing.
|
|
|
103
107
|
candidate manifest to cover the whole recorded chain — run
|
|
104
108
|
`devrites-engine state merge-manifest <slug>` before Prove.
|
|
105
109
|
|
|
106
|
-
- Only
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
`/rite-autocomplete`.
|
|
110
|
+
- Only checked recorded continuations qualify, under the
|
|
111
|
+
[sequence grammar](../workspace-artifact-schema.md#what-each-file-owns).
|
|
112
|
+
No next entry or opening budget stops new openings, not existing child work.
|
|
110
113
|
- Milestones are **not** shipped: they stay sealed and unarchived in `.devrites/work/`
|
|
111
114
|
with `Next step: /rite-ship` preserved. Local `WIP(<slug>):` checkpoints still
|
|
112
115
|
land ([checkpoint.md](../../../rite-build/reference/checkpoint.md)), so the tree
|
|
@@ -118,15 +121,13 @@ candidate manifest to cover the whole recorded chain — run
|
|
|
118
121
|
`/rite-autocomplete` recovers agent-owned Seal `NO-GO` per
|
|
119
122
|
[stop-conditions.md](../../../rite-autocomplete/reference/stop-conditions.md), not a handoff.
|
|
120
123
|
|
|
121
|
-
`
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
after a batch completes. **Failing case:** `/rite-autocomplete --parallel 5`
|
|
129
|
-
honors leftover `max_parallel: 1`, or grants five writers per workspace.
|
|
124
|
+
`--parallel N` wins over AFK `max_parallel`, else retained lease capacity on
|
|
125
|
+
resume, else 10. Build's flag never rewrites AFK; explicit controller entry may
|
|
126
|
+
update only mode/capacity. One cap covers all admitted sources, even explicit 1;
|
|
127
|
+
standalone Build stays local. Follow the [global pass](../parallel-workspaces.md#continuous-global-frontier)
|
|
128
|
+
for immediate-successor preparation, narrow `frontier-blocked` deferrals,
|
|
129
|
+
qualified foreign `serial:` handoff and automatic dispatch-return scheduling.
|
|
130
|
+
These are scheduling disclosures, never readiness, isolation, proof or Ship waivers.
|
|
130
131
|
|
|
131
132
|
## Unattended resource envelope
|
|
132
133
|
|
|
@@ -157,8 +158,8 @@ applicable remaining limit. Agent/time/token/cost counters are per native activa
|
|
|
157
158
|
for a new activation. Slice/recovery state and review queue remain durable/recomputed across wakes.
|
|
158
159
|
Persist stops/checkpoints before notification.
|
|
159
160
|
|
|
160
|
-
|
|
161
|
-
|
|
161
|
+
Fresh AFK omits expiry and notification/token/cost caps. Standalone post-Vet
|
|
162
|
+
counts may lower slices; preserve existing fields except controller entry above.
|
|
162
163
|
|
|
163
164
|
Delete the file to restore HITL on the next invocation.
|
|
164
165
|
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
# Workspace artifact schema
|
|
2
2
|
|
|
3
3
|
Feature truth: `.devrites/work/<slug>/`, discovered by `state.md`; remnants/archives
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
without path/alias/format migration.
|
|
4
|
+
inactive. Spec's `README.md` is optional. Use canonical filenames. Both released
|
|
5
|
+
cursors read; no `schema` requires `devrites-engine migrate <slug>`.
|
|
6
|
+
`/rite-upgrade`: audit only, no path/alias/format migration.
|
|
8
7
|
|
|
9
8
|
## Contents
|
|
10
9
|
|
|
@@ -59,6 +58,7 @@ accept safe legacy basenames. Ordinary phases never rename them.
|
|
|
59
58
|
| `visual/<name>.outline.md` | required machine dual-read companion for the sibling HTML; outline wins on conflict; never a candidate path | 200 lines (advisory; not gate-checked) |
|
|
60
59
|
| `visual/README.md` | optional index of visuals in the workspace | 80 lines (advisory; not gate-checked) |
|
|
61
60
|
| `decisions.md` | ADR-style `DEC-###` log: status, context, options, decision, consequences, related IDs; optional `Files:`/`Tags:` fields make entries queryable by path or theme; Build's `## Carry-forward constraints` lines (rule, source slice, evidence, `Files:`) | 200 lines |
|
|
61
|
+
| `roadmap.md` | optional sequence authority (below); headerless maps stay legacy | — |
|
|
62
62
|
| `assumptions.md` | assumptions with confidence, owner, validation status | 160 lines |
|
|
63
63
|
| `questions.md` | current `q-YYYY-MM-DD-NNN` (or released `Q-###`) open/resolved questions, gate, answer, impact | 180 lines |
|
|
64
64
|
| `plan.md` | technical approach, slice strategy, canonical shared-contract proof, validation strategy, rollback | 220 lines |
|
|
@@ -85,6 +85,17 @@ accept safe legacy basenames. Ordinary phases never rename them.
|
|
|
85
85
|
For visual pairs load only matching [playbooks](visual-playbooks/index.md); use
|
|
86
86
|
the [required outline headings](visual-playbooks/outline-template.md).
|
|
87
87
|
|
|
88
|
+
Canonical `roadmap.md`: either header claims explicit authority; require both
|
|
89
|
+
`Sequence root: <actual-anchor-slug>` and `Decision: DEC-NNN`, identifying one
|
|
90
|
+
`## DEC-NNN` in owner-local `decisions.md`. One related live/archive owner, one
|
|
91
|
+
`Position`/`Workspace` table: contiguous from 1, unique valid slugs matching all
|
|
92
|
+
related positions/exact successors; no unenrolled nodes. Valid authority supersedes
|
|
93
|
+
history for scheduling; preserve historical bytes. Headerless maps remain legacy.
|
|
94
|
+
Partial/malformed headers, multiple owners, invalid root/decision/table, symlink
|
|
95
|
+
or unreadable maps fail closed, no fallback. Native normalization records approved
|
|
96
|
+
actual identities, preserves history. Engine identity checks grant no semantic
|
|
97
|
+
approval, independence, Build or Ship readiness.
|
|
98
|
+
|
|
88
99
|
## Candidate manifest and bindings
|
|
89
100
|
|
|
90
101
|
`touched-files.md` contains exactly one `## Touched files` heading and exactly
|
|
@@ -141,40 +152,32 @@ The worktree digest is deterministic but is not an atomic filesystem snapshot
|
|
|
141
152
|
against a malicious concurrent same-size rewrite. Ship's exact Git-index scope,
|
|
142
153
|
byte, binding, and secret checks own the final freeze immediately before commit.
|
|
143
154
|
|
|
144
|
-
Only
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
check
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
[feature-sequence split](../../rite-plan/reference/slicing.md#feature-ceiling-split-an-epic-never-override-the-budget)),
|
|
171
|
-
and history in `state.md` (checkpoint narrative moves verbatim to
|
|
172
|
-
`history/<file>-<YYYYMMDD>.md`, append-only, never a phase read-next, with a one-line
|
|
173
|
-
pointer left behind). A legacy reason-only `Budget override:` line no longer clears a
|
|
174
|
-
gate; `/rite-upgrade` routes it to relocation or the split, and new writers never create one for those two reasons.
|
|
175
|
-
Apply [[`context-hygiene.md`](standards/context-hygiene.md) dispatch packets](standards/context-hygiene.md#dispatch-packets)
|
|
176
|
-
for byte-size checks and lossless retrieval; budget overrides neither rewrite protected
|
|
177
|
-
history nor require loading it all.
|
|
155
|
+
Only structural `Budget override: <=N lines; <reason>` outside fences permits N
|
|
156
|
+
lines/N×400 bytes, N ≤ 2× budget. Reason-only overrides count as none. Budgets:
|
|
157
|
+
400 bytes/line (`state.md`: 120 lines/48 KiB); long lines cannot evade them.
|
|
158
|
+
`orient`: `artifact_budgets` (lines/bytes/over/override), `bulk_files` (non-canonical
|
|
159
|
+
files >64 KiB). Writers check limits before returning; no local script assumed.
|
|
160
|
+
|
|
161
|
+
`check readiness`/`check seal`/`state append` block present budgeted artifacts
|
|
162
|
+
(optional/`drift.md` included) at ≥1.5× lines or bytes without covering override.
|
|
163
|
+
Report exact measurement and remedies: lossless relocation (`/rite-plan revise`),
|
|
164
|
+
split (`/rite-plan course-correct`), bounded override. Past 2×: relocation/split
|
|
165
|
+
only; below 1.5×: advisory in `orient`.
|
|
166
|
+
Proof ledgers (`evidence.md`, `browser-evidence.md`, `touched-files.md`) alone may
|
|
167
|
+
grow unbounded, always advisory; manifest limits still apply. Read standalone
|
|
168
|
+
binding, `EVID-###`/section index (`grep -n`), then candidate AC/slice bodies.
|
|
169
|
+
Inspect no-in-scope-ID entries as anomalies. Whole-file reads require `orient`
|
|
170
|
+
within budget; Seal checks literal `AC-###` completeness, reader judges quality.
|
|
171
|
+
|
|
172
|
+
Slice/AC count and cursor history never justify durable overrides. Decomposition
|
|
173
|
+
overflow (`tasks.md`/`plan.md`/`traceability.md`) requires a
|
|
174
|
+
[feature-sequence split](../../rite-plan/reference/slicing.md#feature-ceiling-split-an-epic-never-override-the-budget).
|
|
175
|
+
Move `state.md` narrative verbatim to append-only `history/<file>-<YYYYMMDD>.md`;
|
|
176
|
+
leave a one-line pointer; history never enters phase read-next. Legacy reason-only
|
|
177
|
+
overrides cannot clear gates: `/rite-upgrade` routes relocation/split; new writers
|
|
178
|
+
never override these reasons. Use
|
|
179
|
+
[dispatch packets](standards/context-hygiene.md#dispatch-packets)
|
|
180
|
+
for byte checks/lossless retrieval. Overrides neither rewrite nor require loading protected history.
|
|
178
181
|
|
|
179
182
|
## Anchored notes
|
|
180
183
|
|
|
@@ -86,48 +86,45 @@ With `--lookahead` (trigger `lookahead`), follow
|
|
|
86
86
|
[`lookahead.md`](reference/lookahead.md) instead of the steps below: plan the
|
|
87
87
|
next sequence continuation through Vet in a second session, then stop.
|
|
88
88
|
|
|
89
|
-
1. **Orient and parse.** Resolve source per [phase target binding](../devrites-lib/reference/parallel-workspaces.md#phase-target-binding)
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
[
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
`
|
|
97
|
-
|
|
89
|
+
1. **Orient and parse.** Resolve source per [phase target binding](../devrites-lib/reference/parallel-workspaces.md#phase-target-binding).
|
|
90
|
+
Read its existing cursor; a fresh idea starts empty at step 2. Normalize this
|
|
91
|
+
invocation to idea, `ship_preflight: yes|no`, `max_slices: unlimited`,
|
|
92
|
+
`parallel: N|default`, `profile: standard|full`, `cross_model: yes|no`.
|
|
93
|
+
Apply the loop's [AFK contract](reference/loop.md#arm-afk-once) to an existing
|
|
94
|
+
sentinel: upsert `mode: autocomplete`, plus capacity only for explicit
|
|
95
|
+
`--parallel N`. Mode identifies this controller, never grants authority.
|
|
96
|
+
Run `devrites-engine frontier <source>` before local recovery; execute the
|
|
97
|
+
[global pass](../devrites-lib/reference/parallel-workspaces.md#continuous-global-frontier).
|
|
98
|
+
Reconcile blocked/terminal cursors against retained action evidence and exact
|
|
99
|
+
fingerprint attempts; resume offline recovery below its cap. This explicit
|
|
100
|
+
invocation reopens parked fingerprints. Reconstruct missing return cursors
|
|
101
|
+
only from the current phase and approved `test-plan.md`/evidence action.
|
|
98
102
|
<!-- workflow-artifact-adapter: {"module":"devrites-lib/reference/standards/workflow-artifacts.md","entry":"lifecycle cursor encounters admitted set or resumable journal","action":"invoke classifier; execute returned route internally","return":"saved phase/action; zero intermediate reply"} -->
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
handoff <source> --resume` first for that selected source and open only the
|
|
103
|
-
`read_next` artifacts it names, per [`context-hygiene.md`](../devrites-lib/reference/standards/context-hygiene.md) § Compaction fallback.
|
|
104
|
-
Normalize current arguments to idea, `ship_preflight: yes|no`,
|
|
105
|
-
`max_slices: unlimited`, `parallel: N|default`, `profile: standard|full`,
|
|
106
|
-
and `cross_model: yes|no`.
|
|
107
|
-
**Completion:** arguments and source authority are unambiguous; local cursor and pending handles remain intact.
|
|
103
|
+
After compaction/resume, run `devrites-engine handoff <source> --resume`
|
|
104
|
+
and open its `read_next` artifacts per [context hygiene](../devrites-lib/reference/standards/context-hygiene.md).
|
|
105
|
+
**Completion:** arguments/source are unambiguous; local cursor and handles survive.
|
|
108
106
|
2. **Specify and clarify.** Run `devrites-interview`, `/rite-spec`, and
|
|
109
107
|
`/rite-clarify` as one window. `open` material coverage never arms
|
|
110
108
|
AFK. **Completion:** `Decision coverage: CLEAR` is durable.
|
|
111
|
-
3. **Arm AFK once.** Apply the loop
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
**Completion:** loop reaches Seal GO or persists a valid stop before any later phase.
|
|
109
|
+
3. **Arm AFK once.** Apply the [one-write AFK contract](reference/loop.md#arm-afk-once):
|
|
110
|
+
create only after clarity; explicit controller entry upserts
|
|
111
|
+
`mode: autocomplete` and, only with `--parallel N`, `max_parallel: N`.
|
|
112
|
+
Preserve all other fields; reject malformed/duplicate mode rather than
|
|
113
|
+
silently becoming standalone AFK. **Completion:** valid controller identity
|
|
114
|
+
and capacity are durable; no gate or Git authority changed.
|
|
115
|
+
**Failing case:** leftover `max_parallel: 1` after explicit `--parallel 5`.
|
|
116
|
+
4. **Drive phases.** Execute [the loop](reference/loop.md): Spec → Clarify →
|
|
117
|
+
Temper → Define → Vet → Build → Prove → Polish → Review → Seal. Durable files
|
|
118
|
+
carry state. Apply the mutable post-vet budget before Build. Consume fresh scheduling
|
|
119
|
+
emitted by recorded `dispatch return`; rerun frontier after further changes
|
|
120
|
+
and before waits. Before ordinary local Temper/Define/Plan/Vet context/dispatch,
|
|
121
|
+
resolve sequence authority and start actual immediate-successor preparation
|
|
122
|
+
under [early admission](reference/loop.md#early-preparation-admission),
|
|
123
|
+
or retain the global pass's concrete deferral; keep the full Build gate.
|
|
124
|
+
Derive initial preparatory-only routing before any marked wave; do not recurse
|
|
125
|
+
through the roadmap. Preserve local cursors, protected validation windows and
|
|
126
|
+
every admission/isolation gate; pass Build the resolved global cap.
|
|
127
|
+
**Completion:** Seal GO or a durable valid stop precedes later phases.
|
|
131
128
|
5. **Apply stops.** At every gate use
|
|
132
129
|
[stop-conditions.md](reference/stop-conditions.md). A `blocked` label alone is not a stop condition:
|
|
133
130
|
route agent-owned red results through bounded recovery.
|
|
@@ -12,6 +12,7 @@ Autocomplete chains existing `/rite-*` workflows without routine-phase pauses. A
|
|
|
12
12
|
## Arm AFK once
|
|
13
13
|
|
|
14
14
|
```yaml
|
|
15
|
+
mode: autocomplete
|
|
15
16
|
allow_gates: [advisory, validating]
|
|
16
17
|
# max_slices / max_agents / max_minutes / max_review_queue omitted: unlimited
|
|
17
18
|
# continue_sequence: false # opt out; default chains after Seal GO
|
|
@@ -22,18 +23,15 @@ allow_gates: [advisory, validating]
|
|
|
22
23
|
# notify: "<cmd>"
|
|
23
24
|
```
|
|
24
25
|
|
|
25
|
-
Read existing
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
It is otherwise read-only: never rewrite it after Vet or reset it on resume. Leftover `expires_at` is ignored
|
|
35
|
-
and never rewritten. **Failing case:** leftover `max_parallel: 1` keeps the run
|
|
36
|
-
serial after `--parallel 5`.
|
|
26
|
+
Read existing AFK first. On each explicit Autocomplete invocation, upsert only
|
|
27
|
+
`mode: autocomplete` and, if supplied, `max_parallel: N`; preserve other fields.
|
|
28
|
+
Missing mode retains standalone AFK behavior until that explicit entry. Invalid
|
|
29
|
+
or duplicate mode fails closed; mode grants neither phase nor action authority.
|
|
30
|
+
If absent, create AFK after clarity with the mode above; capacity is explicit N,
|
|
31
|
+
else retained global lease capacity, else 10. Preserve existing capacity without
|
|
32
|
+
the flag. Nested phases/wakes leave AFK unchanged: no `max_slices` flag seeding,
|
|
33
|
+
expiry rewrite or reset. Legacy slice/agent/time/review limits do not stop this
|
|
34
|
+
controller. **Failing case:** `--parallel 5` retains `max_parallel: 1`.
|
|
37
35
|
|
|
38
36
|
### Derive the mutable post-vet budget
|
|
39
37
|
|
|
@@ -43,18 +41,41 @@ remaining. AFK configuration itself stays unchanged.
|
|
|
43
41
|
|
|
44
42
|
### Admit each unattended cycle
|
|
45
43
|
|
|
46
|
-
Before each phase
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
44
|
+
Before each phase/fan-out/recovery/writer, check readiness/overlap and apply early
|
|
45
|
+
admission and the global pass below; local readiness is insufficient. Count every leaf.
|
|
46
|
+
Explicit activation resets only activation-local counters, not durable recovery.
|
|
47
|
+
Pass resolved `--parallel N` to [Build](../../rite-build/reference/output.md#caller-owned-continuation).
|
|
48
|
+
Legacy or invented execution ceilings never stop this controller; human limits bind.
|
|
49
|
+
Resolve ranked validating/blocking picks via `devrites-engine state resolve`, not
|
|
50
|
+
a user handoff. Escalating, irreversible-risk, access, unrecommended blocking picks
|
|
51
|
+
and Seal judgment (`slice: seal`) still pause.
|
|
52
|
+
|
|
53
|
+
## Early preparation admission
|
|
54
|
+
|
|
55
|
+
Internal exclusive `context`/`dispatch open` flags:
|
|
56
|
+
- `--prepare-for <parent-source>`: permitted native non-Build preparation roles
|
|
57
|
+
(only controlling-root context may be roleless), exact existing immediate
|
|
58
|
+
successor/parent agreeing on canonical identity, binding, adjacency and chain.
|
|
59
|
+
Exempts the child's successor gate, never product writes.
|
|
60
|
+
- `--sequence-research`: only canonical `evidence-scout`, Spec/Clarify/Temper/Define/
|
|
61
|
+
Plan/Vet, exact existing source and normal path/role/ledger constraints. Exempts
|
|
62
|
+
authority/successor admission solely to investigate broken authority read-only:
|
|
63
|
+
no acceptance, scope/approval/phase advance, successor creation, writers,
|
|
64
|
+
readiness or preparation credit.
|
|
65
|
+
|
|
66
|
+
Context (`--skill rite-<phase>` too) checks before writes; no account required.
|
|
67
|
+
Use context → packet → open → native launch → `dispatch start` actual handles
|
|
68
|
+
before parent admission; openings alone do not count.
|
|
69
|
+
|
|
70
|
+
Derive preparatory-only B before any marked wave from nonterminal parent A:
|
|
71
|
+
until ordinary unmarked B Temper/Define/Plan/Vet or Build-wright admission
|
|
72
|
+
(checking C first), A becoming terminal or ordered handoff to B, C waits—even
|
|
73
|
+
explicit C `next`/`check continuation`. No C creation/rerouting before A's eligible
|
|
74
|
+
phase. Completed B history retains this bound; Spec/Clarify/research/read-only
|
|
75
|
+
Build do not release it. Independent work stays visible; all global-pass gates bind.
|
|
76
|
+
|
|
77
|
+
Shared registry edits alone do not serialize disjoint modules. Isolate their
|
|
78
|
+
writer; refusal-only tests never replace positive requirements or defer their band.
|
|
58
79
|
|
|
59
80
|
## Phase arc
|
|
60
81
|
|
|
@@ -74,12 +95,10 @@ Workspace files, not chat, carry state. Read/execute each phase skill:
|
|
|
74
95
|
| 10 | `/rite-seal` | GO/NO-GO; no Git |
|
|
75
96
|
| 11 | `/rite-ship` | only after GO; `--ship` never authorizes Git; stop at literal-GO/native approval |
|
|
76
97
|
|
|
77
|
-
At phase entry, before
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
Preserve local cursors, pending handles and protected validation windows;
|
|
82
|
-
scheduling precedes owner Seal without changing ordered handoff below.
|
|
98
|
+
At phase entry, before recovery/waits, execute the
|
|
99
|
+
[global pass](../../devrites-lib/reference/parallel-workspaces.md#continuous-global-frontier).
|
|
100
|
+
Consume persisted return frontiers; rerun after landing/artifact/capacity changes.
|
|
101
|
+
Execute authorized routes, retaining handles, cursors and protected proof windows.
|
|
83
102
|
|
|
84
103
|
Check [stop-conditions.md](stop-conditions.md) before advancing. Discard stale
|
|
85
104
|
pass evidence after source edits. Re-read the selected source before each phase per [phase target binding](../../devrites-lib/reference/parallel-workspaces.md#phase-target-binding). On a cold resume or
|
|
@@ -92,19 +111,12 @@ floor; `--update` never excuses an unreconciled regression.
|
|
|
92
111
|
|
|
93
112
|
## Sequence continuation
|
|
94
113
|
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
For an already prepared child, do not re-specify. Follow
|
|
103
|
-
[`parallel-workspaces.md`](../../devrites-lib/reference/parallel-workspaces.md)
|
|
104
|
-
while the owner is still running: honor claims, repair/re-Vet stale readiness,
|
|
105
|
-
and admit only explicitly independent/dependency-satisfied isolated work.
|
|
106
|
-
ACTIVE changes to the child only at normal ordered handoff after the owner Seal;
|
|
107
|
-
resume its durable cursor without a second controller or another opening charge.
|
|
114
|
+
With a recorded successor, budget and no opt-out, Seal GO stays internal:
|
|
115
|
+
leave the owner sealed/unshipped with `/rite-ship`; resume the child's cursor/
|
|
116
|
+
controller or authorized native Spec. Use the
|
|
117
|
+
[shared grammar](../../devrites-lib/reference/workspace-artifact-schema.md#what-each-file-owns).
|
|
118
|
+
Charge once; pipeline only immediate successors. ACTIVE changes at ordered handoff,
|
|
119
|
+
not early planning or isolated independent Build.
|
|
108
120
|
|
|
109
121
|
Before invoking a continuation, require durable `state.md`
|
|
110
122
|
`sequence_workspaces_remaining > 0`; if absent, first write
|
|
@@ -158,19 +170,14 @@ and park it after three escalations while independent work continues.
|
|
|
158
170
|
|
|
159
171
|
## Continuous caller obligation
|
|
160
172
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
Critical/Important invariant is progress, not exhaustion.
|
|
173
|
-
|
|
174
|
-
The number of completed repair/Vet cycles, context pressure, compaction, session
|
|
175
|
-
duration, and nested completion never turn checkpoints into handoffs. Persist and
|
|
176
|
-
resume to the requested rest point or shared human/safety/access/parked-recovery stop.
|
|
173
|
+
Execute each green slice/phase's `next_action` internally. Before replying, run
|
|
174
|
+
`devrites-engine check continuation`: consume `required`'s `invoke:`; only `clear`
|
|
175
|
+
permits reply. Controller normalization/preparation/foreign work precedes local
|
|
176
|
+
Build; local repair/picks/reconciliation/discharged deferrals keep their phase,
|
|
177
|
+
not recursive Autocomplete. Route agent-owned NEEDS_REPLAN, budgeted Critical/Important recovery,
|
|
178
|
+
independent work and recommended blocking answers internally; invoke repair or
|
|
179
|
+
`state resolve` unless the [resolver-failure stop](stop-conditions.md#other-stop-classes)
|
|
180
|
+
applies. Distinct invariants are progress; unchanged resolver retries are not.
|
|
181
|
+
Cycles, context pressure, compaction, duration and nested completion never create
|
|
182
|
+
handoffs. Persist/resume until requested completion or a shared human/safety/
|
|
183
|
+
access/parked-recovery stop.
|
|
@@ -28,24 +28,27 @@ Fully escalated fingerprints park unless remaining owner is human.
|
|
|
28
28
|
|
|
29
29
|
## Not stops: internal technical routing
|
|
30
30
|
|
|
31
|
-
AFK
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
31
|
+
For AFK `status=running`, consume an internal phase edge. In
|
|
32
|
+
`mode: autocomplete`, actionable global normalization, preparation or foreign
|
|
33
|
+
work takes priority over local Build; local-only picks do not recurse through
|
|
34
|
+
Autocomplete. Source human/Ship holds remain binding, while independent
|
|
35
|
+
authorized planning can continue. `clear` is reply permission, not Ship approval.
|
|
36
|
+
|
|
37
|
+
A preparation refusal routes native work or a narrow disclosed scheduling
|
|
38
|
+
deferral under the [global pass](../../devrites-lib/reference/parallel-workspaces.md#continuous-global-frontier).
|
|
39
|
+
Deferral removes only its named scheduling obligation from repeated continuation:
|
|
40
|
+
it neither makes a placeholder prepared nor waives readiness, malformed authority,
|
|
41
|
+
claims, isolation, proof or human gates. Qualified foreign serial handoff is a
|
|
42
|
+
separate rule. Revisit deferrals when their constraint changes.
|
|
43
|
+
|
|
44
|
+
Agent-owned NEEDS_REPLAN or nested STOP persists the return cursor and invokes
|
|
45
|
+
Plan repair, affected Recovery Vet, remediation and proof inline. Three
|
|
46
|
+
no-progress corrections spend that fingerprint's strategy; escalate through
|
|
47
|
+
shared root cause, diagnostic amplification and boundary redesign without asking.
|
|
48
|
+
After three escalations, park it and finish independent work. Preserve attempts;
|
|
49
|
+
resume through `/rite-autocomplete`, not a routine phase command. A new explicit
|
|
50
|
+
invocation reopens parked fingerprints; wakes/compaction do not. Closure is
|
|
51
|
+
progress; a distinct Critical/Important invariant gets its own cap.
|
|
49
52
|
|
|
50
53
|
Spent consumptive-action authorization is not technical-recovery exhaustion.
|
|
51
54
|
It blocks another execution; retained new Critical/Important evidence still
|
|
@@ -74,14 +77,10 @@ Without a safe seam, escalate or park; only a real human/risk/scope gate stops f
|
|
|
74
77
|
- **Clarify:** material `open`/unowned decision coverage or a
|
|
75
78
|
low-confidence high-consequence assumption. Continue the initial interview;
|
|
76
79
|
never arm AFK early.
|
|
77
|
-
- **Seal:**
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
can close, a finding with a fix direction, a missing `review.md` verdict), then
|
|
82
|
-
re-enter Seal. The unattended `N` to accepting Important risks means repair, not
|
|
83
|
-
stop. Stop only for blockers that need a human: accepting a risk, changing scope
|
|
84
|
-
or an acceptance criterion, or access. Record each one as a question.
|
|
80
|
+
- **Seal:** NO-GO never rounds up to GO. Recover agent-owned missing/unbound proof,
|
|
81
|
+
reviewer gaps and findings, then re-enter Seal; declining Important-risk
|
|
82
|
+
acceptance means repair. A human-owned risk, scope/acceptance change or access
|
|
83
|
+
blocker remains a question. A first repairable NO-GO is not a handoff.
|
|
85
84
|
- **Reslice:** execute its marked action before deciding continue/stop.
|
|
86
85
|
- **Slice budget:** do not stop on `--max-slices`. Leftover
|
|
87
86
|
pre-existing remaining value, explicit flag, sentinel cap, or post-vet pending count
|
|
@@ -91,8 +90,9 @@ Without a safe seam, escalate or park; only a real human/risk/scope gate stops f
|
|
|
91
90
|
another session blocks only work on those paths; run independent work, re-check,
|
|
92
91
|
and stop only when nothing independent remains. `released`/`dead` claims are
|
|
93
92
|
reconciled per [§ Cancellation](../../devrites-lib/reference/parallel-dispatch.md#cancellation-and-terminal-reconciliation).
|
|
94
|
-
- **Resource envelope:** overlapping
|
|
95
|
-
|
|
93
|
+
- **Resource envelope:** overlapping controllers, missing AFK after arm or invalid/
|
|
94
|
+
duplicate mode fail closed. Ignored slice/agent/time/review ceilings do not stop
|
|
95
|
+
Autocomplete; mode itself grants no authority.
|
|
96
96
|
- **Confidence:** intent still cannot become testable acceptance after interview.
|
|
97
97
|
- **Repeated failure:** not a stop. Escalate; fully escalated fingerprints park.
|
|
98
98
|
Stop only when no independent work remains.
|
|
@@ -4,11 +4,11 @@
|
|
|
4
4
|
|
|
5
5
|
Opt-in only. Default `/rite-build` stays [`one-slice-cycle.md`](one-slice-cycle.md).
|
|
6
6
|
|
|
7
|
-
Autocomplete
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
stays
|
|
11
|
-
|
|
7
|
+
Autocomplete executes the shared [global pass](../../devrites-lib/reference/parallel-workspaces.md#continuous-global-frontier)
|
|
8
|
+
before local writers: actual immediate-successor preparation or narrow disclosed
|
|
9
|
+
deferral, then global cohort admission. Consume fresh dispatch-return scheduling.
|
|
10
|
+
Standalone Build stays local; select notices never broaden its picks. A placeholder
|
|
11
|
+
is not preparation; one successor pipelines safely without preparing the whole roadmap.
|
|
12
12
|
|
|
13
13
|
## Entry
|
|
14
14
|
|
|
@@ -17,13 +17,15 @@ expand its picks. Autocomplete consumes `frontier-select-command`, then this lif
|
|
|
17
17
|
| omitted / `--parallel 1` | Serial one-slice |
|
|
18
18
|
| `--parallel N` (**2≤N≤10**) | N is a **cap**, not a quota: run the largest eligible set ≤ N |
|
|
19
19
|
| non-integer / `N≤0` / `N>10` | Hard refuse (no silent clamp) |
|
|
20
|
-
| Autocomplete `--parallel N` |
|
|
20
|
+
| Autocomplete `--parallel N` | Global cap for this run; controller entry upserts mode and explicit capacity, preserving other AFK fields |
|
|
21
21
|
| Autocomplete, no flag | Same path, cap from sentinel `max_parallel` else 10; serial only when ineligible |
|
|
22
22
|
|
|
23
23
|
AFK caps `N`. Charge each green sibling once after its successful landing;
|
|
24
24
|
rejected/unlanded work charges zero, without undoing prior landed accounting.
|
|
25
25
|
`parallel create` refuses another retained repository controller.
|
|
26
|
-
|
|
26
|
+
Cold resume reconciles retained repair artifacts by exact fingerprint. A blocked
|
|
27
|
+
label, round count or distinct finding alone does not stop: establish current
|
|
28
|
+
review coverage under step 4 and repair unless a genuine stop remains.
|
|
27
29
|
|
|
28
30
|
## Dynamic selection and re-batching
|
|
29
31
|
|
|
@@ -89,14 +91,14 @@ Before `parallel select`, add each slice's hidden write surfaces (list owner:
|
|
|
89
91
|
snapshot directory, formatter sweep — and compare paths case-folded
|
|
90
92
|
(`src/Api.ts` = `src/api.ts`); `--from-plan` adds the manifest/lockfile for a package.
|
|
91
93
|
Slices colliding on either run serially; the rest
|
|
92
|
-
stay eligible. Record `serial: <ids> — <surface>` in `evidence.md`.
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
94
|
+
stay eligible. Record `serial: <ids> — <surface>` in `evidence.md`. AFK cap≥2
|
|
95
|
+
refuses narrower Build-wright waves until other picks are started/reserved or
|
|
96
|
+
each skipped pick has a substantive serial reason. Repairing/already-started/in-wave
|
|
97
|
+
alone is not a reason. Controller admission also includes ready foreign picks:
|
|
98
|
+
only exact `serial: child/SLICE-001 — <reason>` can defer that foreign lane; bare
|
|
99
|
+
`SLICE-001` is local. Preparation `frontier-blocked:` cannot waive ready Build
|
|
100
|
+
picks or safety gates. Qualified unsupported-isolation deferral preserves truthful
|
|
101
|
+
owner dispatch/ordered handoff, never early same-tree foreign Build. HITL stays unchanged.
|
|
100
102
|
|
|
101
103
|
## Control vs workers
|
|
102
104
|
|