Skip to main content
Glama

rag_index

Index local documents into a searchable knowledge base for RAG queries. Pass a file or directory path for incremental indexing; unchanged files are skipped and deleted ones pruned.

Instructions

Index local documents into the knowledge base before searching. Pass an absolute directory path for a recursive incremental walk (skips unchanged files by content hash, prunes entries for deleted files) or a single file path. Idempotent and safe to re-run; only changed content is re-embedded. Supported types: md/txt/code files (see README for the full list); dot-directories like .git and .obsidian are skipped automatically. After indexing completes, use rag_search to query. To remove everything instead, use rag_clear.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYesAbsolute path to a directory of documents (or a single file) to index.
extensionsNoExtra file extensions to include beyond the defaults
Behavior5/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It thoroughly covers the tool's behavior: recursive incremental walk, content-hash change detection, deletion pruning, idempotency, re-embedding only changed content, and automatic skipping of dot-directories. No contradictions with any structured metadata exist.

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 concise (four sentences), front-loaded with the primary purpose, and each sentence contributes meaningful information. No redundancy or filler; it efficiently packs behavioral details and sibling references without bloat.

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?

The description adequately explains the tool's actions and effects for an indexing operation, given that no output schema exists. It mentions the workflow step ('After indexing completes, use rag_search') but does not specify the response format or return value. This is a minor gap; for a tool like this, the key context is what gets destroyed/created and when to use it, which is well covered.

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 100%, so the schema already documents both parameters. The description adds value by clarifying that 'path' accepts an absolute directory or a single file, and mentions supported types (md/txt/code) which relates to the 'extensions' parameter's defaults. This goes beyond the schema's basic explanation.

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 states a clear verb ('Index') and resource ('local documents into the knowledge base'), and explicitly distinguishes itself from siblings by noting that rag_search is for querying and rag_clear is for removal. This makes the tool's role unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives explicit usage context: 'before searching', and directs users to use rag_search after indexing and rag_clear for removal. This effectively routes the agent to the correct workflow and alternatives, leaving no ambiguity about when to invoke this tool.

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/Ayush-yadav11/quillrag'

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