Yade MCP logo

Yade MCP

by yusong652

Connects AI agents to YADE for API discovery, live Python execution, and managed discrete-element simulations.

Install Yade MCP

Pick your client, then add it in one click or paste the config.

STDIOPython
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "yusong652-yade-mcp": {
      "command": "uvx",
      "args": [
        "yade-mcp"
      ]
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

Install not yet sandbox-tested— the server itself is confirmed live (we called its tools/list endpoint). The stdio install command is a separate, ongoing check.

Overview

yusong652/yade-mcp connects MCP clients to YADE, an open-source discrete element method engine for granular and particle simulation. It exposes YADE API browsing and BM25 keyword search, plus synchronous code execution and queued background tasks with status, history, and interruption controls. Documentation tools work without the bridge; execution tools connect to a running YADE process through the bridge. Reach for it when an agent needs to inspect YADE classes, develop simulation code interactively, or manage long-running runs.

Use cases

  • Search YADE classes for material, contact, gravity, or stress APIs
  • Prototype simulation changes in a persistent YADE REPL
  • Submit long-running granular simulations as background tasks
  • Inspect intermediate state while a simulation continues
  • Review, cancel, or resume queued simulation work

Key features

  • YADE class-tree browsing
  • BM25 API documentation search
  • Persistent synchronous Python REPL
  • Queued background simulation tasks
  • Task status, history, and interruption controls
  • Shared YADE simulation state

Tools7

What Yade MCP lets your agent do. Expand a tool for its parameters.

Verified live~2.0k tokens of context

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked 2d ago

Recent health check succeeded.

35/35 checks healthy over the last 81d

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 9d ago via OSV.dev · yade-mcp (PyPI)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars15Stargazers on the source repository.
Last commit7d agoMost recent push to the default branch.
Tools exposed7Callable tools this server registers over MCP.
Directory activity1 upvotesConfig copies, upvotes, and views on AllMCPs.

How Yade MCP works

What yusong652/yade-mcp does

yusong652/yade-mcp gives MCP-compatible agents access to YADE’s Python API and a live YADE simulation environment. YADE is an open-source discrete element method engine used for granular and particle simulation. The server covers both API discovery and execution workflows, so an agent can find the relevant class before using it, test code in a session, or submit a longer simulation for background processing.

Its documentation functions expose YADE’s native class hierarchy and a keyword search over API documentation. The browser follows each class’s real inheritance path to its category root. Search uses BM25 ranking and returns matching class or function names with descriptions.

How it works

The server provides seven MCP tools. yade_browse_api and yade_query_api do not require a bridge. The five execution tools communicate with the YADE MCP bridge running inside YADE’s Python environment.

yade_execute_code runs Python synchronously in the active YADE process. Calls share the YADE __main__ namespace, so variables and simulation state persist between calls. The tool can inspect state while a background task is running, but it is intended for short operations and interactive testing.

For longer work, yade_execute_task submits a script and returns a task ID. Tasks run one at a time in submission order and share a single YADE process and simulation state. yade_check_task_status reports output, progress, and final status; yade_list_tasks provides paginated task history; and yade_interrupt_task stops a running task or removes a queued task. Interrupted scripts preserve state that was already created in the shared YADE namespace.

Setup and configuration

Install YADE and uv, then register the MCP server with an MCP client using uvx yade-mcp. The repository gives commands for Claude Code, Codex CLI, and Gemini CLI, along with a generic MCP configuration using uvx as the command.

The bridge must be installed into the Python interpreter embedded by YADE, not an unrelated virtual environment. From the YADE console, install yade-mcp-bridge with that interpreter, restart YADE, and run:

server.ts
import yade_mcp_bridge
yade_mcp_bridge.start()

The bridge listens on port 9002 by default. Pass another port to start(port=...) and configure the MCP server with the matching --bridge-url. For containerized YADE, bind the bridge to 0.0.0.0 and publish the selected port.

Tools and capabilities

  • Browse YADE’s inheritance-based Python class tree.
  • Search API documentation by terms such as friction material, gravity engine, or contact force.
  • Execute short Python snippets and inspect persistent simulation state.
  • Queue long simulations and multi-stage scripts.
  • Poll output, review task history, and cancel queued or running work.
  • Continue examining the YADE namespace after an interrupted task.

Use background tasks for operations expected to take more than a few seconds. A synchronous call that times out may leave YADE partially modified or the bridge unresponsive, depending on where interruption occurs. Code should not catch BaseException, because that can suppress bridge-initiated cancellation.

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about Yade MCP

yusong652/yade-mcp is an MCP server that connects AI agents to YADE, an open-source discrete element method engine for granular and particle simulation. Its main tools browse and search YADE’s Python API, execute code in a live YADE process, submit background tasks, monitor progress, review history, and interrupt work.

Install YADE and uv, register `uvx yade-mcp` with your MCP client, then install `yade-mcp-bridge` into YADE’s embedded Python interpreter. Restart YADE, run `import yade_mcp_bridge; yade_mcp_bridge.start()` in its console, and restart the agent client.

Use `yade_execute_task` for long simulations. It returns a task ID immediately and queues scripts for one-at-a-time execution; use `yade_check_task_status` for output and progress, `yade_list_tasks` for history, and `yade_interrupt_task` to stop or cancel work.

Yes, Claude Code is a documented client for yusong652/yade-mcp. Register it with `claude mcp add yade-mcp -- uvx yade-mcp`, then start the YADE bridge so the execution tools can reach the running YADE process.

Yes, `yade_execute_code` remains available while a background task runs. Use it to inspect values such as body counts, iterations, stress, coordination, or energy, while remembering that synchronous code is intended for quick operations rather than long-running work.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewYade MCP AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/yusong652-yade-mcp?style=directory)](https://allmcps.com/mcp/yusong652-yade-mcp)
HTML Embed
<a href="https://allmcps.com/mcp/yusong652-yade-mcp"><img src="https://allmcps.com/api/badge/yusong652-yade-mcp?style=directory" alt="Yade MCP on AllMCPs" /></a>