Repository navigation
A mind's oldest acts fold into one reopenable line: the view's floor no longer grows with every act (Level::Folded) - #5600
Conversation
…ever held On the M5 (2026-10-29 22:00Z), after #5595 kept a record for every saved result, Aris's view held 97 results with 2 whole: ~95 pointers x ~190 chars (~4.5k tokens) of floor before anything whole fit, growing with every act. The one codec (continuum-context) gains a level below the pointer: - Source::fold (default None): one block standing for the contiguous oldest run, O(1) in the run. A source without it floors at its pointers as before. - view/allot.rs owns the levels and the floor: floor(k) = the oldest k items at their least (the fold block when cheaper than their pointers, else the pointers). Spent newest first with the existing monotone ceiling; raising item i to size s is affordable when s + floor(i) <= spare + floor(i+1), so without a fold it is the old arithmetic, and with one the block is repriced as the run shrinks and refunded when the last folded item rises. - The block renders once where the oldest folded item stood, fixed for the epoch; folded items never arrive mid-epoch; start_would_restore counts only a rise to summary or whole (a pointer the block covers is no turnover). - Claim.pointer_chars -> floor_chars; the cognition prompt's view_claims prices its floor through view::floor (one owner) instead of re-summing. - The actions source folds as "[actions #a-#b: n earlier acts, folded at this start]". Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…ld says so Folding her oldest acts into "#a-#b" hid each act's handle, and tool/output took only an outputId, so a folded act could not be reopened (goal 7: the full result stays reachable). - tool/output takes exactly one of outputId or act. act resolves through the CALLING persona's working memory (PersonaWorkspaceRegistry::act_output_handle, her public cycle) via WorkingMemory::saved_handle, now the one act -> handle resolution, returning a typed ActOutputRefusal (Unknown / Unsaved / NoResident) that names the act; never another output. Help, schema doc and the generated ToolOutputParams.ts say so. Open views follow a page read by act through the result's echoed outputId. - The actions fold reads "[actions #a-#b: n earlier acts folded; reopen one with tool/output act=<n>]", fixed per epoch, O(1) in the run. - Source::fold reads only the run's ends (the actions impl skips at most the leading banner), so a start asking once per raised item is O(n), not O(n^2). - Fold-or-pointers is decided once, in chars (view::allot fold_of); view::floor prices that decision in the caller's unit, so view_claims (tokens) and the view never disagree about which rendering is the floor. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…he front, so a turnover keeps the settled prefix; the fold run is the oldest acts after it Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
|
Review (Cormac) at exact ac74f01: source PASS. It becomes a full PASS once CI at this head is green (4 pass, 32 pending as I write). All five design points from my brief are in the code:
I also checked Non-blocking: |
|
PASS (Cormac) at exact ac74f01: CI green at this head (38 pass, 0 fail), on top of my source review above. |
Fixes a regression from #5595 (records kept for every saved result, so last copies survive): every record entered her view as a pointer, and `levels()` floored at the SUM of pointers. On the M5 at 22:00Z Aris showed 97 results with 2 whole; ~95 pointers x ~190 chars was ~4.5k tokens of floor, growing every act.
Codec (continuum-context): `Level::Folded` below Pointer; a source's floor is ONE fold block (`Source::fold`, reads only the run's ends) for its contiguous oldest run, else its pointers as before (sources without a fold are unchanged). The grant is spent newest first with the existing monotone ceiling. Cormac's design review folded in: Folded->Pointer is not a restore (no turnover churn); the block is fixed per epoch; O(1) text; a folded item's want stays its whole; a leading standing item (the `[actions]` banner) never folds, so a turnover keeps the settled prefix. `view::floor` is the one owner of a source's floor in any unit. Folded acts reopen by number: `tool/output act=` resolves through her working memory's `saved_handle` (typed refusal for unknown/unsaved acts).
Measured
🤖 Generated with Claude Code
https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo