Skip to main content

MCP server for QtBridge (桥通) — bridge finite element analysis software

Project description

bridge-qt-mcp

MCP server for QtBridge (桥通) — bridge finite element analysis software.

This MCP server exposes 348 tools that allow AI assistants (Claude Desktop, Claude Code, etc.) to directly control the QtBridge software for bridge modeling, analysis, and design verification.

Features

  • 348 tools auto-generated from the qtmodel Python API
    • mdb_* (234 tools) — Modeling: nodes, elements, materials, sections, loads, tendons, construction stages
    • odb_* (89 tools) — Results: reactions, deformations, stresses, visualization
    • cdb_* (25 tools) — Design checks: concrete, steel box, steel truss, anti-overturn
  • Zero configuration — all tools are auto-discovered from the qtmodel package
  • Full parameter schemas with types, defaults, and descriptions from docstrings

Prerequisites

  • QtBridge (桥通) software must be running (provides HTTP API at localhost:55125)
  • Python >= 3.10

Installation

pip install bridge-qt-mcp

Or install from source:

git clone https://github.com/Inface0443/pyqt.git
cd pyqt
pip install -e .

Configuration

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
{
  "mcpServers": {
    "bridge-qt": {
      "command": "bridge-qt-mcp"
    }
  }
}

Claude Code

claude mcp add bridge-qt -- bridge-qt-mcp

Cursor / Other MCP Clients

Use stdio transport with command bridge-qt-mcp.

Usage Examples

Once connected, you can ask Claude to interact with QtBridge directly:

Modeling:

"Create 10 nodes at coordinates (0,0,0) to (9,0,0) with 1m spacing, then connect them with beam elements using C50 concrete."

Results:

"Get the support reactions at nodes 500, 502, 488 for construction stage 9, and export them to an Excel file."

Visualization:

"Plot the bending moment diagram for the operational stage with load case '成桥(合计)'."

Design Checks:

"Run the concrete structure verification for the default structure group."

Tool Naming Convention

Tools follow the pattern {module}_{method_name}:

Prefix Module Description
mdb_ Model Database Pre-processing: create/modify model
odb_ Output Database Post-processing: query results
cdb_ Check Database Design verification

Common Tools

Tool Description
mdb_add_nodes Add nodes by coordinates
mdb_add_element Add a single element
mdb_add_material Define material properties
mdb_add_section Define cross-section
mdb_add_construction_stage Define construction stage
mdb_do_solve Run analysis
odb_get_reaction Get support reactions
odb_get_deformation Get node displacements
odb_get_element_force Get element internal forces
odb_get_element_stress Get element stresses
odb_plot_beam_element_force Plot beam force diagram
cdb_solve_concrete_check Run concrete verification

Development

# Clone the repo
git clone https://github.com/Inface0443/pyqt.git
cd pyqt

# Install in development mode
pip install -e .

# Run the server directly
bridge-qt-mcp
# or
python -m qtmodel.mcp_server

qtmodel Python API

This package also provides the qtmodel Python library for scripting QtBridge directly:

from qtmodel import mdb, odb, cdb

# Add nodes
mdb.add_nodes(node_data=[[1, 0, 0, 0], [2, 1, 0, 0], [3, 2, 0, 0]])

# Add beam elements
mdb.add_element(index=1, ele_type=1, node_ids=[1, 2], mat_id=1, sec_id=1)
mdb.add_element(index=2, ele_type=1, node_ids=[2, 3], mat_id=1, sec_id=1)

# Run analysis
mdb.do_solve()

# Get results
import json
reactions = json.loads(odb.get_reaction(ids=[1, 3], stage_id=1))
print(reactions)

See the full API documentation for details.

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bridge_qt_mcp-0.1.0.tar.gz (401.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bridge_qt_mcp-0.1.0-py3-none-any.whl (89.6 kB view details)

Uploaded Python 3

File details

Details for the file bridge_qt_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: bridge_qt_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 401.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for bridge_qt_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 db50b9eb5cdd2339d6439b724555645fc03f66a83f55fef0d6ab9768bb2ba75f
MD5 fae7958e4fbad1047a90e7760090f29f
BLAKE2b-256 28827b1f724f351f294536d1458e58ef5eee58735eb568d0f721f253db759a0f

See more details on using hashes here.

File details

Details for the file bridge_qt_mcp-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: bridge_qt_mcp-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 89.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for bridge_qt_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3ade1b18516d6b528b8470efb3d6857686e072c765c905375734f317e4486330
MD5 cdff8689aa8562f3cf0ebbbbb1257bd7
BLAKE2b-256 977289c4a069c3acd0286dfd4f8cdc034992d0e7c8e4d1dbd3a8cd1b9a72b24c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page