Skip to main content
Glama

Generate diagram

generate_diagram

Generate a draft diagram of the repository architecture from scan and import facts. Select Mermaid or Graphviz DOT, and choose high-level modules or detailed file grouping.

Instructions

Combine scan + import facts into a DRAFT diagram string — Mermaid flowchart (default) or Graphviz DOT. level 'high' (default) shows modules/directories; 'detail' shows files grouped by module. This is a draft the calling model is expected to refine.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesAbsolute or relative path to the repository root
levelNoDiagram granularity (default 'high')
formatNoDiagram notation: 'mermaid' (default; renders on GitHub) or 'dot' (Graphviz interop)
Behavior4/5

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

With no annotations, the description carries the transparency burden. It adds behavioral context beyond the schema by noting the output is a 'draft the calling model is expected to refine,' implying the result is not final and may need iteration. It also explains the level parameter's effect on granularity, which is not in the schema. It does not mention side effects, but generating a string implies a read-only operation.

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 three sentences, with the first sentence front-loading the core action and output. Every sentence adds value: purpose, level semantics, and the draft-refinement caveat. There is no redundancy or filler, making it concise and well-structured.

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 tool with no output schema and no annotations, the description covers the essential aspects: purpose, parameter semantics, output nature (draft diagram string), and context (combines scan/import facts). It could explicitly note prerequisites (e.g., that scan_repo and build_import_graph should be run first), but the phrasing 'combine scan + import facts' implies this dependency. Overall, it is sufficiently complete for an agent to understand invocation and result.

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

Parameters4/5

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

The input schema has 100% parameter coverage, providing descriptions for path, level, and format. The description adds value beyond the schema by elaborating on the level values: 'high' shows modules/directories and 'detail' shows files grouped by module. It also confirms the default formats inline, though these are already in the schema. The level semantics are the key addition.

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 opens with a specific verb phrase 'Combine scan + import facts into a DRAFT diagram string,' clearly defining the tool's purpose and output. It distinguishes itself from siblings like render_diagram by explicitly labeling the output as a draft for refinement, and names the supported formats (Mermaid/DOT), making the tool's role unambiguous.

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 provides clear context for when to use the tool: after scan and import facts are available, to produce a draft diagram. It does not explicitly name alternatives or exclusions (e.g., 'use render_diagram for final output'), but the 'draft' framing and sibling names imply the appropriate workflow. This is clear context but lacks explicit when-not-to-use guidance.

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/builditwithgk/repo-cartographer'

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