Skip to main content
Glama

explain_rule

Explain what a code rule checks, why it matters, and how to fix the issue. Provide the rule ID (e.g. design:CYCLE) to get its purpose and remediation steps.

Instructions

What a rule checks, why it matters, and how to fix it (e.g. design:CYCLE, ruff:F821).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
rule_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
fixYes
titleYes
sourceYes
rule_idYes
dimensionYes
rationaleYes
referencesNo
max_severityYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.1/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden. It describes the shape of the returned explanation but says nothing about side effects, permission needs, or what happens for an unknown/misspelled rule ID, and the return content is largely already covered by the existing output schema.

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?

A single efficient fragment that front-loads the output contract (what it checks, why it matters, how to fix) and tucks examples at the end. No wasted words, though it is a sentence fragment rather than a fully formed statement.

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 one-parameter lookup tool with an output schema already documenting return values, this covers the essentials: purpose, output content, and input format by example. The main gap is routing to list_analyzers for valid rule IDs, which a slightly fuller description would include.

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 0%, so the description must compensate for the single rule_id parameter. The examples 'design:CYCLE' and 'ruff:F821' usefully convey the expected 'analyzer:code' format, but nothing explains where to obtain valid IDs, whether the prefix is required, or how invalid input is handled.

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 identifies the resource (a lint/analysis rule) and its output substance: what the rule checks, why it matters, and remediation guidance, with example rule IDs like design:CYCLE and ruff:F821. It stops short of a clean verb+resource statement and never distinguishes itself from siblings evaluate or list_analyzers.

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

Usage Guidelines2/5

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

There is no explicit when-to-use guidance and no mention of alternatives, even though list_analyzers is the obvious place to discover rule IDs like the examples shown. The agent must infer that this is a lookup companion to evaluate rather than a fixer or lister.

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

Deploy Server

Other Tools