Skip to main content
Glama
FullyDefined – AI for SOLIDWORKS

FullyDefined – AI for SOLIDWORKS

set_equation

Sets a global variable or dimension equation in a SOLIDWORKS model and rebuilds it, rolling back changes that break the model.

Instructions

Set an equation and rebuild. name is a global variable ('Wall'; created when new) or a dimension ('D1@Sketch1'); alternatively give index from list_equations. expression is the right-hand side, e.g. '3mm' or '"Wall" * 2'; a number without a unit is in the document's unit (20 is 20 inch in an inch document). A change that breaks the model is rolled back. A size the tools dimensioned from the drawing (DrawnN) becomes the user's when an equation drives it: it is renamed (the result says to what).

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": {
      "expression": "<expression>"
    },
    "name": "set_equation"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameNoGlobal variable (e.g. 'Wall') or dimension (e.g. 'D1@Sketch1')
indexNoIndex of an existing equation (instead of name)
expressionYesRight-hand side, e.g. '3mm', '"Wall" * 2'

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

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

With no annotations supplied, the description carries the full behavioral burden and does so well: it discloses that the model is rebuilt, invalid changes are rolled back, units have document-specific defaults, and driven drawing dimensions may be renamed.

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?

The description is front-loaded with the core action and then layers parameter and behavioral details efficiently. Despite being dense, every clause adds useful information for invoking the tool correctly.

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

Completeness5/5

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

For a mutation tool with no annotations or output schema, the description covers the important behavioral context: rebuild, rollback, unit handling, and dimension renaming. An agent has enough information to use the tool correctly without needing additional structured metadata.

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

Parameters5/5

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

Schema coverage is already 100%, and the description still adds meaningful semantics beyond the schema: 'name' can create a new global variable, 'index' is an alternative sourced from list_equations, and unitless expressions inherit the document's unit.

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 a specific verb and resource: 'Set an equation and rebuild.' It makes the tool identifiable apart from list_equations by explaining how to specify an existing equation via name or index.

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 gives clear guidance on how to address the equation using name or index, including that a global variable is created when new and that list_equations provides an index. It does not explicitly compare this tool with alternatives such as set_dimension, so there is no full when-to-use versus when-not-to-use treatment.

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