NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Replicable Composition

Kiarash Banihashem, MohammadHossein Bateni, Hossein Esfandiari, Samira Goudarzi, MohammadTaghi HajiaghayiarXiv 2026

TL;DR

This paper resolves a fundamental open question in algorithmic stability by delivering the first "advanced composition theorem" for replicable algorithms, proving that $k$ independent problems can be solved simultaneously with a sample complexity that scales nearly linearly ($\widetilde{O}(\sum n_i)$) rather than quadratically. However, the authors uncover a striking catch: if an adversary can choose the problems adaptively based on prior answers, a quadratic sample blowup ($\Omega(nk^2)$) becomes provably unavoidable. Along the way, they introduce a novel "phantom run" technique to establish structural properties like label invariance and provide a new framework to boost algorithmic success probabilities at a minimal additive sample cost.

What Problem Does This Paper Address?

In modern data science, scientific reproducibility is a major crisis. To address this, researchers recently introduced the concept of replicability. An algorithm is considered replicable if, when run on two completely fresh datasets sampled from the same distribution, it outputs the exact same result with high probability—provided it uses the same internal random coins.

While individual replicable algorithms have been designed for tasks like statistical query estimation and PAC learning, a core structural question remained unanswered: How do these algorithms compose? If you want to solve $k$ different tasks simultaneously, each requiring $n$ samples to be replicable, how many total samples do you need?

A naive approach (running them in parallel) results in an error accumulation that requires $\widetilde{O}(nk^2)$ samples to fix. Indirect methods using Differential Privacy (DP) yield $\widetilde{O}(n^2k)$. This paper tackles the open question posed by Bun et al. (STOC’23): Can we achieve the optimal, linear $\widetilde{O}(nk)$ sample complexity scaling for composing replicable algorithms?

Methods

The authors achieve their optimal non-adaptive composition upper bound using a clever three-step pipeline that bridges replicability with another stability concept called Perfect Generalization (PG):

  1. Replicable to PG: They first convert each individual replicable algorithm into a perfectly generalizing algorithm. PG algorithms constrain the log-probability ratio of output events under resampling, acting similarly to differential privacy but over data distributions rather than specific datasets.
  2. Heterogeneous PG Composition: They compose these PG algorithms in the "distributional space" using a new privacy-style advanced composition theorem tailored for algorithms with different (heterogeneous) parameters.
  3. PG back to Replicable: Finally, they map the composed PG result back into a single replicable algorithm using correlated sampling—a strategy that synchronizes outputs across different runs using shared randomness.

To prove their lower bounds for the adaptive setting, the authors introduce the phantom run technique. This involves analyzing a hypothetical third independent execution of an algorithm to decouple the history of previous rounds from the current round, exposing how independent errors inevitably compound when adaptivity is permitted.

Datasets

Not discussed in the paper. This work is entirely theoretical and mathematical, relying on rigorous proofs, statistical bounds, and complexity analysis rather than empirical evaluation on datasets.

Key Insights and Ideas

  • Perfect Generalization is the Right Bridge: Directly translating between differential privacy and replicability incurs a quadratic sample blowup ($n \mapsto n^2$). Perfect generalization sits perfectly between the two, allowing a concentration-based analysis (where expected instability contributions scale as $\epsilon^2$ rather than $\epsilon$) without losing sample efficiency.
  • The Adaptivity Separation: In Differential Privacy, advanced composition holds whether the queries are chosen all at once (non-adaptive) or sequentially (adaptive). Replicability breaks this parallel. In the adaptive setting, algorithms must commit to outputs before seeing future tasks, forcing errors to behave independently and compound quadratically ($\Omega(nk^2)$). In the non-adaptive setting, algorithms can coordinate and correlate their errors, enabling linear scaling.
  • The "Phantom Run" Conceptual Shift: The phantom run shows that a replicable algorithm never needs to look at statistically irrelevant data. This allows any replicable algorithm to be transformed into an order-invariant or label-invariant version without losing accuracy or sample efficiency.

Key Results

  • Optimal Non-Adaptive Composition: Proved that $k$ statistical problems can be composed non-adaptively with a sample complexity of $\widetilde{O}(\sum_{i=1}^k n_i)$, achieving the optimal linear scaling and settling the STOC'23 open question.
  • Adaptive Lower Bound: Proved a tight lower bound of $\Omega(nk^2)$ for adaptive composition, establishing a definitive quadratic separation between adaptive and non-adaptive replicability.
  • Additive Boosting Framework: Developed a new boosting theorem showing that the failure probability ($\beta$) of a replicable algorithm can be driven down at an additive sample complexity cost rather than a multiplicative penalty. This immediately improved the known upper bounds for several canonical problems, such as Statistical Query estimation, PAC learning (finite classes, thresholds, Littlestone dimension), and the Heavy-hitters problem (see table below).
Problem Previous Sample Complexity Bound New Bound (This Work)
Statistical Query $O\left(\frac{\log(1/\beta)}{\alpha^2\rho^2}\right)$ $O\left(\frac{\log(1/\rho)}{\alpha^2\rho^2} + \frac{\log(1/\beta)}{\alpha^2}\right)$
Heavy-hitters $\widetilde{O}\left(\frac{\log(1/\beta)}{\nu\epsilon^2\rho^2}\right)$ $\widetilde{O}\left(\frac{1}{\nu\epsilon^2\rho^2} + \frac{\log(1/\beta)}{\epsilon^2}\right)$
PAC, Littlestone $\widetilde{O}\left(\frac{d^{12}\log^3(1/\beta)}{\alpha^2\rho^2}\right)$ $\widetilde{O}\left(\frac{d^{12}}{\alpha^2\rho^2} + \frac{\log(1/\beta)}{\alpha}\right)$

Limitations and Future Work

  • Computational Cost of Pointwise Invariance: While the paper proves that any replicable algorithm for a symmetric problem can be made pointwise label-invariant via correlated sampling, doing so requires exactly computing the algorithm's output distribution. This can be computationally prohibitive, meaning the result guarantees the existence of such an algorithm but not its efficient implementation.
  • Bypassing the Adaptive Barrier: Since adaptive composition faces a strict $\Omega(nk^2)$ barrier, future work could explore whether restricted classes of adaptive adversaries or relaxed definitions of replicability might allow for sub-quadratic sample complexity in sequential settings.

Summary updated

BibTeX
@misc{banihashem2026replicable,
  author = {Kiarash Banihashem and MohammadHossein Bateni and Hossein Esfandiari and Samira Goudarzi and MohammadTaghi Hajiaghayi},
  title = {{Replicable Composition}},
  year = {2026},
  eprint = {2604.10423},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2604.10423},
}
Figure