Skip to main content
Glama
kompas-mcp

kompas-mcp

by biryak

kompas-mcp

Локальный MCP-сервер для КОМПАС-3D v25 (COM API7). План: docs/plan/PLAN.md · фаза 0: docs/phase0/REPORT.md.

Работает с уже запущенным КОМПАС-3D того же пользователя: читает модели, строит и правит детали, заполняет основную надпись, выгружает STEP/IGES/STL/PDF/DXF/SVG. Каждое изменение проверяется (объём, ошибки дерева), делается бэкап, отменяется одним Ctrl+Z. Сетевых вызовов и телеметрии нет.

Последний выпуск — 0.6.0; описание ниже — по ветке main, история выпусков — в docs/release-notes.md. Руководство пользователя: docs/user/README.md. Отчёты по фазам: 2, 3, 4, 5, 6.

Требования

  • Windows 10/11 x64, КОМПАС-3D v25 с легальной лицензией. Сервер не запускает КОМПАС сам: откройте его до начала работы.

  • Любой MCP-клиент: Claude Desktop/Code, VS Code с Copilot, Cursor, Windsurf, Gemini CLI, Codex CLI, LM Studio и др. (см. «Подключение к ИИ-клиенту»); клиент и КОМПАС запускаются без «от имени администратора».

Related MCP server: solidworks-mcp

Установка (для пользователей)

Вариант 1 — одной командой (PowerShell, без прав администратора):

powershell -ExecutionPolicy Bypass -c "irm https://github.com/biryak/fresh-kompas-mcp/releases/latest/download/install.ps1 | iex"

Скрипт:

  1. Ставит uv, если его нет.

  2. Скачивает пакет последнего релиза и проверяет SHA256 по SHA256SUMS.txt релиза: пакет не подписан сертификатом, это его замена.

  3. Ставит пакет в отдельное окружение (uv tool install).

  4. Запускает самопроверку doctor.

  5. Спрашивает папки, с которыми серверу можно работать, и для каждого найденного ИИ-клиента — подключить ли его (Claude Desktop/Code, VS Code с Copilot, Cursor, Windsurf, Gemini CLI, Codex CLI, LM Studio). Конфиг Claude Desktop ищется там, где он есть: %APPDATA%\Claude у обычной установки или %LOCALAPPDATA%\Claude-Data\… у установки из пакета Windows; перед правкой любого конфига делается копия .bak-kompas-mcp.

  6. Добавляет папку программ uv в PATH (uv tool update-shell), если её там нет: команда kompas-mcp работает в новом окне терминала.

После установки перезапустите ИИ-клиент.

Параметры (-Version v0.6.0, -Roots "D:\CAD;E:\Projects", -Clients "cursor,vscode" — только эти клиенты без вопросов, -Wheel <файл .whl> — без скачивания, -Yes) и удаление передаются так:

