Skip to main content
Glama

rosettex ๐Ÿ“œโœจ

Translate scientific papers into 19+ languages โ€” and keep the paper's own layout.

PyPI CI Python Agents License: MIT

Quick Install โ€ข Features โ€ข How It Works โ€ข Connect Your Agent โ€ข Languages โ€ข Manual Install

A born-digital PDF (left) and rosettex's Vietnamese output (right): same page, same figure, same fonts for names and formulas. Paper: Berestov et al., CEUR-WS Vol-3550 (CC BY 4.0).


rosettex lets an AI coding agent translate a whole scientific paper โ€” from its TeX source or from a born-digital PDF โ€” and returns a PDF with the paper's own layout.

rosettex does not translate by itself โ€” your agent is the translator. rosettex does the engineering around it: it splits the paper into question sheets with protected placeholders, checks every answer against strict rules, and typesets the result so formulas, figures, citations and links stay real, selectable and clickable. It ships as a CLI, an MCP server and an Agent Skill, packaged as a plugin for the major agent harnesses.

๐ŸŒŸ Key Features

Feature

Description

๐Ÿค– Built for agents

Every command speaks --json and returns the next command to run (next_argv); an agent can drive the whole loop and resume after any interruption.

๐Ÿ“ Original layout

From TeX source the paper is rebuilt with its own class and packages; from a PDF the original pages are kept and only the text in the translated boxes is replaced.

๐Ÿงฎ Formulas stay formulas

Math, citations and links become placeholders (โŸฆm1โŸง, โŸฆl2โŸง) the translation must keep; on PDFs they are copied as vector snippets of the original, and a formula the agent copies verbatim is protected automatically.

๐Ÿ›ก๏ธ Strict checks

rosettex check catches lost placeholders, changed numbers, glossary violations, untranslated text and over-long answers before anything is built.

๐Ÿ” Repair loop

When text does not fit, build answers needs_repair with the segments to shorten and by how much; nothing is silently cut.

๐ŸŒ Many scripts

Latin, Cyrillic, CJK, Arabic/Persian/Urdu, Devanagari, Bengali, Tamil, Thai, Myanmar, Ethiopic โ€ฆ with bundled fonts (Noto, Vazirmatn) and copy/search-friendly output.

๐Ÿ”Œ One plugin, many harnesses

Claude Code, Codex, GitHub Copilot, VS Code, Cursor, Antigravity, Gemini CLI, Hermes, Devin and more install it from this repository; any MCP client or Agent Skills host can use it too.

๐Ÿ’ป Linux, macOS, Windows

CI builds translated PDFs (Vietnamese, Arabic, Japanese) on all three.

Related MCP server: MagicTeX MCP Server

๐Ÿ”€ Two Routes

From TeX source

From a born-digital PDF

Input

folder, archive, arXiv ID or link

a PDF with a text layer (journals, arXiv PDF-only, Word exports)

Output

the paper recompiled with LuaLaTeX in the target language

the original pages with translated text in the same boxes

Best for

any paper with source; changes of writing direction (e.g. English โ†’ Arabic)

papers without source

๐Ÿ”„ How It Works

flowchart LR
    A[๐Ÿ“„ TeX source<br/>or PDF] --> B[๐Ÿงฉ rosettex prepare<br/>sheets + placeholders]
    B --> C[๐Ÿค– Your agent<br/>translates]
    C --> D[๐Ÿ›ก๏ธ rosettex check<br/>placeholders ยท numbers ยท terms]
    D --> E[๐Ÿ—๏ธ rosettex build<br/>LuaLaTeX]
    E -->|needs_repair| C
    E --> F[๐Ÿ“‘ Translated PDF]
rosettex fetch 2108.07760 -o work         # folder, archive, arXiv ID/link, or a local .pdf
rosettex prepare work --lang vi           # question sheets in work/read/, glossary in work/terms.md
# โ€ฆ the agent appends "sNNNN <translation>" lines to work/out/NN.txt โ€ฆ
rosettex check work                       # repeat until ok
rosettex build work --out paper.vi.pdf    # may ask for shorter text (needs_repair), then build again

๐Ÿš€ Quick Install: Let Your Agent Do It

TIP

Copy the prompt below and send it to your coding agent. It installs everything into your home folder and asks before any download.

