Riddy21 / Riddy21/Friday_Budgeting_Pro
[P5] savings() tool — savings rate + monthly trend
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
Summary
Add a new savings_summary MCP tool that returns the user's savings rate and a monthly savings trend.
Requirements
-
Add a new MCP tool
savings_summary(period: str)inserver/main.py:- Accepts same period strings as
summary():month,year,ytd,YYYY-MM,YYYY - Returns:
{ "period": "2026-05", "income": 5000.00, "savings": 800.00, "savings_rate": 16.0, "monthly_trend": [ {"month": "2026-03", "income": 5000, "savings": 700, "rate": 14.0}, {"month": "2026-04", "income": 5000, "savings": 750, "rate": 15.0}, {"month": "2026-05", "income": 5000, "savings": 800, "rate": 16.0} ] } savings= sum oftransaction_entries.amountwhereentry_type = 'savings'savings_rate= (savings / income) × 100, rounded to 1 decimal; 0.0 if income is zeromonthly_trend= last 3 full months (always 3 entries, 0-filled if no data)
- Accepts same period strings as
-
Register the tool with
@mcp.tooldecorator -
Add to SKILL.md under the appropriate section
-
Add tests in
tests/covering the calculation and edge cases (zero income, no savings data) -
Update ARCHITECTURE.md MCP Tools section
Interactive check
Call the tool directly in Python and confirm it returns real output (not not_implemented).
Depends on
#281 (savings item_type must exist before this tool is meaningful)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in server/main.py by examining the existing summary() period handling and MCP tool registration. Add tests under tests/ for savings-rate calculation, zero income, missing savings data, and three zero-filled monthly entries. Update SKILL.md and ARCHITECTURE.md as requested, then call the tool directly in Python to confirm it returns the specified real output.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api, backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 58/100