Skip to main content
Glama
RobertCoop

OpenSCAD MCP Server

by RobertCoop

scad_eval

Evaluate OpenSCAD expressions and return typed values (numbers, vectors, strings, booleans) within a model's variable scope. No geometry evaluated, precise to 6 digits.

Instructions

Evaluate OpenSCAD expressions and return typed values (number, vector, string, bool, range, undef). With scad_content/scad_file the expressions run in that model's variable and function scope, so "wall*2 + clearance" or "len(hole_positions)" work; without a model they run standalone. Numbers carry OpenSCAD's 6 significant digits. No geometry is evaluated.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
scad_fileNo
variablesNo
expressionsYes
scad_contentNo
include_pathsNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.6.1

TDQS

A4/5.0
Behavior4/5

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

With no annotations, the description carries the full burden. It discloses numeric precision (6 significant digits), scope behavior, and the boundary 'No geometry is evaluated.' It does not explicitly state whether the tool is side-effect-free or mention error handling, but it covers key execution behaviors.

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?

Four sentences with no filler. The core purpose leads, followed by scope context, a precision note, and a boundary statement. Every sentence earns its place.

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?

For a tool with five parameters and no annotations, the description does not fully document the roles of variables and include_paths, nor does it mention error behavior or security implications. The output schema covers return types, but the input-side gaps make it only adequately complete.

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 coverage is 0%, so the description should compensate for all parameters. It explains the role of scad_content/scad_file and implies expressions, but says nothing about variables (how they map into expressions) or include_paths (what they resolve). This leaves two of five parameters semantically underdocumented.

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?

The description opens with 'Evaluate OpenSCAD expressions and return typed values' – a specific verb and resource with a clear list of result types. It also explicitly states 'No geometry is evaluated,' which differentiates it from sibling tools like render and measure.

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

Usage Guidelines4/5

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

It explains when to pass scad_content/scad_file versus running standalone, which is useful context. However, it does not name alternative tools or explicitly state when not to use this tool, leaving the agent to infer exclusion from sibling names.

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