TopologicPy MCP Server
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@TopologicPy MCP ServerCreate a 3-storey building 12m x 20m with 3.5m floor heights"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
TopologicPy MCP Server
A Model Context Protocol server that exposes TopologicPy TopologicPy-docs's spatial modeling capabilities to LLM agents like Claude Code, Claude Desktop, and other MCP clients. This was created to assist us in developing further tools around Topologic and TopologicPy
What This Enables
Ask Claude (or any MCP-equipped LLM) to build architectural models through natural language:
"Create a 3-storey office building, 12m × 20m with 3.5m floor heights, then show me the adjacency graph and export to IFC"
The MCP server translates these requests into precise TopologicPy operations, maintaining a named object session across the conversation.
Architecture
┌─────────────────────────────────────────────────┐
│ MCP Client (Claude Code, etc.) │
│ Natural language ↔ tool calls │
└────────────────────┬────────────────────────────┘
│ MCP Protocol (stdio/SSE)
▼
┌─────────────────────────────────────────────────┐
│ TopologicPy MCP Server │
│ ┌───────────────────────────────────────────┐ │
│ │ Session Store (named topology objects) │ │
│ │ • "building" → CellComplex │ │
│ │ • "floor_0" → Cell │ │
│ │ • "graph" → Graph │ │
│ └───────────────────────────────────────────┘ │
│ │
│ Tools: create, boolean, transform, query, I/O │
│ Resources: session state, BREP strings │
│ Prompts: building envelope, adjacency, grids │
└────────────────────┬────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────┐
│ TopologicPy │
│ Vertex → Edge → Wire → Face → Shell → Cell │
│ CellComplex → Cluster → Graph → Dictionary │
│ OpenCASCADE (BREP) • IfcOpenShell (IFC) │
└─────────────────────────────────────────────────┘Available Tools (36 tools)
Creation
Tool | Description |
| Create a point at (x, y, z) |
| Line segment between two vertices |
| Polyline from ordered vertices |
| Face from a closed wire |
| Rectangular face |
| Circular face (polygon approximation) |
| 3D solid from bounding faces |
| Box / rectangular prism |
| Cylindrical cell |
| Merged cell assembly (shared boundaries) |
| Unstructured collection |
Boolean Operations
Tool | Description |
| A ∪ B |
| A − B |
| A ∩ B |
| Resolve self-intersections |
Transformations
Tool | Description |
| Move by vector |
| Rotate around axis |
| Scale relative to origin |
Query & Analysis
Tool | Description |
| List all named objects in session |
| Detailed info (counts, centroid, volume, area) |
| Extract vertex coordinates |
| Extract and optionally store sub-elements |
Graph Operations
Tool | Description |
| Dual/adjacency graph |
| Shortest path between vertices |
Dictionary (Metadata)
Tool | Description |
| Attach key-value metadata |
| Read attached metadata |
Import / Export
Tool | Description |
| Export to BREP string/file |
| Import from BREP string/file |
| Export triangulated mesh (OBJ) |
| Export to IFC (BIM) |
| Import from IFC file |
Session Management
Tool | Description |
| Delete from session |
| Rename an object |
| Deep copy with new name |
Installation
With uv (recommended)
cd topologic-mcp-server
uv venv
source .venv/bin/activate
uv pip install -e .With pip
cd topologic-mcp-server
pip install -e .Usage
With Claude Code
Add to your Claude Code MCP configuration (~/.claude/claude_code_config.json):
{
"mcpServers": {
"topologic": {
"command": "python",
"args": ["-m", "topologic_mcp"],
"cwd": "/path/to/topologic-mcp-server"
}
}
}Or using uv directly:
{
"mcpServers": {
"topologic": {
"command": "uv",
"args": ["run", "--directory", "/path/to/topologic-mcp-server", "topologic-mcp"]
}
}
}With Claude Desktop
Add to claude_desktop_config.json:
{
"mcpServers": {
"topologic": {
"command": "uv",
"args": ["run", "--directory", "/path/to/topologic-mcp-server", "topologic-mcp"]
}
}
}Standalone (stdio transport)
python -m topologic_mcpWith MCP Inspector (for testing)
mcp dev src/topologic_mcp/server.pyExample Conversations
Create a simple building
User: Create a 3-storey building, 10m × 15m, 3m floor height
Claude: [calls create_vertex, create_cell_prism × 3, translate × 2,
create_cellcomplex_by_cells, query_topology]
Result: CellComplex "building" with 3 cells, 16 faces, 33 edges, 20 verticesAnalyze spatial adjacency
User: Show me which floors share faces in the building
Claude: [calls create_graph_from_topology with via_shared_faces=True,
get_sub_topologies to list cells, query each cell]
Result: Graph with 3 vertices (one per floor) and 2 edges
(floor_0↔floor_1, floor_1↔floor_2)Boolean operations
User: Cut a 2m diameter hole through the middle of floor_1
Claude: [calls create_cell_cylinder for the hole, translate to position,
boolean_difference to subtract from floor_1]
Result: Updated floor_1 with cylindrical voidLicense
GPL-3.0-or-later (matching TopologicPy's license)
Contributing
This server wraps TopologicPy's pure-Python API. To add new tools:
Add a
@mcp.tool()decorated function inserver.pyFollow the naming convention:
verb_noun(e.g.,create_vertex,export_brep)Always accept
ctx: Contextas the first parameterUse the
TopologyStorefromctx.request_context.lifespan_contextReturn descriptive strings (the LLM reads these)
This server cannot be installed
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Adventurous-Systems/topologicpy_MCP'
If you have feedback or need assistance with the MCP directory API, please join our Discord server