MCP server for Stubborn — deterministic code and contract context
Project description
stubborn-mcp
MCP server for Stubborn — exposes source-neutral code and contract graph tools to Cursor and other MCP clients.
Thin adapter over stubborn.api. All compile and contract graph logic lives in stubborn-stub.
Part of the stubborn-ai program — see stubborn-hub.
Install
pip install stubborn-stub stubborn-mcp
For binary/NDJSON SCIP indexing, install Stubborn with its SCIP extra:
pip install "stubborn-stub[scip]" stubborn-mcp
stubborn index --scip index.scip --out metadata/symbols.db
export STUBBORN_DB=metadata/symbols.db
stubborn-mcp
Contract-only databases are also supported:
stubborn index-openapi \
--openapi openapi.json \
--service customers-service \
--workspace petclinic \
--out metadata/symbols.db
export STUBBORN_DB=metadata/symbols.db
stubborn-mcp
Cursor configuration
.cursor/mcp.json:
{
"mcpServers": {
"stubborn": {
"command": "stubborn-mcp",
"env": {
"STUBBORN_DB": "${workspaceFolder}/metadata/symbols.db"
}
}
}
}
Module entry: python -m stubborn_mcp
Tools
| Tool | Purpose |
|---|---|
workspace_info |
Inspect workspace source kinds: code repos, contract sources, symbols, endpoints |
get_context |
Prune + weave code or contract context (java-stub or stubborn-dsl) |
list_symbols |
Browse/search symbols by stable_id |
list_contracts |
Browse/search OpenAPI contract endpoint stable IDs and schema constraints |
metrics |
Compression KPI vs source tree |
Full parameter reference: docs/MCP.md
Setup diagnostics
Read-only MCP and DB checks (ADR-015) — does not start the MCP server:
export STUBBORN_DB=metadata/symbols.db
stubborn-mcp doctor
stubborn-mcp doctor --json
Aggregate with sibling packages: stubborn-hub DEMO-LAUNCHERS.
Development
git clone https://github.com/stubborn-ai/stubborn-mcp.git
cd stubborn-mcp
pip install -e "../stubborn"
pip install -e ".[dev]"
pytest
License
MIT — see LICENSE.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file stubborn_mcp-0.1.0b3.tar.gz.
File metadata
- Download URL: stubborn_mcp-0.1.0b3.tar.gz
- Upload date:
- Size: 11.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
00b3e73d5a3648faa6e600e2f75b3afa25804d62905b96a59a9e8d95ab27459f
|
|
| MD5 |
0ab6cf3086b38da078ea3c6f04340598
|
|
| BLAKE2b-256 |
29311172d25a6095aabc06fcaa079547202258db628caff23c573feca92cc8fe
|
File details
Details for the file stubborn_mcp-0.1.0b3-py3-none-any.whl.
File metadata
- Download URL: stubborn_mcp-0.1.0b3-py3-none-any.whl
- Upload date:
- Size: 10.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dd1c1f73eba6aef34d6b903389cd9a95eb9cd852fa700fe4d9804e3ea31b7139
|
|
| MD5 |
a575f7270bab29de9c385449038948a5
|
|
| BLAKE2b-256 |
8a0300117170fe507af55ea33b72ce9da70eed04f97f4e1c926963f121b679fc
|