The full upstream README, mirrored here for reference. Install config, tool schemas, adoption signals, and an original overview live on the Tripitaka MCP listing page.
An MCP Server for searching and citing content from the Pāli Tipiṭaka. Gives AI agents (such as Claude or Cursor) the ability to look up suttas, quote the teachings, and compare translations across languages.
🙏 This project is offered as Dhamma Dāna — 100% free, non-commercial only. License details: LICENSE (code) + NOTICE.md (data)
bilara-data for any Abhidhamma book). Live counts via list_structure.mn1, pli-tv-bu-vb-pj1, patthana1.1) and generate properly formatted academic citations.bhikkhūnaṁ → bhikkhu).bilara-data verbatim, so it is the authoritative text; AI clients surface this link so users verify the source in one click./sse) and canonical Streamable HTTP (/mcp, MCP spec 2025-03-26).tripitaka://structure, tripitaka://sutta/{id}, tripitaka://word/{w} for clients that pin context as resources./topics/* — six markdown pages covering canon structure, getting-started + tool selection, places (Mahājanapada + holy sites + cosmology), 10 foundational themes with locus classicus, ~30 major figures, and a phase-based timeline of the Buddha's 45-year mission. Sutta IDs verified against live data; AI clients can fetch a page in one shot instead of running 30+ tool calls.skills/tipitaka-research.md ships a ready-to-install workflow file that activates a multi-step research pattern (clarify → verify coverage → search → drill in → cite) on Claude Desktop / Claude Code.| Technology | Role |
|---|---|
| Python + FastMCP | MCP Server |
| PostgreSQL + pgvector | Database + Vector Search |
| sentence-transformers | Embeddings for semantic search |
| Docker Compose | Infrastructure |
The maintainers run a free public instance at tripitaka-mcp.com.
| Endpoint | Use |
|---|---|
https://mcp.tripitaka-mcp.com/mcp | Streamable HTTP (MCP spec 2025-03-26) |
https://mcp.tripitaka-mcp.com/sse | Legacy SSE (older clients) |
Connect Claude Desktop in three steps (no install, no Docker, no GPU — you just need Node.js):
1. Find your absolute npx path. Claude Desktop doesn't read your shell profile, so a bare npx won't resolve. Open a terminal:
2. Open claude_desktop_config.json (~/Library/Application Support/Claude/ on macOS, %APPDATA%\Claude\ on Windows) and add the entry below — substitute YOUR_NPX_PATH with the output from step 1, and YOUR_NODE_BIN_DIR with that path's parent directory:
3. Quit Claude Desktop completely (⌘Q on macOS, tray → Quit on Windows) and reopen. The 🔌 indicator in the bottom-left should show tripitaka with 12 tools available.
First connection takes 5–10 seconds while
npxdownloadsmcp-remoteon demand — give Claude Desktop a moment after restart before assuming it failed.
Once connected, try asking Claude things like:
Claude will pick the right tool, fetch the canonical Pāli, and surface a clickable link to the project's bilingual reader for verification.
The hosted server is rate-limited (10 req/10s + 60 req/min per IP) and offered for personal study, research, and dhamma practice — see NOTICE.md before redistributing or using commercially.
pipx — local SQLite, no server)Prefer to keep everything on your own machine — no network calls to the hosted server? Install the local edition. It ships the whole Pāli canon as a single SQLite file (~120 MB) and runs as a local stdio MCP server.
If the install fails like this:
pipx is using a different interpreter than you think. It builds its own isolated environment on purpose and ignores whatever venv you have active — so an old system Python gets picked even when the shell you typed in has 3.12. Tell it which to use:
(Any 3.10 or newer works; pipx environment shows what it defaults to.)
Then point Claude Desktop / Cursor at the local command — no npx, no mcp-remote, no internet:
(If tripitaka-mcp isn't on the client's PATH, use the absolute path from which tripitaka-mcp.)
Need a URL instead of stdio? Some tools — scripts, notebooks, anything that wants to share one server across several clients — want an HTTP endpoint rather than a subprocess:
It binds 127.0.0.1 unless you say otherwise; the canon is read-only, but
nothing here asks who is calling, so think before binding a public interface.
Hosted vs local — what's different
Both serve the same ~444K-segment canon. The differences:
Hosted (mcp.tripitaka-mcp.com) | Local (pipx) | |
|---|---|---|
| Tools | all 12 | 9 (10 with TRIPITAKA_MCP_APP=1) — no search_semantic / search_hybrid |
| Concept / semantic search | ✅ vector search (pgvector) | ❌ — use search_by_keyword instead |
| Keyword search | PostgreSQL trigram — fuzzy, typo-tolerant, similarity-ranked | SQLite FTS5 — whole-word / token match; results and ranking can differ from hosted |
| Canon data | always current | a snapshot from when you ran init — re-run tripitaka-mcp init to refresh |
| Updates | automatic | pipx upgrade tripitaka-mcp for code; re-run init for data |
| Privacy | queries reach the hosted server (nothing logged — see Privacy Policy) | nothing leaves your machine |
| Internet | required | not needed after init |
| Rate limit | 10 req / 10 s, 60 req / min per IP | none |
| Setup | zero / one-click | Python 3.10+, pipx, one-time ~120 MB download |
search_semantic / search_hybrid and the trigram keyword index need PostgreSQL + pgvector + a ~1 GB embedding model — too heavy for a lightweight local install, so they stay hosted-only. In local mode those two tools aren't registered at all: a connected client sees only the 9 available tools, so it never tries to call a tool that can't work.
Because the local server is a standard stdio MCP server, it also enables a fully offline AI stack — pair it with a local model (e.g. Ollama) and any MCP-capable chat UI, and nothing leaves your machine.
The installer downloads a prepared database dump from Hugging Face — dhamma-seeker/tripitaka-mcp-dump and restores it automatically — cutting setup time from 2–4 hours (loading data + generating embeddings) down to ~5 minutes. (If a local dump file already exists, the local copy is used instead.)
The installer will:
docker, compose, openssl, and curl are installed.env with random passwords (for both the admin and the readonly user)Options:
The project supports Postman testing in SSE mode:
MCP_TRANSPORT=sse python main.pyTo deploy to production without re-loading the data and re-running the embedding model, restoring from a database dump is the recommended path.
The production stack runs 3 services:
db — PostgreSQL + pgvector (internal only, no exposed port)mcp-server — FastMCP (runs as a readonly user, read-only FS, cap_drop: ALL)caddy — reverse proxy + Let's Encrypt + rate limit (10 req/10s and 60 req/1 min per IP)For an extra hardening layer, front Caddy with Cloudflare (DNS proxy + rate-limit rules + DDoS protection on the free tier).
👉 Full details: DEPLOYMENT.md
The repo ships claude_desktop_config.example.json with three ready-to-use entries — copy whichever fits your setup into claude_desktop_config.json (~/Library/Application Support/Claude/ on macOS, %APPDATA%\Claude\ on Windows), then edit the absolute paths:
| Entry | When to use | Transport |
|---|---|---|
tripitaka-local | You ran the installer locally on the same machine as Claude Desktop | stdio (no network) |
tripitaka-remote | You self-hosted the server on a VPS and want the modern transport | Streamable HTTP (/mcp) |
tripitaka-remote-sse | Your client doesn't support Streamable HTTP yet | Legacy SSE (/sse) |
The remote entries route through mcp-remote — Claude Desktop ↔ npx bridge ↔ remote MCP. The example file has annotated comments explaining each field; remove the _comment keys before saving.
Heads-up for nvm users:
commandandenv.PATHneed absolute node paths — Claude Desktop doesn't read your shell profile. Find the right paths withwhich npx/which pythonwhile your normal shell is active.
For Claude Desktop / Claude Code users, copying the bundled skill activates the multi-step research workflow automatically:
Details in skills/README.md.
| Tool | Description |
|---|---|
search_hybrid | (Recommended for concept search) Combined keyword + semantic via RRF — best when looking for "discourses about X". |
search_by_keyword | Trigram keyword search — best for the top few matches of an exact word (appamāda, ānāpānassati). |
survey_corpus | Exhaustive corpus survey — exact total + per-pitaka breakdown + the matched word-forms, for "how many times / every place X appears" (coverage, not just best matches). mode=thorough adds concept-level semantic recall. |
search_semantic | Pure vector similarity — usually you want search_hybrid instead. |
get_sutta | Fetch a sutta by ID (e.g. mn1, dn22, dhp1-20) with cross-reference URLs. Whole sutta by default; for long ones use mode="outline" (table of contents, no text), around="<segment_id>"+window (context around a hit), or segment_range/offset+limit to fetch just a slice. |
open_sutta_viewer | Interactive sutta viewer (MCP Apps) — renders the sutta inline in the chat as Pāli + English side by side, with the cited segment highlighted. The calling model can attach an AI translation of the displayed segments into the user's own language (translations param) as a clearly-badged third row — the canon itself stays Pāli + English. Requires an MCP Apps-capable host (Claude, Claude Desktop, VS Code Copilot, …); other hosts get a graceful text fallback. |
get_reference | Generate a properly formatted academic citation with all source URLs. |
compare_translations | Compare renderings of a single segment across editions. |
list_structure | Show the Tipiṭaka structure with segment-count coverage per nikāya. |
list_editions | List Thai/English translation editions currently loaded. |
get_word_definition | Pāli dictionary lookup (PTS, DPPN, and the Payutto Thai dictionary). |
define_from_suttas | Find how the suttas/Vinaya define a term in their own words — canonical formulas like "Katamañca X? ... ayaṁ vuccati X", "X adhivacana", Vinaya "X nāma". Complements get_word_definition with primary-source definitions rather than dictionary glosses. |
parse_pali_word | Strip Pāli suffixes to recover the root form when get_word_definition misses (bhikkhūnaṁ → bhikkhu). |
search_semanticThe vector index is built only on text_pali (SuttaCentral's bilara-data does not yet include Thai translations) using a multilingual MiniLM model that is not specifically trained on Pāli. As a result:
appamāda, search_by_keyword is more precisesearch_hybrid (keyword + semantic) tolerates this limitation bestUpgrading to a Pāli-trained embedding model (e.g. bge-m3) plus embedding the Thai edition is on the roadmap.
This project aggregates data from multiple sources under different licenses. Please read NOTICE.md in full before redistributing.
| Source | License | Note |
|---|---|---|
| Source code | MIT | Free to use, fork, modify |
| SuttaCentral bilara-data | CC0 | Public domain |
| Thai translations (Dhīranando, Jayasāro) | CC0 | Via SuttaCentral |
| Dictionary of Buddhism by Somdet Phra Buddhaghosacariya (P. A. Payutto) | Dhamma Dāna | ⚠️ Non-commercial use only |
| PTS / DPPN / Dhammika Dictionaries | Public Domain / CC | — |
For commercial use: remove the dictionary component, or contact Wat Nyanavesakavan for permission.
See CREDITS.md for contributor details and NOTICE.md for license terms.
Gratitude to:
Sādhu 🙏 — May the sharing of this Dhamma bring benefit and happiness to all beings.