Skip to main content
Glama

Format markdown document

mdformat

Format markdown files in place, preserving YAML frontmatter, to maintain consistent styling in architecture decision records and specifications.

Instructions

Format a markdown file in place, preserving any YAML frontmatter. Returns True if the file was changed, False if already formatted.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.36.0

TDQS

A3.8/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does disclose the key traits: this mutates the file in place, it preserves YAML frontmatter, and it returns a change/no-change boolean. It stops short of error behavior (missing file, permission failures) or formatting scope.

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?

Two tight sentences with the action and preservation guarantee front-loaded, and the return semantics packed into the same breath. No filler.

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 formatting tool with an output schema present, the description covers purpose, mutation semantics, and return meaning. The remaining gap is failure/error behavior, which is minor at this complexity.

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?

The single 'path' parameter has 0% schema description coverage, so the description must compensate. It implies the path points to a markdown file, but adds no format, relative-vs-absolute, or existence requirements beyond that inference.

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?

States a specific verb and resource ('Format a markdown file in place') plus a distinguishing behavioral detail (YAML frontmatter preserved). The operation is unique among the many get_/create_/parse_ siblings, so an agent can select it without confusion, though it never explicitly names an alternative.

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?

Usage is only implied: the 'Returns True if changed, False if already formatted' clause suggests an idempotent normalization step, but there is no explicit when-to-use, when-not-to-use, or routing to siblings like validate or update.

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