Prose surfaces are budgeted to the byte; the live context window is budgeted by nothing #202
Labels
No labels
already-shipped
bug
documentation
duplicate
enhancement
external-review
good first issue
help wanted
in progress
invalid
needs-decision
proposal
question
security
wontfix
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: crenshawdev/cadence-archived#202
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The asymmetry
weight-budgets.jsonbudgets Cadence's PROSE surfaces byte-exactly - 23 entriesacross
references/**andtemplates/**- andself-verifyfails on an overrunAND on a surface that shrinks below its recorded count. That check is why the
plan-frontmatter.mdbudget had to be re-pinned in the same commit that grew thefile, this milestone.
Nothing budgets the RUNTIME window a dispatch actually grows to. Cadence weighs
what it ships and never what it runs.
Why the runtime window is the one that costs
Over the last 7 days on this repo, cache-read is 62.5% of the bill and the average
context window is 121,250 tokens across 15,579 messages. Cost is close to
turns x window x 0.10, so the window is one of the two terms that multiply out tothe bill. The shipped prose surfaces are a small constant inside it.
burnrate records
peak_ctxper session. The worst on this project is 436,169 -more than three and a half times the average window, in a single session.
The proposal
A window ceiling per dispatch, in the same spirit as the byte budgets:
that the executor misbehaved, so the remedy is upstream and a hard failure would
punish the wrong actor.
self-verifyposture (a recorded number, an explicit re-pin when it legitimatelymoves) applies to both what Cadence ships and what Cadence runs.
What it depends on
Peak context per dispatch is not in
trace.jsonltoday - no window field existsthere. Either the close seam gains one, or this reads burnrate's per-session
peak_ctx. Both are filed separately; this issue is the consumer, not theinstrumentation.
Why it is worth having as its own idea
The byte budgets work. They caught a real drift this milestone and they are
cheap. The argument here is only that they measure the wrong thing for cost: a
16KB reference file is budgeted to the byte while a 436,169-token live window is
governed by nothing at all.