& ([scriptblock]::Create((irm https://github.com/biryak/fresh-kompas-mcp/releases/latest/download/install.ps1))) -Uninstall

Вариант 2 — Claude Desktop, расширение. Скачайте kompas-mcp-<версия>.mcpb со страницы Releases и откройте его двойным щелчком. В настройках расширения укажите «Папки проектов». Нужен установленный uv. Claude Desktop покажет, что расширение не подписано: так и есть.

Вариант 3 — вручную (uv уже установлен). Ссылку на kompas_mcp-<версия>-py3-none-any.whl возьмите со страницы Releases и сверьте SHA256 с SHA256SUMS.txt:

uv tool install --python 3.13 <ссылка на .whl>
uv tool update-shell

Затем в новом окне терминала подключите клиент (см. ниже):

kompas-mcp connect --all --roots "D:\CAD"

Проверка (КОМПАС запущен):

kompas-mcp doctor --live

Подключение к ИИ-клиенту (Claude, ChatGPT/Codex, Gemini, Copilot, локальные модели)

kompas-mcp — обычный MCP-сервер (stdio), поэтому с ним работает любой клиент с поддержкой MCP и любая модель, которую этот клиент умеет вызывать. Установщик сам находит клиенты на компьютере и для каждого спрашивает, подключить ли сервер. Позже то же делает команда kompas-mcp connect:

kompas-mcp connect

покажет найденные клиенты и где сервер уже подключён;

kompas-mcp connect cursor --roots "D:\CAD;E:\Projects"

подключит один клиент (--all — все найденные; --profile read-only — только чтение). Отключить: kompas-mcp disconnect cursor (или --all). Перед первой правкой конфига клиента рядом сохраняется копия <файл>.bak-kompas-mcp; чужие записи и настройки не меняются. После подключения перезапустите клиент.

Клиент

id

Модели

Куда пишется

Claude Desktop

claude-desktop

Claude

claude_desktop_config.json (обычная установка или пакет Windows)

Claude Code

claude-code

Claude

claude mcp add -s user

VS Code + GitHub Copilot (режим агента)

vscode

GPT, Claude, Gemini — что доступно в Copilot

%APPDATA%\Code\User\mcp.json

Cursor

cursor

на выбор в Cursor

~\.cursor\mcp.json

Windsurf

windsurf

на выбор в Windsurf

~\.codeium\windsurf\mcp_config.json

Gemini CLI

gemini

Gemini

~\.gemini\settings.json

Codex CLI (OpenAI)

codex

GPT

~\.codex\config.toml (таймаут запуска 60 с, вызова 300 с)

LM Studio

lmstudio

локальные модели на вашем компьютере

~\.lmstudio\mcp.json

Любой другой MCP-клиент

—

—

блок для его настроек: kompas-mcp connect --print

Что учесть с другими моделями:

  • Модель должна уметь вызывать инструменты (tool calling). Из локальных подходят, например, Qwen3 и gpt-oss в LM Studio; маленьким моделям 45 инструментов даются плохо — начните с --profile read-only (8 инструментов: статус, документы, отчёт по модели, выбор граней, снимок).

  • Правила безопасности (перезапись файлов, закрытие документов, папки, PDM) проверяет сам сервер, а не модель: они действуют с любым клиентом. Подсказки сервера (instructions) и prompts часть клиентов не показывает — тогда попросите модель сначала вызвать kompas_status.

  • Снимки (view_capture) клиент без поддержки картинок получает только как размер изображения.

  • Данные уходят тому, кто обслуживает выбранную модель. С локальной моделью в LM Studio они остаются на компьютере; ограничения из руководства (ДСП/КТ/ГОЗ) решает служба ИБ.

Для разработчика

uv sync
uv run pytest

Живые тесты на КОМПАС: KOMPAS_INTEGRATION=1 uv run pytest tests/integration (открывают только новые документы). Релиз: тег vX.Y.Z → GitHub Actions собирает wheel, sdist, .mcpb, SHA256SUMS.txt и публикует Release.

KOMPAS_MCP_ROOTS задаёт папки, с которыми серверу разрешено работать; несколько папок разделяются ;. Машинная политика в HKLM\Software\Policies\kompas-mcp или %ProgramData%\kompas-mcp\policy.json (только admin) имеет приоритет; см. PLAN §9.

Инструменты

Инструмент

Что делает

kompas_status

Версия КОМПАС, лицензия, модальные окна, состояние воркера, политика

doc_list / doc_open

Список открытых документов и их handles; открытие файла (по умолчанию только для чтения). STEP/IGES импортируются в новую модель из временной копии (исходник не меняется); в ответе единицы файла (мм, дюймы…), габарит в мм и тела

inspect_model

Дерево построения, переменные, МЦХ (мм/кг, всегда свежие), габарит, свойства, исполнение, ошибки, имена по умолчанию; на спецификации — строки и свободные строки с id; на чертеже — листы, виды (масштаб, положение, модель), их размеры и технические требования

select

Грани и рёбра по геометрии (surface_type, radius_mm, normal, extreme, created_by, expect_count) или уже выбранные из справочника КОМПАС материалы; справочные данные с источником — резьба (kind="thread") и предельные отклонения (kind="fit") из таблиц КОМПАС

material_pick

Выбор материала в штатном окне КОМПАС и назначение детали; повторное назначение запомненного — part_set_properties(material_id=…)

selection_get

Что сейчас выделил пользователь

view_capture

PNG документа; view — спереди/сверху/изометрия и др., fit — показать всё; вид пользователя восстанавливается сразу после снимка

variables_set (чтение — inspect_model, obj= для переменных операции)

Переменные детали и операций; привязка параметров операций к переменным (expr); допуски (H7, h6… из базы допусков КОМПАС)

sketch_create

Эскиз целиком за один вызов (линии, прямоугольники, окружности, дуги, полилинии); по желанию параметрический: ограничения (горизонтальность, совпадение точек, касание, концентричность и др.) и управляющие размеры с переменными. into — дополнить готовый эскиз. Состав эскиза и его размеры — inspect_model(obj=…), новое значение размера — feature_edit(params={"W": 120})

aux_plane

Вспомогательная геометрия: плоскость со смещением, под углом через ось или ребро, через три точки; ось по двум точкам, ребру, двум плоскостям, оси цилиндра или конуса; точка по координатам

part_extrude / part_revolve

Бобышка/вырез выдавливанием или вращением; вырез «не в ту сторону» отклоняется

part_sweep_loft

Кинематическая операция (профиль по траектории: трубы, гнутые стержни) и операция по сечениям (переходы); бобышка или вырез

part_body

Многотельные детали: тело отдельным телом (new_body в выдавливании и вращении), объединение, вычитание, пересечение тел, отсечение плоскостью (остаётся сторона с указанной точкой), перенос и копия тела; список тел — inspect_model(sections=["bodies"])

part_thread_rib_draft

Условное изображение резьбы на валу или в отверстии (обозначение из таблицы резьб КОМПАС), ребро жёсткости, уклон граней

part_fillet_chamfer / part_shell / part_pattern

Скругление/фаска по рёбрам из селектора; оболочка; круговой/линейный/зеркальный массив

part_hole

Отверстие на плоской грани в точке at=[x, y] или по расстояниям от двух граней/рёбер; резьба (M8, M20×1,5 и др.) из базы резьб КОМПАС thread.db; конец 118° или плоский

feature_edit (в т.ч. delete) / part_set_properties

Параметры готовой операции (params: глубина, направление, «через всё», эскиз, угол и ось, радиус, катет, толщина, диаметр, число и шаг копий, смещение) — одним Ctrl+Z, с откатом, если ломается дерево; определение операции — inspect_model(obj=…); переименование, исключение, удаление операций; обозначение и наименование детали

batch

Несколько операций одним шагом Ctrl+Z, есть dry_run; вырез внутри — operation: "cut"

doc_create / doc_save / doc_close

Новый документ; сохранение с проверкой записи (замена чужого файла — только с согласия); закрытие без потери несохранённого

inspect_check

Проверка геометрии; measure=[a, b] — расстояние (мин./макс./по нормали), ближайшие точки, угол и взаимное положение граней, рёбер, осей, плоскостей, компонентов: толщина стенки, зазор, соосность

drw_set_stamp

Основная надпись: графы без источника в модели (фамилии, даты, организация); ассоциативные графы — из модели

export / job_status

Выгрузка заданием: STEP AP214/AP242, IGES, STL, PNG для моделей; PDF, DXF (мм), DWG (AutoCAD 2018, мм 1:1), SVG, PNG для чертежей. Исходники не меняются, в заголовках нет путей и имени пользователя

Prompts: review_model, create_part_from_spec, modify_parameter, fill_title_block, batch_export, make_drawing, assembly_bom, review_documents (сверка модели, чертежа, спецификации и ТЗ — роль въедливого корректора). Ревизия — inspect_model(sections=["review"]): на модели — чек-лист, на чертеже и спецификации — сверка с моделью и сборкой.

v1 (отчёт фазы 5)

Инструмент

Что делает

asm_add_component / asm_mate

Компоненты сборки из файлов и их сопряжения, в том числе симметрия (kind="symmetric", plane) — центрирование по замыслу

asm_edit

Перенести компонент числами (начало и оси; сопряжения держат то, что ограничивают), заменить файл компонента, удалить компонент или сопряжение — каждое одним Ctrl+Z. Положение компонентов и сопряжения — inspect_model(sections=["components"])

asm_check_collisions

Пересечения компонентов (пары и объём)

asm_bom

Состав изделия по разделам ГОСТ 2.106, выгрузка в .xlsx

embodiment

Исполнения: список, создание (-01, -02…), переключение

drw_create_views / drw_tech_requirements

Ассоциативные виды по ЕСКД с осевыми; технические требования и неуказанная шероховатость

drw_add_section / drw_add_dimension

Разрезы и сечения; ассоциативные размеры: линейные, угловые, диаметр, радиус; знаки шероховатости на поверхностях

drw_view_edit

Масштаб, положение, поворот и имя вида — одним Ctrl+Z; предупреждает, если вид вышел за рамку

drw_add_positions

Позиции (линии-выноски) на сборочном чертеже

drw_rebuild

Обновить чертёж после изменения модели; называет размеры, потерявшие привязку к изменённой модели

spec_create

Спецификация .spw по сохранённой сборке; export в xlsx/ods/pdf

spec_edit

Строки спецификации, которых нет в модели: документация, прочие изделия, материалы, комплекты — добавить, изменить, удалить (в Undo КОМПАС не попадает, в ответе есть before)

part_set_properties(spec_section=…)

Раздел спецификации детали: готовый файл крепежа → «Стандартные изделия»

Стандартные изделия ПОЛИНОМ

Вставляет пользователь из каталога КОМПАС; asm_components помечает их catalog="polynom", asm_bom и spec_create относят к «Стандартным изделиям»

Ресурсы

Ресурс

Что даёт

kompas://status, kompas://docs, kompas://materials

То же, что kompas_status, doc_list, материалы из справочника

kompas://doc/{handle}/{раздел}

Часть отчёта по документу (как inspect_model): tree, variables, mass, bbox, properties, errors, embodiment, naming; stamp — основная надпись

kompas://doc/{handle}/preview.png

PNG документа, как view_capture (около 800 px); отключается вместе со снимками (allow_screenshot)

kompas://api/{имя}, kompas://api/{имя}/{член}

Справка по интерфейсу или перечислению API КОМПАС (IPart7, ksObj3dTypeEnum) из библиотек типов установленного КОМПАС: члены строкой Имя(параметры) [get/put]; описание члена — вторым ресурсом

Материалы

Единственный источник — справочник материалов КОМПАС (ПОЛИНОМ:MDM). material_pick открывает штатное окно выбора КОМПАС, пользователь выбирает материал, сервер назначает его детали (одна запись Undo, бэкап, проверка массы) и запоминает в %LOCALAPPDATA%\kompas-mcp\materials_seen.json. part_set_properties(material_id=…) повторно назначает запомненный материал без окна. Своего списка материалов у сервера нет; если нужного материала нет в справочнике, его заводят в справочнике КОМПАС/ПОЛИНОМ (при наличии прав).

Available Tools

45 tools
asm_add_componentAdd componentA

Insert a part/assembly file into an assembly at its origin. Then position it with asm_mate (the first component is usually fixed=true). Component list and boxes: inspect_model(sections=['components']). Returns a receipt; one Ctrl+Z for the user; on a failed check the assembly is restored (VERIFY_FAILED).

Inputs: doc (required), path (required), fixed.

asm_bomBill of materialsA
Idempotent

Bill of materials of an assembly (top level) grouped by ГОСТ 2.106 sections: Сборочные единицы, Детали, Стандартные изделия — designation, name, quantity, material. Optionally written to .xlsx. This is NOT a KOMPAS specification document (.spw): use it as a check or a draft.

Inputs: doc (required), xlsx_path.

asm_check_collisionsCheck collisionsA
Idempotent

Interference check between components of an assembly (all top-level components by default). Reports each intersecting pair and its volume (mm3). Temporary check object: no Undo entry, no tree change.

Inputs: doc (required), components.

asm_editEdit assemblyA
Destructive

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).

Inputs: doc (required), action (required), target (required), path, +3 more.

asm_mateMate componentsA

Mate constraint between two references of components: faces/edges from select(created_by=) or obj: planes/axes. kinds: coincident (faces touch), concentric (axes of cylinders), parallel, perpendicular, tangent, distance (mm), angle (deg). The answer lists component boxes after the mate. Returns a receipt; one Ctrl+Z for the user; on a failed check the assembly is restored (VERIFY_FAILED).

Inputs: doc (required), kind (required), obj1 (required), obj2 (required), +3 more.

aux_planeAuxiliary plane / axis / pointA

Auxiliary geometry for sketches, holes and patterns at any angle. kind=offset: plane parallel to base at offset mm; angle: plane through line (axis/edge) at angle° to base; three_points: plane through points; axis: by two_points | edge | two_planes | face (axis of a cylinder/cone face); point: at [x, y, z]. Points are [x, y, z] mm (an auxiliary point is made for each) or handles of vertices/points. The first created handle is the plane/axis/point. Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), at, by, base, +8 more.

batchBatchA

Several operations as ONE atomic step (one Ctrl+Z): all succeed or the model is restored. Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), ops (required), dry_run.

doc_closeClose documentA
Destructive

Close a document. A document with unsaved changes is closed only with save=true or discard_changes=true; otherwise CONFIRMATION_REQUIRED tells you to ask the user.

Inputs: doc (required), save, discard_changes.

doc_createCreate documentA
Idempotent

Create a new, unsaved KOMPAS document (default template) and make it active. Save it with doc_save(path=…) — ask the user where.

Inputs: kind (required).

doc_listList open documentsA
Read-onlyIdempotent

Documents open in KOMPAS with their handles, type, path, active/changed/read-only flags. Handles change when the server reconnects; always take fresh ones from here.

Inputs: no named parameters.

doc_openOpen documentA
Idempotent

Open a KOMPAS document (.m3d/.a3d/.cdw/.frw/.spw) from an allowed root. Opens read-only by default. Returns the document handle. If the file is already open, returns its existing handle. STEP/IGES (.stp/.step/.igs/.iges) are IMPORTED: a new model in mm is created from a temporary copy (the source is never modified); the answer has import.source_units read from the file header (e.g. inch), the bounding box in mm and the imported bodies. Imported bodies have no feature history.

Inputs: path (required), read_only.

doc_saveSave documentA
Destructive

Save a document in place, or Save As to a new path (the handle changes: use the returned one). An existing file is never replaced without overwrite=true. PDM folders and read-only files are refused. The file on disk is verified after saving.

Inputs: doc (required), path, overwrite.

drw_add_dimensionAdd dimensionsA

Associative dimensions on a drawing view; points are MODEL coordinates (mm, model origin, e.g. from inspect_model/select), projected onto the view. Put points on real edges/vertices of the part so the dimension binds to the geometry and follows model changes (result associative). linear: p1, p2 (+ diameter_sign for ⌀ of a shaft on its side view); diameter/radius: center + radius of a circle seen as a circle in this view; angle: vertex + a point on each line (chamfers, slopes); roughness: p1 on the surface's edge + text (values from the user, ГОСТ 2.309). All dimensions of one call = one Ctrl+Z. Check with view_capture; inspect_model on the drawing lists what is there.

Inputs: doc (required), view (required), dimensions (required).

drw_add_positionsAdd position leadersA

Position leaders (ГОСТ 2.109) on an assembly drawing: shelves lined up in one column/row beside the view, ordered so the leader lines do not cross; one Ctrl+Z. Check with view_capture.

Inputs: doc (required), view (required), items (required), gap, +2 more.

drw_add_sectionAdd sectionA

Cutting line A-A on an associative view and the section view (разрез) or cross-section (сечение) built from it, in the base view's scale; one Ctrl+Z. Check the result with view_capture.

Inputs: doc (required), line (required), base_view (required), x, +3 more.

drw_create_viewsCreate drawing viewsA

Add standard ASSOCIATIVE views of a saved model to a drawing (they follow model changes), with centre lines. Check the layout with view_capture. Sections: drw_add_section. Dimensions: drw_add_dimension.

Inputs: doc (required), model_path (required), x, y, +4 more.

drw_rebuildRebuild drawingA

Update a saved drawing after its model changed: reopens it so the associative views AND dimension values follow the saved model (answers KOMPAS «Перестроить чертеж?» with «Да»). Save the model first. Returns the dimensions whose values changed and unbound_dimensions: dimensions whose edge/face the model change replaced (e.g. a cut makes a new end face) lose their binding and keep the OLD value while the view is up to date — delete and re-add them with drw_add_dimension, or tell the user.

Inputs: doc (required), save.

drw_set_stampFill title blockA

Fill title-block (основная надпись) cells that have no source in the model. In a drawing with associative views, name/designation/material/mass come from the model and are refused — set them with part_set_properties / material_pick and call this with refresh=true. Values are read back.

Inputs: doc (required), cells (required), sheet, refresh.

drw_tech_requirementsTechnical requirementsA

Replace the drawing's technical requirements (технические требования) with these lines and/or set the general roughness; read back. Heat treatment, coating, unspecified tolerances come from the user — a 3D model does not hold them.

Inputs: doc (required), lines, general_roughness.

drw_view_editMove / scale viewA

Change a drawing view: scale, position, rotation, name — one Ctrl+Z; dimensions keep their values. Warns when the view then sticks out of the sheet. Check the layout with view_capture.

Inputs: doc (required), view (required), x, y, +3 more.

embodimentEmbodimentsA

Embodiments (исполнения, ГОСТ 2.113) of a part/assembly. action=list: all with marking, number, mass. create: new embodiment with number like '01' (marking = base marking + '-01'); it becomes CURRENT. activate: make embodiment index current. Variables (variables_set) and properties set afterwards apply to the CURRENT embodiment only — create the part variables BEFORE the first embodiment (KOMPAS refuses new variables in a dependent embodiment). Creating is one Ctrl+Z; switching is not undoable (as in KOMPAS).

Inputs: doc (required), index, action, number.

exportExportA

Export documents to exchange formats as a background JOB (one checkpoint per file): returns the job state after wait_s; poll job_status(job_id) until status is done/partial/failed. Sources are never modified. File names: . in out_dir. STEP/IGES headers carry no local paths or Windows user name. Drawings are exported from their saved file (save first).

Inputs: formats (required), out_dir (required), sources (required), author, +4 more.

feature_editEdit / delete featureA
Destructive

Change an existing feature: params = its parameters, as listed by inspect_model(obj=…) under definition.params / editable — extrusion {depth, depth2, direction normal|reverse|both|middle, through, sketch}, revolve {angle, axis}, fillet {radius}, chamfer {distance, angle}, shell {thickness, outward}, hole {diameter, depth, through}, circular_pattern {count, step (null = even over 360°), axis}, linear_pattern {count, step, axis}, offset_plane {offset, reverse}, sketch {: mm or an expression such as a part variable name}; one Ctrl+Z, and the call is rolled back if this or any other feature breaks. To keep a parameter driven by a part variable use variables_set(expr) instead. Also: rename, exclude from / include in the calculation, or delete (delete=true: dependent features may break — then the call is rolled back; ask the user before deleting anything they built). NOTE: renaming is not undoable by Ctrl+Z in KOMPAS. Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), obj (required), delete, params, +2 more.

inspect_checkCheck geometry / measureA
Idempotent

KOMPAS geometry check of a part (open edges, self-intersections, tiny objects, spikes...), or with measure the distance between two objects: min/max distance (mm), the closest points, the angle and their relation (surfaces_parallel, axes_coaxial, …; normal_distance_mm for parallel ones) — e.g. a wall thickness, the gap between assembly components, whether a hole is coaxial. Temporary objects only: no Undo entry, no tree change, the «changed» flag is kept. Collisions: asm_check_collisions.

Inputs: doc (required), checks, measure, linear_tolerance_mm.

inspect_modelInspect modelA
Read-onlyIdempotent

Read-only report on a part/assembly: feature tree (object handles, validity, errors), variables (with tolerances), mass properties in mm/kg (fresh, never cached), bounding box, properties (designation/name/material), active embodiment, rebuild errors and default-named features. 'review' adds a deterministic checklist (broken features, default names, missing designation/name/ material, manual mass, variables without notes) — the basis of the review_model prompt. On a DRAWING (.cdw) the report is the drawing itself: sheets, views (number, scale, position, angle, source model, section), their dimensions (kind, value, tolerance, associative) and technical requirements; with 'review' it is cross-checked against its model (hand-typed dimension values, unbound dimensions, title block vs model properties/mass, scale, views off the sheet). On a SPECIFICATION 'review' compares its rows with the attached assembly's components and quantities (the assembly must be open). Leaves no Undo entry and does not mark the document as changed. Also clears NEEDS_REVIEW.

Inputs: doc (required), obj, page, sections.

job_statusJob statusA
Read-onlyIdempotent

Status of a long-running job (export returns a job id): done/failed/pending counts and the result of every finished item (each is a checkpoint). Job ids live as long as the server process.

Inputs: job_id (required), wait_s.

kompas_statusKOMPAS statusA
Read-onlyIdempotent

Connection and environment status: KOMPAS version/build/PID, licence variant, open modal dialog, worker state (generation, restarts, documents flagged needs_review) and the effective security policy (managed/unmanaged/untrusted, profile, roots). Call this first and after any error.

Inputs: no named parameters.

material_pickPick material in KOMPASA

Open KOMPAS's own material handbook dialog so the USER chooses the material (the handbook is the source of truth for name and density). Tell the user the dialog is open and wait. If doc is given, the material is assigned to the part with a backup and a mass check (receipt). NOTE: KOMPAS does not record material changes in Undo (Ctrl+Z will not revert it); to revert call part_set_properties(material_id=restore_material_id). The choice is remembered: later part_set_properties(material_id=…) assigns it without the dialog.

Inputs: doc.

part_bodyBodies: boolean / cut off / moveA

Multi-body parts (bodies come from part_extrude/part_revolve with new_body=true; list them with inspect_model(sections=['bodies'])). kind=boolean: base body + tool bodies, operation union | difference (base minus tools) | intersect. kind=cut_off: cut the part by a plane and keep the side with keep_point. kind=move: shift bodies by offset [dx, dy, dz] mm, copy=true keeps the originals. Verified by volume/bodies. Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), kind (required), base, copy, +7 more.

part_extrudeExtrudeA

Boss or cut extrusion of a sketch. Verified: boss must add volume, cut must remove it; a cut that goes away from the material is rejected (then try direction='reverse'). Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), sketch (required), op, name, +5 more.

part_fillet_chamferFillet / chamferA

Fillet or chamfer on edges chosen by geometry (never by index). Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), kind (required), size (required), edges (required), +2 more.

part_holeHoleA

Hole feature on a planar face (appears as «Отверстие» in the tree), optionally with a cosmetic thread from KOMPAS's own thread database (ГОСТ 24705-2004 by default: 'M8' = coarse pitch, 'M20x1.5' = fine). Position: at=[x, y] — a point on the face (on faces parallel to XY these are the global X, Y; required for round faces, which take no references) — or distances dist1/dist2 from two references ref1/ref2. With a thread and no diameter the hole diameter is the thread's minor diameter D1 from that database (M8 -> 6.647); pass diameter to use a tap drill instead (e.g. 6.8 for M8). Verified: the volume must shrink; receipt.removed_centroid_mm shows where the hole axis landed. For several identical holes use part_pattern on the result. Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), face (required), at, end, +11 more.

part_patternPatternA

Circular / linear / mirror pattern of features. Circular without step = copies evenly over the full circle, and they stay even when the count changes — to drive the count by a variable n, bind only the pattern's count variable (expr 'n') via variables_set. A given step is the angle (circular) or distance (linear) between ADJACENT copies. Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), kind (required), features (required), axis, +4 more.

part_revolveRevolveA

Boss or cut by revolution of a sketch about an axis (shafts: axis X, sketch on XY). Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), sketch (required), op, axis, +3 more.

part_set_propertiesPart propertiesA

Set the part's designation (обозначение, ГОСТ Р 2.201) and name (наименование) in the MODEL, so the title block and the BOM follow them associatively. Never invent a designation: take it from the user. Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), name, marking, material_id, +1 more.

part_shellShellA

Hollow the body leaving walls of the given thickness; listed faces become openings. Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), faces (required), thickness (required), name, +1 more.

part_sweep_loftSweep / loftA

kind=sweep (кинематическая операция): a closed profile sketch moved along a path — a path sketch and/or edges that START on the profile's plane (pipes, springs, bent rods). kind=loft (по сечениям): a body through 2+ closed section sketches in order, each on its own plane (aux_plane), e.g. a round-to-square transition. Verified like extrusions: boss must add volume, cut must remove it. Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), kind (required), op, name, +5 more.

part_thread_rib_draftThread / rib / draftA

kind=thread: cosmetic thread (условное изображение резьбы, ГОСТ 2.311) on a cylindrical face — a shaft (outer, face Ø = d) or a bore (inner, face Ø = drill d1); designation 'M20' / 'M20x1.5' is looked up in KOMPAS's thread table. kind=rib: rib (ребро жёсткости) from a sketch with an open line running between two walls, symmetric thickness. kind=draft: draft (уклон) of faces about a neutral plane/face, inward (removes material) unless outward=true. Verified: rib adds volume, draft moves it the chosen way, the thread is valid and reads back its designation. Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), kind (required), base, face, +11 more.

selectSelect geometry / reference dataA
Read-onlyIdempotent

Find faces/edges by geometric properties (never by index), materials already taken from KOMPAS's handbook, or REFERENCE DATA with its source (thread, fit) — quote such values from here, never from memory. Face/edge results are 'topo:' handles valid only for the returned model revision. With expect_count, a mismatch returns SELECTION_MISMATCH listing all candidates with their attributes.

Inputs: doc, kind, query, normal, +6 more.

selection_getGet user selectionA
Read-onlyIdempotent

What the user has currently selected in KOMPAS (faces/edges as topo handles, features as obj handles). Use this when a selector is ambiguous: ask the user to click the object, then call this.

Inputs: doc (required).

sketch_createCreate sketchA

Create a whole sketch in ONE call (it is never left open in edit mode), optionally parametric: constraints and DRIVING dimensions whose variables change the sketch later (feature_edit(obj=sketch, params={var: value}) or tie them to part variables with expr). into=obj:sketch adds entities/constraints/dimensions to an existing sketch. inspect_model(obj=sketch) reads its geometry, dimensions and constraint state. Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), into, name, plane, +4 more.

spec_createCreate specificationA
Destructive

Specification (спецификация, ГОСТ 2.106) of a SAVED assembly: a new .spw with the assembly attached; KOMPAS fills the sections, positions, designations, names and quantities from the components and the title block from the assembly. Returns the rows (check them against asm_bom). Saved to path.

Inputs: path (required), assembly (required), overwrite.

spec_editSpecification rowsA
Destructive

Rows of a specification (.spw) that do not come from the model: Документация, Прочие изделия, Материалы, Комплекты (ГОСТ 2.106). inspect_model on the .spw lists them with ids (free_rows). Positions are filled by KOMPAS by its own settings. NOTE: KOMPAS keeps no Undo for specification rows — the result has before; delete rows only with the user's consent.

Inputs: doc (required), add, edit, delete.

variables_setSet variablesA

Create/change part variables and bind feature parameters to them (parametric model). Returns a receipt: created object handles, volume/mass before and after, backup path. The whole call is ONE Ctrl+Z for the user; if verification fails the model is restored and VERIFY_FAILED is returned.

Inputs: doc (required), items (required).

view_captureCapture viewA
Read-onlyIdempotent

PNG image of the document as KOMPAS renders it. By default the user's current view; view/fit turn the view for this snapshot only — the user's orientation and zoom are restored right after (they may see a short flicker). Front = XY plane (ГОСТ 2.305 главный вид), top = ZX.

Inputs: doc (required), fit, size, view.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.8/5.0

    Scored across 45 tools

    Disambiguation4/5

    Each tool targets a distinct CAD operation, and domain prefixes (part_/drw_/asm_/spec_/doc_) plus explicit descriptions separate the modeling, drawing, assembly and specification surfaces. A few near-pairs remain — select vs selection_get, inspect_model vs inspect_check, asm_bom vs spec_create, feature_edit vs variables_set — but the descriptions draw clear lines between them.

    Naming Consistency3/5

    There is a recognizable domain-prefix scheme (part_extrude, drw_add_dimension, asm_mate, doc_open), but verb ordering is mixed: noun_verb forms (sketch_create, variables_set, material_pick, selection_get) coexist with verb_noun forms (doc_save, doc_close, view_capture). Several tools carry no domain prefix at all (select, batch, export, embodiment, aux_plane, feature_edit), so the pattern is readable but not uniform.

    Tool Count3/5

    45 tools is heavy and well above the comfortable range for an agent, risking navigation and selection cost. However, the scope genuinely spans 3D modeling, assemblies, drawings, specifications, documents and export, and each tool maps to a real, non-redundant operation rather than being filler.

    Completeness4/5

    Coverage is unusually deep: sketching, all major solid features, patterns, booleans, mates and components, drawing views/dimensions/sections/positions/title block, specifications, save/open/close, export with job polling, and read-only inspection/verification. Minor gaps exist — no way to edit or delete an existing drawing dimension (only add), and limited drawing sheet/template management — which agents can work around.

    Maintenance

    ActivityNo data
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      Connects Claude to a running Autodesk Civil 3D instance via COM automation to perform drawing, surface, alignment, COGO point, line, and corridor operations.
      13
      MIT
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables Claude Desktop to connect to SolidWorks via the COM API for automated sheet metal part analysis, including inspecting thickness, holes, bends, and exporting flat patterns as DXF.
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      Connects Claude Desktop to a running AutoCAD instance over local Windows COM, letting users query, draw, edit, organize layers, measure areas, take off quantities, and export sheets to PDF using plain language. Every action is undoable, logged, and optionally restricted to read-only mode with no network exposure.
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables an AI assistant to control KOMPAS-3D through its COM API, including opening and saving documents, building parts and assemblies, measuring models, and creating dimensioned drawings.
      1
      MIT