OpenCidian: open Chinese ↔ Vietnamese dictionary (Hán Việt, pinyin, character breakdown)
RemoteAbout OpenCidian: open Chinese ↔ Vietnamese dictionary (Hán Việt, pinyin, character breakdown)
OpenCidian is Perxel's open Chinese–Vietnamese dictionary MCP server for systems needing Hán Việt, pinyin, meanings, and character analysis. It is the dictionary's only public entry point; results include field-level sources and dataset version, while correction suggestions open public GitHub issues.
Key features
- 01Look up Hanzi, pinyin, or Vietnamese
- 02View readings, components, and character etymology
- 03Find words containing a character
- 04Search by Vietnamese or English meaning
- 05Annotate text with readings and meanings
- 06Submit correction suggestions as GitHub issues
Use cases
- 01Find Vietnamese meanings of Chinese words
- 02Examine character components and readings
- 03Annotate Chinese text with word information
- 04Report possible dictionary data errors
MCP support
OpenCidian provides a stateless remote MCP server over Streamable HTTP and is the dictionary's only public access route. Lookup tools are read-only; the correction tool opens a public issue in opencidian-data and does not modify the data.
Configuration
Remote servers need no local install. Pick your client, then copy the config or install in one click.
https://opencidian-mcp.perxel.com/mcpclaude mcp add --transport http opencidian-opencidian https://opencidian-mcp.perxel.com/mcp{"mcpServers":{"opencidian-opencidian":{"type":"http","url":"https://opencidian-mcp.perxel.com/mcp"}}}Open in Cursor{"servers":{"opencidian-opencidian":{"type":"http","url":"https://opencidian-mcp.perxel.com/mcp"}}}Open in VS Code{"mcpServers":{"opencidian-opencidian":{"type":"http","url":"https://opencidian-mcp.perxel.com/mcp"}}}{"mcpServers":{"opencidian-opencidian":{"serverUrl":"https://opencidian-mcp.perxel.com/mcp"}}}Run commands in a terminal; paste JSON into the client’s MCP config and restart. Servers that need sign-in will prompt on first connect.
Tools
Details
From the project READMEopencidian-mcp
A remote MCP server for OpenCidian by Perxel: an open Chinese-Vietnamese dictionary. It is the only public way in for systems: there is no public API. Read-only except suggest_correction, which opens a public GitHub issue for a maintainer (it never changes the data); no sign-in. A Cloudflare Worker built from the Perxel MCP Kit (kit/, see STANDARD.md) over opencidian-api, which is internal: it answers 404 to every read without X-MCP-Secret, which this Worker sends over its service binding.
opencidian-mcp (this repo) ──service binding──▶ opencidian-api ──▶ D1
POST /mcp (Streamable HTTP, stateless) loaded from opencidian-data's releases
GET / lists connect instructions and every tool; GET /llms.txt says what OpenCidian is, how to connect, example questions, licence and attribution (src/lib/llms.ts); /dash is a public usage dashboard. Host: opencidian-mcp.perxel.com.
Tools
| Tool | Wraps | Notes |
|---|---|---|
lookup | GET /v1/lookup | Hanzi, pinyin (with or without tones) or Vietnamese; by forces the reading, limit 1-50. |
get_character | GET /v1/chars/{char} | Hán Việt, pinyin, radical, parts, etymology, strokes, traditional forms. |
words_with | GET /v1/words-with/{char} | Words of 2+ characters containing it, HSK words first. |
search_meaning | GET /v1/search | Vietnamese (default) or English meaning → candidate Chinese words. |
annotate_text | POST /v1/annotate | Text (up to 2,000 characters) → words with pinyin, Hán Việt and meaning. |
suggest_correction | POST /v1/corrections | Opens a public issue in opencidian-data (labels correction, from-ai); a maintainer turns it into a correction file. Never changes the data. 5 a minute for all MCP callers together. |
about | GET /v1/meta | Version, licence, full attribution, sources with their pinned versions. |
Every answer carries src per field, the dataset version and a short credit; the full attribution (every source) comes from about only, to keep answers small.
Setup
pnpm install
cp .dev.vars.example .dev.vars # MCP_SECRET: the one in ../opencidian-api/.dev.vars
pnpm test && pnpm typecheck
Against a local opencidian-api: run wrangler dev there, then pnpm dev here. Against the deployed API: a temporary copy of wrangler.mcp.jsonc with "remote": true on the API service binding (never committed), then pnpm exec wrangler dev -c <copy> --port 8788.
Evals: pnpm eval --url http://localhost:8788/mcp (evals/questions.md).
Deploy
On push to main (.github/workflows/deploy.yml, repo secrets CLOUDFLARE_API_TOKEN and CLOUDFLARE_ACCOUNT_ID), or pnpm exec wrangler deploy -c wrangler.mcp.jsonc. Secrets: MCP_SECRET (same as opencidian-api's), IP_HASH_SALT, COOKIE_ENCRYPTION_KEY, DASH_PROXY_KEY (see wrangler.mcp.jsonc).
Licence
Code MIT (kit/ keeps the kit's own licence). Data CC BY-SA 4.0: credit "OpenCidian by Perxel" and its sources.
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.