Skip to main content
Glama
mcp-server-autocad-lisp-helper

mcp-server-autocad-lisp-helper

check_missing_cleanups

Detects unhandled local variables and unmodified system variables in AutoLISP code to prevent AutoCAD state leakage.

Instructions

Identifies unhandled local variables (assigned via setq but not declared after '/') and unmodified system variables to prevent AutoCAD state leakage.

Input Schema

NameRequiredDescriptionDefault
codeYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

B3.2/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full behavioral burden. "Identifies" implies a read-only analysis that reports findings rather than rewriting code, and the stated goal (preventing AutoCAD state leakage) gives the agent the purpose behind the check. However, it never states whether the tool mutates or returns suggestions, nor any limits on scope such as whole files versus fragments.

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 dense sentence with the target findings front-loaded and the motivating outcome at the end; nothing is padding. The parenthetical qualification is slightly awkward to parse but necessary to define the defect precisely.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so the description need not explain return values, and the detection targets are clearly specified. What is missing is the input contract — the format and expected shape of the code argument — which is the main gap for an agent trying to invoke it correctly.

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

Parameters2/5

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

There is a single required parameter, "code", with 0% schema description coverage, so the schema contributes no meaning. The description never references the input at all — it does not say that "code" is the AutoLISP source text to be checked, nor whether it accepts a full file or a snippet. For a one-parameter tool at zero coverage, this leaves the agent to guess.

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 names a specific verb ("Identifies") and two concrete defect classes: local variables assigned via setq but not declared after '/', and unmodified system variables. This is far more specific than the tool name alone and lets an agent distinguish it from analyze_lisp_syntax or extract_lisp_functions by the defect type it targets. It stops short of explicitly contrasting itself with those siblings.

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 trailing rationale ("to prevent AutoCAD state leakage") implies the tool is a pre-finalization lint check on AutoLISP code, but there is no explicit statement of when to call it versus analyze_lisp_syntax or extract_lisp_functions, and no stated exclusions or prerequisites. Usage is inferable rather than instructed.

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