BA

brack101/aspenplus-mcp-server

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

37 stars 5 forks 质量 54 趋势 12

MCP(模型上下文协议)服务器,用于Aspen Plus过程仿真集成。该服务器使AI助手通过标准化界面与Aspen Plus模拟交互。

概览

MCP(模型上下文协议)服务器,用于Aspen Plus过程仿真集成。该服务器使AI助手通过标准化界面与Aspen Plus模拟交互。 - : 打开、运行和管理Aspen Plus模拟 - : 读写流属性、块参数和模拟结果 - : 创建、删除和连接设备块和流(增强模式) - : Mixer, Heater, Flash2, Radfrac, DSTWU, RPLUG, RCSTR, RYIELD - : 将Claude及其他AI助手连接到Aspen Plus - Python 3。

概述(AI 翻译)

MCP(模型上下文协议)服务器,用于Aspen Plus过程仿真集成。该服务器使AI助手通过标准化界面与Aspen Plus模拟交互。

特色

  • 过程仿真控制:开启、运行和管理Aspen Plus模拟
  • 数据访问:读写流属性、块参数和仿真结果
  • 流程表操作:创建、删除和连接设备块和流(增强模式)
  • 设备支持:调频器、加热器、Flash2、Radfrac、DSTWU、RPLUG、RCSTR、RYIELD
  • AI集成:将Claude及其他AI助手连接到Aspen Plus

要求

  • Python 3.10 或更高版本
  • Windows 操作系统(用于 Aspen Plus COM 接口)
  • 安装了Aspen Plus系统
  • pywin32 包

安装

  1. 克隆此仓库:

  2. 创建虚拟环境:

  3. 安装该软件包:

用途

运行服务器

可用工具

基础模式工具

  • open_simulation - 打开Aspen Plus模拟文件(设置use_enhanced: false)
  • run_simulation - 运行当前模拟
  • get_value - 利用节点路径从模拟中获取一个值
  • set_value - 在模拟中设置一个值

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

AspenPlus MCP Server

MCP (Model Context Protocol) server for Aspen Plus process simulation integration. This server enables AI assistants to interact with Aspen Plus simulations through a standardized interface.

Features

  • Process Simulation Control: Open, run, and manage Aspen Plus simulations
  • Data Access: Read and write stream properties, block parameters, and simulation results
  • Flowsheet Manipulation: Create, delete, and connect equipment blocks and streams (enhanced mode)
  • Equipment Support: Mixer, Heater, Flash2, Radfrac, DSTWU, RPLUG, RCSTR, RYIELD
  • AI Integration: Connect Claude and other AI assistants to Aspen Plus

Requirements

  • Python 3.10 or higher
  • Windows OS (for Aspen Plus COM interface)
  • Aspen Plus installed
  • pywin32 package

Installation

  1. Clone this repository:
git clone 
cd AspenPlus-MCP-Server
  1. Create a virtual environment:
python -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate
  1. Install the package:
pip install -e .

Usage

Running the Server

python -m aspenplus_mcp.server

Available Tools

Basic Mode Tools

  • open_simulation - Open an Aspen Plus simulation file (set use_enhanced: false)
  • run_simulation - Run the current simulation
  • get_value - Get a value from the simulation using a node path
  • set_value - Set a value in the simulation
  • close_simulation - Close the current simulation

Enhanced Mode Tools (requires use_enhanced: true)

  • place_block - Add a new equipment block to the flowsheet
  • delete_block - Remove an equipment block from the flowsheet
  • place_stream - Add a new stream to the flowsheet
  • connect_stream - Connect a stream to a block port
  • save_simulation - Save the simulation to file

Example Node Paths

# Stream temperature
\\Data\\Streams\\S1\\Output\\TEMP_OUT\\MIXED\\MIXED

# Block parameter
\\Data\\Blocks\\B1\\Input\\TEMP

# Component flow rate
\\Data\\Streams\\S1\\Output\\MOLEFLOW\\MIXED\\WATER

Development

Install development dependencies:

pip install -e ".[dev]"

Run tests:

pytest

Format code:

black src/

Configuration with Claude Desktop

Add to your Claude Desktop config file:

Windows: %APPDATA%\Claude\claude_desktop_config.json

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

Linux: ~/.config/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "aspenplus": {
      "command": "C:\\path\\to\\AspenPlus-MCP-Server\\venv\\Scripts\\python.exe",
      "args": [
        "-m",
        "aspenplus_mcp.server"
      ]
    }
  }
}

Important Notes:

  • Use the full absolute path to your virtual environment’s Python executable
  • On Windows, use double backslashes (\\) in paths or forward slashes (/)
  • After editing the config file, restart Claude Desktop completely
在 GitHub 查看完整 README

安装

This server does not publish a one-line install command.

Open the repository installation guide 新手?先看 mcpskill.org 教程 →

配置

{ "mcpServers": { "aspenplus": { "command": "C:\\path\\to\\AspenPlus-MCP-Server\\venv\\Scripts\\python.exe", "args": [ "-m", "aspenplus_mcp.server" ] } } }