Skip to main content
Glama

cad_edit_existing

Modify existing CAD models by applying validated instruction lists to dimensions, variables, features, properties, and materials, then rebuild and return before/after changes.

Instructions

修改现有模型。edits 为指令列表: {"op":"set_dimension","name":"D1@凸台-拉伸1","value":20} / {"op":"set_variable","name":"pitch","value":180} / {"op":"suppress","feature":"圆角1","suppressed":true} / {"op":"set_property","name":"Description","value":"..."} / {"op":"set_material","material":"AL6061-T6"}。 先校验(名称存在、方程式驱动的尺寸要改变量、变化幅度);dry_run=true 只校验。执行后重建,出错不保存; 成功则返回改前改后对比(尺寸/质量/包围盒),并自动更新引用它的装配和工程图、检查悬空标注。 每次修改前自动建检查点(rollback_to)。发布后可用 cad_change_writeback 回写原位置。

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": {
      "file": "<file>",
      "edits": "<edits>"
    },
    "name": "cad_edit_existing"
  }
}

Input Schema

NameRequiredDescriptionDefault
fileYes
editsYes
dry_runNo

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior5/5

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

Annotations only say it is a non-read-only, non-destructive, non-idempotent mutation; the description adds far more: pre-flight validation of names and magnitude, rebuild after execution, no save on error, automatic checkpoint creation before each edit with rollback_to, return of before/after dimension/mass/bounding-box comparison, cascade updates to referencing assemblies and drawings, and dangling-annotation checks. That is exactly the behavioral detail annotations cannot convey.

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?

Purpose is front-loaded in the first clause, then structured as an op catalogue followed by behavioral notes. The op examples are dense but each one earns its place by demonstrating a payload shape the schema cannot express; only the final writeback sentence is somewhat tangential.

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 an output schema and zero schema description coverage, the description covers the full lifecycle – validation, dry-run, execution, rebuild, failure handling, checkpoint safety, cascade propagation, and result shape. An agent knows what will be changed, what happens on failure, and what it gets back.

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%, so the description must carry the parameter cost, and it does for edits by showing five concrete op payloads including which names go into which keys, plus what values mean (e.g. equation-driven dimensions require set_variable). dry_run is also explained semantically. The file parameter is never clarified (path vs. open document handle), which is the one remaining ambiguity.

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?

"修改现有模型" gives a specific verb+resource and the following op enumeration (set_dimension / set_variable / suppress / set_property / set_material) makes the scope of the modification concrete. It also names cad_change_writeback as the follow-up tool, but it never distinguishes itself from sibling mutators like cad_set_parameters, so an agent must infer the boundary from names alone.

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 explicitly states that dry_run=true performs validation only, which is a usable when-to-use rule, and it names cad_change_writeback as the tool for writeback after publish. It stops short of exclusions – there is no statement about when to prefer cad_set_parameters or cad_validate over this tool.

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