TokenBudgetRecord
Interface: TokenBudgetRecord
Defined in: src/core/agent/window/types.ts:172
What one OVER-BUDGET visit to tokenBudget put in the ledger.
Extends
Properties
iteration
readonlyiteration:number
Defined in: src/core/agent/window/types.ts:121
ReAct iteration this visit belongs to.
Inherited from
keepRecentTurns
readonlykeepRecentTurns:number
Defined in: src/core/agent/window/types.ts:181
How many recent turns were off-limits to this visit.
measuredTokens
readonlymeasuredTokens:number
Defined in: src/core/agent/window/types.ts:175
Adapter-reported input tokens of the last call — what tripped the check.
overBudget
readonlyoverBudget:boolean
Defined in: src/core/agent/window/types.ts:179
True when the measurement was over budget (a drop was attempted).
refusals
readonlyrefusals: readonlyWindowRefusal[]
Defined in: src/core/agent/window/types.ts:130
Every turn that refused to leave, named.
Inherited from
removedMessageCount
readonlyremovedMessageCount:number
Defined in: src/core/agent/window/types.ts:125
How many messages left the window.
Inherited from
WindowRecord.removedMessageCount
removedStageIds
readonlyremovedStageIds: readonlystring[]
Defined in: src/core/agent/window/types.ts:123
runtimeStageIds of the stages that appended the messages that left.
Inherited from
strategy
readonlystrategy:"token-budget"
Defined in: src/core/agent/window/types.ts:173
WindowStrategy.name of the strategy that decided — 'summarize-oldest',
'sliding-window', 'token-budget', or your own. Narrow on it.
Overrides
thresholdTokens
readonlythresholdTokens:number
Defined in: src/core/agent/window/types.ts:177
The budget it was compared against.
windowCharsAfter
readonlywindowCharsAfter:number
Defined in: src/core/agent/window/types.ts:128
Inherited from
windowCharsBefore
readonlywindowCharsBefore:number
Defined in: src/core/agent/window/types.ts:127
Window size in chars before / after this visit. Exact, and not tokens.
