Skip to main content

My Code, My Rules banner

CI Publish PyPI Python Docs Coverage

Warning MCMR is early 0.0.x software. Its rules and command line may still change.

Installation

MCMR requires Git and Python 3.14 or newer. Its main target is free-threaded Python 3.14t+.

pip install mcmr
mcmr check .

Use uv tool install mcmr for an isolated command line installation.

What it is

MCMR is a policy engine for whole repositories. A Rust kernel reads source once into typed fact tables. Python rules query the shared evidence and report exact findings with source locations.

  • Deterministic rules are local, fast, and enabled by default.
  • Contextual rules use a configured model only when you enable them.
  • External rules can join repository facts with systems such as DataHub.
  • Safe repairs are kept only after MCMR reparses the edit and reruns the rule.
  • Plugins can add rules and evidence providers through public entry points.

MCMR reads Python, Rust, TypeScript, C, C++, and CUDA.

Usage

mcmr check . --format concise
mcmr check . --repair preview
mcmr check . --repair apply
mcmr check . --contextual --external

Write every verdict to DataHub, then read the history before the next agent changes the code.

mcmr check . --external --writeback
mcmr history .

Demo

The repository includes a deliberately messy MCP server. Run every enabled rule without changing the demo.

mcmr check demo/ --contextual --external --writeback --report-only

See the documentation, the rule reference, and the recorded DataHub examples. SYSTEM.md documents the architecture. The docs also cover contextual setup and rule controls.

MCMR is licensed under Apache 2.0.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mcmr-0.0.3.tar.gz (1.1 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

mcmr-0.0.3-cp314-cp314t-manylinux_2_28_x86_64.whl (12.1 MB view details)

Uploaded CPython 3.14tmanylinux: glibc 2.28+ x86-64

mcmr-0.0.3-cp314-cp314-manylinux_2_28_x86_64.whl (12.1 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.28+ x86-64

File details

Details for the file mcmr-0.0.3.tar.gz.

File metadata

  • Download URL: mcmr-0.0.3.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.3 {"installer":{"name":"uv","version":"0.12.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for mcmr-0.0.3.tar.gz
Algorithm Hash digest
SHA256 828279b350684173fd7d2209b4d06dc4456ed797b177fe995fb915b15954af1e
MD5 5c34a400e32b4301003b81c8bf7e194d
BLAKE2b-256 2af90483980740b706c9fbebc143f5afaa30357aa30b09a7d94ce9250abc12af

See more details on using hashes here.

File details

Details for the file mcmr-0.0.3-cp314-cp314t-manylinux_2_28_x86_64.whl.

File metadata

  • Download URL: mcmr-0.0.3-cp314-cp314t-manylinux_2_28_x86_64.whl
  • Upload date:
  • Size: 12.1 MB
  • Tags: CPython 3.14t, manylinux: glibc 2.28+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.3 {"installer":{"name":"uv","version":"0.12.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for mcmr-0.0.3-cp314-cp314t-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 676029a80b65aa44adc632ec33effa1cd3623d72df418d509dc5c25d375abc39
MD5 114ab85b63f280a31e30019c5a2d6c47
BLAKE2b-256 eaee680beda0cf3610a4b00390ead1e0e065a95d96198392ae4f0787c728cf8d

See more details on using hashes here.

File details

Details for the file mcmr-0.0.3-cp314-cp314-manylinux_2_28_x86_64.whl.

File metadata

  • Download URL: mcmr-0.0.3-cp314-cp314-manylinux_2_28_x86_64.whl
  • Upload date:
  • Size: 12.1 MB
  • Tags: CPython 3.14, manylinux: glibc 2.28+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.12.3 {"installer":{"name":"uv","version":"0.12.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for mcmr-0.0.3-cp314-cp314-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 386734f94d18e82a7cf67edec6114a6310fc67d9abe4979407a9301343f012ba
MD5 94955186fe564b6e51e9552edb680942
BLAKE2b-256 a4f7a8c0d4fba9a95ed3614ec8b168449735aac7dcd729d2aca956cd138df484

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page