Skip to main content
Glama

get_module_docs

Extracts documentation comments and signatures from a Rust or WIT file, so you can review module APIs without opening the source.

Instructions

Extracts documentation comments (///) and the signatures immediately following them from a Rust or WIT file

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filePathYesPath to the file relative to the API or WIT root, e.g. 'src/item.rs'

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations, the description carries the full burden, and it does disclose the return content (doc comments and immediately following signatures). However, it omits that this is a read-only, side-effect-free operation, how missing files or unsupported file types are handled, and any output format details.

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?

A single tightly-worded sentence with the action and scope front-loaded and no filler. Nothing is redundant.

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 tool with no output schema, the description conveys enough: what it extracts and from which file types. It would be stronger if it noted the read-only nature and error behavior, but the core invocation is well covered.

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?

Only one parameter (filePath) exists and schema description coverage is 100%, including the relative-path convention and an example. The description adds no parameter detail, so baseline 3 applies since the schema already does the work.

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 states a specific verb ('Extracts') and resource ('documentation comments (///) and the signatures immediately following them') scoped to Rust or WIT files. It is clear on its own, but it does not distinguish itself from similar siblings like read_api_file or read_code_block, which also read file content.

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?

There is no guidance on when to choose this over alternatives such as read_api_file or read_code_block, nor any mention of prerequisites or supported contexts beyond the Rust/WIT scope. The agent must infer the use case from the name alone.

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