Skip to main content
Glama

search_documents

Find documents relevant to a topic or question using semantic search. Returns ranked results with snippets and source paths.

Instructions

Search across all documents using semantic search.

Use this to find documents relevant to a topic, question, or keyword. Returns ranked results with snippets and source paths.

Args: query: The search query (natural language or keywords) folder_path: Optional folder path to scope the search (e.g. "/contracts") top_k: Max number of results to return (default 10)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYes
folder_pathNo
top_kNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior3/5

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

With no annotations, the description carries the full burden. It states the tool performs semantic search across all documents and returns ranked results with snippets and source paths, indicating read-only behavior. However, it omits details about authentication, rate limits, or any side effects.

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 description is concise and front-loaded: one sentence for purpose, one for usage, one for return format, then a parameter list. It contains no unnecessary words or repetition.

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 and the presence of an output schema, the description covers essential aspects: purpose, usage context, parameters, and return type. It is sufficient for an agent to select and invoke the tool correctly in common scenarios.

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 description compensates for 0% schema coverage by explaining each parameter: query is natural language or keywords, folder_path is optional with an example, and top_k has a default. This adds meaningful context beyond the schema's basic titles.

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 'Search across all documents using semantic search,' specifying the verb (search), resource (documents), and method (semantic). It distinguishes from similar tools like grep_documents by emphasizing semantic relevance. However, it does not explicitly differentiate from sibling 'document_intelligence_search_documents'.

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 advises using this tool to find documents relevant to a topic, question, or keyword, which implies when to use it for semantic search. However, it does not provide explicit guidance on when not to use it or mention alternative tools (e.g., for exact matches).

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/RPasquale/lightbulb-mcp'

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