latex-doc

latex-doc is a skill for Claude Code, Codex from JansenAnalytics/claudex. It costs 25 tokens per session (798 once invoked), scanned B, original, MIT.

A document-building tool that turns Markdown text into LaTeX and then into a PDF. It supports diagrams, mathematical notation, tables, citations, figures, and several document styles.

In plain words
What is it for?
Use it to create academic papers, theses, whitepapers, proposals, memos, and PDFs with references, logos, tables, or diagrams.
Why use it?
It avoids manually formatting complex technical or academic documents in LaTeX. Templates provide consistent layouts for papers, theses, reports, and short notes.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

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.

agentmods
npx agentmods add skills/jansenanalytics/claudex/latex-doc
Any agent
npx skills add JansenAnalytics/claudex --skill latex-doc
Clone the repo
git clone --depth 1 https://github.com/JansenAnalytics/claudex

Made for: Claude Code, Codex.

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 latex-doc

README.md
[![agentmods](https://agentmods.dev/badge/skills/jansenanalytics/claudex/latex-doc.svg)](https://agentmods.dev/skills/jansenanalytics/claudex/latex-doc)
Your own site
<a href="https://agentmods.dev/skills/jansenanalytics/claudex/latex-doc"><img src="https://agentmods.dev/badge/skills/jansenanalytics/claudex/latex-doc.svg" alt="Measured on agentmods" height="20"></a>
Per session 25 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 798 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. Scan, not verified.
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.00025 $0.00798
Opus 5 $0.00013 $0.00399
Sonnet 5 $0.00005 $0.00160
Haiku 4.5 $0.00003 $0.00080

Measured 2d ago against content hash 69be4dee775a, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade B, and why

latex-doc scanned grade B with 1 finding 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 2d ago.

The scan reads SKILL.md. This mod also ships 3 executable files (scripts/build.py, scripts/render-mermaid.cjs, scripts/setup.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

- **biber not found** → `sudo apt-get install biber`
skills/latex-doc/SKILL.md · 96 lines

How it starts

The opening of the file, as written. The whole thing — 96 lines — stays where its author put it; the contents beside it link to each section on GitHub.

latex-doc

Converts Markdown → LaTeX → PDF. Handles Mermaid diagrams, math, tables, citations, figures.

Workflow

  1. Write or receive content as a .md file with YAML front-matter
  2. Run scripts/build.py with the chosen template
  3. Deliver the resulting PDF

Quick build

python3 ${CLAUDE_SKILLS_DIR:-$HOME/.claude-agent/.claude/skills}/latex-doc/scripts/build.py input.md \
  --template whitepaper \
  --output output.pdf

Templates

Name Style Best for
master-thesis Times New Roman, formal, full front matter Academic papers, theses
whitepaper Georgia, navy cover banner, coloured headings Industry reports, proposals
minimal Latin Modern, clean centred title Notes, memos, quick docs

See references/templates.md for full front-matter keys and examples for each template.

All options

--template    master-thesis | whitepaper | minimal  (default: whitepaper)
--output      path/to/output.pdf
--bib         path/to/references.bib
--logo        path/to/logo.png or .pdf
--toc         add table of contents
--keep-tex    also save the intermediate .tex file

Markdown front-matter (YAML)

Always include at the top of the .md file:

---
title: "Document Title"
subtitle: "Optional subtitle"
author:
  - Name One
  - Name Two
date: "March 2025"
abstract: "One paragraph summary."
toc: true # optional
bibliography: refs.bib # optional
---

Mermaid diagrams

Fenced ```mermaid ``` blocks are automatically rendered to PNG before compilation. Requires mmdc — install once with bash ${CLAUDE_SKILLS_DIR:-$HOME/.claude-agent/.claude/skills}/latex-doc/scripts/setup.sh.

Math

Use standard LaTeX math syntax (pandoc +tex_math_dollars):

  • Inline: $E=mc^2$
  • Display: $$\nabla \cdot E = \rho/\varepsilon_0$$

Read the full file on GitHub · 96 lines

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. 2d ago First seen · 96 lines · 25 tokens per session scan B 69be4dee775a

Subscribe to this mod's changes

latex-doc is a skill published in the GitHub repository JansenAnalytics/claudex (5 stars, last pushed 2mo ago), licensed MIT. It adds 25 tokens to every session and 798 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it B with 1 finding (asks for root). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

template-pitch-deck

Pitch-deck generation exemplar — short/medium/long PDF+PPTX decks from one token-resolved, diligence-cited content source.

docxology/template · 35 tokens

Генерация PDF из Markdown с точным академическим форматированием через Pandoc и LaTeX

Навык по созданию PDF-документов из Markdown с соблюдением строгих академических требований (шрифт 14 пт, межстрочный интервал 1.5, формат А4) с использованием Pandoc и пользовательского шаблона LaTeX для сохранения стилей и цветов.

ECNU-ICALK/AutoSkill · 87 tokens

paper-figures

Extract figures from downloaded papers and include them in survey/review reports. Use when the report covers other groups' work and benefits from their architecture diagrams, experimental plots, or system schematics. Your brain prompt supplies the absolute path to the extract-figures script as {{EXTRACTFIGURES}} — use…

Muuuun/luxas · 79 tokens

overleaf

Sync and manage Overleaf LaTeX projects from the command line. Pull projects locally, push changes back, compile PDFs, and download compile outputs like .bbl files for arXiv submissions. Use when working with LaTeX, Overleaf, academic papers, or arXiv.

aloth/olcli · 62 tokens

fin-paper-convert

Compile LaTeX to PDF and convert to target journal format.

csmar432/finai-research · 12 tokens

bib-parse

Extract citations from a PDF and generate a validated .bib file. Use when the user asks to extract citations from a PDF and generate a validated .bib file. Reads the PDF, identifies referenced works, constructs BibTeX entries, and verifies metadata.

flonat/flonat-research · 54 tokens