Skip to main content
Glama

List files (ToolAhead)

list_files
Read-onlyIdempotent

Find workspace files matching a glob pattern. Returns prefetched results from ToolAhead to reduce wait time.

Instructions

Find workspace files whose project-relative paths match a glob pattern. Use this instead of another glob/file-listing tool when available: ToolAhead may return an exact prefetched result.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathNoDirectory to search; defaults to the workspace.
limitNoMaximum paths to return (default 200).
patternYesGlob pattern such as **/*.py or src/**/test_*.py.
Install Server

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, openWorldHint, idempotentHint, and destructiveHint, so the main burden is on the description to add extra context. It adds a meaningful behavioral caveat: the tool 'may return an exact prefetched result,' which informs the agent about potential cached behavior beyond the standard annotations.

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 two concise sentences: the first states the core purpose, the second adds usage guidance and a behavioral caveat. Every word earns its place, with no filler or redundancy.

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?

Given the tool's simplicity, the well-annotated schema, and the presence of safety annotations, the description is mostly complete. It covers purpose, usage, and the key prefetch behavior. A minor gap is not elaborating on what 'exact prefetched result' implies (e.g., freshness or staleness), but overall it is sufficient.

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 already describes 100% of parameters with examples and defaults, so the baseline is 3. The description adds value by clarifying that paths are 'project-relative', which is not fully explicit in the schema, and by establishing the workspace-scoped nature of the search.

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 uses a specific verb ('Find') and resource ('workspace files') with a precise criterion ('project-relative paths match a glob pattern'). It clearly positions the tool as a file-listing tool and distinguishes it from the sibling read/edit/write/run tools, while also noting its advantage over another glob/file-listing tool.

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 explicitly advises using this tool 'instead of another glob/file-listing tool when available' and gives a rationale ('ToolAhead may return an exact prefetched result'). It provides clear usage context but does not name the alternative sibling (e.g., search) or specify when not to use it.

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

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/michael-ra/toolahead'

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