Skip to content

Her work in hand survives a turnover: the file she is editing and her note on each edit stay whole (cards a386374b, 89655d88) - #5985

Merged
joelteply merged 3 commits into
canaryfrom
fable/her-work-survives-a-turnover
Nov 14, 2026
Merged

joelteply merged 3 commits into
canaryfrom
fable/her-work-survives-a-turnover

Conversation

@joelteply

@joelteply joelteply commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Persistent minds that code lose the file they are editing, and the progress they made on it, whenever their view turns over. Then they re-read the file and re-do finished work. This change advances order-of-work line 2 (a mind's context as an epoch) and goal 7 (one budget, never her newest).

Evidence (the M5, canary 575027f, Aris 8044b75b)

  • delib.view.sized / delib.view.turnover (continuum-probes.jsonl.1 + .jsonl):
    • 00:24:45Z: view_tokens 51,438 > granted 50,808 (room 0), restart=false. Epoch 2278, start_chars 63,299, 32 collapsed.
    • 00:28:27Z: view_tokens 45,606 > granted 42,348, restart=false. Epoch 2279, start_chars 63,278, 36 collapsed. This act's tail held her whole re-read of the file: tail_kept 27,278 then 38,262 chars.
  • Captures (prompt-captures/8044b75b…jsonl), epoch 2278 and 2279 starts:
    • The 849-line deploy_actuator.rs read is #8067 … — summary (outline).
    • Her plan thought ("Let me analyze Fable's four review items") and her "Item 4 is done" note are at their head+tail summary.
    • She read the file whole again after the start (00:28:26Z read_file 1-), then 6 more region reads by 00:36Z, with no further edit after 00:03Z.

Step 1: what started these epochs

Overflow, not a restart, count, age or focus switch. turnover_due (prompt/epoch.rs:647, view_tokens > allowed → Turnover::Overflow) fired because the view outgrew what the act granted it. context_window 71,143 is the whole window; the view's grant is that minus tools (~7.9k), framing (~2.7k), reply and the newest-result grant (17,352 at 00:28). The 63k start_chars is the size after the start collapsed, not the trigger. The trigger is legitimate and is kept. What was wrong is what the start collapsed.

The fix (inside the codec, as data)

  • continuum-context: Item::in_hand is one datum, so there is no separate allowance and no constant.
    • view::allot keeps such an item whole while its source's grant holds it beside every other item at its floor. It is charged like any item, and the oldest is given up first when the grant cannot hold them all.
    • The oldest run folds around it, so holding one read does not cost the floor of every later act.
    • Claim::newest counts it, so the start that sizes grants funds it like her newest item.
    • depth::collapsible never offers it.
  • continuum-cognition: the marks are read off typed state.
    • OpenView::edited_seq: an applied code/edit/code/write of a file she has open from this checkout. Matching works whichever spelling was used (checkout-relative or absolute; Aris had both).
    • OpenView::kept_read: her newest read that showed the whole file, else her newest read. A later region read never replaces a whole read.
    • WorkingMemory::in_hand() returns those reads, plus her note on each edit: the first thought after that edit's result, since the read she keeps.
    • The actions and thoughts sources mark those items.
    • release_edge never archives an act from the oldest kept read on, so a fold past it cannot take it out of RAM.
  • Everything else still collapses oldest first. Within an epoch nothing changes: items append as before.

Tests (each with // what this catches:)

  • continuum-context view/tests/in_hand.rs:
    • a start keeps the file whole while newer acts collapse, and the same start without it in hand collapses the file;
    • a grant that cannot hold it gives it up and never overspends;
    • the oldest run folds around it.
  • working_memory/tests/open_views.rs (Aris's shape):
    • an edit puts the read and her note in hand, across spellings and a restart, and a later region read does not replace the whole read;
    • a turnover through the real Actions and Thoughts sources keeps the file and her note whole, with newer acts collapsed, and without the edit the file collapses.
  • working_memory/tests/history.rs: a fold past the file she is editing leaves its read resident.

Size

553 lines added, 56 removed (251 of the additions are tests and docs). thoughts.rs item construction moved into Thoughts::item (a move, so it could be marked). No file passes 1,000 lines (view.rs 964).

Not compiled locally: the M5 is serving live minds, so CI is the compiler.

Live receipt (Measured)

Before (Aris, 8044b75b, canary 575027f, captures since 21:00Z):

  • deploy_actuator.rs: 15 edits and 14 reads.
  • After her last edit (00:03Z): 7 reads from 00:24:44Z to 00:35:42Z, 3 of them whole (1-), across the two turnovers.
  • "Item 4 already done" rework: she wrote that item 4 was committed at 00:21Z and 00:24Z, then spent 5 acts from 00:30Z to 00:45Z re-checking item 4 (about 12 per hour).

After: owner Fable. Deadline is 24 h after this deploys. Check: reads of a file per finished edit of it across turnovers, and acts re-doing an item her own note marked done, per hour, on the same resident. Card a386374b stays open until the receipt is posted.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo

… note on each edit stay whole (cards a386374b, 89655d88)

Aris on the M5, 2026-11-14 00:24:45Z and 00:28:27Z: two overflow turnovers (view 51,438 tokens over a
50,808 grant; 45,606 over 42,348) collapsed the 849-line deploy_actuator.rs she was editing to its
outline and her "item 4 is done" note to its head and tail. She read the file again after each
(7 reads 00:24-00:36Z, no edit) and re-checked item 4 in 5 acts after it was done.

The codec gets one datum, Item::in_hand: a start keeps such an item whole while its source's grant
holds it beside the rest at their floor (oldest given up first, charged like any item), the claim's
newest end counts it, depth never collapses it, and the oldest run folds around it. Her memory marks
it from typed state: an applied edit/write of a file she has open (OpenView::edited_seq) keeps its
whole read (KeptRead: a whole read is never replaced by a later region), and the first thought after
each edit's result is her note. The memory owner never releases acts from that read on.

Not compiled locally (the M5 is serving); CI is the compiler.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
joelteply and others added 2 commits November 13, 2026 19:22
…ds, verbs once, allot without a retry loop (review of #5985)

Review findings (js-shaped-rust-2026-11-14 #8 #9 #10 #25 #27 #28):
- ThoughtRecord.body is ThoughtBody { Resident { text, saved }, Shed { handle, chars: NonZeroUsize } };
  the empty-message fallback is gone. The checkpoint wire shape is unchanged (serde try_from/into),
  and an unreadable checkpointed thought is dropped with a probe, never failing the checkpoint.
- A thought's item key is its ElementId (Item::occurrence, ElementId::key); the fold names the count
  and the newest saved whole.
- OpenView.work is ViewWork { Seen, Read(KeptRead), Editing { read, edited } }: an edit without a
  kept read cannot be represented. The edited path comes from CodeEditParams / CodeWriteParams.
- ActSeq and ThoughtOccurrence newtypes; ActionRecord.verbs classed once at the act seam.
- allot: the first suffix of her work in hand whose floor fits (Floors), one walk, no remove(0) loop.

#26 (one lock for WorkingMemory, CheckoutRoot scope) is left for its own change: scope is persisted on
three record types and WorkingMemory holds ~20 locks.

Not compiled locally (the M5 is serving); CI is the compiler.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…g does

The resident-bounds ratchet requires a touched thought_log.rs to end with no store that only grows.
At each start, thoughts up to the thoughts source's fold edge whose wholes are saved leave her log
(and her checkpoint); a thought held only in RAM and her note on an edit in hand stay, and the view
forgets the released ids. A thought's view key comes from one owner (Thoughts::key_of).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
@joelteply
joelteply merged commit 2f36a90 into canary Nov 14, 2026
18 checks passed
@joelteply
joelteply deleted the fable/her-work-survives-a-turnover branch November 14, 2026 02:22
joelteply added a commit that referenced this pull request Nov 14, 2026
…e ratchets

Rule 10/11 text: canary's #5986 wording kept, plus the shape-ratchet section, its
baselines and the correction that time_bounds and wall_clock never counted sleeps.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
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