Getting started & client setup¶
mcp-latex is a Model Context Protocol server. You
register it with an MCP client (an AI assistant), which then calls its tools.
Requirements¶
- Node.js 20 or newer
- A TeX engine (
latexmk/pdflatex) is only needed for thecompiletool;check_documentandparse_logwork without it.
Claude Desktop¶
claude_desktop_config.json:
Claude Code¶
.mcp.json at your project root (or claude mcp add):
Try it without a client¶
Call check_document with { "source": "See \\ref{missing}." }.
Run from source¶
git clone https://github.com/marcelogdomingues/mcp-latex
cd mcp-latex
npm install
npm start
npm test
Example prompts¶
- "Check my thesis for undefined references and unbalanced environments."
- "Parse this build log and tell me the first real error and its line."
- "Compile main.tex, then fix whatever failed."