Geometry Engine MCP Server
by prasannafree
README.md
# Geometry Engine MCP Server
An Model Context Protocol (MCP) server providing geometry utilities (like hypotenuse calculation and shape registration) over Server-Sent Events (SSE) via FastMCP and Docker.
---
## 📋 Prerequisites
Before getting started, make sure you have the following installed:
* [Docker](https://docs.docker.com/get-docker/) installed and running.
* [Visual Studio Code](https://code.visualstudio.com/) with an MCP-compatible Chat Extension (e.g., GitHub Copilot Agent / VS Code MCP Client).
* [Git](https://git-scm.com/) installed.
---
## 🚀 Quick Start Guide
### 1. Clone the Repository
```bash
git clone [https://github.com/](https://github.com/)<your-username>/<your-repo-name>.git
cd <your-repo-name>
```
---
### 2. Build and Run the Docker Container
Build the Docker image:
```bash
docker build -t geometry-mcp-clean .
```
Run the container in detached mode on port `8000`:
```bash
docker run -d --rm -p 8000:8000 --name geometry-mcp-server geometry-mcp-clean
```
Verify that the server is running by checking the active containers:
```bash
docker ps
```
---
### 3. Connect to VS Code
1. Create a local configuration folder inside the repository (if it doesn't already exist):
```bash
mkdir -p .vscode
```
2. Create or update `.vscode/mcp.json` with the following configuration:
```json
{
"servers": {
"geometry-engine": {
"type": "http",
"url": "http://localhost:8000/sse"
}
}
}
```
3. Open VS Code Command Palette (`Ctrl + Shift + P` or `Cmd + Shift + P`).
4. Search for and execute: **`MCP: Restart Server`** $\rightarrow$ select **`geometry-engine`**.
---
## 🛠Available Tools
* **`calculate_hypotenuse(a: float, b: float)`**: Calculates the hypotenuse of a right-angled triangle given legs $a$ and $b$.
* **`register_circle_shape(circle: CustomCircle)`**: Saves circle properties (`shape_name`, `radius`) to the server state registry.
---
## 💬 Usage Example
In your VS Code Chat panel:
> *"Calculate the hypotenuse for a right-angled triangle with sides 6 and 8 using geometry-engine."*This server cannot be deployed
Maintenance
ActivitySlowing
ResponsivenessNo issues