Skip to main content
Glama
kompas-mcp

kompas-mcp

by biryak

Edit assembly

asm_edit
Destructive

Move, replace, or delete components and remove mates in a KOMPAS-3D assembly, with mate-aware placement and automatic restore if validation fails.

Instructions

Change what is already in an assembly (handles: inspect_model(sections=['components']) lists components with placement and the mates). action=move: place a component by numbers — origin [x,y,z] mm and/or its x_axis + z_axis directions; mates and fixed keep the coordinates they constrain (the answer shows held_by_mates). replace: put another file (path) in place of a component; its mates are re-evaluated (broken_mates lists the ones to re-create). delete: remove a component; delete_mate: remove a mate. Ask the user before deleting or replacing what they placed. Returns a receipt; one Ctrl+Z for the user; on a failed check the assembly is restored (VERIFY_FAILED).

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": {
      "doc": "<doc>",
      "action": "<action>",
      "target": "<target>"
    },
    "name": "asm_edit"
  }
}

Input Schema

NameRequiredDescriptionDefault
docYesAssembly document handle
pathNoreplace: .m3d/.a3d file inside the allowed roots
actionYes
originNomove: new origin of the component, mm
targetYesobj: handle of the component (or of the mate for delete_mate)
x_axisNomove: direction of the component's X axis in assembly coordinates
z_axisNomove: direction of its Z axis (perpendicular to x_axis)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.6.0

TDQS

A4.5/5.0
Behavior5/5

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

Annotations already flag destructiveHint=true and idempotentHint=false, but the description adds far more: a receipt is returned, the change is a single Ctrl+Z, and a failed check restores the assembly with VERIFY_FAILED. It also discloses side effects the annotations cannot express, such as mates being re-evaluated with broken_mates reported, and coordinates held by mates/fixed shown as held_by_mates.

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?

Front-loaded with the core statement and handle-discovery pointer, then per-action clauses. Dense but nearly every clause carries operational weight; the em-dash chaining makes it slightly harder to scan than it could be.

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 7-parameter destructive mutation with no output schema, it covers rollback, undo, verification failure, and mate consequences. The only gap is that 'Returns a receipt' is not elaborated, but the surrounding failure/undo behavior covers what an agent most needs before calling.

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 86%, so baseline is 3, but the description adds real meaning: origin in mm, x_axis/z_axis defining orientation while leaving mate-constrained coordinates untouched, path restricted to .m3d/.a3d in allowed roots, and target being a component handle versus a mate handle depending on delete_mate. The action-to-parameter coupling is documented in the description, not the 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 (change) and resource (assembly) and then enumerates all four operations (move, replace, delete, delete_mate) with concrete semantics for each. This cleanly separates it from siblings like asm_add_component and asm_mate without needing their schemas.

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?

Explicitly routes discovery of handles to inspect_model(sections=['components']) and gives a per-action condition ('Ask the user before deleting or replacing what they placed'). It never names asm_add_component as the tool for creating new components, so the add-vs-edit boundary is only implied by the opening 'Change what is already in an assembly'.

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