Skip to main content
Glama
xiuxiansk

mcp-local-rag

by xiuxiansk

delete_file

Remove previously ingested files or data from the local vector database by providing filePath or source. Use to clean up indexed content when documents are updated or no longer needed.

Instructions

Delete a previously ingested file or data from the vector database. Use filePath for files ingested via ingest_file, or source for data ingested via ingest_data. Either filePath or source must be provided. Returns deleted (operation succeeded), removedChunks, and existed (whether anything was actually present).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sourceNoSource identifier used in ingest_data. Examples: "https://example.com/page", "clipboard://2024-12-30"
filePathNoAbsolute path to the file (for ingest_file). Example: "/Users/user/documents/manual.pdf"
Behavior4/5

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

Without annotations, the description carries the full burden. It discloses the return structure (deleted, removedChunks, existed) and clarifies that 'existed' indicates whether anything was present. This goes beyond vague 'delete' statements by explaining outcome semantics. It doesn't mention irreversibility or auth, but the core behavior is transparent.

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 three sentences with no wasted words. It front-loads the purpose, then logically explains parameter selection, and ends with return values. Each sentence contributes new information without redundancy.

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 moderate complexity, the description covers the essential aspects: what it deletes, how to specify the target, and what the response indicates. It doesn't mention error cases for both parameters provided, but the 'existed' flag mitigates missing-file uncertainty. The lack of an output schema makes the return explanation valuable.

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 schema already provides 100% parameter coverage, so baseline is 3. The description adds significant meaning by mapping parameters to ingestion methods (filePath for ingest_file, source for ingest_data) and enforcing the 'either/or' constraint, which is absent from the schema's optional flags.

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 the tool's function: 'Delete a previously ingested file or data from the vector database.' It specifies the verb (delete), the resource (previously ingested files/data), and distinguishes from sibling tools like ingest_file and ingest_data by focusing on the removal operation.

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

Usage Guidelines4/5

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

The description provides clear context on when to use this tool: for previously ingested items only, and gives explicit guidance on choosing filePath vs. source based on how the data was ingested. It lacks explicit alternatives or when-not-to-use, but the coverage is strong for a delete operation.

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/xiuxiansk/mcp-local-rag'

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