Skip to main content
Glama
grandMA2 MCP
by drohi-r

lint_macro

Statically analyze grandMA2 macros for unsafe patterns like ungated destructive commands, broken jumps, missing quotes, raw patterns, and infinite loops, then return issues and an overall status.

Instructions

Static analysis of a grandMA2 macro for unsafe patterns (SAFE_READ).

Checks for: destructive commands without gates, broken jump targets,
missing quotes, unsafe raw patterns, potential infinite loops.

Args:
    macro_id: Macro number to lint.

Returns:
    str: JSON with issues[], overall (clean/warning/error), lines_checked.

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": {
      "macro_id": "<macro_id>"
    },
    "name": "lint_macro"
  }
}

Input Schema

NameRequiredDescriptionDefault
macro_idYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations, the description carries the burden and does reasonably well: 'Static analysis' plus the SAFE_READ marker makes clear this does not mutate the macro, and the enumerated check list tells the agent what classes of problems are detected. It does not state whether issues block execution or how severe the analysis is, but the core behavioral profile is disclosed.

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?

Front-loaded with a one-line purpose, then the check list, then compact Args/Returns blocks. No filler sentences and every line adds information.

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 simple one-parameter, read-only analysis tool this covers purpose, scope, and output shape. The Returns block is partly redundant given an output schema exists, but as a summary of issues[]/overall/lines_checked it remains useful.

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?

Schema coverage is 0% (the single parameter has no description), so the description must compensate: 'macro_id: Macro number to lint' clarifies that the integer is the macro's number rather than an internal id or name. That closes the main ambiguity for a one-parameter tool.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Static analysis of a grandMA2 macro') and enumerates exactly what is checked: destructive commands without gates, broken jump targets, missing quotes, unsafe raw patterns, infinite loops. This is clearly distinguishable from siblings like run_macro or generate_ma2_macro without opening either schema.

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 'SAFE_READ' tag and 'unsafe patterns' framing imply a pre-flight/validation role, but the description never says when to call it versus run_macro or generate_ma2_macro, nor does it state exclusions or prerequisites. Usage is implied rather than instructed.

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