Skip to content

fix(admission): a held card takes the lane before a musing turn — three lane classes, work first among the non-directed - #4058

Merged
joelteply merged 1 commit into
canaryfrom
fix/a-held-card-takes-the-lane-before-a-musing-turn
Sep 15, 2026
Merged

joelteply merged 1 commit into
canaryfrom
fix/a-held-card-takes-the-lane-before-a-musing-turn

Conversation

@joelteply

Copy link
Copy Markdown
Contributor

What

Three lane classes at the serving-lane admission gate instead of two. LanePriority { Directed, Work, Ambient } replaces the directed: bool:

  • Directed is unchanged: the full pool, one lane always reserved (Build(deps-dev): Bump eslint from 9.24.0 to 9.37.0 #139).
  • Work: the caller holds a card in progress (the faculty's own holds_live_work). It queues in the non-directed semaphore in arrival order and is counted while it waits.
  • Ambient: an undirected turn with no card in hand (musing, wandering, a dream). It takes a non-directed permit only when one is free and no Work caller is counted; otherwise it parks on the gate's release signal and never enters the queue ahead of work. Parked, not starved: once no work waits it takes the next free lane.

Receipts: admission.lane.granted / released carry priority; admission.lane.ambient_yielded_to_work fires once per park.

Why

Measured 2026-09-15 04:20–05:00Z on the M5 (16 minds, 4 Ornith lanes @58k): 33 lane holds at 302 s p50 / 617 s p90, 14 acts, 0 writes, only 5 message-turn starts. The lanes went to self-cycle turns, and a mind musing with no card queued for the same budget, in arrival order, as a mind holding a card mid-edit. The health receipt read READING for the hour. The lane is the scarce thing; it goes to the mind that will write first.

Acceptance

On a node with more minds than lanes: admission.lane.ambient_yielded_to_work > 0 within the first hour, admission.lane.granted with priority=Work outnumbering Ambient while any card is held, and the [health] line's writes/hour up from 0. Whole cognition::resource_admission mod: 12/12.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo

…ee lane classes, work first among the non-directed

Measured 2026-09-15 04:20–05:00Z on the M5 (16 minds, 4 Ornith lanes @58k): 33 lane
holds at 302 s p50 / 617 s p90, 14 acts, 0 writes, only 5 message-turn starts — the
lanes went to self-cycle turns, and a mind musing with no card ("let me take stock")
queued for the same non-directed budget, in arrival order, as a mind holding a card
mid-edit. The health receipt read READING for the hour. A lane is the scarce thing;
it goes to the mind that will write first.

`LanePriority { Directed, Work, Ambient }` replaces the `directed: bool` at
`acquire_serving_lane`:
- Directed — unchanged: the full pool, one lane always reserved (#139).
- Work — the caller holds a card in progress (`holds_live_work`, the faculty's own
  predicate): queues in the non-directed semaphore and is COUNTED while it waits.
- Ambient — no card in hand (musing, wandering, a dream): takes a non-directed permit
  only when one is free AND no Work caller is counted; otherwise parks on the gate's
  release signal (1 s tick as a missed-wake guard) and never enters the queue ahead of
  work. Parked, not starved: once no work waits it takes the next free lane.

Receipts: `admission.lane.granted/released` carry `priority`; a new
`admission.lane.ambient_yielded_to_work` fires once per park. Test: with one
non-directed lane held, a Work and an Ambient caller both arrive; the freed lane goes
to Work, Ambient stays parked until Work releases, then takes it.

Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
@joelteply
joelteply merged commit 91a2949 into canary Sep 15, 2026
5 checks passed
@joelteply
joelteply deleted the fix/a-held-card-takes-the-lane-before-a-musing-turn branch September 15, 2026 05:32
joelteply added a commit that referenced this pull request Sep 15, 2026
…s Work class keyed on InProgress and saw none (#4060)

#4058's receipt on the M5 (build 5331, 06:08–06:33Z): 25 non-directed lane grants,
every one Ambient, 0 Work, 13 acts. The active-work block renders a held card as
`[Claimed]` or `[InProgress]` (card_holder treats both as held), and the board held
11 Claimed against 3 InProgress — the predicate the lane gate borrowed
(`holds_live_work`, keyed on InProgress for the working-presence contract) read
"no work" for almost every holder.

`renders_held_card` = Claimed or InProgress; the faculty's `holds_work_card` uses it
for `LanePriority::Work`. The presence contract keeps its own key untouched.


Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo

Co-authored-by: Claude Opus 5 (1M context) <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant