pyNastran MCP Server
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
pyNastran MCP Server
A Model Context Protocol (MCP) Server for pyNastran, built with FastMCP. Enables AI agents to interact with Nastran FEA models.
Features
π§ BDF Tools: Read, write, and analyze Nastran input files
π OP2 Tools: Extract results from Nastran output files
π Geometry Tools: Mesh quality checks and geometric analysis
π Analysis Tools: Automated report generation
π FastMCP: Built with modern FastMCP framework
π Multiple Transports: stdio, SSE, and streamable-http
Related MCP server: COMSOL MCP Server
Installation
pip install pynastran-mcpOr install from source:
git clone https://github.com/Shaoqigit/pynastran-mcp.git
cd pynastran-mcp
pip install -e .Quick Start
Stdio Transport (Default)
For MCP clients like Cherry Studio, Claude Desktop:
pynastran-mcpSSE Transport
# Default: host=127.0.0.1, port=8080
pynastran-mcp --transport sse
# Custom host and port
pynastran-mcp --transport sse --host 0.0.0.0 --port 8080Streamable HTTP Transport (Production)
# Default: host=127.0.0.1, port=8080
pynastran-mcp --transport streamable-http
# Custom host and port
pynastran-mcp --transport streamable-http --host 0.0.0.0 --port 8080MCP Client Configuration
Cherry Studio / Cursor / Claude Desktop
Add to your MCP client configuration:
{
"mcpServers": {
"pynastran": {
"command": "pynastran-mcp"
}
}
}See CHERRY_STUDIO_TUTORIAL.md for detailed setup instructions.
Available Tools
BDF Tools
Tool | Description |
| Read BDF file and return model summary |
| Get detailed model information |
| Write model to new BDF file |
| Get node coordinates |
| Get element connectivity |
| Get material properties |
| Get property definitions |
OP2 Tools
Tool | Description |
| Read OP2 result file |
| List available result cases |
| Extract stress results |
| Extract displacement results |
Geometry Tools
Tool | Description |
| Check mesh quality metrics |
| Get model bounding box |
Analysis Tools
Tool | Description |
| Generate comprehensive analysis report |
Usage Examples
With AI Agents
Once configured, you can ask your AI assistant:
"Read the BDF file at /path/to/model.bdf and tell me about the mesh"
"Analyze the stress results from /path/to/results.op2"
"Check the mesh quality and suggest improvements"
"Generate a report for my Nastran model"Programmatic Usage
from pynastran_mcp.tools.bdf_tools import BdfTools
from pynastran_mcp.tools.op2_tools import Op2Tools
async def analyze_model():
# BDF Analysis
bdf_tools = BdfTools()
summary = await bdf_tools.read_bdf("wing.bdf")
print(summary)
# OP2 Results
op2_tools = Op2Tools()
stresses = await op2_tools.get_stress("results.op2", element_type="CQUAD4")
print(stresses)Project Structure
pynastran-mcp/
βββ pynastran_mcp/
β βββ __init__.py
β βββ server.py # FastMCP server with all tools
β βββ tools/
β βββ __init__.py
β βββ bdf_tools.py # BDF file operations
β βββ op2_tools.py # OP2 result operations
β βββ geometry_tools.py # Mesh quality checks
β βββ analysis_tools.py # Report generation
βββ pyproject.toml
βββ README.md
βββ examples/
βββ example_usage.pyRequirements
Python 3.10+
pyNastran >= 1.4.0
mcp >= 1.0.0 (with FastMCP)
Development
# Setup
git clone https://github.com/Shaoqigit/pynastran-mcp.git
cd pynastran-mcp
pip install -e ".[dev]"
# Run tests
pytest
# Code formatting
black pynastran_mcp/License
MIT License - see LICENSE file
Acknowledgments
pyNastran - The underlying Nastran interface library
MCP Python SDK - FastMCP framework
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
Fork the repository
Create your feature branch (
git checkout -b feature/amazing-feature)Commit your changes (
git commit -m 'Add some amazing feature')Push to the branch (
git push origin feature/amazing-feature)Open a Pull Request
Please make sure to update tests as appropriate and follow the existing code style.
pyNastran - The underlying Nastran interface library
MCP Python SDK - FastMCP framework
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogβ¦
Related MCP Connectors
Nifty's MCP server β exposes tasks, projects, messages, and files as tools for AI agents.
MCP server for building and testing AI agents with multi-model experimentation and insights.
MCP server for AI agents to plan, verify, and deploy Cloudflare-native apps.
MCP Server for Slima - AI Writing IDE for Novel Authors with AI Beta Reader.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceMCP server that exposes CAD geometry reasoning over STEP files to LLMs, allowing natural language queries about parts, assemblies, dimensions, holes, and mass properties.-
- AlicenseBqualityDmaintenanceMCP Server for COMSOL Multiphysics simulation automation via AI agents.782MIT
- AlicenseBqualityCmaintenanceEnables natural language interaction with ANSYS Mechanical simulation software via gRPC, allowing users to manage geometry, mesh, boundary conditions, solve analyses, and generate reports through MCP-compatible AI clients.3720Apache 2.0

Ansys CFX-MCPofficial
AlicenseAqualityBmaintenanceAn MCP server that enables AI assistants to interact with Ansys CFX through PyCFX, supporting natural-language-assisted CFX-Pre, CFX Solver, and CFD-Post workflows for setup, execution, and postprocessing.71,162 PyPI5Apache 2.0