Skip to main content
Glama
conorluddy

XC-MCP: XCode CLI wrapper

by conorluddy

Get Cache Statistics

cache-get-stats
Read-onlyIdempotent

Retrieve comprehensive cache statistics across simulator, project, and response caches. Monitor hit rates, entry counts, and storage usage to optimize performance and debug issues.

Instructions

cache-get-stats

📊 Get comprehensive statistics across all XC-MCP cache systems - Monitor cache performance and effectiveness.

Retrieves detailed statistics from the simulator cache, project cache, and response cache systems. Shows hit rates, entry counts, storage usage, and performance metrics across all caching layers. Essential for monitoring cache effectiveness and identifying optimization opportunities.

Advantages

• Monitor cache performance across all simulator, project, and response caches • Understand cache hit rates to optimize build and test workflows • Track memory usage and identify tuning opportunities • Debug performance issues by analyzing cache patterns

Parameters

Required

  • (None - retrieves statistics from all cache systems automatically)

Optional

  • (None)

Returns

  • Tool execution results with structured cache statistics

  • Statistics for each cache system (simulator, project, response)

  • Hit rates, entry counts, and performance metrics

  • Timestamp of statistics collection

  • cache-set-config: Configure cache retention times

  • cache-get-config: Get current cache configuration

  • cache-clear: Clear cached data

Notes

  • Tool is auto-registered with MCP server

  • Statistics are calculated in real-time

  • Use regularly to monitor cache effectiveness

  • Export statistics for performance analysis across time

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv4.1.0
  2. Removedv1.1.0
  3. First observedv1.0.0

TDQS

A3.6/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, and non-destructive behavior. The description adds useful context: statistics are calculated in real time and cover all cache systems. There is no contradiction between the description and annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness2/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with a clear summary but is padded with repetitive marketing-style bullets and vague notes such as 'Export statistics for performance analysis across time' and 'Tool is auto-registered with MCP server'. A zero-parameter read-only tool does not need this much prose.

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?

There is no output schema, so the description appropriately explains what the agent should expect: hit rates, entry counts, storage usage, performance metrics, and timestamps. It also names related cache tools, making the call context sufficiently complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool has zero parameters, and the description explicitly lists 'Required: None' and 'Optional: None'. This confirms the schema and removes any ambiguity, though there is no deeper parameter semantics to add.

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 a specific verb and resource: it retrieves statistics from the simulator, project, and response cache systems. It is readily distinguishable from sibling cache tools like cache-get-config and cache-clear, though it does not explicitly say 'use this for stats, not config'.

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 description says to use the tool for monitoring cache effectiveness and identifying optimization opportunities, giving clear context. However, it does not provide explicit when-to-use versus alternatives or when-not-to-use guidance, leaving some selection reasoning to the agent.

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