
AgentFEM
io.github.haoming-luoPublished by GitHub account haoming-luov0.1.0Updated Oct 24, 2026
Build, run, inspect, and verify finite-element simulations with AgentFEM.
Overview
AgentFEM MCP lets an AI assistant build, validate, run and inspect finite-element simulation projects through the AgentFEM scientific engine.
- What you can do
- Inspect the installed AgentFEM runtime and its capability map, and create projects from version-matched templates. Validate projects, reporting process success and scientific acceptance separately. Read project and recent-run identity. Launch isolated serial or MPI simulation runs and poll their durable background status. Read compact result summaries and trust state, requesting full evidence only when needed.
- When to use it
- Use it when you want an assistant to set up and run finite-element studies with AgentFEM while keeping projects, runs and numerical evidence inspectable, rather than hand-driving the solver CLI.
- Requirements
- Runs locally over stdio via uvx from the agentfem-mcp PyPI package (or pip install). AgentFEM itself must already be installed; AGENTFEM_COMMAND can point to its executable. AGENTFEM_MCP_ROOTS should list approved project roots; without it, access is limited to the working directory. Desktop clients on macOS or Linux can use the .mcpb bundle; Windows needs the WSL2 setup.
Installation
In SourceWeft
- Open AgentFEM in the dashboard and add it to a workspace.
- Enable the server for the chats that should use its tools.
Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.
Other MCP clients
Follow the launch instructions in the repository.
README
AgentFEM MCP
[CI] [PyPI] [MCP Registry] [AgentFEM MCP server]
One finite-element platform. Any compatible agent. Evidence intact.
AgentFEM MCP gives Codex, Claude, and other MCP-compatible agents a small, stable tool surface for building and running inspectable finite-element projects. AgentFEM remains the deterministic scientific engine; the agent interprets intent and explains evidence.
Install from PyPI · Discover in the official MCP Registry · Read the AgentFEM agent guide
For a supported desktop client on macOS or Linux, download the tiny
AgentFEM-0.1.0.mcpb connection bundle from the
0.1.0 release.
It installs only the interface; the AgentFEM scientific runtime remains the
single source of solver capabilities, upgrades, and results.
It exposes seven tools—not hundreds of solver internals:
Bring it to life
Want to see the underlying workflow before installing?
- Explore a 3D structural-design case: compare support weight and deflection under the same load. The public browser edition uses precomputed candidates.
- Try the simulation-to-surrogate mini-lab: ten real FEM outputs, a small NumPy model, and an interactive notebook.
- Follow the AI-assisted cantilever quick start: create a readable project, run it, and inspect its numerical result.
AgentFEM must already be installed. With uvx, Codex needs one command and the
adapter remains isolated from the numerical environment:
Or install the lightweight adapter in the active environment:
The 0.1.0 lifecycle is acceptance-tested with the public AgentFEM 0.3.3 CLI contracts and the current 0.3.7 development line.
Give your agent a project root, not your whole home directory.
Codex
Codex officially supports local stdio MCP servers. Confirm the connection with
codex mcp list, then begin with:
Use AgentFEM to create, validate, run, verify, and briefly explain a 2D cantilever. Keep the project and result paths visible.
Claude Desktop and compatible clients
On macOS or Linux, open the release's .mcpb file in a supporting desktop
client and choose the one project folder the connection may access. AgentFEM
must already be installed. Windows support currently uses the explicit WSL2
configuration from the AgentFEM guide rather than claiming a native bridge.
Claude Code:
Claude Desktop configuration:
If a desktop app cannot see the activated conda environment, set
AGENTFEM_COMMAND to the absolute agentfem executable. The official macOS
runtime, AgentFEM WSL2 runtime, and common agentfem-env/fenicsx-env layouts
are also detected automatically.
VS Code and other models
VS Code can place the same local server in .vscode/mcp.json:
The server is model-neutral. A DeepSeek or other model can use it through any host that implements local MCP tools. ChatGPT connectors require a public HTTPS server; AgentFEM will add that route only with a real authenticated compute and artifact boundary, rather than silently uploading local models through this adapter.
Directory health image
The repository's minimal, unprivileged Dockerfile exists for MCP directory
startup and tool-introspection checks. It intentionally contains the public MCP
adapter, not a second AgentFEM solver distribution. Real simulations should use
the installed AgentFEM runtime and an explicit local project root.
Local Codex plugin
This repository contains a portable AgentFEM workflow skill and a local Codex
marketplace under .agents/plugins/. It combines scientific operating guidance
with the same MCP server; it does not create a second solver interface.
The contract
- No language model or API key is embedded in AgentFEM MCP.
- No shell command or arbitrary Python string is accepted from a tool call.
- All project paths must remain under explicitly approved roots.
- Numerical runs occur in child processes, isolating PETSc/MPI lifetime from the MCP server.
completed,verified, andvalidatedremain different scientific states.- Compact system discovery preserves AgentFEM's website, repository, citation, and its consent-first, once-per-release-series community invitation. The MCP server never performs an account action for the user.
Environment controls
With no root configured, the server restricts access to its working directory. The default maximum is 16 MPI ranks and can only be changed by the server operator, not by an agent tool call.
Development
See SECURITY.md for the trust boundary and CONTRIBUTING.md for contribution expectations. The first release evidence records protocol, package, and real-solver acceptance separately.
AgentFEM MCP is Apache-2.0 licensed and maintained as an official companion to AgentFEM.
Source: README.md at commit 5d17b48
Tools
0Version history
1- v0.1.0LatestSep 16, 2026
Score
40% of the applicable checks met
How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.
- Reached in the last 30 days25 pts
Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.
- Auth declared10 pts
Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.
- Tools listed15 pts
Answer tools/list without a credential, or ship a package that starts in a sandbox without one.
- DescriptionRequired15 pts
- Logo10 pts
- Documentation15 pts
- License10 pts
Declare a license in the repository or the registry entry.