Skip to content

fix(savings): report savings as yearly instead of monthly - #202

Merged
liamcervante merged 1 commit into
mainfrom
fix-521-mcp-providing-monthly-savings-instead-of-yearly-savings-for
Aug 6, 2026
Merged

fix(savings): report savings as yearly instead of monthly#202
liamcervante merged 1 commit into
mainfrom
fix-521-mcp-providing-monthly-savings-instead-of-yearly-savings-for

Conversation

@liamcervante

@liamcervante liamcervante commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

Fixes FIX-521

The dashboard switched to displaying annualized (/yr) savings, but the CLI and MCP surfaces still quoted the monthly figures the plugins and the Agents API report. This annualizes savings at the boundary where they enter the CLI, so every user-facing surface — human CLI output, --json, and MCP structured output — quotes savings per year. Costs and environmental metrics stay monthly.

Scan path

The plugin proto still reports monthly savings; format.convertProjectResult now multiplies by 12 into a renamed yearly_savings field on FinOps issues.

  • summary.total_potential_monthly_savingstotal_potential_yearly_savings
  • inspect: total_monthly_savingstotal_yearly_savings (summary, top-savings, --total-savings), monthly_savingsyearly_savings (top-savings rows, --fields projections), budget-detail savings rows → yearly_savings
  • human renderers print /yr on savings lines (Yearly Savings column, group-by and budget-detail views)

Findings path

The Agents API keeps returning estimatedMonthlySavings and the API client still decodes it faithfully. New FindingOutput / TaskOutput wire shapes convert at the CLI layer — floored after ×12, matching the dashboard's Format.annualizedDollars — exposed as estimatedYearlySavings / yearlySavings. The findings_list page total became total_yearly_savings, human renderers print $X/yr, and the findings/inspect MCP tool descriptions now say yearly.

Also updates the llmbench harness prompts and regenerates the inspect golden files.

Important

This changes the public scan --json wire format (monthly_savingsyearly_savings, with ×12 semantics). Consumers of the scan JSON need to pick up the rename. Companion skill-docs change: infracost/agent-skills PR to follow.

The dashboard switched to displaying annualized (/yr) savings; the CLI
and MCP surfaces still quoted the monthly figures the plugins and the
Agents API report. Annualize at the boundary instead:

- Scan output: finops issue monthly_savings -> yearly_savings (x12 at
  the plugin proto conversion), summary total_potential_yearly_savings,
  and the inspect views/fields/renderers follow (total_yearly_savings,
  yearly_savings columns, /yr labels). Costs and environmental metrics
  stay monthly.
- Findings/tasks: new FindingOutput/TaskOutput wire shapes annualize
  the Agents API's monthly figures (floored after x12, matching the
  dashboard's Format.annualizedDollars) as estimatedYearlySavings /
  yearlySavings, with /yr in the human renderers and updated MCP tool
  descriptions.
@liamcervante
liamcervante merged commit d5672b1 into main Aug 6, 2026
5 checks passed
@liamcervante
liamcervante deleted the fix-521-mcp-providing-monthly-savings-instead-of-yearly-savings-for branch August 6, 2026 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants