Skip to main content

Moonglade Deterministic Math MCP (moonglade-math-mcp)

Zero-hallucination symbolic and fixed-point mathematical execution engine exposed via the Model Context Protocol (MCP). Every calculation traverses a deterministic priority hierarchy (Plugin Submodule → Domain → Basic Math) and emits a cryptographic MathProof receipt containing the exact result, step-by-step execution trace, rounding mode (ROUND_HALF_EVEN), and SHA-256 verification digest.

Repository Architecture

moonglade-math-mcp/
├── pyproject.toml
├── README.md
├── mcp_math_engine/          # Core Hierarchical Engine & MCP JSON-RPC Server
│   ├── core.py               # MathProof receipt & 35-digit Decimal context
│   ├── registry.py           # Priority-cascading namespace dispatcher
│   ├── server.py             # Stdio MCP server (calculate & list_math_hierarchy)
│   └── modules/              # Built-in foundational tiers
│       ├── basic_math.py     # Rational arithmetic, algebra, geometry, statistics
│       ├── scientific_math.py# Symbolic calculus (SymPy), matrices, SI constants
│       └── financial_math.py # Fixed-point TVM, compound interest, base EMI
├── plugins/                  # Auto-discovered Domain Extension Plugins
│   ├── __init__.py           # Dynamic plugin loader (discover_and_register_plugins)
│   ├── banking_adjudication/ # Epoch-governed retail mortgage & covenant underwriting
│   ├── building_energy/      # Municipal energy consumption & BIM budget rates
│   ├── energy_grid/          # Grid load, storage & renewable dispatch
│   ├── municipal_spatial/    # Spatial density & parcel calculations
│   └── transit_mobility/     # Fleet headway, capacity & mobility metrics
└── tests/                    # Automated Verification Suite

Creating a Domain Extension Plugin

Drop a new folder inside plugins/<your_plugin>/ with a pack.py (or plugin.py) defining register_pack(registry: MathRegistry):

from mcp_math_engine.core import MathProof, to_decimal
from mcp_math_engine.registry import MathRegistry

def register_pack(registry: MathRegistry):
    registry.register_module("custom.domain", priority=100, parent="basic", description="Custom domain formulas")
    registry.register_operation("my_formula", "custom.domain", my_handler)

All plugins in plugins/ are automatically discovered and registered on engine startup.

Metadata

Release files for mg-math-mcp 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mg-math-mcp 1.0.1
File Size Uploaded Provenance Actions
mg_math_mcp-1.0.1.tar.gz 33.1 kB Without provenance Details for mg_math_mcp-1.0.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for mg-math-mcp 1.0.1
File Interpreter ABI Platform Actions
mg_math_mcp-1.0.1-py3-none-any.whl Python 3 none any Details for mg_math_mcp-1.0.1-py3-none-any.whl

Total release size: 68.6 kB

Release files / mg_math_mcp-1.0.1.tar.gz

Download URL mg_math_mcp-1.0.1.tar.gz
Size 33.1 kB
Tags Source
SHA-256 checksum
How to use checksums
dce6cbb63c87a483551f255950ed711b4ac2df8318fcf511c0be4b5f6b561b45
BLAKE2b-256 checksum
How to use checksums
ceaa6c20167e0066fd530bc82d8614e57d7a754756404e456c64fda79675a328
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.16.0

Release files / mg_math_mcp-1.0.1-py3-none-any.whl

Download URL mg_math_mcp-1.0.1-py3-none-any.whl
Size 35.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
917ab98891974d9fc7ee36d13599f5c527c1eff050f748de7c20cf28b5eab4da
BLAKE2b-256 checksum
How to use checksums
23d8aea7ffd1345fd2bfaa654c6ecd575bb954ca205e6334e3cc94c1ce5f2ef7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.16.0

Security for mg-math-mcp 1.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page