Skip to main content
Glama
avenir-mcp

avenir-mcp

Forecast the balance

forecast_balance
Read-onlyIdempotent

Projects account balances month by month from a YNAB budget and identifies the first month money would run out, so you can plan spending and income.

Instructions

Project the balance month by month and say when money would run out.

Starts from today's balance of the open on-budget accounts (or those given). For the current month, what was already spent or received since the 1st is deducted from the monthly averages, so only what is left is projected. Assumes, and returns as assumptions so the user can correct them: YNAB's scheduled transactions on their dates, whatever their frequency, a yearly bill included, charges that recur in the last 4 months (same payee, stable amount), the average of all other spending over the last 3 months, and what you pass. A payee with a schedule is projected by that schedule alone. A transfer between two projected accounts is left out, since it moves nothing out of them; a transfer to an account left out of the projection (a card not projected, a loan in a tracking account) is real money leaving, and counts. What you pass is the expected monthly income (default: the last 3 months' non-recurring inflows, which may include one-off money such as capital injections) and one-off amounts such as a tax bill (negative) or a refund (positive). Amounts in currency units. lowest is the lowest point within a month; first_shortfall is the first month it goes below zero. For a month already gone use get_monthly_summary, or get_spending_trends to compare several; for how long today's money would last with no income at all, get_runway. Changes nothing.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "plan_id": "<plan_id>",
      "until": "<until>"
    },
    "name": "forecast_balance"
  }
}

Input Schema

NameRequiredDescriptionDefault
untilYesLast month to project, YYYY-MM, at most 24 months ahead.
plan_idYesYNAB plan id or 'last-used'.
one_offsNoExpected one-off amounts: {date YYYY-MM-DD, amount, label}; not those already scheduled in YNAB, which are counted.
account_idsNoAccounts to include (from list_accounts); default all open on-budget accounts.
monthly_incomeNoIncome expected each month, replacing the income found in the history (recurring or average) and scheduled in YNAB; default: what they show.
variable_monthlyNoMonthly spending besides recurring charges (negative); default: the last 3 months' average.

Output Schema

NameRequiredDescriptionDefault
monthsYesThe projected months.
messageYesThe conclusion in one sentence, for the agent to relay.
accountsYesNames of the accounts projected together.
assumptionsYesEverything the projection assumed, to check with the user.
start_balanceYesTheir total balance today.
first_shortfallYesFirst month whose lowest balance is below zero; null if none.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only declare readOnly/idempotent/openWorld; the description goes far beyond by disclosing the entire projection methodology: scheduled transactions counted on their dates, recurring charges from the last 4 months, other spending averaged over 3 months, transfers between projected accounts excluded but transfers out to non-projected accounts counted, and assumptions returned so the user can correct them. It also states "Changes nothing," which corroborates the readOnly annotation rather than contradicting it.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The lead sentence is well front-loaded, but the middle paragraph is a dense wall of stacked clauses and parentheticals ("a transfer to an account left out of the projection (a card not projected, a loan in a tracking account) is real money leaving, and counts") that is harder to parse than the complexity requires. The content earns its place; the sentence structure does not.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex simulation tool with six parameters, this is unusually complete: it covers data sources, default derivation, exclusion rules, and even defines the returned fields `lowest` and `first_shortfall`. With an output schema and full annotations present, no material gap remains for an agent to call this correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline would be 3, but the description adds real meaning: it explains that monthly_income replaces income found in history *and* scheduled in YNAB (a defaulting behavior the schema does not state), that one_offs must not duplicate already-scheduled items, and that account_ids defaults to open on-budget accounts. It adds less about until and variable_monthly than it could, but the incremental value is genuine.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

"Project the balance month by month and say when money would run out" states a specific verb (project), resource (balance), and the two outputs that matter (trajectory and shortfall). It is immediately distinguishable from get_monthly_summary and get_runway, which the description itself names.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The closing sentence gives explicit routing: use get_monthly_summary for a month already gone, get_spending_trends to compare several, get_runway for how long today's money lasts with no income at all. This is a clear when-to-use-this versus when-to-use-something-else statement, with the alternatives named.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.