codecalc — Claude Code MCP server: what it does, how to install
Local calculator and execution engine giving AI agents access to 31 programming languages, symbolic math, and SMT logic verification without cloud calls.
claude mcp add codecalc -- uvx codecalcWhat codecalc does
codecalc gives coding agents a local environment to verify assertions directly. It exposes 51 tools designed for exact rational arithmetic, formal SMT checks with Z3, algorithmic complexity estimation, and script execution across 31 runtime environments. It runs locally without telemetry or API keys.
The server features dedicated equivalence verifiers. Calls like verify_translation and verify_optimization check whether rewritten logic matches original behavior across languages or refactors. Execution relies on an rlimit sandbox by default, with opt-in isolation through gVisor containers on Linux or AppContainer on Windows.
Its threat model targets a single developer on a local stdio connection; it will not fit multi-tenant infrastructure.
What it helps with
- verify that refactored code preserves identical behavior
- solve formal logic propositions with the Z3 SMT solver
- measure runtime algorithmic complexity without guessing Big-O notation
- execute untrusted scripts locally in an isolated sandbox
Example prompts for the agent
- Check if my optimized Rust implementation behaves identically to the Python prototype
- Solve this set of logic constraints using the
z3_checktool - Calculate the exact symbolic derivative for this mathematical equation
How to install codecalc
Platform CLI
claude mcp add codecalc -- uvx codecalcuvx runs the command named after the package; if the README names another one, use uvx --from codecalc <command>
Platform CLI
codex mcp add codecalc -- uvx codecalcuvx runs the command named after the package; if the README names another one, use uvx --from codecalc <command>
Config file
{
"mcpServers": {
"codecalc": {
"command": "uvx",
"args": [
"codecalc"
]
}
}
}uvx runs the command named after the package; if the README names another one, use uvx --from codecalc <command>
Config file
{
"servers": {
"codecalc": {
"type": "stdio",
"command": "uvx",
"args": [
"codecalc"
]
}
}
}uvx runs the command named after the package; if the README names another one, use uvx --from codecalc <command>
Platform CLI
gemini mcp add codecalc uvx codecalcuvx runs the command named after the package; if the README names another one, use uvx --from codecalc <command>
Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about codecalc
How to install codecalc in Claude Code?
Run claude mcp add codecalc -- uvx codecalc in your terminal to register the server. You can also run uvx 'codecalc[full]' setup --write to automatically configure detected clients.
What does codecalc do?
It provides 51 MCP tools covering code execution across 31 languages, symbolic calculus, SMT logic solving, and automated behavioral verification.
Does codecalc require external API keys or network access?
The core engine operates completely offline without telemetry or API tokens. Network operations happen only when a specific command explicitly needs external package installation.