Skip to main content
Glama

generate_diagram

Create Mermaid diagrams for file trees in a codebase, visualizing directory structures, dependencies, and file importance. Customize layout, depth, and style for clear code architecture insights.

Instructions

Generate a Mermaid diagram for the current file tree

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
layoutNo
maxDepthNoMaximum depth for directory trees (1-10)
minImportanceNoOnly show files above this importance (0-10)
outputFileNoOptional output file name for the diagram
outputFormatNoOutput format (mmd or png)
showDependenciesNoWhether to show dependency relationships
styleYesDiagram style
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the tool generates a diagram but doesn't explain what happens after generation (e.g., where the diagram is saved, if it's displayed or returned as data, or any side effects like file creation). For a tool with 7 parameters and no output schema, this lack of behavioral context is a significant gap.

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 a single, efficient sentence: 'Generate a Mermaid diagram for the current file tree.' It's front-loaded with the core purpose, has zero waste, and is appropriately sized for the tool's complexity. Every word earns its place, making it highly concise and well-structured.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (7 parameters, nested objects, no output schema, and no annotations), the description is incomplete. It doesn't explain the output (e.g., whether it returns a file path, diagram data, or nothing), behavioral aspects like side effects, or usage context relative to siblings. For a diagram-generation tool with rich parameters, this minimal description leaves too many gaps for effective agent use.

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 high at 86%, with most parameters well-documented in the schema (e.g., 'maxDepth' has description 'Maximum depth for directory trees (1-10)'). The description adds no parameter-specific information beyond what the schema provides, so it meets the baseline of 3 for high coverage but doesn't compensate for any gaps.

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 clearly states the tool's purpose: 'Generate a Mermaid diagram for the current file tree.' It specifies the verb ('Generate'), resource ('Mermaid diagram'), and scope ('current file tree'), making the purpose unambiguous. However, it doesn't explicitly differentiate from sibling tools like 'create_file_tree' or 'list_files,' which could also involve file tree operations, so it doesn't reach the highest score.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools like 'create_file_tree' (which might create a textual representation) or 'list_files' (which might list files without a diagram), nor does it specify prerequisites or contexts for use. The agent must infer usage from the purpose alone, which is insufficient.

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

Related 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/admica/FileScopeMCP'

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