Skip to main content
Glama

search_documents

Retrieve relevant passages from your local knowledge base by entering a query. Control the number of results and choose between semantic or keyword search.

Instructions

Search the knowledge base for passages relevant to a query.

Args: query: What to look for, in natural language or keywords. limit: Maximum number of passages to return (1-50, default 5). mode: "auto" (semantic if available, else keyword), "semantic", or "keyword". Use "keyword" to force exact-word matching.

Returns: The most relevant passages, each labelled with its source and score.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYes
limitNo
modeNoauto

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

No annotations are provided, so the description carries the full burden. It clearly explains the return format (passages with source and score) and the behavior of each mode. However, it does not explicitly state that the operation is read-only or mention any side effects, permissions, or rate limits, which are not critical for a search tool but would add completeness.

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 very concise: a single sentence for purpose, a bullet-like list for parameters, and a sentence for the return format. Every sentence provides essential information. It is front-loaded with the key action and then details.

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

Completeness5/5

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

Given the tool has three parameters, no annotations, and an output schema, the description is complete. It explains all parameters, the default behavior for mode and limit, and what the response contains (passages with source and score). The output schema existence means the description does not need to detail the return structure beyond that.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema has 0% coverage (no parameter descriptions in the JSON schema), so the description must fully compensate. It does so by explaining each parameter in detail: query (natural language or keywords), limit (1-50, default 5), and mode (three options with behavior descriptions). This adds significant meaning beyond the basic types and defaults in the schema.

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 clearly states this tool searches the knowledge base for passages relevant to a query, using a specific verb and resource. It distinguishes itself from siblings (add_note, get_document, list_sources) by being a search tool that returns multiple passages, rather than adding a note, getting a single document, or listing sources.

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 finding relevant passages but does not explicitly state when to use this tool versus alternatives or when not to use it. There is no mention of prerequisites or context that would help an agent decide between search_documents and its siblings.

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/jaswanthsurya007-source/recall-mcp'

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