tex-cleaner

tex-cleaner is a skill for Claude Code, Codex from Morningstar202604/awesome-skillkit. It costs 189 tokens per session (1,926 once invoked), scanned A, original, Apache-2.0.

A static checker and optional cleaner for LaTeX source files prepared for arXiv or another venue. arXiv is an online repository where researchers share papers; the tool checks the source without compiling it.

In plain words
What is it for?
Use it before packaging a TeX project to scan for issues, count lines, remove comments when requested, and receive a static arXiv-ready report.
Why use it?
It finds submission-package problems such as unused packages, missing references, external files, leftover table-of-contents data, and non-ASCII characters. It can remove comments into a new file while leaving the original unchanged.

Skill for Claude CodeCodex

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

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is python3 scripts/tex_cleaner.py --input draft.tex.

Good fit Use it before packaging a TeX project to scan for issues, count lines, remove comments when requested, and receive a static arXiv-ready report.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/Morningstar202604/awesome-skillkit
agentmods
npx agentmods add skills/morningstar202604/awesome-skillkit/tex-cleaner

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 tex-cleaner

README.md
[![agentmods](https://agentmods.dev/badge/skills/morningstar202604/awesome-skillkit/tex-cleaner/github.svg)](https://agentmods.dev/skills/morningstar202604/awesome-skillkit/tex-cleaner)
Your own site
<a href="https://agentmods.dev/skills/morningstar202604/awesome-skillkit/tex-cleaner"><img src="https://agentmods.dev/badge/skills/morningstar202604/awesome-skillkit/tex-cleaner/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 tex-cleaner

Your own site · 80×15
<a href="https://agentmods.dev/skills/morningstar202604/awesome-skillkit/tex-cleaner"><img src="https://agentmods.dev/badge/skills/morningstar202604/awesome-skillkit/tex-cleaner.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 189 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,926 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.00189 $0.01926
Opus 5.5 $0.00076 $0.00770
Sonnet 5.5 $0.00038 $0.00385
Haiku 4.5 $0.00019 $0.00193

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

Security

Grade A, and why

tex-cleaner 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 2mo 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.

site/skills/paper/tex-cleaner/SKILL.md · 109 lines

How it starts

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

TeX Cleaner (SOTA)

The last mile before the submission zip: comment stripping + unused-package detection + asset inventory + arXiv-ready verdict.

Honest disclosure: read-only by default — without --clean it only prints a report and doesn't touch any file; --clean must come with --output (otherwise rc=1; never silently no-ops), and it writes a new file, leaving the original untouched. arxiv_ready is a static-scan conclusion, with no compile verification.

Input Checklist

Input Required Notes
TeX source file yes --input draft.tex; rc=1 if missing
clean switch no --clean; errors out alone, must pair with --output
output path no --output draft_clean.tex; only takes effect when --clean is also given
base directory no --dir; checks whether \input/figures/bib exist (defaults to the directory containing --input)

When missing, ask everything at once: "Please provide: ① input file --input ② check-only or also clean ③ if cleaning, the save path --output."

Pre-flight Checks

python3 --version                           # expect >= 3.8, else error and STOP
test -f scripts/tex_cleaner.py && echo OK   # expect OK printed, else script missing STOP
test -f "$INPUT" && echo TEX_OK             # expect TEX_OK; if missing the script rc=1, STOP first

Workflow

Step 1: Read-Only Check (dry-run)

python3 scripts/tex_cleaner.py --input draft.tex
python3 scripts/tex_cleaner.py --input draft.tex --dir paper/   # also checks asset existence

Expected: JSON output containing status ("clean"/"issues_found"), issues[], unused_packages[], assets{groups,missing}, removed_comments, full_line_comments_removed, n_lines_original, n_lines_cleaned, arxiv_ready (bool); no file written at this point. If it fails: rc=1 with {"status":"error","error":"Not found: ..."} -> check the --input path.

Step 2: Handle Issues by Category

Read the full file on GitHub · 109 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. 2mo ago Changed · -20 tokens per session 9bafe1f6a76f
  2. 2mo ago Changed · +5 lines · +31 tokens per session b65fca0c773c
  3. 2mo ago First seen · 104 lines · 178 tokens per session scan A 329ed6ec1a87

Subscribe to this mod's changes

tex-cleaner is a skill published in the GitHub repository Morningstar202604/awesome-skillkit (0 stars, last pushed 2mo ago), licensed Apache-2.0. It adds 189 tokens to every session and 1,926 once invoked, about $0.0008 per session on Opus 5.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-09-19.

Related

tex-cleaner compared with skills from other repositories

tex-cleaner next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
tex-cleanerMorningstar202604/awesome-skillkitSkill02mo agoApache-2.0A189Claude Code, Codex
extracting-lab-tablesmaziyarpanahi/openmedSkill5.9kyesterdayApache-2.0A210Claude Code
ingesting-clinical-documentsmaziyarpanahi/openmedSkill5.9kyesterdayApache-2.0A151Claude Code
parsing-ccda-documentsmaziyarpanahi/openmedSkill5.9kyesterdayApache-2.0A152Claude Code
structuring-radiology-reportsmaziyarpanahi/openmedSkill5.9kyesterdayApache-2.0A195Claude Code
summarizing-clinical-notesmaziyarpanahi/openmedSkill5.9kyesterdayApache-2.0A129Claude Code
figuressynthetic-sciences/openscienceSkill4.5kyesterdayApache-2.0A99Claude Code