export-latex

export-latex is a command for Claude Code from TobiasBlask/open-paper-machine. It costs 55 tokens per session (373 once invoked), scanned A, original, MIT.

A command that turns a paper draft, bibliography, and figures into a LaTeX project and PDF. LaTeX is a document system commonly used for academic papers, and the arXiv style matches a standard research-paper format.

In plain words
What is it for?
It helps check the required files, create the LaTeX folder, generate paper.tex, compile the PDF, and report missing citations, figures, or TODOs.
Why use it?
It removes the manual work of converting Markdown, resolving citations, placing figures, and running the required LaTeX compilation steps.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution.

Part of the open-academic-paper-machine plugin — 33 skills, 21 commands, 4 agents shipped together

Good fit It helps check the required files, create the LaTeX folder, generate paper.tex, compile the PDF, and report missing citations, figures, or TODOs.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/tobiasblask/open-paper-machine/export-latex
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/TobiasBlask/open-paper-machine

Made for: Claude Code.

Or install open-academic-paper-machine, the plugin that ships this one along with the rest of its 33 skills, 21 commands, 4 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for export-latex

README.md
[![agentmods](https://agentmods.dev/badge/commands/tobiasblask/open-paper-machine/export-latex/github.svg)](https://agentmods.dev/commands/tobiasblask/open-paper-machine/export-latex)
Your own site
<a href="https://agentmods.dev/commands/tobiasblask/open-paper-machine/export-latex"><img src="https://agentmods.dev/badge/commands/tobiasblask/open-paper-machine/export-latex/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for export-latex

Your own site · 80×15
<a href="https://agentmods.dev/commands/tobiasblask/open-paper-machine/export-latex"><img src="https://agentmods.dev/badge/commands/tobiasblask/open-paper-machine/export-latex.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 55 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 373 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00055 $0.00373
Opus 5 $0.00028 $0.00187
Sonnet 5 $0.00011 $0.00075
Haiku 4.5 $0.00006 $0.00037

Measured 8d ago against content hash 04118a1b1704, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

export-latex scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

commands/export-latex.md · 35 lines

What it actually says

Export LaTeX: $ARGUMENTS

Activate the latex-engine skill. Read skills/latex-engine/SKILL.md in full. Then execute the full export pipeline:

  1. Verify prerequisites: Check that draft.md and references.bib exist in the working directory. If they don't exist, inform the user they need to run /write-paper first.

  2. Install LaTeX if needed: Check if pdflatex is available. If not, install:

    apt-get update && apt-get install -y texlive-latex-base texlive-latex-extra texlive-fonts-recommended texlive-bibtex-extra
    
  3. Set up the latex/ directory: Create latex/ with arxiv.sty, references.bib, and figures/.

  4. Run the converter: Use scripts/md_to_latex.py to generate paper.tex.

    • If $ARGUMENTS includes author info, pass it through.
    • If $ARGUMENTS includes a title override, use it.
  5. Compile to PDF: Run pdflatex → bibtex → pdflatex → pdflatex.

  6. Validate: Check for undefined citations, missing figures, and remaining TODOs.

  7. Report results: Present the final package with file list and any issues found.

Do not ask for confirmation to start — execute immediately.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 35 lines · 55 tokens per session scan A 04118a1b1704

Subscribe to this mod's changes

export-latex is a command published in the GitHub repository TobiasBlask/open-paper-machine (18 stars, last pushed 5mo ago), licensed MIT. It adds 55 tokens to every session and 373 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other commands, from other repositories

faostat-analytical-brief

Produce a FAOSTAT-style multi-page analytical brief (PDF + xlsx appendix).

berba-q/faostat-skills · 17 tokens

ars-format-convert

ARS academic-paper format-convert mode — convert to LaTeX / DOCX / PDF / Markdown.

tuoxie2046/claude-code-research-skills · 22 tokens

latex-polish

Inspect a cleanly compiling LaTeX document for source pathologies and rendered visual defects by linting and viewing selected PDF pages. Use when compilation succeeds but title pages, floats, tables, figures, or layout still need publication-quality review. Not for basic compilation health; use $latex-health-check.

flonat/flonat-research · 60 tokens

latex

Compile one specified LaTeX document, resolve build errors, audit citations, and report build quality. Use when a .tex source must be built or a concrete compilation failure repaired. Not for corpus-wide build checks, visual polish after a clean build, or creating a project; use $latex-health-check, $latex-polish, or…

flonat/flonat-research · 72 tokens

bib-filter

Filter a LaTeX project's bibliography to the entries actually cited, with Overleaf-source resolution, temporary staging, validation, approval-gated canonical replacement, and compilation. Use before submission or after large revisions.

flonat/flonat-research · 41 tokens

paper-trail-cascade

Acquire PDFs via the 8-source cascade (11 with opt-in extended sources) for a single ref by slug, or a batch filtered by state. Validates page 1 anti-homonymy on each download.

roomi-fields/paper-trail · 44 tokens