Skip to main content
Glama

read_directory

List files and folders in a directory to explore the file structure when analyzing code for architectural decisions.

Instructions

List files and folders in a directory. Use this to explore the file structure within accessible roots.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesDirectory path to list (relative to project root or absolute within roots)
Behavior3/5

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

No annotations are provided, so the description carries full burden. It states the tool lists files and folders, which is a safe read operation, but does not disclose error handling (e.g., invalid paths), return format, or whether it follows symlinks. Basic transparency but lacks behavioral depth.

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, front-loaded with purpose, no extraneous information. Every word earns its place, achieving high efficiency.

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

Completeness3/5

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

With no output schema and no annotations, the description is adequate for a simple listing tool but lacks details on output format, error cases, and differentiation from sibling 'list_directory'. Could be more complete for full autonomy.

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 schema covers 100% of parameters, and the description adds practical context beyond the schema: 'relative to project root or absolute within roots'. This clarifies path semantics, aiding correct invocation.

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 lists files and folders in a directory, with the purpose of exploring file structure. It specifies 'within accessible roots', adding scope. However, it does not differentiate from the sibling tool 'list_directory', which likely has similar functionality.

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?

The description implies usage for exploring file structure but offers no guidance on when not to use it or alternatives. Notably, 'list_directory' exists as a sibling, yet no distinction is provided, leaving the agent uncertain which to choose.

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/tosin2013/mcp-adr-analysis-server'

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