wealth-engine
A personal finance and business economics MCP server that provides math-backed answers to financial questions, including investment growth, loan amortization, debt payoff strategies, and tax estimation, all computed locally without API keys or network calls.
README
💰 Wealth Engine MCP
An MCP server that helps you make more money and keep more of it — a complete personal-finance and business-economics toolkit your AI assistant can use to give you real, math-backed answers.
No API keys. No accounts. No network calls. Every answer is computed locally from battle-tested financial formulas, so it works the moment you install it and produces the same numbers every time.
The honest truth: software can't literally print money. But the decisions these tools inform — charging the right freelance rate, pricing a product at the profit-maximizing point, killing the avalanche of interest on your debt, picking the investment with the best risk-adjusted return — are worth a lot of money over a lifetime. That's where the leverage is.
Why this exists
Most "money" advice is vibes. This is arithmetic. Each tool implements the actual formula a financial analyst would use, returns a transparent breakdown (not just a single number), and is covered by tests that check it against known-correct values.
- ✅ 11 financial tools, each a real engine
- ✅ Zero setup — no keys, no DB, runs over stdio
- ✅ 58 passing tests validating the math against closed-form results
- ✅ Strict TypeScript, structured JSON output for both humans and agents
- ✅ Works in Cursor, Claude Desktop, and any MCP client
The tools
| Tool | What it answers |
|---|---|
compound_growth |
"If I invest $X and add $Y/month at Z%, what will it become?" (with inflation-adjusted real value) |
loan_amortization |
"What's my mortgage payment, and how much do extra payments save me?" |
debt_payoff |
"What's the fastest, cheapest way out of my debts — avalanche or snowball?" |
fire_calculator |
"How big a portfolio do I need to retire, and how many years until I'm financially independent?" |
freelance_rate |
"What hourly rate must I actually charge to hit my income goal?" |
price_optimizer |
"What price maximizes my profit, given how demand responds?" |
roi_compare |
"Which opportunity creates the most value?" (ROI, payback, NPV, IRR) |
tax_estimate |
"What's my income tax, effective rate, and marginal rate?" |
budget_analyzer |
"Where is my money leaking vs the 50/30/20 rule?" |
subscription_audit |
"How much can I recover by cutting low-value subscriptions?" |
side_hustle_ranker |
"Which side hustle is worth my time, risk-adjusted?" |
Install
1. Build it
npm install
npm run build
This produces dist/index.js, the runnable MCP server.
2. Register it with your MCP client
Cursor
Create or edit .cursor/mcp.json in your project (or ~/.cursor/mcp.json for global use):
{
"mcpServers": {
"wealth-engine": {
"command": "node",
"args": ["C:/Users/jejej/OneDrive/Escritorio/github_projects/mcp/dist/index.js"]
}
}
}
Then open Cursor → Settings → MCP and confirm wealth-engine shows 11 tools. Ask the agent something like "Use the freelance rate tool to tell me what to charge for a $150k target."
Claude Desktop
Edit claude_desktop_config.json:
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"wealth-engine": {
"command": "node",
"args": ["C:/Users/jejej/OneDrive/Escritorio/github_projects/mcp/dist/index.js"]
}
}
}
Restart Claude Desktop. The tools appear under the 🔌 menu.
Tip: During development you can skip the build step and run the TypeScript directly with
"command": "npx", "args": ["tsx", "/abs/path/src/index.ts"].
Tool reference & examples
Every tool accepts a JSON object and returns both a human-readable text block and machine-readable structuredContent. Below are representative inputs and the headline outputs.
compound_growth
{
"principal": 10000,
"contribution": 500,
"annualRatePct": 7,
"years": 30,
"periodsPerYear": 12,
"annualInflationPct": 2.5
}
Returns futureValue, totalContributed, totalInterest, realFutureValue (today's purchasing power), growthMultiple, and a year-by-year schedule.
loan_amortization
{ "amount": 400000, "annualRatePct": 6.5, "years": 30, "extraPayment": 300 }
Returns the periodicPayment, totalInterest, payoffYears, interestSavedVsNoExtra, and a full amortization schedule.
debt_payoff
{
"debts": [
{ "name": "Visa", "balance": 6000, "annualRatePct": 24.99, "minPayment": 150 },
{ "name": "Car", "balance": 12000, "annualRatePct": 6.5, "minPayment": 280 }
],
"monthlyBudget": 900,
"strategy": "compare"
}
compare (default) runs avalanche and snowball, reports monthsToDebtFree and totalInterestPaid for each, and tells you which is cheaper and by how much.
fire_calculator
{ "annualIncome": 120000, "annualExpenses": 48000, "currentInvestments": 80000, "realReturnPct": 5 }
Returns your fireNumber, savingsRate, yearsToFire, plus leanFireNumber and fatFireNumber.
freelance_rate
{
"targetAnnualIncome": 150000,
"annualBusinessExpenses": 12000,
"taxRatePct": 30,
"workingWeeksPerYear": 46,
"billableUtilization": 0.6
}
Returns the hourlyRate and dayRate you must charge, the billableHoursPerYear, and how that compares to the naive salary / 2080 mistake (vsNaiveSalaryRate).
price_optimizer
{
"demandPoints": [
{ "price": 29, "quantity": 420 },
{ "price": 39, "quantity": 300 },
{ "price": 49, "quantity": 190 }
],
"unitCost": 8,
"fixedCost": 2000
}
Fits a linear demand curve, then returns the optimalPrice (profit-max), revenueMaximizingPrice, the fitted demandModel with R², and a transparent price sweep.
roi_compare
{
"investments": [
{ "name": "Rental", "cashFlows": [-50000, 6000, 6000, 6000, 6000, 76000] },
{ "name": "Business", "cashFlows": [-50000, 0, 20000, 30000, 40000] }
],
"discountRatePct": 8
}
Returns per-investment roi, paybackPeriod, npv, irrPct, and the winners bestByNpv / bestByRoi / bestByIrr.
tax_estimate
{ "income": 95000, "deduction": 14600 }
Defaults to US 2024 single-filer federal brackets (override with your own brackets for any country/year). Returns totalTax, afterTaxIncome, effectiveRatePct, marginalRatePct, and the per-bracket breakdown.
budget_analyzer
{
"monthlyIncome": 6000,
"categories": [
{ "name": "Rent", "amount": 2200, "type": "needs" },
{ "name": "Dining", "amount": 800, "type": "wants" },
{ "name": "Index funds", "amount": 1200, "type": "savings" }
]
}
Compares your split to 50/30/20, finds unallocated money and overspending gaps, and returns concrete recommendations.
subscription_audit
{
"subscriptions": [
{ "name": "Streaming A", "amount": 15.99, "cycle": "monthly", "usesPerMonth": 12, "valueRating": 4 },
{ "name": "Gym", "amount": 60, "cycle": "monthly", "usesPerMonth": 1, "valueRating": 2 }
]
}
Annualizes every line, computes costPerUse, flags each as keep / review / cut, and totals potentialAnnualSavings.
side_hustle_ranker
{
"hustles": [
{ "name": "Consulting", "monthlyRevenue": 4000, "hoursPerMonth": 30, "successProbability": 0.9 },
{ "name": "Print shop", "monthlyRevenue": 2500, "monthlyCost": 600, "hoursPerMonth": 60, "startupCost": 5000, "rampMonths": 4, "successProbability": 0.6 }
]
}
Ranks by risk-adjusted effective hourly value, with breakEvenMonths and expectedYearOneProfit for each.
Development
npm run dev # run the server from TypeScript (tsx)
npm run typecheck # strict type checking, no emit
npm test # run the full vitest suite
npm run test:watch # watch mode
npm run build # compile to dist/
Project layout
src/
index.ts # stdio entry point (the MCP process)
server.ts # registers all 11 tools with Zod schemas
finance/ # pure, dependency-free financial engines
compound.ts loan.ts debt.ts fire.ts freelance.ts
pricing.ts roi.ts tax.ts budget.ts subscriptions.ts
sideHustle.ts money.ts
test/ # one spec per engine + an end-to-end server test
The design rule: all math lives in src/finance/ as pure functions with no MCP or I/O dependencies. The server is a thin adapter. That keeps the logic trivially testable and reusable.
How the numbers are validated
The tests don't just check "it runs" — they assert against independently-derived values:
- Compound growth is checked against the closed-form annuity future-value formula.
- Loan amortization is checked against the standard mortgage payment (a $100k/6%/30yr loan → ~$599.55/mo, ~$115,838 total interest).
- Tax is checked bracket-by-bracket against hand-computed US 2024 figures.
- IRR is checked against known multi-period rates and the trivial
[-100, 110] → 10%case. - Price optimization is checked against the analytic optimum of a known linear demand curve.
- An end-to-end test spins up the server over an in-memory transport, lists the tools, and calls them through the real MCP protocol.
Run npm test to see all 58 pass.
Disclaimer
This is an educational/decision-support tool, not financial, tax, investment, or legal advice. Tax brackets and assumptions are illustrative defaults — verify against current rules for your jurisdiction, and consult a qualified professional before making consequential decisions.
License
MIT — see LICENSE.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。