Install rosettex (https://github.com/20235106-huynk/rosettex) and connect it to yourself: install uv if it is
missing, then `uv tool install rosettex`, `rosettex setup` (follow its next_argv), `rosettex doctor`, and the rosettex
plugin for your harness from the README (or `rosettex install-skill`). No sudo; ask me before any download or installer.

Then just ask, for example: "Translate arXiv 1512.03385 into Simplified Chinese and save it as ~/papers/resnet.zh.pdf." The agent fetches the paper, picks the field and key terms, translates sheet by sheet, runs check until it passes, builds the PDF, shortens any text build reports as too long, and tells you where the PDF is.

๐Ÿ”Œ Connect Your Agent

This repository is a plugin at its root: one skill (skills/rosettex) and one MCP server that uvx starts from the release on PyPI (uvx rosettex==<version> mcp), so uv must be on PATH. The first run of setup installs TeX (the agent asks you first).

Install as a plugin

Harness

Command

Claude Code

/plugin marketplace add 20235106-huynk/rosettex, then /plugin install rosettex@rosettex

Claude Desktop / claude.ai

Customize โ€บ Plugins โ€บ Add marketplace 20235106-huynk/rosettex

Codex CLI / ChatGPT desktop

codex plugin marketplace add 20235106-huynk/rosettex, then install rosettex from /plugins (or the app's Plugins directory)

GitHub Copilot CLI

copilot plugin install 20235106-huynk/rosettex

VS Code (Copilot)

Chat: Install Plugin from Source with the repository URL, or add 20235106-huynk/rosettex to chat.plugins.marketplaces

Antigravity

agy plugin install https://github.com/20235106-huynk/rosettex (or the strict-clean slim package in plugins/antigravity)

Gemini CLI

gemini extensions install https://github.com/20235106-huynk/rosettex

Hermes

hermes plugins install 20235106-huynk/rosettex/plugins/hermes, then hermes plugins enable rosettex

Devin (Desktop, CLI, cloud)

devin plugins install 20235106-huynk/rosettex; cloud: Customize โ€บ Add plugin โ€บ From repository

Factory Droid

droid plugin marketplace add 20235106-huynk/rosettex, then droid plugin install rosettex@rosettex

Auggie

auggie plugin marketplace add 20235106-huynk/rosettex

Junie CLI

/extensions marketplace add 20235106-huynk/rosettex, then /extensions install rosettex

Qwen Code

qwen extensions install 20235106-huynk/rosettex

goose

goose plugin install https://github.com/20235106-huynk/rosettex.git

Kiro IDE

Powers โ€บ Add Custom Power โ€บ Import power from a repository URL

Skill + MCP server (every other harness)

  1. Install the skill: rosettex install-skill (writes ~/.agents/skills, ~/.claude/skills, ~/.gemini/config/skills, and the Cline, Kiro, Qoder, Trae and CodeBuddy skill folders when they exist), or npx skills add 20235106-huynk/rosettex.

  2. Add the MCP server. Most harnesses (Cursor, Cline, Kiro, Qoder, Kimi Code, Pi, CodeBuddy, Warp, Junie, Auggie, Tabnine, Trae, JetBrains AI Assistant) take the standard block in their MCP settings:

{ "mcpServers": { "rosettex": { "command": "uvx", "args": ["rosettex", "mcp"] } } }

Harness

Where

Entry

OpenCode

opencode.json

"mcp": { "servers": { "rosettex": { "type": "local", "command": ["uvx", "rosettex", "mcp"] } } }

Kilo

kilo.jsonc

"mcp": { "rosettex": { "type": "local", "command": ["uvx", "rosettex", "mcp"] } }

Crush

crush.json

"mcp": { "rosettex": { "type": "stdio", "command": "uvx", "args": ["rosettex", "mcp"] } }

goose

config.yaml

extensions: { rosettex: { name: rosettex, type: stdio, enabled: true, cmd: uvx, args: [rosettex, mcp], envs: {}, timeout: 300 } }

Mistral Vibe

config.toml

[[mcp_servers]] with name = "rosettex", transport = "stdio", command = "uvx", args = [...]

Amp

CLI

amp mcp add rosettex -- uvx rosettex mcp

Zed

settings.json

"context_servers": { "rosettex": { "command": "uvx", "args": [...] } }

Zencoder

VS Code settings.json

"zencoder.mcpServers" with the standard block

Visual Studio

%USERPROFILE%\.mcp.json

"servers": { "rosettex": { "command": "uvx", "args": [...] } }

GitHub Copilot cloud agent

repository Settings โ€บ Copilot โ€บ MCP servers

"type": "local", "tools": ["*"], and install uv in copilot-setup-steps.yml

Harnesses that accept only remote MCP servers (Android Studio, Replit, ChatGPT custom MCP) cannot run this stdio server; use the skill and the CLI there. Without any integration, tell the agent: "Run rosettex guide and follow it."

๐Ÿ› ๏ธ Manual Install

Requirements

  • Python โ‰ฅ 3.11 and uv.

  • LuaLaTeX: rosettex setup installs a private TinyTeX into ~/.rosettex (asks first; retries flaky CTAN mirrors), or rosettex setup --tex system uses an existing TeX Live.

uv tool install rosettex
rosettex setup              # or: rosettex setup --tex system
rosettex doctor
rosettex install-skill

Environment variables

  • ROSETTEX_HOME: where rosettex keeps its TeX toolchain and state (default ~/.rosettex).

Update and uninstall

uv tool upgrade rosettex && rosettex install-skill --force
rosettex install-skill --remove && uv tool uninstall rosettex   # then delete the folder ~/.rosettex

๐ŸŒ Languages

Language data covers about 50 target languages (src/rosettex/data/langs/). Tested end to end:

Script

Languages

Latin

Vietnamese, French

Cyrillic

Russian

Han / Kana / Hangul

Chinese (Simplified, Traditional), Japanese, Korean

Arabic (RTL)

Arabic, Persian, Urdu

Indic

Hindi, Bengali, Gujarati, Kannada, Tamil, Telugu

Southeast Asian

Thai, Myanmar

Ethiopic

Amharic

โš ๏ธ Limits

  • The PDF route needs a born-digital PDF with a text layer (no OCR) and keeps the writing direction: a left-to-right paper cannot become right-to-left there โ€” use the TeX source for that.

  • Table contents are not translated; scanned PDFs, vertical writing and PDF forms are not supported.

  • Very tight layouts may need shorter translations (needs_repair) or a slightly smaller font.

๐Ÿ”’ Privacy and network access

rosettex runs on your machine: no server, no account, no telemetry. It goes online only to download what you ask for โ€” a paper from arxiv.org (fetch), the TeX toolchain from github.com and mirror.ctan.org (setup, after you agree), and the package from PyPI when uvx starts the MCP server. Local papers are never uploaded. Your AI agent, not rosettex, does the translating; what it sends to its model provider follows that provider's policy. Details: PRIVACY.md.

๐Ÿ“„ License

MIT โ€” see LICENSE. Bundled fonts are under the SIL Open Font License 1.1 (src/rosettex/data/fonts/LICENSES/). Release notes: CHANGELOG.md.

Available Tools

10 tools
buildC

Typeset the translated PDF. See guide.

Inputs: out (required), work (required), force, budget, +1 more.

checkC
Read-only

Check the translations written so far. See guide.

Inputs: work (required), file.

doctorC
Read-only

Check the toolchain. See guide.

Inputs: force.

fetchA

Fetch a paper's TeX source (folder, archive, arXiv ID/link) or born-digital PDF into a work directory. See guide.

Inputs: out (required), source (required), main.

fixC
Destructive

Copy a source file into work/fix/ for editing, or drop a fix (TeX route only). See guide.

Inputs: work (required), drop, file.

guideC
Read-only

The full rosettex workflow and rules. Read it first. See guide.

Inputs: no named parameters.

prepareC

Prepare the work directory for translation into a language. See guide.

Inputs: lang (required), work (required), from, route.

reviewC
Read-only

Write a review sheet of the translation. See guide.

Inputs: work (required), out.

setupB

Install the TeX toolchain rosettex needs (asks before downloading). See guide.

Inputs: tex, yes, budget.

statusC
Read-only

Where a work directory stands and what to run next. See guide.

Inputs: work (required).

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelogโ€ฆ

    TDQS

    B3.1/5.0

    Scored across 10 tools

    Disambiguation4/5

    Most tools map to distinct workflow stages (fetch source, prepare workdir, build PDF, fix a file, install toolchain, diagnose toolchain). The inspection-flavored tools 'check', 'review', and 'status' sit close together, but the descriptions separate them (verify translations vs. produce a review sheet vs. report workdir state).

    Naming Consistency4/5

    All names are single lowercase tokens with no camelCase/snake_case mixing, which reads consistently. The only minor deviation is that most are imperative verbs (fetch, prepare, build, fix) while a few are bare nouns (guide, status).

    Tool Count4/5

    Ten tools is well within the healthy range and each has an identifiable role in the pipeline. The set is slightly heavy on inspection/diagnostics (check, review, status, doctor), but none is clearly redundant.

    Completeness4/5

    The surface covers the full lifecycle: install toolchain, fetch source, prepare workdir, check/review translations, edit via fix, typeset, and query state, plus docs. Minor gaps exist โ€” there is no explicit tool for committing or exporting the finished translation, and 'fix' bundles copy and drop behaviors into one entry point.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      C
      maintenance
      Enables AI assistants to create, edit, and validate LaTeX documents through a standardized protocol with support for multiple document classes and package management. It provides tools for document structure analysis and file organization to streamline the generation of professional academic papers.
      8
      27
      MIT
    • A
      license
      A
      quality
      C
      maintenance
      Enables batch translation of arXiv, DOI, or paper-page LaTeX sources into Simplified Chinese and compilation of Chinese PDFs via XeLaTeX, using DeepSeek's deepseek-flash model with glossary, structure validation, resume, and QA.
      4
      MIT
    • F
      license
      Not graded
      quality
      A
      maintenance
      Enables MCP clients such as Claude Desktop, Claude Code, and Cursor to directly access and process scientific papers by retrieving and flattening their LaTeX sources. It provides tools for full paper prompts, abstracts, section headings, and specific sections, improving handling of equations and mathematical notation.
      -