Skip to main content
Glama
MCP PostgreSQL Operations

MCP PostgreSQL Operations

by call518

get_index_io_stats

Analyze per-index I/O statistics and buffer cache hit ratios to identify indexes causing excessive disk reads and poor buffer cache performance.

Instructions

[Tool Purpose]: Analyze I/O performance statistics for indexes (disk reads vs buffer cache hits)

[Exact Functionality]:

  • Show index-level I/O statistics and buffer hit ratios

  • Identify indexes with poor buffer cache performance

  • Provide detailed I/O performance metrics per index

  • Help optimize index and buffer cache usage

[Required Use Cases]:

  • When user requests "index I/O stats", "index buffer performance", etc.

  • When analyzing index-level I/O performance

  • When identifying indexes causing excessive disk I/O

  • When optimizing index buffer cache efficiency

[Strictly Prohibited Use Cases]:

  • Requests for index optimization actions

  • Requests for buffer cache configuration changes

  • Requests for statistics reset

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_index_io_stats"
  }
}

Input Schema

NameRequiredDescriptionDefault
schema_nameNoSchema name to filter (default: public)public
database_nameNoDatabase name to analyze (uses default database if omitted)

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv3.4.3
    • addedInput schema / properties / database_name / description
      Added value: +"Database name to analyze (uses default database if omitted)"
    • addedInput schema / properties / schema_name / description
      Added value: +"Schema name to filter (default: public)"
  2. Changed7 schema fields changedv3.4.2
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / database_name / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • removedInput schema / properties / database_name / title
      Removed value: -"Database Name"
    • removedInput schema / properties / database_name / type
      Removed value: -"string"
    • removedInput schema / properties / schema_name / title
      Removed value: -"Schema Name"
    • removedOutput schema / properties / result / title
      Removed value: -"Result"
    • removedOutput schema / title
      Removed value: -"_WrappedResult"
  3. Addedv1.0.0

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations, the description implies a read-oriented analysis tool through verbs like 'Show', 'Identify', and 'Provide', and the prohibited use cases reinforce that it does not perform optimization or configuration changes. However, it does not explicitly state side-effect behavior, permissions, or execution characteristics beyond that implication.

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 front-loaded and organized into purpose, functionality, use cases, and prohibited use cases. It is somewhat repetitive between the purpose and functionality sections, but the structure makes selection easy and there is little wasted text.

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 a moderate-complexity read-only analysis tool with two fully documented parameters and an output schema, the description covers purpose, selection guidance, and exclusions adequately. It could be more complete by naming sibling alternatives or explicitly confirming read-only behavior, but no critical invocation information is missing.

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 coverage is 100%, so both schema_name and database_name are already documented in the input schema. The description adds no parameter-specific meaning beyond the schema, which is acceptable but not value-adding at the parameter level.

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 states a specific resource and scope: index-level I/O performance statistics including disk reads versus buffer cache hits. It clearly separates index I/O from general or table I/O by repeated use of 'index-level' and 'per index', though it does not explicitly name sibling alternatives.

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?

It provides explicit use cases such as analyzing index-level I/O performance and identifying indexes causing excessive disk I/O, plus prohibited cases like optimization actions, buffer cache configuration changes, and statistics reset. Alternatives among sibling tools are not explicitly named, so it falls short of full when-versus-which guidance.

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