Skip to content

feat: add FinOps model choice opportunity scoring#147

Merged
ccf merged 2 commits intomainfrom
feat/model-choice-opportunity-scoring
Mar 26, 2026
Merged

feat: add FinOps model choice opportunity scoring#147
ccf merged 2 commits intomainfrom
feat/model-choice-opportunity-scoring

Conversation

@ccf
Copy link
Owner

@ccf ccf commented Mar 26, 2026

Summary

  • score workflow-level model downshift opportunities inside FinOps cost modeling
  • surface potential savings and confidence in the FinOps modeling tab
  • true up the roadmap status for model-choice opportunity scoring

Testing

  • PYTHONPATH=src pytest tests/test_finops.py -q
  • ruff check src/primer/common/schemas.py src/primer/server/services/finops_service.py tests/test_finops.py
  • cd frontend && ./node_modules/.bin/vitest run --run src/components/finops/tests/workflow-cost-table.test.tsx src/components/finops/tests/workflow-compare-card.test.tsx src/components/finops/tests/model-choice-opportunity-table.test.tsx
  • cd frontend && ./node_modules/.bin/eslint src/components/finops/model-choice-opportunity-table.tsx src/components/finops/modeling-tab.tsx src/components/finops/tests/model-choice-opportunity-table.test.tsx src/types/api.ts
  • cd frontend && ./node_modules/.bin/tsc --noEmit

Note

Medium Risk
Adds new backend analytics and schema fields to the cost-modeling response plus a new UI surface, which could affect query performance and the correctness of cost/success calculations used for recommendations.

Overview
Adds model-choice opportunity scoring to FinOps cost modeling: the backend now analyzes sessions by workflow archetype to suggest cheaper models that maintain similar success rates, returning top opportunities plus aggregated potential monthly savings in CostModelingResponse.

Surfaces these recommendations in the FinOps modeling tab via a new ModelChoiceOpportunityTable component (with tests), and updates API types/schemas accordingly; also marks the roadmap item as shipped.

Written by Cursor Bugbot for commit cb4e62a. This will update automatically on new commits. Configure here.

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is ON, but it could not run because the spend limit has been reached. To enable Bugbot Autofix, raise your spend limit in the Cursor dashboard.

@ccf ccf merged commit 21791da into main Mar 26, 2026
6 checks passed
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.

1 participant