Docs · Start
Architecture
Research lanes, frozen contracts C0–C7, security games and how evidence reaches the UI.
Research lanes
QMint is built by parallel research lanes, each owning one package or directory and merging through the lead. The live status of every lane and gate is on the overview (read from project/TRACKER.yaml).
| Lane | Package | Scope | CLI |
|---|---|---|---|
| A | research/ | Literature, theorem registry seed, prior-art matrix, corrections, novelty audit | files |
| B | qmint.protocols | Wiesner, Kent 2022 S-money and Schiansky 2023 payment state machines | simulate |
| C | qmint.attacks | Adversaries, Monte Carlo attacks, W1 Choi-matrix SDP with certified duals | attacks |
| D | qmint.proofs | Proof obligations, ideal and finite-size bounds, independent checker | proofs |
| E | qmint.photonics | Zenodo 7979319 photon timetags, QBER reproduction, calibration | data |
| F | qmint.quantum | BB84 circuits, noise channels, cloners, Qiskit/QuTiP cross-checks | — |
| G | qmint.networks | Discrete-event causal simulator, Jiang 2024 topologies, RIPE Atlas latency | — |
| H | qmint.classical | Classical double-spend baselines H0–H6 and the comparability matrix | baselines |
| I | qmint.compiler | Resource-optimised certificate compiler (savings do not survive calibration uncertainty) | compiler |
| J | qmint.quantum.ionq | IonQ / Qollab hardware path (dry-run only) | qollab |
| K | qmint.api · web/ | Research API and this website | — |
| L | qmint.core | Frozen contracts, records, configuration, pipeline | doctor |
| N | qmint.evaluation | Figures and tables (manuscript not yet written) | figures · paper |
Frozen contracts C0–C7
Lanes communicate only through frozen Pydantic v2 contracts in qmint/core/contracts.py (schema 1.0.0). JSON Schemas live in schemas/v1/, and their hashes are enforced by tests/contracts. Changes go to schemas/v2/ through a lead-approved migration.
| Contract | Models | Key invariants |
|---|---|---|
| C0 | ProtocolSpec | protocol_id must be registered in PROTOCOL_GAMES; the game must be one of that protocol's games |
| C1 | TokenRecord, IssuerSecret | public metadata rejects secret-like keys; IssuerSecret refuses serialisation and is redacted in repr |
| C2 | MeasurementEvent, PhotonEvent, CalibrationRecord | PHOTON_EXPERIMENT calibration requires a dataset SHA-256; fractions in [0, 1]; experiment family must match the consumer |
| C3 | AttackResult | successes ≤ trials; Monte Carlo requires a CI; SDP evidence requires primal, dual and dual residual |
| C4 | SpacetimeNetwork, TransactionTrace | links reference known sites; no retrocausal edges; local validation, settlement and irrevocability are distinct events |
| C5 | SecurityCertificate, BoundRequest, BoundResult | default UNCERTIFIED with null bounds; CERTIFIED only with met assumptions, proof ref, checker id, evidence hashes and every target bounded |
| C6 | BenchmarkRecord, EvidenceManifest | quantum/classical flag consistent with protocol id; every record carries evidence kind, git sha and environment lock |
| C7 | enums, Interval, Unit | BB84 (Z,0)=|0⟩ (Z,1)=|1⟩ (X,0)=|+⟩ (X,1)=|−⟩; no implicit little-endian decoding; time in ns; ε is a maximum adversary win probability, never an error bar |
Security games
A bound is valid only for its own game. QMint never moves a theorem across games: W1 ≠ W1_CV ≠ W2 ≠ S1 ≠ S2 ≠ D1 ≠ A1. The registry with theorem anchors is at GET /api/v1/games.
| Game | Definition | Bound |
|---|---|---|
| W1 | Molina–Vidick–Watrous 2012 simple 1→2 counterfeiting, exact verifier | (3/4)^n |
| W1_CV | MVW classical-verification variant | (3/4 + √2/8)^n |
| W2 | Noisy / threshold Wiesner | no closed form |
| S1 | Kent et al. 2022 ideal two-site S-token | (1/2 + 1/(2√2))^N |
| S2 | Kent et al. 2022 realistic noisy/lossy S-token | finite-size lemmas |
| D1 | Schiansky et al. 2023 quantum-digital payment | never certified |
| A1 | Gavinsky et al. 2025 anonymity / issuer tracking | not verified |
| C1 | Classical double-spend systems game | no theorem |
From lane to screen
A number reaches the screen through four steps, and keeps its label at each one:
- A lane computes it and wraps it in a contract (for example an
AttackResultwithMONTE_CARLOevidence and a Clopper–Pearson interval). - The API turns it into a
Quantity: value, unit, evidence kind, method, source and optional interval. Anullvalue means “not available”, never 0. - The response envelope adds
status(OK,DEMO_ADAPTER,NOT_AVAILABLE),reasonandprovenance(git sha, time, seed, software versions). - The web app renders the value next to its
EvidenceLabel, generated from the same Python table.
Web application
The site is a Next.js App Router application in web/. The marketing route group serves /; the platform group wraps /app, /lab/*, /benchmarks, /certificates, /research and /docs in one shell (sidebar, breadcrumbs, ⌘K palette). Design tokens are in app/globals.css; primitives in components/ui; the typed client in lib/api.