40 lines
2.1 KiB
Markdown
40 lines
2.1 KiB
Markdown
# BeXProof: Verifiable Best Execution and Compliance Verifier (Python MVP)
|
|
|
|
BeXProof is a modular, open-source verifier and enforcement layer designed to accompany equity order routers and brokers. It guarantees and proves Best Execution while preserving data privacy, using a policy-driven DSL, verifiable routing logs, a ZKP-inspired proof substrate, and a tamper-evident ledger for auditable outcomes.
|
|
|
|
What you will find in this repository
|
|
- A production-oriented Python MVP with a small, extensible architecture.
|
|
- Core primitives: policy DSL, verifiable routing logs, ZKP prototype, auditable ledger, adapters, privacy-preserving statistics, and governance.
|
|
- A test suite with basic unit tests for each primitive.
|
|
- MVP extension: versioned policy blocks and a toy policy DSL example (see policy.py changes).
|
|
- A packaging and publishing readiness plan (AGENTS.md, READY_TO_PUBLISH).
|
|
|
|
How to run locally
|
|
- Install dependencies and run tests via the included test script (test.sh).
|
|
- The MVP intentionally keeps crypto lightweight (HMAC-based signatures for demonstration) to enable fast iteration; replace with real cryptography when integrating into a production environment.
|
|
|
|
This repository is organized to be production-friendly and test-driven from the start.
|
|
|
|
Hooking into packaging
|
|
- This package is prepared for Python packaging under the name `idea164_bexproof_verifiable_best` as per the publishing requirements.
|
|
|
|
Note: See AGENTS.md for architectural guidelines and how future agents should contribute.
|
|
|
|
Toy policy snippet (example)
|
|
- Simple legacy policy shape (supported by load_policy):
|
|
{
|
|
"version": 1,
|
|
"rules": {
|
|
"price_improvement_min": 0.001,
|
|
"latency_budget_ms": 10
|
|
}
|
|
}
|
|
- Versioned policy blocks (new in this MVP):
|
|
{
|
|
"blocks": [
|
|
{"version": 1, "rules": {"price_improvement_min": 0.001, "latency_budget_ms": 10}},
|
|
{"version": 2, "rules": {"price_improvement_min": 0.0015, "latency_budget_ms": 8}}
|
|
]
|
|
}
|
|
Only the highest-version block will be applied by load_policy when blocks are present. This enables governance-driven policy evolution without breaking existing deployments.
|