Skip to main content
Glama

rag_optimize_retrieval

Optimize RAG retrieval quality and speed by analyzing a project directory to identify and resolve performance bottlenecks.

Instructions

Optimize retrieval quality and speed (Pro feature)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
api_keyNo
directoryYesProject directory
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden. It discloses only that this is a 'Pro feature' (an entitlement hint), but says nothing about whether the optimization mutates files in the directory, rewrites configuration, is idempotent, or has side effects — a significant gap for an 'optimize' verb that takes a project directory.

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?

A single front-loaded eight-word sentence with a parenthetical qualifier — efficient and scannable. The brevity is borderline under-specification rather than disciplined trimming, but every word does earn its place.

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

Completeness2/5

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

Given two parameters, no output schema, no annotations, and three competing RAG/vector siblings (rag_generate_pipeline, rag_add_chunking, vectordb_optimize_search), the description is incomplete: it does not state what gets changed, what api_key is for, what prerequisites exist, or how this differs from adjacent optimization tools. An agent would need to open the tool or guess.

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

Parameters2/5

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

Schema description coverage is 50%: directory has a description but api_key has none. The description adds no parameter-level meaning; the 'Pro feature' hint weakly implies api_key is for entitlement, but that is left to inference and does not compensate for the undocumented parameter.

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?

States a specific verb and resource: 'Optimize retrieval quality and speed' — an agent can infer this improves an existing retrieval system rather than generating a pipeline or adding chunking. However, it does not clearly differentiate from the very similar sibling vectordb_optimize_search, and the '(Pro feature)' qualifier adds commercial context but no functional scope.

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

Usage Guidelines2/5

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

No guidance whatsoever on when to use this tool versus alternatives. With close siblings like rag_generate_pipeline, rag_add_chunking, and vectordb_optimize_search, the description gives no decision criteria, prerequisites, or preconditions (e.g., 'run after a pipeline exists'), leaving the agent to guess which optimization tool fits.

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/barnburner121/claude-plugin-marketplace'

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