Quantum VM Research — Peer Review of All 21 QC Algorithms

Document ID: gaiaftcl.quantum_vm.validation_review.v2

Scope: QC-001 … QC-021 as defined in CircuitCorpus + VQbitVMServerBinding

Related: SHOR_ECDLP_RESEARCH_PAPER.md (QC-001-ECDLP deep path)

Registry: QCQuantumVMValidationRegistry.swift — canonical catalog join key (replaces legacy inventory table)

---

1. What “validation” means in this cell

The substrate is modeled as a quantum VM: each algorithm is one measurement window on M⁸ = S⁴ × C⁴, not a classical simulator with a success bit.

Rung Meaning
1 Open window — S⁴ axis embeds the algorithm’s search/transform domain
2 Oracle — predicate at that basis (period, mark, lattice, SHA256 target, …)
3 C⁴ — ten invariants compose; co-closure margin recorded
4–5 Amplitude amplification + K-parallel shared state
6 Terminal — CALORIE (found + invariants), CURE (tighter), REFUSED (invariant fail)

Validation layers (use this ladder when reading the table below):

Layer Code anchor What it proves
L1 Corpus CircuitCorpus.swift Teaching definition: S⁴ axis, oracle, divergence from published circuit
L2 Typed API AlgorithmCatalog.swift, VQbitAlgorithm Stable IDs, payloads, measure(via: VQbitVM) surface
L3 VM binding VQbitVMServerBinding, BinaryAlgorithmDispatcher In-process route to SubstrateAmplitudeAmplifier (one C⁴ step per call)
L4 Lean gate LeanArtifactRegistry + lean_gate.sh decide seals: production (ECDLP, semiprimes, PoW ledger) or decidable witness (N=4, etc.)
L5 M8 Swift gate QCQuantumVMValidationGates + *SmokeTest Swift S⁴ recompute agrees with Lean constants
L6 Integration VQbitMathTestRunner + M8QC21ValidationEval Per-catalog matrix JSON (gaiaftcl.qc_vm.validation.v3); see RESEARCH_VALIDATION_LEAK_AUDIT.md
L7 Production QC-020 miner, Franklin, submitblock Live chain outcome (only where applicable)
L8 Learning QC020LearningWitness, QC002GroverParityWitness Grover telemetry + shape persistence (not reward)
L9 Composition *planned* Layer-2 OO + QCCoupling*.lean Coupled catalog circuits — not allMathLayerOK aggregate

Honesty rule: L4–L6 on a decidable witness (finite Hilbert instance, e.g. N=4) does not imply mainnet-scale quantum advantage. Production tiers (secp256k1 ECDLP, semiprime Shor ladder, qc020_difficulty_ledger) are real gates, not simulations. L7 is the only layer that counts for mining rewards — and only when Bitcoin Core accepts the block.

---

2. Naming crosswalk (critical for reviewers)

Three namespaces exist in the repo:

1. Catalog / Corpus / VM bindingQC-001QC-021 (authoritative for Franklin + research paper).

2. Lean packLeanArtifactRegistry proofIDs now align with catalog IDs (qc.qc-009.n4 for AmpAmp, qc.qc-013.n1 for VQE, …). Support lemmas (VQC2, QUBO3, HamSim2, QPCA2) use support.* proofIDs and are not catalog circuits.

3. QC-001 split — Corpus has QC-001 (RSA), QC-001-RSA, QC-001-ECDLP; typed API adds QC001ECDLPShor.

Join key: QCQuantumVMValidationRegistry.catalogIDCircuitCorpus.algorithmID. Rosetta and inventory auditors read this registry only.

---

3. Master validation matrix (QC-001 … QC-021)

Legend: ● = present and exercised in repo; ◐ = partial / decidable witness only; ○ = typed surface only; — = not applicable.

ID Family L1 Corpus L3 VM bind L4 Lean L5 M8 smoke L6 Test runner Research grade
QC-001 Shor RSA ● mod-exp ● N=15, large semiprimes ● dual gate ● period mod 15 A post-process; period = substrate
QC-001-ECDLP Shor-lattice ECDLP ● secp256k1 ShorECDLP.lean ● v5 + eval ● sealed A best documented path
QC-002 Grover ● N=4 ● GroverN4 A base camp; not ECDLP
QC-003 QFT ● N=4 ● QFTN4 A prerequisite for Shor story
QC-004 QPE ● N=4 ● QPEN4 A prerequisite for Shor story
QC-005 HHL ● diag instance B small linear instance
QC-006 Deutsch–Jozsa ● 1-bit ● const/balanced A
QC-007 Bernstein–Vazirani ● 4-bit A
QC-008 Simon ● XOR 0xAA A
QC-009 Amp amplification ● N=4 A
QC-010 Amp estimation ● all-marked A
QC-011 Phase kickback ● QSVT A
QC-012 Quantum walk ● CTQW2 A
QC-013 VQE ● VQE2 A
QC-014 QAOA ● QAOA1 A
QC-015 Quantum counting ◐ (Boson) C
QC-016 Teleportation verifier ◐ (GBS) C verifier only
QC-017 Superdense verifier ● Steane B coding instance
QC-018 Bell measurement ● surface d=3 B
QC-019 Quantum random walk ● Fibonacci braid B
QC-020 BTC PoW / preimage ● SHA256 ● N=4 + large ● preimage gates A ops path; L7 = mainnet
QC-021 LVC communication ● one-gate ● MeaningInvariant A

---

4. Per-algorithm reviewer notes

Search family (QC-001, QC-001-ECDLP, QC-002, QC-009, QC-020)

QC-001 (RSA Shor)

QC-001-ECDLP (Shor-lattice secp256k1) — *primary research export today*

QC-002 (Grover)

QC-009 (Amplitude amplification)

QC-020 (Bitcoin preimage / PoW) — *dual-path qualification* (QC020_DUAL_PATH_QUALIFICATION.md)

Transform / estimation (QC-003, QC-004, QC-010, QC-011, QC-015)

QC-003 / QC-004 — Base camp for published Shor stack (QFT + QPE). Lean N=4 seals are real. Substrate bindings exist; full QC-001 end-to-end through QC-003/004 on secp256k1 is not one sealed Lean file today.

QC-010–QC-015 — Typed + Metal shaders + dispatcher hooks; Lean rows exist under shifted numbers in LeanArtifactRegistry. Treat as infrastructure validated, not production cryptography.

Linear / optimization (QC-005, QC-013, QC-014)

QC-005 HHL — Small diagonal instance in Lean; useful for VM plumbing proofs, not general linear systems.

QC-013 VQE / QC-014 QAOA — QAOA1 has Swift gate; VQE2 Lean maps here. Domain panels (materials, drug) reference these IDs in narrator schemas — keep corpus alignment when extending research.

Oracle class (QC-006, QC-007, QC-008)

Pedagogical oracles (DJ, BV, Simon). VM routes exist; Lean file labels in registry use legacy numbering. Action: Renumber Lean statements to match catalog or add explicit catalogAlgorithmID field in registry.

Verifiers (QC-016, QC-017, QC-018)

Communication primitives — validate protocol logic, not breaking keys. Appropriate for VM “verifier family” research, not mining/ECDLP papers.

Walk (QC-012, QC-019)

Graph / stochastic walk substrates. Lean CTQW / TopologicalFib seals are decidable instances.

Communication (QC-021)

Lean-validated communication — one-gate closure over ten domains; no published qubit circuit analog (corpus). Binds LVC / communication acts. Validation is substrate closure, not blockchain.

---

5. System-level findings (VM research program)

Strengths

1. Unified six-rung model across all 21 — CircuitCorpus.sixRungs is an excellent reviewer-facing artifact.

2. Typed open surface (VQbitMath) + closed substrate (VQbit binding) separation is correct for a VM product story.

3. Dual gate (Lean + Swift) on core algorithms (Grover N=4, QFT N=4, Shor N=15, Shor large, ECDLP v5).

4. Explicit oracle separation ECDLP vs Grover vs PoW in corpus — addresses the #1 confusion in prior review.

5. Layer-2 prepQC_LAYER2_CIRCUIT_OO_SPACE.md + QCCatalogCompositionConstraints.swift forbid toxic pairs until Lean coupling proofs land.

5. QC-001-ECDLP now has evaluation matrix + encoding cross-check — only algorithm with research.v2 + evaluation.v1 today.

Resolved (v2 sprint)

