Skip to main content
Glama

find_files

Recursively search a directory for filenames matching a glob pattern, returning up to 500 relative file paths.

Instructions

Recursively find files under a directory matching a glob pattern.

Args: path: Directory to search under, relative to the workspace root. pattern: Filename glob, e.g. ".py" or ".md" (matched against the filename only, not the full path).

Returns: Up to 500 matching relative file paths.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathNo.
patternNo*

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior4/5

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

No annotations are supplied, so the description carries the full burden and it delivers meaningful traits: recursion depth behavior, glob matching against the filename only (not the full path), and a hard cap of 500 results. It omits error behavior, hidden-file handling, and result ordering, which keeps it short of a 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The Args/Returns structure is front-loaded and each line earns its place; no filler. The verbose docstring formatting is slightly heavy for a 2-parameter tool but does not obscure the content.

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 2-parameter read tool with no output schema, the description supplies what the schema cannot: workspace-relative semantics, matching scope, and the 500-result return bound. Only edge-case behavior (errors, hidden files, symlinks) is left unspecified.

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?

Schema description coverage is 0%, so the description must compensate, and it does: 'path' is defined as relative to the workspace root and 'pattern' as a filename-only glob with concrete examples ('*.py'). It does not restate the schema defaults ('.' and '*'), which would be the only remaining gap.

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?

States a specific verb+resource+mechanism: 'Recursively find files under a directory matching a glob pattern.' An agent can distinguish this from list_directory (non-recursive) and search_text_in_files (content search) by the recursion + filename-glob combination, though no sibling is named explicitly.

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 when-to-use guidance, no exclusion of alternatives, and no conditions under which to prefer find_files over list_directory or search_text_in_files. Usage is only implied by the verb 'find'.

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