Reverse-engineers compiled Shor's algorithm: extracts hidden a and N, de-route SWAPs, verify by sim.
53
Shor-Rev-Engine reverse-engineers compiled implementations of Shor's algorithm through a four-stage pipeline: (1) ingestion & parsing of OpenQASM netlists (plus text-level QIR / circuit-graph-JSON classification) into gates, registers and a circuit DAG; (2) inverse transpilation / de-routing that strips coupling-only SWAP networks back to clean logical gates; (3) structural pattern matching that detects the Hadamard superposition layer, the modular exponentiation oracle f(x) = a^x mod N (ripple-carry adder markers included) and the inverse QFT, and recovers the hidden base a and modulus N from constant-folding metadata; and (4) state-vector verification that simulates the extracted oracle, checks the inverse-QFT peaks against the predicted period r, and recovers the factors by classical post-processing.
Two synthetic samples ship in the box: N=15, a=7 (period 4, factors 3 x 5, exact peaks) and N=21, a=2 (period 6, factors 3 x 7). Local, synthetic, educational only — HOLD gates block live hardware, cloud submission and any non-consented key use. The runnable implementation is the zero-dependency Python model; the Rust crates are spec source mirroring it. ONE interface (main.py).
docker pull credkellar/shor-rev-engine
docker run --rm credkellar/shor-rev-engine
Content type
Image
Digest
sha256:7a33b098e…
Size
48.6 MB
Last updated
4 days ago
docker pull credkellar/shor-rev-engine