Skip to main content
Glama
isdaniel

MySQL-Performance-Tuner-Mcp

get_index_recommendations

Read-onlyIdempotent

Analyze MySQL query patterns to identify full table scans and inefficient index usage, then generate prioritized index recommendations for performance optimization.

Instructions

Get AI-powered index recommendations for MySQL user tables.

Analyzes query patterns from performance_schema to recommend indexes:

  • Identifies queries with full table scans

  • Finds queries not using indexes efficiently

  • Suggests composite indexes for multi-column filters

  • Prioritizes recommendations by potential impact

Note: This tool only analyzes user/custom tables and excludes MySQL system tables (mysql, information_schema, performance_schema, sys).

Based on MySQL performance_schema statistics and query patterns. Similar to MySQLTuner's index analysis but with more detailed recommendations.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
schema_nameNoSchema/database to analyze
max_recommendationsNoMaximum number of recommendations (default: 10)
min_improvement_percentNoMinimum expected improvement percentage (default: 10)
include_query_analysisNoInclude analysis of specific queries
Behavior4/5

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

Annotations already provide important behavioral hints (readOnlyHint: true, idempotentHint: true, destructiveHint: false), indicating a safe, non-modifying operation. The description adds valuable context beyond this: it explains what the tool analyzes (full table scans, inefficient index use), what it recommends (composite indexes), how it prioritizes (by potential impact), and its data sources (performance_schema statistics). This enriches understanding without contradicting annotations.

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 and appropriately sized. It front-loads the core purpose, then details the analysis approach in bullet points, and adds important notes and comparisons. Every sentence adds value, though the final comparison to MySQLTuner could be slightly trimmed without losing essential information.

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 complexity (AI-powered index analysis with 4 parameters) and rich annotations, the description provides good contextual completeness. It explains the analysis methodology, scope limitations, and data sources. However, without an output schema, it doesn't detail the return format (e.g., structure of recommendations), leaving a minor gap in full understanding.

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 the input schema already documents all parameters thoroughly. The description doesn't add specific parameter semantics beyond what's in the schema (e.g., it doesn't explain how 'min_improvement_percent' relates to the analysis). However, it implies the scope of analysis (user tables, query patterns) which contextualizes parameter usage. Baseline 3 is appropriate given high schema coverage.

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 with specific verbs ('Get AI-powered index recommendations', 'Analyzes query patterns') and resources ('MySQL user tables', 'performance_schema'). It distinguishes from siblings by focusing specifically on index recommendations rather than general analysis, health checks, or other MySQL diagnostics like 'get_index_stats' or 'find_unused_indexes'.

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 about when to use this tool ('analyzes query patterns from performance_schema to recommend indexes') and what it excludes ('only analyzes user/custom tables and excludes MySQL system tables'). However, it doesn't explicitly mention when NOT to use it or name specific alternatives among the sibling tools, such as 'find_unused_indexes' for different index analysis.

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/isdaniel/mysqltuner_mcp'

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