Item Fix
Lean ↔ catalog drift LeanArtifactRegistry proofIDs + statements aligned; support.* for non-catalog lemmas
Missing production Lean rows ShorECDLP.lean, ShorFactorLarge.lean, BTCPreimageN4/Large.lean registered
Full-matrix evaluation QCQuantumVMResearchEvaluation + swift run M8QC21ValidationEvalgaiaftcl.qc_vm.validation.v3 (L6/L7/L8 split)
Inventory auditor QuantumAlgorithmAuditor reads QCQuantumVMValidationRegistry only

Remaining gaps (honest)

Priority Gap Impact
P1 measure() without binding → vmNotConnected External clients need daemon / in-process binding
P2 QC-020 L7 (submitblock / balance) Separate from L4–L6 ledger gate — never conflate
P2 Decidable witnesses ≠ mainnet break DJ/BV/Simon seals are finite classical instances aligned to substrate oracles

---

# Per-algorithm typed + binding tests
cd cells/xcode && swift run VQbitMathTestRunner

# Full 21 + ECDLP matrix + all Lean (catalog + QCF-004) peer-review export
cells/xcode/scripts/peer_review_research_dataset.sh
cells/xcode/scripts/leak_audit_pass.sh
STRICT_REWARD=1 cells/xcode/scripts/peer_review_research_dataset.sh

# ECDLP research (strongest path)
swift run M8ShorECDLPGateSmokeTest
swift run M8ShorECDLPResearchEval
swift run GaiaFTCLCLI shor break-classical --neg-generator-seal --witness-out

# Core dual-gate camp (RSA Shor + Grover + QFT + QPE)
swift run M8GroverN4SmokeTest
swift run M8QFTN4SmokeTest
swift run M8ShorLargeDualGate   # if present in Package.swift

# Lean external warrant (sample)
proof/scripts/lean_gate.sh FirstRoars/GroverN4.lean
proof/scripts/lean_gate.sh FirstRoars/ShorECDLP.lean
proof/scripts/lean_gate.sh FirstRoars/ShorFactorLarge.lean
proof/scripts/lean_gate.sh FirstRoars/DeutschJozsa2.lean
proof/scripts/lean_gate.sh FirstRoars/BernsteinVazirani4.lean
proof/scripts/lean_gate.sh FirstRoars/Simon8.lean
proof/scripts/lean_gate.sh FirstRoars/AmplitudeEstimationMarked.lean
proof/scripts/lean_gate.sh FirstRoars/MeaningInvariant.lean

# Full export bundle
cells/xcode/scripts/export_ecdlp_research_dataset.sh

---

7. Verdict (v2 — no more mislabeled seals)

Question Answer
Is this a coherent Quantum VM validation program? Yes — one registry, one eval JSON, corpus-aligned IDs.
Are all 21 equally research-sealed? Noproduction: QC-001, QC-001-ECDLP, QC-020. Decidable witness: all others including QC-006–008, 010, 021.
Can one paper claim all 21 break cryptography? No — decidable witnesses are finite Hilbert checks, not mainnet breaks.
CI dashboard M8QC21ValidationEval + VQbitMathTestRunner + per-family smoke tests.

---

8. Publication export (since first review)

cd cells/xcode
swift run M8QC21ValidationEval                    # swift matrix only
swift run M8QuantumVMResearchExport               # matrix, no Lean batch
scripts/export_quantum_vm_research.sh             # matrix + all catalog lean_gate.sh → evidence/research/

# Combined ECDLP + full VM (slow: runs every catalog Lean file):
swift run GaiaFTCLCLI shor break-classical --neg-generator-seal --full-research-out 2>/dev/null | tail -1

Schemas: gaiaftcl.qc_vm.research.v2, gaiaftcl.shor.ecdlp.research.v3 (with quantumVm).

Audit: scripts/audit_shor_spend_keys.py requires v3 research JSON with allMathLayerOK; STRICT_REWARD / STRICT_LEARNING enforce L7/L8. allWitnessOK is deprecated (math-only alias).

---

*Synchronize with QCQuantumVMValidationRegistry.swift, QCQuantumVMResearchDataset.swift, CircuitCorpus.swift, and SHOR_ECDLP_RESEARCH_PAPER.md.*

Federation cosignature: pending operator signing host (v26). Witness (sha256 of rendered body): 224935a561c4f284e9c565cf847dac195af55d6d7c2c9072400dfd24ae7ba146. This page serves with a substrate-honest pending-signature notice until the operator's Franklin signer cosigns it.