overleaf-setup

A setup guide for connecting a local LaTeX writing project to Overleaf, a web service for creating and collaborating on LaTeX documents.

In plain words
What is it for?
Use it to install and authenticate the Overleaf command-line tool, connect a local folder to an Overleaf project, and configure automatic pushes after edits.
Why use it?
It removes the need to manually upload changed source files and applies the project's required citation format during synchronization.

Skill for Claude CodeCodex

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/yqi96/warranted/overleaf-setup
Any agent
npx skills add yqi96/warranted --skill overleaf-setup
Clone the repo
git clone --depth 1 https://github.com/yqi96/warranted

Made for: Claude Code, Codex.

Per session 59 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 825 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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 $0.00059 $0.00825
Opus 5 $0.00030 $0.00413
Sonnet 5 $0.00012 $0.00165
Haiku 4.5 $0.00006 $0.00082

Measured 2d ago against content hash 51e533783e1c, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

overleaf-setup 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 2d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (scripts/overleaf-push.py), 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.

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.

skills/overleaf-setup/SKILL.md · 118 lines

How it starts

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

Goal

Configure automatic Overleaf push so that every .tex edit triggers a push without further agent involvement. The skill ends when the hook is written to settings.local.json and the user has been told to restart Claude Code.


Step 1 — Install

uv tool install overleaf-for-agents

Verify:

leaf --version

Step 2 — Authenticate

leaf login

A browser window opens. Tell the user: "Log in to Overleaf and wait for your project dashboard to appear. Let me know when ready."

Verify after confirmation:

leaf list

Fallback — if leaf login fails (no Chrome / CDP error):

  1. Ask the user to open https://www.overleaf.com, log in, then go to DevTools → Application → Cookies → copy the value of overleaf_session2 (starts with s%3A)
  2. Write the value to ~/.olauth
  3. Retry leaf list

Step 3 — Choose or create project, and local directory

Ask the user whether they want to sync to an existing project or create a new one.

Existing project: run leaf list, show the output, ask which project to use. Record PROJECT_ID (24-char hex).

New project: ask for a project name, then run:

leaf create "NAME"

Record PROJECT_ID from the output.

Also ask which local directory contains the LaTeX files. Record LATEX_DIR (absolute path).


Step 4 — Init

leaf init --project PROJECT_ID --dir LATEX_DIR

This writes leaf.toml into LATEX_DIR. The push script copies it into staging on each run.


Step 5 — Write the hook

Determine SKILL_DIR (absolute path to ${CLAUDE_PLUGIN_ROOT}/skills/overleaf-sync) and DB_PATH (absolute path to .toulmin/argument.db).

Merge the following into .claude/settings.local.json, preserving any existing hooks:

{
  "hooks": {
    "Stop": [{
      "hooks": [{
        "type": "command",
        "command": "uv run SKILL_DIR/scripts/overleaf-push.py --dir LATEX_DIR --db DB_PATH --require-statement-cites",
        "timeout": 120,
        "statusMessage": "Checking citations and pushing to Overleaf..."
      }]
    }]
  }
}

Read the full file on GitHub · 118 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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 · 118 lines · 59 tokens per session scan A 51e533783e1c

Subscribe to this mod's changes

overleaf-setup is a skill published in the GitHub repository yqi96/warranted (2 stars, last pushed 12d ago), licensed MIT. It adds 59 tokens to every session and 825 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-31.

Related

Other skills, from other repositories

proof-checker

Rigorous mathematical proof verification and fixing workflow. Reads a LaTeX proof, identifies gaps via cross-model review (external reviewer backend, ultra reasoning), fixes each gap with full derivations, re-reviews, and generates an audit report. Use when user says "检查证明", "verify proof", "proof check", "审证明"…

wanshuiyin/Auto-claude-code-research-in-sleep · 87 tokens

citation-audit

Zero-context verification that every bibliographic entry in the paper is real, correctly attributed, and used in a context the cited paper actually supports — catching hallucinated authors, wrong years, fabricated venues, version mismatches, and wrong-context citations. Use when user says "审查引用", "check citations"…

wanshuiyin/Auto-claude-code-research-in-sleep · 86 tokens

idea-creator

Generate and rank research ideas given a broad direction. Use when user says "找idea", "brainstorm ideas", "generate research ideas", "what can we work on", or wants to explore a research area for publishable directions.

wanshuiyin/Auto-claude-code-research-in-sleep · 51 tokens

idea-discovery

Workflow 1: Full idea discovery pipeline to go from a broad research direction to validated, pilot-tested ideas. Use when user says "找idea全流程", "idea discovery pipeline", "从零开始找方向", or wants the complete idea exploration workflow.

wanshuiyin/Auto-claude-code-research-in-sleep · 56 tokens

paper-illustration

Generate publication-quality AI illustrations for academic papers using Gemini image generation. Creates architecture diagrams, method illustrations with Claude-supervised iterative refinement loop. Use when user says "生成图表", "画架构图", "AI绘图", "paper illustration", "generate diagram", or needs visual figures for papers.

wanshuiyin/Auto-claude-code-research-in-sleep · 67 tokens

meta-optimize

Analyze ARIS usage logs and propose optimizations to SKILL.md files, reviewer prompts, and workflow defaults. Outer-loop harness optimization inspired by Meta-Harness (Lee et al., 2026). Use when user says "优化技能", "meta optimize", "improve skills", "分析使用记录", or wants to optimize ARIS's own harness components based on…

wanshuiyin/Auto-claude-code-research-in-sleep · 81 tokens