Semiprime Factorization with Discrete Diffusion and Beam Search: Scaling Laws
Brendan O Donoghue, Nenad Tomasev, Volodymyr Mnih, Timothy Nguyen, Dalin Guo, Arun Nair, Kenneth Yang, Alexandre Frechette, Jasper Xian, Jean Tarbouriech, Pavel Tyletski, Ingrid von Glehn, Johannes Bausch, Demis Hassabis, Raia Hadsell
Abstract
We demonstrate that transformer architectures trained with discrete denoising diffusion and decoded via guided test-time beam search can learn to recover the prime factors of semiprime integers directly from data. Our approach establishes a new frontier for learning-based semiprime factorization, successfully factoring 68-bit integers-a substantial advance over the prior 56-bit state of the art. While computationally less efficient than classical factoring algorithms, our model requires no domain-specific number-theoretic priors and learns purely from training examples. In practice, the diffusion model acts as a generative prior, identifying promising factor candidates where exact verification or lattice-based post-processing can complete the factorization. Furthermore, we derive empirical scaling laws relating approximation quality to training data volume, model size, and test-time computation. In contrast to language, problem size is the key driver of scaling behavior. Achieving a fixed accuracy on a held-out test set requires compute that scales exponentially with bit length. Consequently, our findings pose no threat to security, as the projected compute cost required to factorize cryptographically relevant integers remains prohibitive.
Create a lesson
Related papers
Stein Guidance without Gradients: Discretization Uniform Diffusion Inference Time Scaling beyond Particle SMC
Shared title terminologycs.LGYouheng Zhu, Chenyang Wang, Minshuo Chen et al.
Discrete Diffusion Playground: A 2D Benchmark for Discrete Generative Models
Shared title terminologycs.LGJustin Shao, Sihyun Park, David Ryan Koes et al.
CHARM: Certified Homology-Aware Reverse-scale Mapping via Diffusion-Guided Quotient Towers
Shared title terminologycs.LGZhe Li
CrysLDM: Latent Diffusion Model for Crystal Material Generation
Shared title terminologycs.LGSubhojyoti Khastagir, Kishalay Das, Pawan Goyal et al.
Think Before You Forecast: Scaling Test-Time Compute for Time Series Forecasting
Shared title terminologycs.LGDaojun Liang, Xiao Hong, Pei Zhang et al.
OnCache: Learning Dynamic Caching Schedules for Efficient Diffusion Inference
Shared title terminologycs.LGZhikang Xie, Xichen Ye, Yifan Wu et al.