Skip to main content
Glama

Turn code metrics on or off

statica_metric_set
DestructiveIdempotent

Enable or disable individual code metrics by key for a project; unnamed metrics retain their state, and changes affect all users of the server project—confirm before applying.

Instructions

Turn individual code metrics on or off by key (for example FUCYC). Metrics not named keep their state. Applies to everyone using the server project; confirm with the user first.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "projectDir": "<projectDir>"
    },
    "name": "statica_metric_set"
  }
}

Input Schema

NameRequiredDescriptionDefault
onNoMetric keys to turn on.
offNoMetric keys to turn off.
projectDirYesAbsolute path of the project directory being analyzed (usually the session's working directory).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior4/5

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

The annotations already flag destructiveHint=true, openWorldHint=true and idempotentHint=true, but the description adds real context beyond them: partial-update semantics ('Metrics not named keep their state') and blast radius ('Applies to everyone using the server project'), plus a confirmation requirement. It does not say what happens with an unknown key or what the call returns, keeping it from a 5.

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

Conciseness5/5

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

Three short sentences with the core action front-loaded, followed by the state-preservation rule and the scope/caution. No redundant restatement of the title or schema, and nothing is buried.

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?

For a destructive, server-wide configuration mutation with no output schema, the description covers the essentials: what changes, what does not change, who is affected, and the need for user confirmation. Only edge behavior (invalid keys, persistence across sessions, result shape) is left unstated.

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 the on/off/projectDir parameters are already fully documented in the schema; the description only reinforces the key concept with an example (FUCYC) and the partial-update behavior of the two arrays. That is a modest addition over structured data, matching the baseline 3.

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 verb and resource ('Turn individual code metrics on or off by key') and even gives a concrete example key (FUCYC), which is far more informative than the title alone. It does not explicitly name a sibling such as statica_metric_show to contrast read vs. write, so it falls just short of the top score.

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 'confirm with the user first' caution is genuine usage guidance for a mutating tool, and the scope sentence implies when this applies (project-wide changes). However, there is no explicit statement of when to prefer this over statica_metric_show for inspecting metrics, nor any when-not-to-use condition.

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