Skip to main content
Glama

Check LaTeX document

check_document

Detects undefined references, duplicate/unused labels, and unbalanced environments in LaTeX. Lists labels, references, and citations, requiring no TeX installation.

Instructions

Static analysis of LaTeX source: finds undefined references, duplicate/unused labels, and unbalanced environments. Lists labels, references and citations. Works without a TeX install.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathNoPath to a .tex file (used if source is omitted)
sourceNoLaTeX source to analyze
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the behavioral disclosure burden. It explicitly labels the operation as 'static analysis', signaling no side effects or compilation, and lists what it finds. It does not detail the exact output format or whether any files are written, but 'static analysis' strongly implies read-only behavior, which is adequately transparent.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two concise sentences with no redundancy. It front-loads the core purpose ('static analysis of LaTeX source'), then efficiently enumerates specific findings and a key practical detail (no TeX install required). Every word earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description covers purpose, capabilities, and operating constraints for a simple 2-parameter tool. It omits an explicit return format, but no output schema exists, and the listed outputs ('lists labels, references and citations') give adequate context for an agent to understand what to expect.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, with clear descriptions for both 'path' and 'source'. The tool description adds no extra details about parameter semantics or relationships beyond what the schema already provides, so the baseline score of 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool performs static analysis of LaTeX source, listing specific checks (undefined references, duplicate/unused labels, unbalanced environments) and outputs (labels, references, citations). It distinguishes itself from siblings 'parse_log' and 'compile' by focusing on source analysis rather than log parsing or compilation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies when to use the tool (for checking LaTeX source without compiling) and adds a useful constraint ('works without a TeX install'). However, it does not explicitly compare with sibling tools or state when not to use it, missing a stronger usage guideline.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/marcelogdomingues/mcp-latex'

If you have feedback or need assistance with the MCP directory API, please join our Discord server