X402 Git

prediction-audit-calibration-ledger

Tamper-evident forecast recording, SHA-256 commitment verification and Brier-score calibration for models and agents.

Top level of the repository
SizeFolderInside
1.7 kBexamples/1 script
8.5 kBsrc/1 script
5.1 kBtests/1 test file
19.3 kB(root)14 docs · 2 config files
21 files · 34.7 kB · computed 2026-09-16
SizePath
46 B.gitignore
1.3 kBAGENT_EVAL.md
2.2 kBARCHITECTURE.md
322 BCHANGELOG.md
411 BDEPENDENCIES.md
1.7 kBLICENSE.md
602 BLIMITATIONS.md
2.1 kBPREVIEW.md
1.2 kBQUICKSTART.md
2.5 kBREADME.md
734 BSECURITY.md
738 BSUPPORT.md
702 BTEST_REPORT.md
225 BTHIRD_PARTY_NOTICES.md
812 BTHREAT_MODEL.md
386 BVERIFICATION.md
1.1 kBcommercial-manifest.json
1.7 kBexamples/verify_predictions.py
2 kBrelease-manifest.json
8.5 kBsrc/ledger.py
5.1 kBtests/test_ledger.py
computed 2026-09-16 21:17 UTC · analyzer 0.1.0

Already bought this?

View your purchases

README

Prediction Audit & Calibration Ledger

Tamper-evident forecast recording, verification and Brier-score calibration.

Tests License Zero Runtime Deps


1. WHAT IS THIS?

The Prediction Audit & Calibration Ledger is a standalone Python library for quantitative funds, research desks, AI signal providers, and prediction markets to record pre-event forecasts in a continuous, tamper-evident cryptographic hash chain and score their realized accuracy using Brier scoring rules upon post-event resolution.

2. WHO IS IT FOR?

  • Quantitative researchers and algorithmic trading firms.
  • Prediction market operators and signal providers.
  • AI forecasting model evaluators seeking mathematical proof of model calibration.

3. WHAT PROBLEM DOES IT SOLVE?

Without pre-event cryptographic commitments, historical trading signals and prediction records are susceptible to "hindsight bias," cherry-picking, and retroactive tampering. Running full Web3 blockchain smart contracts for high-frequency predictions incurs prohibitive gas fees and leaks alpha publicly before execution. This ledger provides local, zero-gas, tamper-evident hash chaining.

4. WHY PAY FOR IT INSTEAD OF BUILDING IT?

  • Canonical Payload Serialization: Uses deterministic key sorting to guarantee that identical payloads always yield identical SHA-256 digests.
  • Tamper Evidence: Detects any retroactive field mutation, record deletion, or row reordering during chain traversal.
  • Calibrated Brier Scoring: Implements mathematically validated binary and multi-class Brier scoring algorithms ($BS = \sum (p_k - o_k)^2$).
  • Zero External Dependencies: Built 100% on Python 3.11+ standard library (hashlib, sqlite3, json, dataclasses).

5. WHAT IS VERIFIED?

  • 7 / 7 Automated Unit Tests Passed: Reference mathematical Brier scoring, pre-event commitments, mutation detection, deletion detection, row swapping, SQLite database reopen, and 1,000-record scale test.
  • Microsecond Execution: Traversal and verification of 1,000 chained entries completes in < 15 ms.

6. HOW DO I RUN IT?

# 1. Run the unit test suite
python3 -B tests/test_ledger.py

# 2. Run the interactive verification demonstration
python3 -B examples/verify_predictions.py

Security scan report

Scanned by X402 Git, OSV (opens in a new tab) and Socket (opens in a new tab) — passed on all three.

secrets
none found
X402 Git
size limits
within caps
X402 Git
known malware
no dependency manifests to check
OSV
known vulnerabilities
no dependency manifests to check
OSV
dependency behaviour
no dependency manifests to check
Socket
instruction smuggling
none found
X402 Git
what it can do
nothing to declare
X402 Git

What this can do

links to 1 host in its docs · nothing runs at install

Releases 1

  1. v1.0.02026-09-16

    release: v1.0.0 commercial source edition

$99updates $19

Buy — go to the order block