Skip to main content
Glama

Query Knowledge Base

lyzr_kb_query
Read-onlyIdempotent

Query a knowledge base with a search term and knowledge base ID to retrieve the most relevant text chunks.

Instructions

Retrieve relevant chunks from a knowledge base.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYesThe search query
top_kNoMax results
rag_idYesKnowledge base id
Behavior2/5

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

Annotations already declare readOnlyHint, openWorldHint, and idempotentHint as true, so the agent knows this is a safe read operation. However, the description adds no additional behavioral context such as pagination, result ordering, default values for top_k, or whether rag_id must reference a specific resource type. With no output schema, the description also does not clarify the exact structure of the returned chunks, leaving a transparency gap beyond what annotations provide.

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 a single, clear sentence: 'Retrieve relevant chunks from a knowledge base.' It is front-loaded with the action and resource, contains no filler words, and is appropriately sized for a simple read-only tool. It gives just enough information without unnecessary elaboration, making it efficient and easy to parse.

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

Completeness3/5

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

Given the tool's low complexity (3 simple parameters, no nested objects) and strong annotations (readOnly, idempotent, openWorld), the description is minimally adequate. However, without an output schema, the description should hint at what the response contains. 'Relevant chunks' is a vague return description and does not clarify whether the response includes scores, metadata, or just text. It also lacks any context about how this relates to other KB tools, making it less complete for selection purposes.

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?

Schema description coverage is 100%, so all three parameters (query, top_k, rag_id) have meaningful descriptions in the schema. The tool description itself adds no additional parameter semantics, but since the schema already documents each parameter clearly, the baseline of 3 is appropriate. The parameter descriptions are concise and self-explanatory, so no further clarification is needed.

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?

The description uses a specific verb ('Retrieve') and resource ('relevant chunks from a knowledge base'), clearly indicating a retrieval/search operation. It is distinct from sibling KB tools like create, list, or get, though it does not explicitly name alternatives. The name 'lyzr_kb_query' plus 'relevant chunks' suggests semantic search rather than simple metadata fetching, giving it enough clarity without being fully explicit.

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?

The description provides no guidance on when to use this tool versus alternatives. It does not mention exclusions, prerequisites, or mention any sibling tools like lyzr_kb_list, lyzr_kb_get, or lyzr_rag_get_doc_content. The only signal is the verb 'retrieve' implying search, but there is no explicit usage context or selection criteria.

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/nandanNM/lyzr-mcp'

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