typesetting-latex

typesetting-latex is a skill for Claude Code, Codex from cosmicstack-labs/mercury-agent-skills. It costs 25 tokens per session (8,745 once invoked), scanned B, original, MIT.

A guide to preparing professional documents with LaTeX, a text-based system that automatically formats papers, books, resumes, presentations, and other formal documents.

In plain words
What is it for?
Use it to create academic papers, theses, technical books, resumes, presentations, bibliographies, and formal reports.
Why use it?
It helps keep complex layouts, mathematical formulas, tables, references, and document structure consistent.

Skill for Claude CodeCodex

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

Good fit Use it to create academic papers, theses, technical books, resumes, presentations, bibliographies, and formal reports.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/cosmicstack-labs/mercury-agent-skills/typesetting-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.

Any agent
npx skills add cosmicstack-labs/mercury-agent-skills --skill typesetting-latex
Clone the repo
git clone --depth 1 https://github.com/cosmicstack-labs/mercury-agent-skills

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

README.md
[![agentmods](https://agentmods.dev/badge/skills/cosmicstack-labs/mercury-agent-skills/typesetting-latex/github.svg)](https://agentmods.dev/skills/cosmicstack-labs/mercury-agent-skills/typesetting-latex)
Your own site
<a href="https://agentmods.dev/skills/cosmicstack-labs/mercury-agent-skills/typesetting-latex"><img src="https://agentmods.dev/badge/skills/cosmicstack-labs/mercury-agent-skills/typesetting-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 typesetting-latex

Your own site · 80×15
<a href="https://agentmods.dev/skills/cosmicstack-labs/mercury-agent-skills/typesetting-latex"><img src="https://agentmods.dev/badge/skills/cosmicstack-labs/mercury-agent-skills/typesetting-latex.svg" alt="Reviewed on agentmods" width="80" 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 8,745 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 4 findings, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high Tool Misuse · line 1048
    Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
    Fix: Validate all tool parameters against an allowlist. Reject dangerous parameter values (shell=True, --force, -rf /) and use safe defaults.
  • high Tool Misuse · line 1081
    Tool calls are chained to bypass individual safety checks or escalate capabilities beyond what any single tool call would allow.
    Fix: Limit tool chaining depth and validate the output of each tool before passing it to the next. Require explicit user approval for multi-step chains.
  • medium Privilege Escalation · line 1082
    Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
    Fix: Avoid sudo/root unless strictly required. Prefer least-privilege patterns. If elevation is needed, document the justification and scope.
  • medium Privilege Escalation · line 1083
    Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
    Fix: Avoid sudo/root unless strictly required. Prefer least-privilege patterns. If elevation is needed, document the justification and scope.
How audits are shown
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.08745
Opus 5.5 $0.00010 $0.03498
Sonnet 5.5 $0.00005 $0.01749
Haiku 4.5 $0.00003 $0.00874

Measured 3mo ago against content hash b2779aaf5e28, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade B, and why

typesetting-latex 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 3mo 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.

Asks for rootmediumPrivilege escalation

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

sudo apt-get update
categories/pdf-generation/typesetting-latex/SKILL.md · 1,215 lines

How it starts

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

LaTeX Typesetting

LaTeX is the gold standard for professional typesetting — used for academic papers, technical books, theses, resumes, and presentations. This skill covers document structure, packages, math typesetting, tables, figures, bibliographies, beamer presentations, and CI/CD workflows.


LaTeX Document Structure

Minimum Working Example

% document.tex — A minimal LaTeX document
\documentclass{article}

\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}

\title{A Simple LaTeX Document}
\author{Jane Doe}
\date{\today}

\begin{document}

\maketitle

\section{Introduction}

This is the first paragraph of the document. 
LaTeX handles all the typesetting automatically.

\section{Methodology}

We describe our approach in this section.

\end{document}

Document Classes

% Available document classes with typical use cases

% Research articles and short reports
\documentclass{article}

% Books and long-form content
\documentclass{book}

% Reports and theses
\documentclass{report}

% Presentations
\documentclass{beamer}

% Letters
\documentclass{letter}

% Resumes/CVs
\documentclass{resume}

% IEEE conference papers
\documentclass[conference]{IEEEtran}

% ACM conference papers
\documentclass[sigconf]{acmart}

% American Mathematical Society
\documentclass{amsart}

% With options
\documentclass[
  11pt,              % Font size: 10pt, 11pt, 12pt
  a4paper,           % Paper size: a4paper, letterpaper, legalpaper
  twoside,           % Two-sided printing
  openright,         % Chapters start on right-hand pages
  draft,             % Draft mode with overfull boxes marked
]{report}

Preamble Organization

% preamble.tex — Clean preamble organization

% ---------- Encoding and Fonts ----------
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{lmodern}               % Latin Modern (enhanced Computer Modern)

% ---------- Page Layout ----------
\usepackage[
  top=2.5cm,
  bottom=2.5cm,
  left=3cm,
  right=2.5cm,
  headheight=15pt,
]{geometry}

% ---------- Language ----------
\usepackage[english]{babel}        % Language-specific rules
\usepackage{csquotes}              % Context-sensitive quotes

% ---------- Math ----------
\usepackage{amsmath}               % AMS math environments
\usepackage{amssymb}               % AMS symbol collection
\usepackage{amsthm}                % Theorem environments
\usepackage{mathtools}             % Math tool enhancements

% ---------- Graphics and Color ----------
\usepackage{graphicx}              % Include images
\usepackage[table,xcdraw]{xcolor}  % Color support
\usepackage{caption}               % Caption customization
\usepackage{subcaption}            % Sub-figures

% ---------- Tables ----------
\usepackage{array}                 % Advanced table columns
\usepackage{booktabs}              % Professional table rules
\usepackage{longtable}             % Multi-page tables
\usepackage{tabularx}              % Auto-width columns

% ---------- Hyperlinks ----------
\usepackage[
  colorlinks=true,
  linkcolor=blue!60!black,
  citecolor=green!40!black,
  urlcolor=blue!60!black,
]{hyperref}

% ---------- Bibliography ----------
\usepackage[
  style=ieee,
  sorting=none,
  backend=biber,
]{biblatex}
\addbibresource{references.bib}

% ---------- Custom Commands ----------
\newcommand{\R}{\mathbb{R}}
\newcommand{\N}{\mathbb{N}}
\newcommand{\E}{\mathbb{E}}
\newcommand{\Var}{\operatorname{Var}}

% ---------- Theorem Environments ----------
\newtheorem{theorem}{Theorem}[section]
\newtheorem{lemma}{Lemma}[section]
\newtheorem{corollary}{Corollary}[theorem]
\theoremstyle{definition}
\newtheorem{definition}{Definition}[section]
\theoremstyle{remark}
\newtheorem{remark}{Remark}[section]

% ---------- Metadata ----------
\title{Advanced Topics in Machine Learning}
\author{Jane Doe\textsuperscript{1} \and John Smith\textsuperscript{2}}
\date{\today}

\begin{document}
\maketitle
\end{document}

Read the full file on GitHub · 1,215 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. 3mo ago First seen · 1,215 lines · 25 tokens per session scan B b2779aaf5e28

Subscribe to this mod's changes

typesetting-latex is a skill published in the GitHub repository cosmicstack-labs/mercury-agent-skills (496 stars, last pushed 3mo ago), licensed MIT. It adds 25 tokens to every session and 8,745 once invoked, about $0.0001 per session on Opus 5.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

typesetting-latex compared with skills from other repositories

typesetting-latex next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
typesetting-latexcosmicstack-labs/mercury-agent-skillsSkill4963mo agoMITB25Claude Code, Codex
pdfagentscope-ai/QwenPawSkill38kyesterdayApache-2.0A95Claude Code, Codex
huashu-md-to-pdfalchaincyf/huashu-skillsSkill2.4k4d agoMITA83Claude Code, Codex
pptx-postersforyourhealth111-pixel/Vibe-SkillsSkill3.9k24d agoApache-2.0A66Claude Code
report-generatorforyourhealth111-pixel/Vibe-SkillsSkill3.9k24d agoApache-2.0A24Claude Code
pdfforyourhealth111-pixel/Vibe-SkillsSkill3.9k24d agoApache-2.0A29Claude Code, Codex
adobe-document-reviewadobe/skillsSkill343todayApache-2.0A162Claude Code