SuperAPIAI Directory

typst-mcp

github.com · AI coding

Typst typesetting tools: convert between LaTeX and Typst, validate Typst syntax and generate images from Typst code.

Open website Alternatives
PricingOpen source开源项目(可免费自部署)

About this tool

Purpose: Typst MCP Server is a Model Context Protocol (MCP) implementation that enables AI models to operate the Typst typesetting system, suitable for generating, validating, and previewing Typst documents and illustrations in AI programming assistant environments.

Main capabilities (all provided as tools): list_docs_chapters() lists all chapters of the Typst documentation, making it easy for the model to select relevant chapters; get_docs_chapter(route) retrieves the content of a specified chapter, and there is also get_docs_chapters(routes: list) for batch retrieval; latex_snippet_to_typst(latex_snippet) uses Pandoc to convert LaTeX code to Typst, and there is also a batch version latex_snippets_to_typst; check_if_snippet_is_valid_typst_syntax(typst_snippet) validates Typst code syntax, and there is also a batch version; typst_to_image(typst_snippet) renders Typst code as a PNG image, suitable for multimodal models to check the effect of complex illustrations.

Usage: First clone the repository git clone https://github.com/johannesbrandenburger/typst-mcp.git,再克隆 Typst repository git clone https://github.com/typst/typst.git,在 In the Typst repository, run cargo run --package typst-docs -- --assets-dir ../typst-mcp/typst-docs --out-file ../typst-mcp/typst-docs/main.json to generate documentation data, then execute uv sync to install dependencies. The server can be run locally or configured for platforms such as Claude Desktop, Cursor, Roo Code, opencode, Claude Code, and VS Code Agent Mode.

Limitations: Currently all functionality is implemented as tools, because Cursor and VS Code cannot yet handle other primitives; the JSON Schema of the Typst documentation is unstable and may change at any time, and since it is generated from Typst source code, completeness or correctness is not guaranteed. If the Schema changes, this repository needs to be updated.

Up/Down to navigate · Enter to open · ESC to closeBrowse all tools