Skip to main content
Glama
zvec-ai

zvec-mcp-server

Official
by zvec-ai

create_index

Create an index on a collection field to accelerate vector or scalar queries. Choose from HNSW, Flat, IVF, or inverted index types.

Instructions

Create an index on a field to accelerate queries.

Use HnswIndexParamInput / FlatIndexParamInput / IVFIndexParamInput for vector fields, and InvertIndexParamInput for scalar fields.

Args: params (CreateIndexInput): Validated input parameters containing: - collection_name (str): Collection identifier - field_name (str): Name of the field to index - index_param: One of HnswIndexParamInput, FlatIndexParamInput, IVFIndexParamInput, or InvertIndexParamInput (use 'type' field as discriminator)

Returns: str: Success message or error message

Examples: - Use when: "Create an HNSW index on the embedding field" - Use when: "Build an inverted index on the category scalar field"

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior3/5

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

The description discloses that the tool creates an index, which is consistent with readOnlyHint=false. It mentions that the index accelerates queries. However, it does not specify what happens if the index already exists (overwrite? error?) or any prerequisites like required permissions or collection existence. Given the annotations provide little additional context, the description could be more transparent.

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?

The description is well-structured with a clear purpose statement, conditional usage guidelines, an Args section, and examples. It avoids unnecessary repetition. Slightly longer than necessary but each sentence contributes value.

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?

The description covers the main variants (vector vs scalar indexes) and mentions the return type. However, it does not address important contextual aspects such as whether the index creation is idempotent, what happens on failure, or prerequisites like requiring an existing collection and field. Given the tool's complexity, this information would be useful for an agent to invoke correctly.

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?

The input schema already contains descriptions for all parameters (collection_name, field_name, index_param with sub-schemas). The description adds minimal extra semantics by providing examples and stating the tool uses validated input parameters. Schema description coverage is high due to the detailed schema, so the description's added value is marginal.

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 purpose: 'Create an index on a field to accelerate queries.' It uses a specific verb-resource pair and distinguishes itself from siblings like 'drop_index' and 'destroy_collection' by focusing on creation of indexes. The mention of different index types (HNSW, Flat, IVF, Invert) further clarifies the scope.

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 explicit guidance on when to use each index parameter type: HnswIndexParamInput/FlatIndexParamInput/IVFIndexParamInput for vector fields and InvertIndexParamInput for scalar fields. However, it lacks explicit guidance on when not to use this tool (e.g., if an index already exists or if the collection doesn't exist), so it's not a 5.

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/zvec-ai/zvec-mcp-server'

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