skills/latex/SKILL.md
Manage and compile LaTeX projects under per-profile CORRESPONDANCE_ROOT. Projects support multiple independent entrypoints that share common files (preambles, constants, letterhead, etc.).
npx skillsauth add maximebaudette/agent-skills latexInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
This skill lets agents create and compile professional LaTeX documents while respecting per-profile isolation via CORRESPONDANCE_ROOT.
CORRESPONDANCE_ROOT (see Setup below).common/ by convention (documented per correspondance root — see AGENTS.md guidance).latex-project.json.This structure works well for:
Each profile must declare its own root. Add it to the profile's .env (recommended) or clearly document it in the profile's AGENTS.md.
Standard values:
# Andy
CORRESPONDANCE_ROOT=/home/mars/.hermes/profiles/career-manager/workspace/correspondance
# Cooper
CORRESPONDANCE_ROOT=/home/mars/.hermes/profiles/health-coach/workspace/correspondance
# MARS
CORRESPONDANCE_ROOT=/home/mars/.hermes/workspace/correspondance
Create the directory if it doesn't exist:
mkdir -p "$CORRESPONDANCE_ROOT"
Restart the gateway or start a fresh session after setting the variable.
Important: Inside each CORRESPONDANCE_ROOT, create an AGENTS.md file (or similar) that documents local conventions for that profile's correspondance work. This is where you explain the common/ pattern, naming preferences, etc.
A typical project looks like this:
<project-name>/
├── latex-project.json
├── common/ # Shared files (preambles, constants, letterhead, macros, etc.)
│ ├── constants.tex
│ └── letterhead.tex
├── cover-letter.tex # Entrypoint
├── letter-of-intent.tex # Entrypoint
├── expedite-request.tex # Entrypoint
├── .gitignore
└── output/
├── cover-letter.pdf
├── letter-of-intent.pdf
└── expedite-request.pdf
{
"name": "2026-05-USCIS-AOS",
"entrypoints": [
{ "file": "cover-letter.tex", "label": "Cover Letter" },
{ "file": "letter-of-intent.tex", "label": "Letter of Intent" },
{ "file": "expedite-request.tex", "label": "Expedite Request" }
],
"upload": {
"gdrive_folder_id": null,
"email": null
}
}
entrypoints lists every document that should produce its own PDF.Use the convenience script (recommended for consistency):
bash ~/.hermes/skills/latex/scripts/new-project.sh "2026-05-motivation-letter-acme"
This creates a project already structured for multiple entrypoints + a common/ directory.
You can also create the structure manually following the layout above.
From inside the project directory or by passing the full path:
# Compile EVERY entrypoint listed in latex-project.json
bash ~/.hermes/skills/latex/scripts/compile.sh /path/to/project
# Compile only one specific document
bash ~/.hermes/skills/latex/scripts/compile.sh /path/to/project cover-letter.tex
The script will:
output/ named after the .tex file (e.g. cover-letter.pdf)\input and \include resolve correctlyYou can (and often should) compile directly:
cd "$CORRESPONDANCE_ROOT/my-project"
mkdir -p output
# Compile one document
tectonic --outdir output cover-letter.tex
# Compile another
tectonic --outdir output letter-of-intent.tex
This is the most reliable method. The scripts are conveniences on top of this.
Always run tectonic from the project root.
When working on an existing project:
latex-project.jsonentrypoints array — these are the documents you can (and usually should) compile separately.The skill instructions should make agents check this file first when asked to compile or update documents in a project.
common/)Place files that are meant to be \input or \include (but never compiled alone) in a common/ directory at the project root.
Example usage in an entrypoint:
\input{common/constants}
\input{common/letterhead}
This is a recommended convention, not enforced by the compiler. Document the exact pattern used in a given correspondance root inside an AGENTS.md file at the root of that profile's CORRESPONDANCE_ROOT. This gives flexibility across different projects and profiles.
After successful compilation, PDFs live in output/.
Use the google-workspace skill for:
The latex-project.json still supports the upload section for optional automation hints.
curl --proto '=https' --tlsv1.2 -LsSf \
https://github.com/tectonic-typesetting/tectonic/releases/download/tectonic%400.15.0/tectonic-x86_64-unknown-linux-musl.tar.gz \
| tar xz -C ~/bin
Ensure ~/bin is in PATH for the relevant profiles.
common/.tectonic when you need precision or debugging.AGENTS.md at the correspondance root level.output/ in .gitignore).tectonic experience.This model supports both simple single documents and complex multi-document packages while keeping everything isolated per profile.
A ready-to-use multi-document example lives here:
skills/latex/templates/example-multi-document/
It contains two entrypoints (cover-letter.tex and motivation-letter.tex) that share files from common/.
Copy the folder into a real CORRESPONDANCE_ROOT, rename it, and start editing. This is the recommended starting point for most new projects.
development
Compile LaTeX documents using the Tectonic engine. Use this skill whenever the user wants to create, edit, or compile a LaTeX document — letters, articles, CVs, reports. Tectonic is a self-contained compiler that auto-downloads only the packages it needs.
tools
Maintain living stack documentation for the MARS host in the Prime Radiant KB. Use this skill whenever: updating the mars host page after infrastructure changes, appending archive entries for deprecated components, documenting a new service/skill/plugin being added or removed, or when the user asks to 'update stack docs', 'document this change', 'archive this setup', 'what's in the stack', or 'generate stack summary'. Also use when you've just finished installing or removing any service, plugin, skill, tool, or cron — proactively suggest documenting it.
tools
Run autonomous dev tasks using Gemini CLI (gemini-cli) with Maxime's free Google quota. Use for programming projects where MARS needs to delegate agentic coding work — file edits, code gen, refactoring, analysis — to Gemini in a project directory.
testing
Weekly or on-demand audit of all agent workspaces (Cooper, Andy, MARS). Checks for stale script references, wrong skill paths, snapshot count drift, config vs file drift, and contradictory instructions. Auto-fixes simple unambiguous issues. Emails Maxime only for items requiring judgment. Silent on clean runs. MARS-only — do not invoke as Cooper or Andy.