Indian Mutual Fund Intelligence MCP
This server is a read-only, provenance-tagged research tool that lets an AI assistant resolve, analyze, and pull source-document evidence for Indian mutual funds.
resolve_fund — turn a messy fund name, ISIN, or AMFI scheme code into an unambiguous scheme+plan identity, with availability flags.
get_fund_performance — compute trailing/rolling returns, risk metrics (volatility, Sharpe/Sortino), drawdowns, and stress-window performance; compare against category or benchmark; defaults to Direct/Growth plan.
get_fund_portfolio — retrieve holdings, sector/asset-class allocations, month-over-month changes (corporate actions flagged), concentration, and persistence; compare to previous month or a specific date.
get_fund_profile — return identity, verbatim mandate excerpts, benchmark, costs, managers, and associated documents.
get_document — fetch source-document evidence by keyword or SEBI-standard section, returning verbatim text with page numbers, SHA-256, and source URL.
All tools are read-only, idempotent, closed-world (no network calls during queries), and return provenance tags making every fact official/calculated/observed/approximation/inferred.
Provides tools to ingest, parse, and reconcile Tata Mutual Fund's monthly portfolio disclosures (holdings, ISIN-keyed change detection, corporate-action flagging, and concentration metrics) from live AMC XLSX files.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Indian Mutual Fund Intelligence MCP show latest NAV and portfolio for PPFAS Flexi Cap Fund"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Indian Mutual Fund MCP
Ask an AI assistant real questions about Indian mutual funds, and get answers built from the funds' own regulatory filings — with a source attached to every number.
This is a research tool. It downloads what AMFI and the fund houses actually publish — daily NAVs, monthly portfolio disclosures, scheme documents — onto your own computer, checks the numbers add up, and makes them available to Claude (or any AI assistant that speaks MCP).
It deliberately does not score, rate, rank, or recommend funds.
⚠️ Not investment advice
This tool reports what public disclosures say, and how confident it is in each fact. Nothing it produces is a recommendation to buy, sell, or hold anything. It is not a substitute for a SEBI-registered investment adviser. Mutual fund investments are subject to market risks; read all scheme-related documents carefully.
Contents
Related MCP server: OpenFin MCP
Who this is for
If you are… | What you get | What it costs you |
A mutual fund researcher or analyst | Point-in-time holdings, month-over-month portfolio changes, rolling returns, overlap between funds, manager and TER history — all traceable to a source document | ~20 minutes of setup, then it's a normal research tool |
A finance professional (RIA, analyst, journalist) | An auditable evidence trail. Every figure says whether it came from a filing or was computed, and from what | Same setup; read How to read the answers before you cite anything |
A DIY investor comfortable with a terminal | Honest answers about funds you already own or are considering, without a website trying to sell you something | Setup, plus the patience to accept "unavailable" as an answer |
A developer | A clean MCP server with six read-only tools over a local SQLite store, 31 AMC adapters, and 483 tests | Read For developers |
If you have never used a terminal, this tool is honestly not yet a good fit — there is no installer or app. You need to paste about six commands into a terminal window. If you're willing to do that, the instructions below assume no prior knowledge and explain what each command does.
What you can ask it
Once it's connected, you talk to your AI assistant in plain English. It picks the right tools and reads the data. Real examples:
Holdings and what changed
"What did Parag Parikh Flexi Cap hold at the end of last month, and what changed versus the month before?"
"Has Quantum Value Fund been trimming its bank exposure over the last year?"
"How much do HDFC Flexi Cap and ICICI Prudential Value Discovery actually overlap?"
Returns and risk
"Show me 3-year rolling returns for Mirae Asset Large Cap against its category."
"How far did this fund fall in the March 2020 crash, and how long did it take to recover?"
"What are the Sharpe and Sortino ratios for these three funds over 5 years, using the same risk-free rate?"
Costs, managers, mandate
"Who manages this fund, and when did they take over?"
"What's the real cost gap between the Direct and Regular plans of this fund?"
"What does the scheme document actually say about its investment strategy? Quote it."
Changes over time
"Has this fund changed its benchmark or its manager in the last three years?"
A good first question is simply: "What can you tell me about Parag Parikh Flexi Cap Fund?"
One habit worth having: fund names in India are genuinely ambiguous — near-identical names across fund houses, renames, and 4–8 plan variants per scheme. The assistant resolves the name first and will tell you if your query matched more than one fund. If the answer looks like it's about the wrong fund, say which AMC you meant.
Before you start
You will need:
Requirement | Why | How to check |
A Mac, Linux, or Windows machine | It runs locally; no account, no server, no API key | — |
Python 3.10 or newer | The tool is written in Python |
|
Installs dependencies and runs the tool |
| |
~2 GB free disk | Stores NAV history and archived source files | — |
An MCP-capable AI client | e.g. Claude Code or the Claude desktop app | — |
Internet access | To download data from AMFI and fund house websites | — |
What it does not need: no API keys, no paid data subscription, no account with anyone, no cloud service. Everything lives on your machine.
Roughly how long: 5 minutes of typing, plus 8–35 minutes of downloading that runs unattended.
If you don't have uv, install it first:
curl -LsSf https://astral.sh/uv/install.sh | shInstall it
Step 1 — Get the code
git clone https://github.com/LogeshR15/indian-mf-mcp.git
cd indian-mf-mcp
uv syncuv sync downloads the libraries the tool depends on. It prints a lot; that's normal.
Step 2 — Build your data store
uv run mf-mcp setupThis is the one command that gets you a working store. It does three things:
Downloads the full scheme universe from AMFI — every scheme, plan, ISIN and category in India (~3,400 schemes, ~14,000 plans). Takes seconds.
Downloads AMFI's market-cap classification lists — all nine half-yearly editions back to June 2022, so a 2023 portfolio is classified against the 2023 list rather than today's.
Downloads daily NAV history — 3 years by default (~8 minutes).
Useful variations:
uv run mf-mcp setup --years 10 # full decade of NAV (~35 min, ~17M data points)
uv run mf-mcp setup --skip-nav-history # stop after step 2 — ready in secondsEverything is resumable. Press Ctrl-C any time; rerunning picks up where it stopped.
Running it again later with --years 10 downloads only the years you don't already have.
Step 3 — Add portfolio holdings for the fund houses you care about
NAV and scheme identity cover every fund in India automatically. Holdings are different — each fund house publishes them in its own format, so you load the ones you want:
uv run mf-mcp backfill --amc ppfas --from 2023-01-01That loads every PPFAS scheme's monthly holdings since Jan 2023 in one command. To see the 31 supported fund houses and what you've already loaded:
uv run mf-mcp amcsTo also pull manager history, TER history and official change notices in the same pass:
uv run mf-mcp backfill --amc ppfas --from 2023-01-01 --doc-types portfolio,factsheet,addendumStart with one or two fund houses. Each takes a few minutes. You can always add more later — nothing is re-downloaded.
Step 4 — Check what you have
uv run mf-mcp statusThis prints how much of each kind of data you hold, and then a numbered list of exactly which commands would fill whatever's still missing. It's the first thing to run whenever something seems wrong.
Step 5 — Connect it to your AI assistant
For Claude Code:
claude mcp add indian-mf -- uv run --directory /path/to/indian-mf-mcp mf-mcp serveReplace /path/to/indian-mf-mcp with wherever you cloned it. mf-mcp setup prints this
line at the end with your own path already filled in and correctly quoted — copy it from
there.
For other MCP clients, the server command is uv run --directory <path> mf-mcp serve,
speaking MCP over stdio.
That's it. Start a new conversation and ask it about a fund.
Where your data lives
Everything goes in ~/.indian-mf-mcp/ — a SQLite database plus an archive of every raw
file it ever downloaded. To put it elsewhere, set INDIAN_MF_MCP_HOME. To start over,
delete that folder and rerun mf-mcp setup.
How to read the answers
This is the part that matters most if you're going to rely on, cite, or publish anything you get out of this tool.
Every single fact it returns carries a tag saying what kind of fact it is. Most data sources hand you a number and expect you to trust it equally. This one doesn't:
Tag | What it means | How much weight to give it |
| Taken directly from a regulatory filing or a fund house's own disclosure, unaltered | Highest. This is what the fund itself filed. |
| Arithmetic this tool performed on official data — a CAGR from NAVs, a concentration ratio from holdings | High, but the method matters. The formula and inputs are stated. |
| Inferred by comparing two filings over time — e.g. a manager change spotted by diffing consecutive factsheets | Medium. The change is real, but the effective date may be off, since you only know it happened between two documents. |
| A deliberate stand-in with a stated error term — e.g. a benchmark tracked via a passive index fund's NAV rather than the licensed index itself | Use with care. Never present these as the real thing; the payload names the proxy. |
| Derived by parsing or pattern-matching, e.g. splitting a scheme name into plan and option | Lowest. Usually right, occasionally not. |
Alongside the facts, every response carries a sources block: the document each number came from, its date, its SHA-256 hash, and the URL it was fetched from. If you need to verify a figure, you can go straight to the original file.
Three rules the tool enforces on itself:
Portfolios must reconcile to 100% or they don't load. If a monthly disclosure's weights don't add up, it's rejected rather than quietly ingested. Partial holdings data is worse than none.
Gaps are reported, never filled. If a fund's TER isn't available, the answer is "unavailable" — never a plausible-sounding guess.
Raw files are archived permanently. AMFI's daily NAV file is the only record of what a scheme's category was on a given day. Once a day passes uncaptured, that history is gone for good.
What it will not do
Being explicit about this, because these are deliberate design decisions, not gaps:
It will not rate, score, or rank funds, or tell you what to buy. There is no star rating and no "best fund" list, because those require judgements this tool has no basis to make.
It will not give you performance attribution. Decomposing returns into allocation/selection effects requires daily holdings. Indian funds disclose holdings monthly. Any attribution computed from monthly snapshots is fiction, so it isn't offered.
It will not compute returns for IDCW (dividend) plans. AMFI's NAV for IDCW plans is not adjusted for distributions, so a CAGR computed from it would understate the real return, sometimes badly. It returns an explicit error and tells you to use the Growth plan instead.
It will not present a benchmark proxy as the real index. Index values are licensed data. Where a benchmark can be tracked via a passive fund's NAV, the result is clearly flagged as a proxy and names the fund used.
It will not guess. Every "unavailable" is a real answer about the limits of Indian public disclosure.
On Sharpe and Sortino: these use a stated risk-free rate, 6.5% annual by default. Sharpe ratios are only comparable across funds when computed with the same rate — if you're comparing funds across a period when rates moved, set it explicitly and say what you used.
What data it covers
Data | Coverage | Source | Updates |
Scheme identity, categories, ISINs | All Indian mutual fund schemes (~3,400) | AMFI | Daily |
Daily NAV | All schemes and plans | AMFI | Daily |
NAV history | Back to whatever window you backfilled | AMFI | One-off, extendable |
Portfolio holdings | 31 of ~53 fund houses you choose to load | Fund house disclosures | Monthly |
Market-cap classification | June 2022 onward | AMFI half-yearly lists | Twice a year |
Managers, TER, change events | Schemes whose factsheets you've loaded | Fund house factsheets & addenda | Monthly |
Scheme documents (SIDs etc.) | Documents you've loaded | Fund house PDFs | As published |
Fund houses with working portfolio adapters (31):
360 ONE · Axis · Bajaj Finserv · Bandhan · Bank of India · Baroda BNP Paribas · DSP · Franklin Templeton · Groww · HDFC · HSBC · ICICI Prudential · Invesco · ITI · Kotak Mahindra · LIC · Mirae Asset · Motilal Oswal · Navi · Nippon India · PPFAS · quant · Quantum · SBI · Sundaram · Tata · Taurus · Trust · Union · UTI · Zerodha
NAV, scheme identity and category data come from AMFI and cover every scheme — the coverage gap affects portfolio holdings only. See docs/amc-coverage.md for which fund houses are still missing and why.
Keeping it current
NAV data goes stale within days. To refresh:
uv run mf-mcp ingest-navall # daily — takes secondsuv run mf-mcp backfill --amc ppfas --from 2026-01-01 # monthly, after disclosures postTo automate the daily NAV update, add it to cron (macOS/Linux):
0 20 * * * cd /path/to/indian-mf-mcp && uv run mf-mcp ingest-navallmf-mcp status warns you when NAV data is more than a few days old.
When something goes wrong
Start with uv run mf-mcp status — it usually names the exact command you need.
Symptom | Cause | Fix |
The assistant says it can't find a fund that definitely exists | Store is empty or NAV not loaded |
|
"No portfolio data for this scheme" | That fund house's holdings aren't loaded |
|
Managers or TER show as unavailable | Factsheets not loaded for that scheme | Rerun backfill with |
Market-cap allocation unavailable | Cap lists missing, or portfolio predates June 2022 |
|
Returns refused for a fund | You asked for an IDCW plan | Ask for the Growth plan |
A fund house download fails | Their website changed or is blocking |
|
To find a fund's internal ID from the terminal:
uv run mf-mcp resolve "parag parikh flexi cap"Parag Parikh Flexi Cap Fund
scheme_id scheme-d41895e60e6fd859
amc PPFAS Mutual Fund
category Equity Scheme / Flexi Cap Fund
plans 4 Direct/Growth, Direct/IDCW, Regular/Growth, Regular/IDCW
nav through 2026-09-15
also loaded nav onlyalso loaded tells you at a glance which kinds of questions will have data behind them
for that fund.
Glossary
For readers newer to Indian mutual funds or to AI tooling:
Term | Meaning |
AMC | Asset Management Company — the fund house (HDFC, SBI, PPFAS…) |
AMFI | Association of Mutual Funds in India — the industry body that publishes daily NAVs and scheme data for every fund |
NAV | Net Asset Value — the per-unit price of a fund, published daily |
TER | Total Expense Ratio — the annual percentage a fund charges you |
Direct vs Regular | Direct plans have no distributor commission, so they cost less and return more. Same portfolio, different fee. |
Growth vs IDCW | Growth reinvests gains; IDCW (Income Distribution cum Capital Withdrawal, formerly "dividend") pays them out |
ISIN | The unique 12-character international identifier for a specific plan |
SID | Scheme Information Document — the legal document describing a fund's mandate, strategy and risks |
Factsheet | A fund house's monthly summary: managers, TER, portfolio highlights |
Addendum | An official notice of a change — new manager, changed TER, changed benchmark |
Rolling returns | Returns measured over every possible window of a given length, rather than one lucky start date |
Drawdown | How far a fund fell from its peak, and how long it took to recover |
Portfolio overlap | How much two funds hold the same stocks — high overlap means less diversification than you think |
MCP | Model Context Protocol — an open standard that lets an AI assistant use external tools. This project is an MCP "server"; your AI assistant is the "client" |
Known limitations
Stated plainly, in keeping with "gaps are reported, never filled":
Portfolio parsing covers XLSX and legacy
.xls, detected by file content rather than extension. A few fund houses occasionally publish PDF-only portfolio disclosures; those are skipped rather than mis-parsed. (PDF extraction is used for SIDs, factsheets and addenda, whichget_documentcovers.)Market-cap allocation covers June 2022 onward. All nine half-yearly AMFI lists are loaded, so classification is point-in-time correct — a 2023 portfolio uses the 2023 list, never a newer one. Portfolios older than June 2022 report market cap as unavailable rather than being classified against a list that didn't exist yet. AMFI publishes the ranking, not the buckets; the large/mid/small split applies SEBI's rank rule (1–100 / 101–250 / 251+).
Change-notice (addendum) extraction uses pattern matching over PDF text, so an unusually-worded notice can be missed.
list_disclosure_eventslabels every event by how it was detected —official(from an addendum) orobserved(reconstructed by diffing factsheets). The two are never blended.
None of this is papered over: the affected responses say so rather than guessing.
For developers
The six MCP tools
Tool | What it returns |
| A messy name, ISIN, or scheme code → unambiguous scheme + plan identity, plus availability flags per data class |
| Trailing and rolling returns, volatility, Sharpe/Sortino, drawdowns, named stress windows, benchmark-proxy and live category comparators |
| Holdings, sector/asset-class/market-cap allocation, month-over-month changes (corporate actions flagged, not asserted as trades), concentration, persistence streaks, pairwise overlap |
| Identity, benchmark, verbatim mandate excerpts, TER, realised Direct-vs-Regular cost spread, current managers |
| Section- or keyword-scoped extraction from SIDs and other scheme PDFs, with page numbers and hashes |
| Manager/TER/benchmark/category changes over time, each tagged by detection method |
All six are read-only, idempotent, and closed-world — they never make a network call, so
clients can parallelize and cache them freely. resolve_fund should always be called
first.
Architecture
AMFI NAVAll.txt ─────┐
AMFI NAV history ────┼──► ingest ──► SQLite store ──► analytics ──┐
AMC portfolio files ─┤ (+ raw archive) ├──► MCP tools ──► Claude
AMC / AMFI PDFs ─────┘ │
change engine ──────────────┘src/indian_mf_mcp/
├── ingest/ fetching and loading (NAV, portfolios, factsheets, SIDs, addenda)
│ └── amc_adapters/ one module per AMC — the main contribution surface
├── parsers/ AMFI delimited files, portfolio XLSX/XLS, PDF sections, format sniffing
├── normalize/ scheme taxonomy, plan/option parsing
├── analytics/ returns, risk, drawdown, benchmark proxy, cost spread, overlap
├── change_engine/ portfolio diffing, corporate actions, concentration, persistence
├── provenance/ epistemic tags and the two-tier fact/source wrapper every tool uses
├── store/ SQLite schema, repositories, raw blob store, store inventory
└── tools/ the six MCP toolsThe CLI splits in two: setup / status / resolve / amcs are the onboarding surface;
ingest-* / backfill* / health are the data-loading surface.
ingest/amc_identity.py is the single place reconciling the three AMC naming schemes in
play — the --amc adapter key (ppfas), the id an adapter declares (amc-ppfas), and the
id the store derives from AMFI's own name (amc-ppfas-mutual-fund).
spec.md holds the full architecture rationale, including which facts are deliberately
not computable from Indian public disclosure, and why.
Tests
uv run pytest tests -q483 tests. Unit tests are offline and run against golden fixtures — real AMC files
committed to tests/fixtures/. Integration tests hit live AMC sites and are excluded from
the default run. To stay strictly offline:
uv run pytest tests/unit -qContributing
Contributions are welcome, especially new AMC adapters — the most valuable and most self-contained contribution available. Start with CONTRIBUTING.md.
One rule is worth stating up front, because it shapes everything else:
We do not evade access controls. No spoofed User-Agents, no proxy rotation, no TLS fingerprint spoofing, no CAPTCHA solving. If an AMC blocks this project's honest User-Agent, the answer is to find infrastructure that isn't blocked — or to record it as blocked and move on.
That rule has cost us at least one otherwise-clean integration. It stays.
Licence
Not yet chosen — see #licensing. Until a licence is added, default copyright applies and contributions cannot be formally accepted.
Data sources
Public disclosures from AMFI and individual AMC websites. This project is not affiliated with, endorsed by, or connected to AMFI, SEBI, or any asset management company.
Available Tools
5 toolsget_documentA
Retrieve source-document evidence — the relevant pages, not the whole PDF.
Identify the document either by doc_id (from get_fund_profile's documents list) or by
scheme_id + doc_type (+ optional as_of). Use query for keyword-scoped retrieval or
sections (SEBI-standard headings: Investment Objective, Investment Strategy, Asset
Allocation Pattern, Risk Factors, Fund Manager, Load Structure, Expenses of the Scheme).
Returns verbatim text with page numbers, sha256, and the source URL — Claude reads and
interprets this prose; the server never paraphrases or extracts it into structured claims.
Inputs: as_of, query, doc_id, return_, +4 more.
get_fund_performanceA
Complete return/risk evidence pack for one or more schemes (list = comparison).
metrics: any of "trailing","rolling","risk","drawdown","stress". comparators: any of "benchmark" (not yet implemented — proxy pending), "category". Defaults to the Direct/Growth plan; a warning is included if that plan does not exist. Never emits a score, rating, or recommendation — only computed facts with provenance.
Inputs: scheme_ids (required), plan, period, metrics, +4 more.
get_fund_portfolioB
Holdings, allocations, and month-over-month change detection for one or more schemes.
sections: any of "holdings","allocations","changes","concentration","persistence". history: "none"|"12M"|"36M"|"60M" — required (non-"none") for the persistence table. compare_to: a date, "prev_month", or null to skip change detection. Corporate actions (splits/bonuses/mergers) are flagged, never silently asserted as trades. Market-cap allocation is not yet available (requires the AMFI cap-list join) and is reported as null rather than guessed. Coverage depends on which AMC adapters have been run.
Inputs: scheme_ids (required), as_of, history, sections, +3 more.
get_fund_profileA
Static/slow-moving profile: identity, mandate excerpts, benchmark, costs, managers, documents.
sections: any of "identity","mandate","benchmark","costs","managers","documents". Mandate is always returned as verbatim SID excerpts with page numbers, never as parsed fields — investment philosophy/strategy is a document-retrieval problem, not structured data (extracting it would produce confident nonsense). Managers and TER are not yet available in this build and are reported as unavailable, never fabricated.
Inputs: scheme_ids (required), as_of, sections, provenance.
resolve_fundA
Resolve a fund name, ISIN, or AMFI scheme code to unambiguous scheme+plan identity.
Always call this first — Indian scheme names are ambiguous (renames, near-identical names across AMCs, 4-8 plan/option variants per scheme).
Inputs: query (required), limit.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 5 tools
Each tool targets a distinct facet: resolve_fund handles identity, get_fund_performance covers returns/risk, get_fund_portfolio covers holdings, get_fund_profile covers static metadata, and get_document retrieves verbatim source evidence. The descriptions explicitly delineate boundaries (e.g. profile returns mandate excerpts vs. document retrieves raw pages), so there is minimal risk of misselection.
Four tools follow a clean get_fund_<noun>/get_document verb_noun pattern, and resolve_fund is a semantically apt deviation for the identity-resolution step. The convention is predictable throughout with no mixed casing or stylistic drift.
Five tools is well-scoped for a fund-intelligence server, and each one earns its place by covering a genuinely separate dimension (identity, performance, portfolio, profile, documents). No tool feels redundant or trivial.
The surface covers the full read-only lifecycle from identity resolution through evidence retrieval, which is coherent for an intelligence (non-mutating) server. Minor gaps exist — benchmark comparators, managers, and TER are explicitly deferred — but they are transparently flagged rather than silently missing.
Maintenance
Related MCP Connectors
Research Indian mutual funds and manage consent-based portfolio tracking records.
MFAPI.in MCP — Indian mutual-fund NAV (net asset value) data.
Read-only market research: index funds, event cards, CLOB data, fund analytics. No orders.
Open financial reference data: companies with LEI/ISIN/FIGI, markets, funds, graph, live series.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceEnables querying Indian mutual fund NAV data through MFAPI.in, providing net asset value information and fund details.99 npmMIT
- FlicenseNot gradedqualityAmaintenanceProvides read-only access to curated financial domain knowledge and product data with verified provenance, enabling users to search and retrieve trusted financial information.-
- AlicenseNot gradedqualityCmaintenanceProvides AI assistants with real-time Indian mutual fund NAV data from AMFI's official feed, requiring no API key.MIT
- FlicenseNot gradedqualityCmaintenanceEnables querying Indian mutual fund NAV analytics via DuckDB, offering tools for fund search, point-to-point returns, category rankings, and more, using local or Azure parquet data.-