Repository navigation
feat(cognition): a roster hold and a declared team are INPUTS to the grid allocation — never something the spawner applies after it (card 426a26fb, lane 2 of Track A) - #4267
Conversation
|
APPROVE with one mechanical condition — read at 562a7a3 (design-before-code, Track A's gate). Right, and it is the design: the hold and the declared team are INPUTS to the one decision — an exclusive hold DEFINES a box's roster (seats = min(warm, names), only the named sit, nothing minted for a ghost name, an empty list restricts nothing), a derived hold only orders (team first, never fewer), and a role floor seats in batches (every floor first, then remainders) with the floor's shortfall as the spawn signal's first claim. No holds, no floors = #4259 unchanged, and the mutation receipt is the kind of proof I want on this file. The condition: #4263 merged at 16:06Z (owners/terms/OfferBook, same file), so this rebases onto canary and the two seams merge into one: (a) Note, not a condition: a hold's names arrive as ids "resolved by whoever builds the inputs" — that is the daemon (my next PR); it resolves the roster_hold file's names through the registry once per change, never per tick. |
…grid allocation — never something the spawner applies after it (card 426a26fb, lane 2 of Track A) Cormac's note on #4259: the operator's roster hold and a recipe's declared team are inputs to THIS decision. Today the spawner caps its own draw by the hold (`seats_under`), skips held-out names at the draw (`draw_intents`), and a recipe's team is a role list with no minimum — three decisions about the same seats in three places. - `Hold { node, only, exclusive }` on `GridInputs`: an EXCLUSIVE hold (the operator's file) admits only its names on its node and the node has at most `only.len()` seats — the hold DEFINES that box's roster, so a name with no mind behind it is an empty seat, never one to mint (the 2026-09-13 shape: population 12, hold of 5, the reconciler asking the exhausted provider for 7 every second). An exclusive hold naming nobody restricts nothing (`seats_under`'s own semantics). A DERIVED hold (a working round's team) orders: its names seat first on its node, everyone else after, never fewer. - `RoleFloor { role, min_seats }`: the declared team. Minds are seated in batches — every role's floor first (in role order), then every role's remainder — so a 4-seat box with 5 coders and 1 orchestrator seats 3 + 1 under a floor of one orchestrator, 4 + 0 without. A floor the grid cannot fill for want of MINDS is the spawn signal's first claim: `open` names the orchestrator before the box's best role. A floor for a role no node holds opens nothing. No floors and no holds = the #4259 allocation exactly (its nine scenarios unchanged). - The seat cap and the admission live in `decide_node` / `allocate`; a hold's node is a named mind's home first. Three scenarios pinned: the exclusive hold (roster, spill, ghost name, empty list), the derived hold (team first, stable, home override), the declared team (3 + 1, floor above the minds, open-for-the-team first, a floor nobody holds). Faster or slower: pure; one allocation per change, never per tick. Same order. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
562a7a3 to
b507eea
Compare
Card 426a26fb — lane 2 of Track A, on top of #4259 (bc48d9b). Companion to #4263 (owners/terms), which touches the same file: whichever lands second rebases (both add fields to
GridInputsand the testinputs()helper; no semantic overlap).What
Hold { node, only, exclusive }onGridInputs. EXCLUSIVE (the operator'sroster_holdfile, names resolved to ids by whoever builds the inputs): only its names sit on its node, and the node has at mostonly.len()seats — the hold DEFINES that box's roster, so a name with no mind behind it is an empty seat, never one to mint. An exclusive hold naming nobody restricts nothing (seats_under's own semantics). DERIVED (a working round's team): its names seat first on its node, everyone else after, never fewer.RoleFloor { role, min_seats }: a recipe's declared team. Minds seat in batches — every role's floor first (role order), then every role's remainder — so a 4-seat box with 5 coders + 1 orchestrator seats 3 + 1 under a floor of one orchestrator, 4 + 0 without. A floor the grid cannot fill for want of MINDS is the spawn signal's first claim:opennames that role before the box's best role. A floor for a role no node holds opens nothing.decide_node/allocate. No holds, no floors = feat(cognition): the grid allocates its minds — one pure allocation with the machine scenarios as tests (card 2eec3977) #4259 exactly: its nine scenarios are unchanged.Why
Cormac's note on #4259: the hold and the declared team are inputs to THIS decision, not something a consumer applies after it. Today the spawner caps its own draw by the hold (
seats_under), skips held-out names at the draw (draw_intents), and the team is a role list with no minimum — three decisions about the same seats in three places. Next slice (same card): the spawner'sseats()reads this node'sNodeAllocationandopenby owner, andseats_under/bounded_by_warm_slotsretire into the allocator.Tests
Three scenarios, each a test first: the exclusive hold (roster, spill to the other box, ghost name, empty list); the derived hold (team first, stable, home override); the declared team (3 + 1, floor above the minds that exist, open-for-the-team first, a floor nobody holds). Receipt:
cargo test --lib cognition::grid_allocation13 passed / 0 failed, REAL_EXIT 0. Proven by mutation: floors ignored → only the team scenario fails; exclusive hold admitting everyone → only the hold scenario fails (12/1 each), file restored.Faster or slower: pure; one allocation per change, never per tick. Same order.
🤖 Generated with Claude Code
https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE