Skip to main content
Glama
Yaeshio

FreeCAD MCP

by Yaeshio

run_fem_analysis

Execute a finite element analysis with CalculiX on an existing FemAnalysis, returning maximum von Mises stress, displacement, and node count.

Instructions

Run the CalculiX solver on an existing Fem::FemAnalysis container and return summary results.

Prerequisites in the document:
- A Part-derived solid (e.g. Part::Box, PartDesign::Body) acting as the geometry.
- A Fem::AnalysisPython container created via `create_object`.
- A Fem::MaterialCommon assigned to the geometry, added to the analysis.
- A Fem::FemMeshGmsh referencing the geometry, added to the analysis (the
  mesh is generated automatically when created via `create_object`).
- At least one Fem::ConstraintFixed and one Fem::ConstraintForce (or
  ConstraintPressure) bound to faces of the geometry, added to the analysis.

A SolverCcxTools is auto-created if the analysis has none.

The solver runs synchronously on the FreeCAD GUI thread and blocks all
other RPC calls for its duration; do not fan out parallel requests.

Returns max von Mises stress (MPa), max/min displacement (mm), node count,
and the working directory CalculiX wrote to. On failure, returns the
prerequisite-check or solver error along with the working directory for
triage.

Args:
    doc_name: Name of the FreeCAD document.
    analysis_name: Name of the Fem::AnalysisPython object.
    timeout: Seconds to wait for the solver (default 600).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
doc_nameYes
analysis_nameYes
timeoutNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

The description discloses that the solver blocks the GUI and all RPC calls, and on failure returns the working directory for triage. However, it does not clarify whether the operation is read-only or modifies the document.

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?

The description is structured with prerequisites, behavior notes, return values, and args. It is front-loaded with the purpose. Although lengthy, each section serves a clear purpose.

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?

Given the complexity of the tool (FEM analysis, no annotations, 0% schema coverage), the description provides comprehensive prerequisites, behavior constraints, return field details, and error handling, making it complete.

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

Parameters3/5

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

The description lists the three parameters with minimal explanation: doc_name, analysis_name (referencing Fem::AnalysisPython), and timeout (default 600). It adds some context over the bare schema, but does not fully compensate for 0% schema coverage.

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 states it runs the CalculiX solver on an existing FemAnalysis container and returns summary results, distinguishing it from all sibling tools which are document management or object manipulation tools.

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

Usage Guidelines5/5

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

The description lists explicit prerequisites (geometry, material, mesh, constraints) and warns against fanning out parallel requests due to synchronous blocking behavior.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Yaeshio/FreeCAD-MCP-For-YDGA'

If you have feedback or need assistance with the MCP directory API, please join our Discord server