Skip to main content
Glama

SVG bloat check

check_svg_bloat
Read-only

Static bloat review for one SVG. Pass svg. Flags XML prolog and DOCTYPE, comments, editor markers (Inkscape, Sodipodi, Sketch, Illustrator, Figma, default Layer ids), generator notes used as title, path numbers with more than 3 decimals (with the characters that rounding to 2 or 3 would remove), hidden elements, empty and attribute-less wrapper groups, unreferenced ids, unused clip paths, masks, gradients and filters, attributes at default values, embedded base64 bitmaps, live text, matrix transforms, a missing viewBox, and script or external references. This tool does not rewrite or optimize the SVG and does not claim output; the byte estimate counts characters that the listed items occupy. Use SVGO or similar and compare the render.

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": {
      "svg": "<svg>"
    },
    "name": "check_svg_bloat"
  }
}

Input Schema

NameRequiredDescriptionDefault
svgYesThe SVG source.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.3/5.0
Behavior5/5

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

Annotations already declare the safe-read profile, and the description adds value well beyond that: it discloses that nothing is rewritten, that the tool does not claim output, and critically it defines the byte estimate ('counts characters that the listed items occupy') — a metric that would otherwise be misread as an optimization result. That is exactly the kind of caveat structured fields cannot carry.

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?

The purpose and scope land in the first clause before the long check enumeration, so it is front-loaded. The rule list is a single dense sentence running roughly twenty categories, which is information-dense but would scan better as a structured list; still, every item is load-bearing for an agent deciding whether to run the check.

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?

For a one-parameter read-only tool with no output schema, the description covers what is examined, what is deliberately not done, and how the headline number is computed. The remaining gap is the shape of the response — whether findings come back itemized per rule, as a score, or as both — which an agent would have to discover by calling it.

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% and the single parameter's own description ('The SVG source') is sufficient, so the baseline is 3. The description's 'Pass `svg`' merely restates the field name and adds no constraint such as size limits, encoding, or whether file paths are accepted.

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?

States a specific verb and resource with explicit scope: 'Static bloat review for one SVG.' The following enumeration makes the exact check set unambiguous, and the closing clause separates it from optimizer siblings ('does not rewrite or optimize the SVG'). An agent knows precisely what class of tool this is without opening the schema.

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?

'Use SVGO or similar and compare the render' positions the tool as a pre-optimization diagnostic, which is genuine usage context. It does not name an in-family alternative or state exclusions (e.g. when to prefer lint_lottie_json or plan_asset_exports), so it stops short of full routing guidance.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources