
Bahi Mcp
io.github.NayakwadiS由 GitHub 帳號 NayakwadiS 發布v0.3.1更新於 Oct 29, 2026
Indian mutual fund data and analytics, NSE/BSE market data, and financial calculators.
概覽
本機 MCP 伺服器,讓助理取得印度共同基金淨值資料、NSE/BSE 股票與指數行情,並進行基金分析與財務計算。
- 可以做什麼
- 搜尋 AMFI 基金方案,讀取方案詳情、最新淨值報價、淨值歷史與投資組合市值,並可清除快取
- 進行基金分析:依真實淨值歷史模擬 SIP 報酬、多檔基金並列比較、滾動報酬分布
- 取得 NSE/BSE 股票報價、指數報價(Nifty 50、Sensex、Bank Nifty、India VIX)及 OHLCV 歷史
- 計算財務數值:XIRR、CAGR、貸款 EMI、定存/零存整付到期值、單筆投資終值、SIP 預測、SWP、退休所需本金及基金贖回稅負估算
- 適用情境
- 適合助理需要回答印度共同基金、NSE/BSE 股票與指數相關問題,或進行投資、貸款、存款與稅務計算的情境,避免憑空猜測數字。較適用於研究與規劃類對話,而非交易或報稅決策。
- 執行需求
- 以本機 Python 套件形式執行(需 Python 3.10+),可用 pip 安裝或透過 uvx 執行;股票與指數工具需額外安裝 yfinance 相依套件。存取 AMFI 與 Yahoo Finance 資料需要網路連線。未宣告任何帳號、API 金鑰或環境變數。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Bahi Mcp,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
bahi-mcp
MCP server that gives AI assistants (Claude, Cursor, VS Code and others) access to Indian mutual fund data, NSE/BSE market data and financial calculators.
Bahi (बही) is the traditional Indian ledger. This server keeps the numbers straight so your assistant doesn't guess them.
Disclaimer: bahi-mcp provides information and calculations from public data sources (AMFI via the
mftoollibrary, and Yahoo Finance for stocks) and from assumptions you supply. It is not investment or tax advice and the author is not a SEBI-registered adviser. Data may be delayed or inaccurate, and tax rules change. Verify before making decisions.
What you can ask
- "Compare these three flexi-cap funds on 3-year return, volatility and max drawdown."
- "How often has this fund beaten 12% on rolling 3-year returns?"
- "If I had invested ₹10,000 a month in scheme 119551 since January 2020, what would it be worth today, and what is my XIRR?"
- "What's the Nifty at, and how has RELIANCE done over the last year?"
- "How much tax would I pay if I sell this equity fund after 14 months with a ₹2 lakh gain?"
- "How much corpus do I need to retire at 55 if I spend ₹60,000 a month today?"
Tools
Mutual fund data (AMFI)
Mutual fund analytics
Stocks and market data (NSE/BSE, via Yahoo Finance; unofficial and best-effort)
Calculators
Dates can be DD-MM-YYYY or YYYY-MM-DD.
Install
Requires Python 3.10+.
Or run without installing, using uv:
Configure your MCP client
Claude Desktop
Add to claude_desktop_config.json:
Drop "--with", "yfinance" if you don't need stock data. Restart Claude Desktop.
Cursor and other clients
For Cursor, save this in ~/.cursor/mcp.json. Remove "--with", "yfinance" if you don't need stock data.
Notes on data and accuracy
- Mutual fund data comes from AMFI through
mftool(3.4 or newer). NAVs are published after market close, usually by about 9 PM IST. mftool caches NAVs for 24 hours, so useclear_cacheafter the evening update to see the latest. - Stock data comes from Yahoo Finance through
yfinance. It is unofficial, can be delayed, rate-limited or change without notice. Don't use it for trading decisions. - Tax estimates follow the configured FY 2026-27 assumptions for equity funds (STCG 20%, LTCG 12.5% above the remaining ₹1.25 lakh annual exemption); provide purchase and sale dates for exact calendar 12-month classification, or holding days for an approximate 365-day cutoff. The exemption is shared across eligible gains in a financial year. Debt funds are modelled at slab rate only for units bought on/after 1 April 2023. Surcharge, loss set-off and older indexation rules are not modelled; verify current law and consult a tax professional.
- Projections (
project_sip,calculate_swp,plan_retirement) assume constant returns. Real markets don't behave that way.
Development
Layout in src/bahi_mcp/:
analytics.py,fund_analytics.py,calculators.py: pure Python, no network, fully tested offlinedata.py: AMFI access throughmftoolmarket.py: stock and index access throughyfinanceserver.py: the MCP tool definitions
Roadmap
- Portfolio overlap and fund-to-fund correlation
- Document search over factsheets and SEBI/RBI circulars
- Hosted version with caching
Contributing
Issues and pull requests are welcome.
License
MIT. See LICENSE.
來源:README.md,提交 77b33b2
工具
0版本歷史
1- v0.3.1最新Oct 29, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分