# rclab-auth/csi-mcp architecture

> Architecture diagram of the GitHub repository rclab-auth/csi-mcp, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-12-02). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/rclab-auth/csi-mcp
- Repository: https://github.com/rclab-auth/csi-mcp

## Overview

CSI MCP provides Claude Desktop with separate SAP2000 and ETABS servers that operate the locally installed structural-analysis applications through their COM APIs. The principal workflow is to connect to or start a program, create or edit a model, run analysis or design, then retrieve results or database tables. Shared tools also expose generic API calls and installation-specific API help; ETABS adds story data. The excerpts establish shared-module wiring and several tool behaviors, while broader capabilities are documented in the README. Unshown tool internals are represented at the shared-tools layer.

Main entry points: [`common/csi_com.py`](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_com.py) (CSI COM layer), [`common/csi_tools.py`](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py) (MCP tool registry), [`ETABS/src/etabs_mcp.py`](https://github.com/rclab-auth/csi-mcp/blob/master/ETABS/src/etabs_mcp.py) (ETABS server), [`SAP2000/src/sap2000_mcp.py`](https://github.com/rclab-auth/csi-mcp/blob/master/SAP2000/src/sap2000_mcp.py) (SAP2000 server)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_servers["MCP servers"]
  node_etabs_server["ETABS server<br/>[etabs_mcp.py]"]
  node_sap_server["SAP2000 server<br/>[sap2000_mcp.py]"]
end

subgraph group_shared["Shared runtime"]
  node_shared_tools["MCP tool registry<br/>[csi_tools.py]"]
  node_com_layer["CSI COM layer<br/>[csi_com.py]"]
  node_api_docs["API help index<br/>[csi_docs.py]"]
end

subgraph group_workflow["Model workflow"]
  node_connection["Connect and status<br/>[csi_tools.py]"]
  node_model_edit["Model authoring<br/>[csi_tools.py]"]
  node_analysis["Analysis runs<br/>[csi_tools.py]"]
  node_design["Design checks<br/>[csi_tools.py]"]
end

subgraph group_inspection["Inspection tools"]
  node_tables["Database tables<br/>[csi_tools.py]"]
  node_results["Structural results<br/>[csi_tools.py]"]
  node_generic_api["Generic API calls<br/>[csi_tools.py]"]
  node_story_data["Story data<br/>[etabs_mcp.py]"]
end

node_claude(("Claude Desktop"))
node_csi_etabs["ETABS application"]
node_csi_sap["SAP2000 application"]
node_help_files["Installed API help"]

node_claude -->|"requests tools"| node_etabs_server
node_claude -->|"requests tools"| node_sap_server
node_etabs_server -->|"sets up ETABS"| node_com_layer
node_etabs_server -->|"creates tools"| node_shared_tools
node_sap_server -->|"sets up SAP2000"| node_com_layer
node_sap_server -->|"creates tools"| node_shared_tools
node_shared_tools -->|"invokes API"| node_com_layer
node_shared_tools -->|"uses API help"| node_api_docs
node_connection -->|"attaches or starts"| node_com_layer
node_com_layer -->|"controls through COM"| node_csi_etabs
node_com_layer -->|"controls through COM"| node_csi_sap
node_model_edit -->|"edits model"| node_csi_etabs
node_model_edit -->|"edits model"| node_csi_sap
node_analysis -->|"runs analysis"| node_csi_etabs
node_analysis -->|"runs analysis"| node_csi_sap
node_design -->|"runs design"| node_csi_etabs
node_design -->|"runs design"| node_csi_sap
node_tables -->|"reads and applies"| node_csi_etabs
node_tables -->|"reads and applies"| node_csi_sap
node_results -->|"reads results"| node_csi_etabs
node_results -->|"reads results"| node_csi_sap
node_generic_api -->|"dispatches calls"| node_com_layer
node_story_data -->|"reads story data"| node_com_layer
node_api_docs -->|"indexes help"| node_help_files

click node_etabs_server "https://github.com/rclab-auth/csi-mcp/blob/master/ETABS/src/etabs_mcp.py"
click node_sap_server "https://github.com/rclab-auth/csi-mcp/blob/master/SAP2000/src/sap2000_mcp.py"
click node_shared_tools "https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py"
click node_com_layer "https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_com.py"
click node_api_docs "https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_docs.py"
click node_connection "https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py"
click node_model_edit "https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py"
click node_analysis "https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py"
click node_design "https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py"
click node_tables "https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py"
click node_results "https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py"
click node_generic_api "https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py"
click node_story_data "https://github.com/rclab-auth/csi-mcp/blob/master/ETABS/src/etabs_mcp.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_etabs_server,node_sap_server toneBlue
class node_shared_tools,node_com_layer,node_api_docs toneAmber
class node_connection,node_model_edit,node_analysis,node_design,node_help_files toneMint
class node_tables,node_results,node_generic_api,node_story_data toneRose
class node_claude,node_csi_etabs,node_csi_sap toneIndigo
```

## Components

### MCP servers

- [ETABS server](https://github.com/rclab-auth/csi-mcp/blob/master/ETABS/src/etabs_mcp.py): `ETABS/src/etabs_mcp.py`
- [SAP2000 server](https://github.com/rclab-auth/csi-mcp/blob/master/SAP2000/src/sap2000_mcp.py): `SAP2000/src/sap2000_mcp.py`

### Shared runtime

- [MCP tool registry](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py): `common/csi_tools.py`
- [CSI COM layer](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_com.py): `common/csi_com.py`
- [API help index](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_docs.py): `common/csi_docs.py`

### Model workflow

- [Connect and status](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py): `common/csi_tools.py`
- [Model authoring](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py): `common/csi_tools.py`
- [Analysis runs](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py): `common/csi_tools.py`
- [Design checks](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py): `common/csi_tools.py`

### Inspection tools

- [Database tables](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py): `common/csi_tools.py`
- [Structural results](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py): `common/csi_tools.py`
- [Generic API calls](https://github.com/rclab-auth/csi-mcp/blob/master/common/csi_tools.py): `common/csi_tools.py`
- [Story data](https://github.com/rclab-auth/csi-mcp/blob/master/ETABS/src/etabs_mcp.py): `ETABS/src/etabs_mcp.py`

### Other components

- **Claude Desktop**
- **ETABS application**
- **SAP2000 application**
- **Installed API help**

## Connections

- Claude Desktop → ETABS server: requests tools (evidence: `README.md`)
- Claude Desktop → SAP2000 server: requests tools (evidence: `README.md`)
- ETABS server → CSI COM layer: sets up ETABS (evidence: `ETABS/src/etabs_mcp.py`)
- ETABS server → MCP tool registry: creates tools (evidence: `ETABS/src/etabs_mcp.py`)
- SAP2000 server → CSI COM layer: sets up SAP2000 (evidence: `SAP2000/src/sap2000_mcp.py`)
- SAP2000 server → MCP tool registry: creates tools (evidence: `SAP2000/src/sap2000_mcp.py`)
- MCP tool registry → CSI COM layer: invokes API (evidence: `common/csi_tools.py`)
- MCP tool registry → API help index: uses API help (evidence: `common/csi_tools.py`)
- Connect and status → CSI COM layer: attaches or starts (evidence: `common/csi_tools.py`)
- CSI COM layer → ETABS application: controls through COM (evidence: `README.md`)
- CSI COM layer → SAP2000 application: controls through COM (evidence: `README.md`)
- Model authoring → ETABS application: edits model (evidence: `README.md`)
- Model authoring → SAP2000 application: edits model (evidence: `README.md`)
- Analysis runs → ETABS application: runs analysis (evidence: `README.md`)
- Analysis runs → SAP2000 application: runs analysis (evidence: `README.md`)
- Design checks → ETABS application: runs design (evidence: `README.md`)
- Design checks → SAP2000 application: runs design (evidence: `README.md`)
- Database tables → ETABS application: reads and applies (evidence: `README.md`)
- Database tables → SAP2000 application: reads and applies (evidence: `README.md`)
- Structural results → ETABS application: reads results (evidence: `README.md`)
- Structural results → SAP2000 application: reads results (evidence: `README.md`)
- Generic API calls → CSI COM layer: dispatches calls (evidence: `common/csi_tools.py`)
- Story data → CSI COM layer: reads story data (evidence: `ETABS/src/etabs_mcp.py`)
- API help index → Installed API help: indexes help (evidence: `common/csi_docs.py`)
