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.
Open Source vs. Commercial
- Open Source Core (
MIT): Themg-math-mcpengine,MathProofreceipts, optionallean_proofsmodule, and v1.0.1 reference plugin examples are licensed under LICENSE. - Commercial Domain Packs: Maintained, compliance-grade Enterprise Domain Packs,
epoch_policyupdates, and SLA-backed RFC 3161/KMS anchoring require a commercial license—see LICENSE-COMMERCIAL.md. - Trademarks: Moonglade™, Moonglade Provenance™, and Moonglade Verified™ are trademarks of Moonglade Inc.—see TRADEMARKS.md.
Metadata
Release files for mg-math-mcp 1.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| mg_math_mcp-1.1.0.tar.gz | 36.7 kB | Without provenance | Details for mg_math_mcp-1.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| mg_math_mcp-1.1.0-py3-none-any.whl | Python 3 | none | any | Details for mg_math_mcp-1.1.0-py3-none-any.whl |
Total release size: 75.5 kB
Release files / mg_math_mcp-1.1.0.tar.gz
| Download URL | mg_math_mcp-1.1.0.tar.gz |
|---|---|
| Size | 36.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
dc28c3d2741d29f8bc3f5726e168eb1f0fa5492a93c8d294a2c856711b66aa72
|
|
BLAKE2b-256 checksum How to use checksums |
13cef4f356447cef8696fea9dc2dc52a47d37f345865b77f617c6384002c0d27
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.5
|
Release files / mg_math_mcp-1.1.0-py3-none-any.whl
| Download URL | mg_math_mcp-1.1.0-py3-none-any.whl |
|---|---|
| Size | 38.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d8a14fe476f8d402f118cbe1a8b46e7f8910c63febe5864f63f767a0a6d61b40
|
|
BLAKE2b-256 checksum How to use checksums |
5f62cebe87cec7d67992584b44653052f7a26311fd735bf814b9d84fd51c31f7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.5
|
Security for mg-math-mcp 1.1.0
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.