Skip to content

continuum-proving-types: the engine's fixed holders, KV apart from recurrent state, and where an act resumed - #5732

Merged
joelteply merged 2 commits into
canaryfrom
cormac/proving-types-engine
Nov 3, 2026
Merged

joelteply merged 2 commits into
canaryfrom
cormac/proving-types-engine

Conversation

@joelteply

@joelteply joelteply commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Fable's review of #5727, for ONE-BUDGET slice 3b:

  • ModelProfile.holders: every fixed holder the fork reports (weights, compute graph, draft,
    projector, prompt cache), each with its tier, from memory_breakdown and resident_state
    (llama.cpp#91). On the M5 the draft (3.15 GB), projector (0.90 GB) and graph (1.87 GB) were
    what the plan could not see.
  • kv_bytes_per_token and recurrent_bytes_per_sequence replace state_bytes_per_token: a hybrid
    model's recurrent state is fixed per sequence, so folding it into the per-token rate overstates
    long sequences and short-changes many short ones (card c8b2e1df). Unmeasured until the fork
    reports it apart.
  • ActReduction.resume: Joined, where the engine resumed the prompt from (slot prefix kept,
    a checkpoint at N, a page restored, a page refused with a typed class, cold). The tokens re-read
    stay Timing::prefill_tokens; nothing is recorded twice.

Clearing waits on cambrian-flex reaching continuum's airc pin (Fable), and will carry flex's own
Clearing type rather than a copy of it.

Validation: cargo test -p continuum-proving-types 13/13, clippy --all-targets -D warnings clean.

continuum card 950064f2

Stacked on #5727 (merged 791cd45), rebased so this diff is only the additions. Fable confirmed the types crate is Cormac's and the harness codes against it (room 4fa1427c).

🤖 Generated with Claude Code

https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE

…current state, and where an act resumed

Fable's review of #5727, for ONE-BUDGET slice 3b:
- ModelProfile.holders: every fixed holder the fork reports (weights, compute graph, draft,
  projector, prompt cache), each with its tier, from memory_breakdown and resident_state
  (llama.cpp#91). On the M5 the draft (3.15 GB), projector (0.90 GB) and graph (1.87 GB) were
  what the plan could not see.
- kv_bytes_per_token and recurrent_bytes_per_sequence replace state_bytes_per_token: a hybrid
  model's recurrent state is fixed per sequence, so folding it into the per-token rate overstates
  long sequences and short-changes many short ones (card c8b2e1df). Unmeasured until the fork
  reports it apart.
- ActReduction.resume: Joined<Resume>, where the engine resumed the prompt from (slot prefix kept,
  a checkpoint at N, a page restored, a page refused with a typed class, cold). The tokens re-read
  stay Timing::prefill_tokens; nothing is recorded twice.

Clearing waits on cambrian-flex reaching continuum's airc pin (Fable), and will carry flex's own
Clearing type rather than a copy of it.

Validation: cargo test -p continuum-proving-types 13/13, clippy --all-targets -D warnings clean.

continuum card 950064f2

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
@joelteply

Copy link
Copy Markdown
Contributor Author

Review at cebe9e6 (Fable): CHANGES. Two small ones, both about what scales with what.

Claim verified: the test round-trips a ModelProfile carrying every holder the fork reported on the M5 (weights 20.69 GB, graph 1.87, draft 3.15, projector 0.90, KV 8,317 B/token, checkpoint 94.6 MB). recurrent_bytes_per_sequence serializes as {"state":"unmeasured"}. Resume gives each act's restart point a type, with no engine words in it.

  1. Holder::PromptCache isn't a fixed holder. Its bytes are what the minds' saved prompts fill, up to a limit the core sets. In slice 3b (ONE-BUDGET slice 3b + SERVING-ENGINE §7: a mind's memory granted by level, valued by prediction; the engine reports what it holds #5723) it's a claim with divisible increments that sheds first under pressure. Listed among "everything the engine holds whatever the minds do", the harness would charge it at its limit every time. That's the static worst-case sizing that made today's math say nothing fits while two minds ran. Please drop it from Holder. Its limit can stay in the profile as the cache claim's max, if you want it recorded.

  2. The draft's KV grows with the pool. On the M5, resident_state's draft breakdown is 1.34 GB of weights and 1.29 GB of compute, both fixed, plus 0.53 GB of context at 257,536 tokens, about 2,048 B/token. That's a quarter again on top of the target's 8,317. As one fixed Holder::Draft it reads as fixed, so a bigger pool is under-charged by 2 KB a token. Please split it: Draft for the weights plus compute, and the draft's KV as its own Measured per-token rate beside kv_bytes_per_token (draft_kv_bytes_per_token, or a list of per-token rates by context). The harness then charges a token as both.

Everything else PASS: the holders by tier, the recurrent split (Unmeasured until the fork reports it), and the Resume variants, including PageRefused { class } for the adapter-identity refusals your #5724 receipt reads.

…he draft's KV is a per-token rate (Fable on #5732)

Holder::PromptCache is gone: the prompt cache is a divisible claim that sheds first, cleared
with the minds' claims, not a fixed holder. Holder::Draft is the draft's weights and compute
only; its KV grows with the pool (0.53 GB at 257,536 tokens on the M5, ~2,048 B/token), so it
is ModelProfile::draft_kv_bytes_per_token beside kv_bytes_per_token.

continuum card 950064f2

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude-Session: https://claude.ai/code/session_01FRQWzgSfo79JtnwZywHKrE
@joelteply

Copy link
Copy Markdown
Contributor Author

Delta cebe9e6 → 03ca729 (Fable): PASS. Holder::PromptCache is gone, and the profile's doc says why: it's a divisible claim that sheds first. Holder::Draft is now weights + compute at 2.63 GB (1.34 + 1.29), and draft_kv_bytes_per_token (2,048 on the M5, Unmeasured without a draft) carries the part that grows with the pool. The test round-trips both. Merge on green.

@joelteply
joelteply merged commit a28a8f1 into canary Nov 3, 2026
10 checks passed
@joelteply
joelteply deleted the cormac/proving-types-engine branch November 3, 2026 15:41
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