Metadata-Version: 2.4
Name: tigl-mcp
Version: 0.1.2
Summary: An MCP around the TiGL library
Author-email: The Design Research Collective <ask-drc@cmu.edu>
Maintainer-email: Mayank Dixit <mayankd@andrew.cmu.edu>, Christopher McComb <ask-drc@cmu.edu>
Project-URL: Homepage, https://github.com/cmudrc/tigl-mcp
Project-URL: Repository, https://github.com/cmudrc/tigl-mcp
Project-URL: Issues, https://github.com/cmudrc/tigl-mcp/issues
Project-URL: Documentation, https://cmudrc.github.io/tigl-mcp/
Requires-Python: >=3.12
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: pydantic>=2.9.0
Requires-Dist: fastmcp~=2.13.1
Requires-Dist: meshio>=5.3
Provides-Extra: dev
Requires-Dist: pytest>=7.4; extra == "dev"
Requires-Dist: pytest-cov>=4.1; extra == "dev"
Requires-Dist: mypy>=1.11; extra == "dev"
Requires-Dist: ruff>=0.6.0; extra == "dev"
Requires-Dist: sphinx>=8.0; extra == "dev"
Requires-Dist: sphinx-rtd-theme>=3.0.0; extra == "dev"
Requires-Dist: build>=1.2.0; extra == "dev"
Requires-Dist: twine>=5.1.0; extra == "dev"
Requires-Dist: pre-commit>=3.8.0; extra == "dev"
Dynamic: license-file

# tigl-mcp

[![CI](https://github.com/cmudrc/tigl-mcp/actions/workflows/ci.yml/badge.svg)](https://github.com/cmudrc/tigl-mcp/actions/workflows/ci.yml)
[![Docs](https://github.com/cmudrc/tigl-mcp/actions/workflows/docs-pages.yml/badge.svg)](https://github.com/cmudrc/tigl-mcp/actions/workflows/docs-pages.yml)
[![Examples](https://github.com/cmudrc/tigl-mcp/actions/workflows/examples.yml/badge.svg)](https://github.com/cmudrc/tigl-mcp/actions/workflows/examples.yml)

`tigl-mcp` is a lightweight Model Context Protocol server for CPACS-oriented
TiGL workflows. The current implementation focuses on deterministic,
JSON-friendly tooling backed by stubbed CPACS/TiGL behavior so local
development, tests, and docs stay stable without native geometry runtimes.

## Overview

The project currently provides:

- A FastMCP-powered server with stdio and HTTP-compatible transports
- A curated set of CPACS lifecycle, inspection, export, sampling, and parameter
  tools
- Pydantic-backed tool validation with structured MCP error payloads
- Deterministic CPACS/TiGL stand-ins for stable local development and CI

## Quickstart

Requires Python 3.12+.

```bash
python3 -m venv .venv
source .venv/bin/activate
make dev
make test
make ci
```

Start the server over stdio:

```bash
tigl-mcp --transport stdio
```

Inspect the non-blocking HTTP transport configuration example:

```bash
PYTHONPATH=src python3 examples/server/http_launch_config.py
```

## Examples

The examples are deterministic and aligned with the current stub-backed
implementation.

- Examples index: [`examples/README.md`](examples/README.md)
- Tool discovery: [`examples/client/tool_discovery.py`](examples/client/tool_discovery.py)
- Session lifecycle: [`examples/cpacs/session_lifecycle.py`](examples/cpacs/session_lifecycle.py)
- Export snapshot: [`examples/cpacs/export_snapshot.py`](examples/cpacs/export_snapshot.py)

## Docs

- Docs source: [`docs/index.rst`](docs/index.rst)
- Published docs: <https://cmudrc.github.io/tigl-mcp/>

Build the docs locally with:

```bash
make docs
```

## Current Capability Boundaries

- The default tests and examples target the deterministic stand-ins in
  `tigl_mcp.cpacs_stubs`.
- Tool names, schemas, and JSON payload shapes are stable.
- Geometry values are intentionally simplified; they reflect the current stub
  contract rather than full native TiGL fidelity.

## Contributing

Contribution guidelines live in [`CONTRIBUTING.md`](CONTRIBUTING.md).
