
Mcp Dharmamitra
io.github.alex-deusPublished by GitHub account alex-deusv0.1.0Updated Oct 25, 2026
Dharmamitra OCR for Tibetan / Sanskrit / Devanagari images; writes extracted text to a file.
Overview
Local MCP server that runs OCR on Tibetan, Sanskrit or Devanagari images through the public Dharmamitra endpoint and writes the extracted text to a file.
- What you can do
- Run OCR on a local image and write the extracted UTF-8 text to a chosen output file, creating parent directories as needed, and return a small JSON summary with job id, page count, processing time and character count instead of the text itself. Optionally transliterate Devanagari to IAST or Tibetan to Wylie, pass a custom model instruction, and choose the OCR model, polling interval and timeout.
- When to use it
- Useful when you have scanned or photographed manuscripts, inscriptions or documents in Tibetan, Sanskrit or Devanagari and want the text extracted into a local file for further work. It suits one-off digitization tasks rather than bulk pipelines, since each call handles one image.
- Requirements
- Runs locally as a Python package via uvx (or uv from a source checkout, or a Docker image). Needs network access to the public Dharmamitra OCR endpoint. The optional DHARMAMITRA_COOKIE environment variable holds a Cloudflare cf_clearance value, needed only if requests start returning 403.
Installation
In SourceWeft
- Open Mcp Dharmamitra in the dashboard and add it to a workspace.
- Enable the server for the chats that should use its tools.
Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.
Other MCP clients
Follow the launch instructions in the repository.
README
mcp-dharmamitra
MCP server that runs OCR on an image via the public Dharmamitra OCR endpoint and writes the extracted text to a local file. Optimised for Tibetan / Sanskrit / Devanagari input.
Tool
ocr_image
Returns a small JSON summary — the extracted text is written to output_path,
not returned to the client.
Install from the MCP registry
Listed as io.github.alex-deus/mcp-dharmamitra
on the official Model Context Protocol registry. The package ships to PyPI as
mcp-dharmamitra and is meant to
be run with uvx — no clone, no manual install.
~/Library/Application Support/Claude/claude_desktop_config.json (or the
equivalent mcp block in Claude Code):
Or via the Claude Code CLI:
Pin a specific version with uvx [email protected].
Install from source
Run locally with the MCP inspector:
Run tests:
For a source checkout the Claude Desktop entry uses the local path:
Docker
Build the image:
MCP talks over stdio, so the container must be run with -i (no -t). Mount
a host directory that holds the input images — the tool arguments
(image_path, output_path) are paths inside the container.
Smoke-test the entrypoint:
Wire the container into Claude Desktop / Claude Code
Replace /path/mcp-dharmamitra with any host
directory you want the tool to be able to read/write. Files inside it will be
visible under /data in the container.
Or the same via CLI:
When calling the tool, pass container paths. Example — image at
<host>/tmp/text.png → /data/text.png:
The resulting text.txt appears in the mounted host directory.
Cloudflare / cf_clearance
The endpoint sits behind Cloudflare. Most requests go through without any
cookie. If you start getting 403, grab a fresh cf_clearance value from a
logged-in browser session on dharmamitra.org and export it:
The server will attach it as a cookie on every request. Do not hardcode it — Cloudflare rotates the value.
Source: README.md at commit 9240b35
Tools
0Version history
1- v0.1.0LatestSep 16, 2026
Score
40% of the applicable checks met
How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.
- Reached in the last 30 days25 pts
Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.
- Auth declared10 pts
Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.
- Tools listed15 pts
Answer tools/list without a credential, or ship a package that starts in a sandbox without one.
- DescriptionRequired15 pts
- Logo10 pts
- Documentation15 pts
- License10 pts
Declare a license in the repository or the registry entry.