Skip to main content
Glama

create_index

Create normal, unique, or composite indexes on a table, with dry-run support for previewing changes before applying.

Instructions

Create an index on a table: normal, unique or composite. Example: columns=['user_id','create_time'], name='idx_order_user_time'. Supports dry_run.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameNo
uniqueNo
columnsYes
commentNo
dry_runNo
model_idYes
table_refYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.1/5.0
Behavior3/5

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

With no annotations provided, the description carries the burden of behavioral disclosure. It mentions 'Supports dry_run,' which is a useful non-destructive testing behavior, but it does not disclose permissions, side effects, idempotency, or error behavior.

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 compact and front-loaded with the core purpose. The example is concrete and useful, and the dry_run note is relevant, though the sentence order could place the dry_run note more prominently.

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 7 parameters, no output schema, and no annotations, the description is incomplete for reliably calling the tool. It omits the purpose of required parameters like model_id and table_ref, and lacks information about return values or failure modes.

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 0%, so the description must compensate for 7 parameters. It provides an example for 'columns' and 'name' and mentions 'dry_run', but it does not explain required parameters 'model_id' and 'table_ref', nor 'unique' and 'comment' semantics.

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 clearly states the tool's function: 'Create an index on a table' and enumerates supported types (normal, unique, composite). The resource 'index' distinguishes it from sibling create tools like create_table, create_column, and create_primary_key, though it does not explicitly name alternatives.

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

Usage Guidelines3/5

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

The purpose statement implies the tool is for creating indexes, which gives basic usage context. However, it offers no guidance on when to choose this over create_primary_key or create_reference, nor any exclusions or prerequisites.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.