Skip to main content
Glama

index_folder

Idempotent

Indexes Markdown, text, and PDF documents in a folder for semantic search, skipping unchanged files and removing deleted ones.

Instructions

Indexes the documents in a folder and its subfolders (Markdown, text and PDF files) so they can be searched with search_docs. Files that haven't changed since the last run are skipped, and files that were deleted are removed from the index.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "path": "<path>"
    },
    "name": "index_folder"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYesAbsolute path of the folder to index.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/5

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

Annotations only declare idempotentHint=true; the description adds real behavioral detail beyond that: recursion into subfolders, which file types are picked up, incremental skipping of unchanged files, and synchronization of deletions out of the index. It stops short of describing cost/runtime on large trees, permission requirements, or what is returned, which keeps it off 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.

Conciseness5/5

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

Two sentences, no filler. The core action and its purpose come first, followed by the incremental/deletion behavior that an agent most needs to anticipate on re-runs.

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 one-parameter indexing tool with no output schema, the description covers what gets indexed, what gets skipped, and what gets removed, which is the bulk of what an agent must know. Missing only the result shape (counts, errors) and permission/failure conditions, which are minor given the absence of an output schema.

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

Parameters3/5

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

There is a single parameter and the schema already documents it at 100% coverage (absolute path of the folder). The description only adds that the path is treated recursively, which the schema does not say, but that is a marginal addition — baseline 3 applies when the schema carries the semantics.

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 pairs a specific verb (indexes) with a precise resource (documents in a folder and its subfolders), enumerates supported formats (Markdown, text, PDF), and states the downstream purpose (searchable via search_docs). That is enough for an agent to separate it from search_docs or remove_from_index without opening any schema.

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 link to search_docs implies this is the setup step that precedes searching, but there is no explicit when-to-use/when-not rule, no statement about re-running against an existing index beyond the skip logic, and no guidance versus list_sources or remove_from_index. Usage is inferable rather than stated.

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