MCP server for Kratos Multiphysics: scaffold, run and post-process finite element simulations
Project description
Kratos MCP Server
An MCP server that lets AI assistants drive Kratos Multiphysics finite element simulations end to end:
- Introspect the installation: applications, elements, conditions, constitutive laws, variables, solvers and their default parameters.
- Scaffold simulation cases from templates: structural (static/dynamic/modal), thermal (transient/stationary) and fluid (transient incompressible) — ProjectParameters.json, Materials.json and structured MDPA meshes with named boundary regions.
- Run simulations as managed background jobs (status, live logs, progress, cancel) that survive server restarts.
- Post-process VTK results: summaries, point probes, convergence analysis.
- Preview results without ParaView: PNG screenshots and GIF animations
(deformed shapes, field contours) rendered with pyvista and shown inline
in the conversation — optional
vizextra.
33 tools, 7 resources and 4 guided prompts. See the full documentation in
docs/ (VitePress).
Quick start
A local Kratos build is not required — the server can pip-install Kratos itself on first use.
Once published to PyPI, no clone needed — uvx fetches and runs it:
claude mcp add kratos -- uvx kratos-mcp-server
From a local checkout (current state, before the first PyPI release):
git clone https://github.com/loumalouomega/Kratos-MCP-Server
cd Kratos-MCP-Server
uv sync
claude mcp add kratos -- uv --directory "$PWD" run kratos-mcp
Then ask your assistant something like:
Check the Kratos installation — install it if it's missing — then set up a cantilever plate 1 m × 0.2 m fixed on the left with a 1 MN/m downward load on the right edge, run it, and report the tip deflection.
The assistant calls kratos_install the first time and reuses it afterwards.
If you already have a compiled Kratos checkout, skip that and point
KRATOS_ROOT at it instead (-e KRATOS_ROOT=/path/to/Kratos on the claude mcp add line) — see Installation.
Requirements
- Python ≥ 3.10, uv
- Kratos Multiphysics, either pip-installed via
kratos_install(Linux/Windows x86_64 only — no macOS wheels) or a compiled build (tested with 10.4, StructuralMechanics / ConvectionDiffusion / FluidDynamics / LinearSolvers applications) - Optional, for
results_render/results_animate: thevizextra (uv sync --extra vizorpip install 'kratos-mcp-server[viz]') and a working OpenGL context (on headless machines: Xvfb or OSMesa VTK wheels — see docs/tools/visualization.md)
Architecture in one paragraph
Kratos is never imported in the server process — it prints a banner on import
(which would corrupt the stdio JSON-RPC stream) and can abort the process on
solver errors. Short operations run in a worker subprocess that returns
JSON through a result file; simulations run detached with per-job
directories under ~/.kratos-mcp/jobs/. See
docs/guide/architecture.md.
Development
uv run pytest -m "not kratos" # unit tests (no Kratos needed)
uv run pytest -m kratos # integration tests against the real build
npm install && npm run docs:dev # documentation site
License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file kratos_mcp_server-0.2.0.tar.gz.
File metadata
- Download URL: kratos_mcp_server-0.2.0.tar.gz
- Upload date:
- Size: 249.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4ab718cf06c5890a65f07fb9cf43f59a928c9a678d3f211f8557a9444f592942
|
|
| MD5 |
ca64baea4677da2100ee7b13ae0b13eb
|
|
| BLAKE2b-256 |
1e3a395276d1acdb56522cc7811d353aa52f057a1c3a347ea2e00ec4b0bc7566
|
Provenance
The following attestation bundles were made for kratos_mcp_server-0.2.0.tar.gz:
Publisher:
release.yml on loumalouomega/Kratos-MCP-Server
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
kratos_mcp_server-0.2.0.tar.gz -
Subject digest:
4ab718cf06c5890a65f07fb9cf43f59a928c9a678d3f211f8557a9444f592942 - Sigstore transparency entry: 2151028126
- Sigstore integration time:
-
Permalink:
loumalouomega/Kratos-MCP-Server@3b2739720b7e599f5a8ba47a03642eaf06b89545 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/loumalouomega
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@3b2739720b7e599f5a8ba47a03642eaf06b89545 -
Trigger Event:
push
-
Statement type:
File details
Details for the file kratos_mcp_server-0.2.0-py3-none-any.whl.
File metadata
- Download URL: kratos_mcp_server-0.2.0-py3-none-any.whl
- Upload date:
- Size: 66.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e46040fdc3bfb14e23db5d17721f0fad6ef1d8678f6424eda4d6861a0b4e45df
|
|
| MD5 |
c9ffc748c1e3fc59f054a55ab1fd5fe6
|
|
| BLAKE2b-256 |
800cf2f896f35367c5a8fc4d8e91292436665bd6e6eb7c480c26c6447e845f02
|
Provenance
The following attestation bundles were made for kratos_mcp_server-0.2.0-py3-none-any.whl:
Publisher:
release.yml on loumalouomega/Kratos-MCP-Server
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
kratos_mcp_server-0.2.0-py3-none-any.whl -
Subject digest:
e46040fdc3bfb14e23db5d17721f0fad6ef1d8678f6424eda4d6861a0b4e45df - Sigstore transparency entry: 2151028241
- Sigstore integration time:
-
Permalink:
loumalouomega/Kratos-MCP-Server@3b2739720b7e599f5a8ba47a03642eaf06b89545 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/loumalouomega
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@3b2739720b7e599f5a8ba47a03642eaf06b89545 -
Trigger Event:
push
-
Statement type: