Repository navigation
fix(budget): skip the session-naming call after a budget stop - #1173
Draft
sosidudku1 wants to merge 3 commits into
Draft
sosidudku1 wants to merge 3 commits into
sosidudku1 wants to merge 3 commits into
Conversation
A turn the spend ceiling ended still fired the session namer, a paid side call (up to 512 output tokens) that the budget never counted. The promise is "stop at the cap", so the namer is now skipped when the turn stopped for money (its own budget or the provider credit). The session stays unnamed until a later turn answers within its budget. ATO-1350, ATO-1354
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
A turn the spend ceiling ended still fired the session namer, a paid side call (up to 512 output tokens) that the budget never counted. The namer is now skipped when the turn stopped for money: its own budget (
cost_ceiling) or the provider credit (credit_exhausted). The session stays unnamed until a later turn answers within its budget.Why
The promise is "stop at the cap". Found by live scenario L10 on 09.11. Linear: ATO-1350 (ATO-1354 is the same bug).
L10 currently allows at most one naming call after the stop; with this change there are none, which still fits.
The "$0.01 of $0.01" vs "$0.02 of $0.01" mismatch from ATO-1354 is not changed here: the model's notice is written before the closing summary step, the card counts that step too.
How it was verified
stoppedForMoneyinruntime-turn-service.test.ts.Not yet checked on the second Mac.