Skip to main content
Glama
MathMagic MCP Pro

MathMagic MCP Pro

by mrtersn9-cpu

mathmagic_edit_equation

Replace an existing equation in an InDesign document with new LaTeX by targeting its [[MM:ID]] marker, re-rendering and swapping it offline or through the plugin.

Instructions

Replace the equation before [[MM:ID]] with new LaTeX (offline: re-render + replace; plugin: Edit Equation).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "latex": "<latex>",
      "marker": "<marker>"
    },
    "name": "mathmagic_edit_equation"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeNooffline (default; no focus change) or plugin (plugin brings windows to front)
latexYesNew LaTeX
markerYes[[MM:ID]]
confirmNoMust be true to make changes
eps_dirNooffline: EPS folder
size_ptNoPer-equation size in pt (menu sizes + 0.1 pt steps)
documentNoOpen InDesign document name (default: active document)
verify_latexNooffline: LaTeX round-trip check

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.2

TDQS

A3.5/5.0
Behavior3/5

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

With no annotations, the description carries the full burden, and it does disclose that offline mode re-renders and replaces without a focus change while plugin mode drives the Edit Equation dialog and brings windows to front. It omits whether the replacement is destructive/undoable, that confirm must be true, and what happens when the marker is missing or ambiguous.

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

Conciseness4/5

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

One compact sentence with the action front-loaded and mode behavior confined to a parenthetical. The phrasing 'equation before [[MM:ID]]' is slightly ambiguous on the first read but is resolved by the schema.

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?

Under 10 words, it still names the action, the target, and the two execution modes with their observable side effects (focus handling, dialog vs. headless re-render). Given zero annotations, it leaves gaps around whether confirm is mandatory and what happens to the original equation if the edit fails — the main safety-relevant omissions.

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 description coverage is 100%, so the baseline is 3. The description adds a little genuine meaning by clarifying that the marker identifies the position and the preceding equation is the target, but it says nothing about mode defaults, size_pt, verify_latex, or eps_dir beyond what the schema already documents.

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

Purpose4/5

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

The description gives a specific verb and resource ('Replace the equation') plus the addressing mechanism ('before [[MM:ID]]'), so it is clearly distinct from create/preview/verify siblings. It stops short of explicitly naming the nearest alternative (create_equation) or stating how the replacement differs from a plain re-render.

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

Usage Guidelines3/5

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

The parenthetical 'offline: re-render + replace; plugin: Edit Equation' implies which execution path applies in each context, giving implicit routing guidance. There is no explicit when-to-use/when-not-to-use guidance relative to siblings such as create_equation or rerender_equations, and no stated prerequisites.

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