feat(queue): queue as data A2, migration, render and dispatch (#1508)

Filbert approved round 1 (f167b85e). Manifest 782bcb62, 21 files, plus
the QUEUE.md markers and the TOOLS.md section. Lead decision 35.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
2026-09-26 20:14:09 -05:00
co-authored by Claude Opus 5.5
parent c9539baa0f
commit 6ca116b7ba
32 changed files with 4886 additions and 103 deletions
+2
View File
@@ -431,3 +431,5 @@ are never rewritten or removed; corrections are new entries.
2026-09-27T00:42:33Z | Dewey (T3 Claude Code, thread 84fb346c) | CHAT-03 brief final edit (#1507 row 5), lead decision 32 | R3 frozen as BRIEF-r3-2c5be6b4.md; final BRIEF.md 1ef15ac0 (1451 lines, 0444) applies decision 30 cuts, decision 31 (no explicit extensions), n1 lock-integrity pin, n2 clear queue_update (O5, N25), Rocko fence build note; diff BRIEF-r3-to-final.diff c6bd1f1e sent to Filbert for scope check, then Sage pins. No commit or push.
2026-09-27T00:44:53Z | Filbert (T3 Claude Code, thread 9cb9731e) | CHAT-03 final scope check (lead decision 32): BRIEF.md 1ef15ac0 against r3 2c5be6b4, diff c6bd1f1e | PASS, all five items applied, nothing else in the diff; result sent to Sage, copy to Dewey; no commit or push
2026-09-27T00:45:04Z | Sage (T3 Claude Code, thread 1ef1e4f8) | CHAT-03 brief pinned | Filbert scope check PASS; BRIEF.md 1ef15ac0 committed with rounds and reviews; lead decision 33; QUEUE row 5. Source author after A2.
2026-09-27T01:11:05Z | Filbert (T3 Claude Code, thread 9cb9731e) | Queue A2 review round 1 (#1508, row 9): build.patch dc0be7ce on c9539baa, manifest 782bcb62, map 012ddce9, queue-md/tools-md patches | APPROVED, no blocking finding; genesis dry run reproduced in a /tmp clone; n1 row 13 can close #1508 before Gate G; report queue-a2-review-r1-2026-09-27.md f167b85e; verdict to Sage, copy to Darkwing; no commit or push
2026-09-27T01:14:09Z | Sage (T3 Claude Code, thread 1ef1e4f8) | queue A2 commit | Filbert A2 r1 approve (f167b85e); 21 files match manifest 782bcb62; queue-md and tools-md patches applied; nine suites green on index export; lead decision 35. Genesis next.
+18
View File
@@ -147,6 +147,24 @@ npm-global `mosaic` CLI; run by path. Exit codes: the launch script's own
once it runs; before that 1 could not start, 2 invalid config or seat, 4
usage. Details and the record's fields: `packages/seat/README.md`.
## Work queue (`scripts/mosaic queue`)
```bash
scripts/mosaic queue list | show ID | next [SEAT]
scripts/mosaic queue add|move|release|assign|note|set ... --op ID [--by NAME]
scripts/mosaic queue verify [--current] | render [--check] | sync | unlock [--check-gate]
scripts/queue-commit.sh -m MSG
```
`docs/plans/queue.json` holds the rows and an append-only log; the table in
`docs/plans/QUEUE.md` between the `mosaic-queue` markers is rendered from it.
Canonical checkout only. Every change needs an `--op ID` chosen before the
first attempt and reused on retry; only an op whose `ok <op> rev N` receipt
printed is done. The lead commits queue changes with `scripts/queue-commit.sh`;
the pre-commit guard refuses any other commit that stages the two queue files.
Exit codes: `0` ok · `1` failed · `2` invalid or refused · `3` uncertain,
retry the same op · `4` usage. Details: `packages/queue/README.md`.
## Discord connector (`scripts/discord.sh`)
```bash
+16
View File
@@ -433,3 +433,19 @@ which stay with him. Each item names who decided it and what happened.
`aborted` with no stop in progress, it treats it as an overlap signal.
It does not invent a stop link. This goes into the build and its tests,
and the pinned brief stays as it is.
35. **Queue A2 lands, then genesis.** Filbert approved A2 round 1 with no
blocking finding (f167b85e). Sage commits it with both patches, then
runs the dry run's order on the canonical checkout: map check, install
the hook, genesis, `queue-commit.sh --genesis`, then these logged ops:
- `assign 10 sage` (map choice 2).
- Row 13's gate becomes "rows 9 to 12 done, then a Monday ledger run
with zero queue violations, or every one moved the same day". This is
Filbert's n1. `after` gates only the start of a row, so it can't stop
row 13 going done before Gate G. The gate text does, and Sage owns
that gate. It also drops the stale 2026-09-21 date.
Map choices 1 to 8 are accepted as written. Row 16 stays
`waiting-on-jason` at genesis. #1510 is checked after genesis, through
the queue. Filbert's n2 (point the header at the goals review, reword
AGENTS.md's priority line) is row 10's work, now Sage's. n3 (a README
line saying `queue-commit.sh` calls `cli.mjs` directly) rides with
row 10.
+22 -14
View File
@@ -1,29 +1,32 @@
# QUEUE — the one task list
Read this first. One row per piece. Nobody needs to read the prose plans to
know what is next; the Brief column says which section to open only when you
are the owner of that row.
Read this first. One row per piece. The table between the markers is
rendered from `docs/plans/queue.json`, and `scripts/mosaic queue` is its only
writer. Don't edit the table by hand: `queue verify` and the commit hook
refuse a table that isn't the render. `packages/queue/README.md` has the verbs.
How to find your next thing:
- **Jason**: the first row whose State starts with `Jason:`.
- **A seat**: the first row where Owner is you and State is `in progress`,
`in review` or `briefed`. If there is none, you have nothing; say so on the
board and stop.
- **Sage, project lead** (Jason's ruling 2026-09-26; Darkwing before that): update this table at every gate, before
anything else is written. CURRENT.md is the narrative log; this table wins
- **A seat**: run `scripts/mosaic queue next`. It names the row to resume,
review or start, or says there is nothing; if nothing, say so on the board
and stop.
- **Jason**: rows in state `waiting-on-jason`, and parked rows to reopen.
- **Sage, project lead** (Jason's ruling 2026-09-26): changes the queue with
`scripts/mosaic queue` and commits `queue.json` with QUEUE.md through
`scripts/queue-commit.sh`. CURRENT.md is the narrative log; the queue wins
if they disagree.
States: `queued` (no brief yet) → `briefed` (brief written, not started) →
`in progress` → `in review` → `Jason: <what he must do>` → `done`. `parked`
means not before the rows above it and not without Jason's say. `required`
means it cannot be parked or reordered below `queued` rows; only Jason moves it.
States: `queued` (brief exists, not accepted) → `briefed` → `in-progress` →
`in-review` → `waiting-on-jason` → `done`. `blocked` returns to the state it
left. `parked` rows wait for Jason to reopen them. A `required` row can't be
parked, and only Jason clears the flag. `after` names the rows a piece waits
for.
Brief locations: "plan page" is `docs/plans/2026-09-12_control-board-mvp.md`.
Gaps found while working go to `docs/plans/DEFERRED.md`, not here.
## Pieces (in order)
<!-- mosaic-queue:begin -->
Lead: Sage from 2026-09-26 (Jason's ruling); Darkwing is a collaborating seat.
Jason is preparing the target for the next phase; until it arrives, the
priority below stands.
@@ -79,8 +82,13 @@ Gate F or when blocked."
| Console features outside the refined session-chat brief, including Fresh creation and model switching | Deferred by WEBUI Q1; required history/control/stop now belong to row 5, not this parked item | `2026-09-13_webui-session-chat.md` |
| Open gaps from the MVP work | Fixed only when a gate needs them | DEFERRED.md, "Open" |
<!-- mosaic-queue:end -->
## Log of table changes
Frozen at genesis. Since then the log in `docs/plans/queue.json` records every
change; the entries below are history.
- 2026-09-13 — created; rows 1 to 8 taken from CURRENT.md, DEFERRED.md and the plan page.
- 2026-09-13 — rows 9 to 13 added (#1508): the process itself becomes data with one writer and ledger checks. Jason: "I want this iron-clad." Required, not parked; rule: these rows cannot be moved to parked, only to done.