Skip to main content
Glama
Praket7

mastercam-mcp

by Praket7

analyze_nc_program

Read-onlyIdempotent

Parses G-code to flag risky rapids, feed/spindle limit violations, unsupported motion, and cycle-time evidence for review.

Instructions

Parse bounded G-code linear motion and flag risky rapids, feed/spindle limits, unsupported motion, and reviewable cycle-time evidence

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
safeZNo
stockNo
unitsYes
machineYes
programYes
fixturesNo
toolRadiusNo
holderRadiusNo
safetyMarginNo
initialMotionNo
coordinateFrameYes
initialPositionYes
dwellPMillisecondsNo
defaultToolChangeSecondsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
okYes
dataNo
liveNo
toolYes
errorNo
receiptNo
documentRevisionNo
operationFingerprintNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.3.0

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already establish read-only, idempotent, and non-destructive behavior. The description adds meaningful scope context: it covers only bounded linear motion, flags unsupported motion, and returns 'reviewable' cycle-time evidence rather than a raw estimate. No contradiction with the annotations.

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?

A single sentence with no filler. The verb and primary resource are front-loaded, and the output categories are listed compactly. Every phrase contributes meaning.

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

Completeness2/5

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

Given the complexity (14 parameters, nested objects, 0% schema description coverage) and the close sibling tools, the description is too thin. It leaves 'bounded' unexplained, gives no guidance on required inputs, and does not route an agent toward or away from analysis siblings. The output schema covers return values, but the input and selection context are incomplete.

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?

Schema description coverage is 0% for 14 parameters, so the description carries the burden of explaining inputs. It does not mention program, units, coordinateFrame, initialPosition, machine, or any other parameter. Terms like 'feed/spindle limits' and 'rapid' only loosely map to machine fields, but this is insufficient for a parameter-rich schema.

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 ('Parse bounded G-code linear motion') and lists concrete outputs ('flag risky rapids, feed/spindle limits, unsupported motion, and reviewable cycle-time evidence'). The scope is clear enough to distinguish it from siblings like analyze_cycle_time and analyze_toolpath_risk.

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 implies a use case: analyzing a G-code program for motion risks and cycle-time evidence. However, it does not explicitly state when to use this tool versus closely related siblings like analyze_toolpath_risk or analyze_cycle_time, and it provides no exclusions or alternative guidance.

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