What is metacontract mcp?
mc-mcp is an extensible MCP server for the metacontract (mc) framework. It enables AI-powered smart contract development workflows via Foundry integration and semantic documentation search, exposing tools for project setup, testing, deployment, and documentation retrieval.
How to use metacontract mcp?
Install via cargo install mc-mcp, add the server to your MCP client (e.g., Cursor, Cline, RooCode) with MC_PROJECT_ROOT set to your project directory. The server automatically starts and provides tools like mc_search_docs_semantic, mc_setup, mc_test, mc_deploy, and mc_upgrade. An optional mcp_config.toml file under the project root customizes reference sources and script paths.
Key features of metacontract mcp
- Layered (onion) architecture for maintainability
- Rust implementation for performance and safety
- Embedded Qdrant vector DB for fast semantic search
- Local embedding generation via fastembed-rs
- Markdown parsing for documentation indexing
- Prebuilt documentation index auto-downloaded from GitHub Releases
Use cases of metacontract mcp
- Initialize a new Foundry project with the metacontract template
- Perform semantic search over mc, Solidity, and user documentation
- Run TDD cycles: write tests and execute
mc_test via your agent
- Deploy or upgrade contracts using scripts defined in
mcp_config.toml
- Calculate ERC-7201 namespaced storage slots
コメント