Skip to main content
Glama

generate_documentation

Creates technical design docs, API references, runbooks, READMEs, or module overviews from supplied source material, returning a structured prompt for the host LLM to complete.

Instructions

Generate technical documentation — design doc, API reference, runbook, README, or module overview — from supplied source material. Returns a structured prompt the host LLM completes into the document.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
docTypeYesType of documentation to generate.
subjectYesWhat is being documented (component name, API name, system area).
audienceNoPrimary readers: 'new joiners', 'on-call engineers', 'API consumers', etc.
sourceMaterialYesSource code, OpenAPI spec, design notes, existing docs to base the output on.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A3.8/5.0
Behavior4/5

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

No annotations are provided, so the description carries the behavioral burden, and it discloses a genuinely non-obvious trait: the tool returns a structured prompt for the host LLM to complete rather than the finished document. This prevents a wrong mental model of the return value. It does not mention token/length limits or permissions, which is why it is not a 5.

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 sentences, zero filler, with the core action front-loaded and the return-behavior caveat immediately after. Every clause 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?

With no output schema, the description must explain what comes back, and it does so clearly via the structured-prompt return. Combined with 100% schema coverage for a four-parameter tool, an agent has what it needs to invoke it correctly.

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 every parameter is already documented in the schema; the description adds only loose references ("doc types", "source material") that map to existing fields. Baseline 3 applies when the schema does the heavy lifting.

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 (generate) and resource (technical documentation) and enumerates the five concrete doc types matching the docType enum. It stops short of differentiating from siblings like generate_adr or generate_implementation_plan, which also produce documents, so an agent must infer the boundary.

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?

"From supplied source material" implies the precondition, and the listed doc types hint at scope. There is no explicit when-to-use vs. alternatives guidance and no exclusions telling the agent when to reach for a sibling generation tool instead.

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