An MCP server that provides PDF translation service
Version: 0.1.0
Powered by: FastMCP & PDFMathTranslate-next
PyPI Package: huoshui-pdf-translator
An intelligent PDF translation assistant that specializes in academic papers with mathematical formulas. Built using the FastMCP framework and powered by PDFMathTranslate-next, it provides comprehensive translation capabilities with context-aware assistance.
This server is available in the Model Context Protocol Registry. Install it using your MCP client.
mcp-name: io.github.huoshuiai42/huoshui-pdf-translator
uvx huoshui-pdf-translator
Add this to your Claude Desktop MCP configuration:
{
"mcpServers": {
"huoshui-pdf-translator": {
"command": "uvx",
"args": ["huoshui-pdf-translator"]
}
}
}
Via pipx:
pipx install huoshui-pdf-translator
Via UV tools:
uv tool install huoshui-pdf-translator
Claude Desktop config for UV tools:
{
"mcpServers": {
"huoshui-pdf-translator": {
"command": "uv",
"args": ["tool", "run", "huoshui-pdf-translator"]
}
}
}
warm_up_translator toolcheck_translation_tool tooltranslate_pdf tool with your PDF pathtranslate_pdfTranslates PDF documents while preserving mathematical formulas and layout.
# Basic usage
translate_pdf(pdf_path="Desktop/paper.pdf")
# With custom output path
translate_pdf(
pdf_path="Documents/research.pdf",
output_path="Documents/translated/research_cn.pdf"
)
pdf_getRetrieves detailed information about a PDF file.
pdf_info = pdf_get(path="Desktop/document.pdf")
# Returns: PDFResource with path, size_bytes, page_count
warm_up_translatorDownloads required assets and models. Run this first to avoid timeouts.
warm_up_translator()
# Downloads fonts and models (~50MB) for faster subsequent translations
check_translation_toolVerifies PDFMathTranslate-next installation and status.
status = check_translation_tool()
# Returns: status, version, message
role_and_rules: Core identity and operational rulesexplain_pdf_paths: Help with file path specificationsexplain_translation_options: Available options and best practicestroubleshoot_translation_error: Error diagnosis and solutionsexplain_translation_result: Result explanation and next stepsThe assistant supports flexible path specifications:
# Absolute paths
/Users/john/Desktop/research.pdf
C:\Users\John\Documents\paper.pdf
# Relative to home directory
Desktop/research.pdf
Documents/papers/study.pdf
# Simple filenames (assumes home directory)
paper.pdf
uvx huoshui-pdf-translatorwarm_up_translator tool (first time only)translate_pdf with your PDF pathThe tool automatically installs pdf2zh-next when needed. If issues occur:
# Check status
# Use check_translation_tool in Claude Desktop
# Manual install if needed
pip install pdf2zh-next
# Run warmup first
# Use warm_up_translator tool in Claude Desktop
The assistant provides intelligent error diagnosis with specific solutions for:
Install from source:
git clone https://github.com/huoshuiai/huoshui-pdf-translator.git
cd huoshui-pdf-translator
uv sync
uv run python -m huoshui_pdf_translator.main
Build and publish:
uv build
uv run twine upload dist/*
huoshui-pdf-translator/
βββ huoshui_pdf_translator/
β βββ __init__.py # Package metadata
β βββ main.py # FastMCP server implementation
βββ pyproject.toml # Package configuration
βββ README.md # This file
βββ LICENSE # Apache-2.0 license
Update to latest version:
uvx install --upgrade huoshui-pdf-translator
# or
uv tool upgrade huoshui-pdf-translator
Contributions are welcome! Please:
This project is licensed under the Apache-2.0 License. See the LICENSE file for details.
Source-derived launch command. Check the maintainerβs required arguments and credentials before running:
uvx huoshui-pdf-translatorMerge this template into ~/Library/Application Support/Claude/claude_desktop_config.json. Keep existing servers. Add any arguments, credentials, and permissions required by the maintainer; this template has not been install-tested.
{
"mcpServers": {
"io-github-huoshuiai42-huoshui-pdf-translator": {
"command": "uvx",
"args": [
"huoshui-pdf-translator"
]
}
}
}Restart Claude Desktop completely for changes to take effect. Confirm the server appears connected in the clientβs tool list, then try a read-only example from its documentation.
Claude Desktop setup referenceio.github.huoshuiai42/huoshui-pdf-translator works with any MCP-compatible client. Copy the config snippet from the Configuration section above and add it to the file shown for your client, then restart the application.
~/Library/Application Support/Claude/claude_desktop_config.jsonRestart Claude Desktop completely for changes to take effect.~/.cursor/mcp.jsonRestart Cursor for changes to take effect..vscode/mcp.jsonReload VS Code window for changes to take effect.~/.codeium/windsurf/mcp_config.jsonRestart Windsurf for changes to take effect..mcp.jsonSave at the project root, then start Claude Code in that project and review the MCP server approval prompt. Keep real credentials out of shared files.