Repository navigation
Know what the team costs, and cap it with monthly budgets - #58
Merged
Merged
Conversation
- Spend is booked when it is spent: one ledger row per stretch of a run, so a run that continues next month counts there, and spend stays when an agent is deleted. Past runs are booked once (old runs that stored the session's total count only what they added) and again after a restore. - Activity shows today, this week, this month and all time, and for the chosen period who and what kind of work the money went to. - Monthly budgets for the team (Settings → AI) and any agent (its settings; only the human sets them). You're told at 80% and at 100%. - At 100% automations, follow-ups and board tickets are held, not failed: the chat says "Held — the team's October budget is used up", the agent says "Held · budget used up", and the work continues by itself on the 1st, as soon as you raise the budget, or now with "Let it run". Chats you start (and Run now) still run, with a note once a month. Unattended work can't hand work to an agent over budget; scheduled checks and dreams wait. - Managers can answer "what did we spend" with spend_overview; runs_list says when a run is held for a budget. - The phone says when a chat is held and can let it run.
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.
so a run that continues next month counts there, and spend stays when
an agent is deleted. Past runs are booked once (old runs that stored the
session's total count only what they added) and again after a restore.
chosen period who and what kind of work the money went to.
settings; only the human sets them). You're told at 80% and at 100%.
the chat says "Held — the team's October budget is used up", the agent
says "Held · budget used up", and the work continues by itself on the
1st, as soon as you raise the budget, or now with "Let it run". Chats
you start (and Run now) still run, with a note once a month. Unattended
work can't hand work to an agent over budget; scheduled checks and
dreams wait.
says when a run is held for a budget.
Checks
pnpm typecheck: all packages passMigration 52 (spend ledger, budget columns on paused runs). The new routes are
GET /api/spend,GET /api/budgetsandPOST /api/budgets/release(Cloud: allowed; phone: closed). Cloud billing keepsGET /api/usage.