TY - GEN
T1 - Learning Probabilistic Termination Proofs
AU - Abate, Alessandro
AU - Giacobbe, M.
AU - Roy, Diptarko
PY - 2021/7/17
Y1 - 2021/7/17
N2 - We present the first machine learning approach to the termination analysis of probabilistic programs. Ranking supermartingales (RSMs) prove that probabilistic programs halt, in expectation, within a finite number of steps. While previously RSMs were directly synthesised from source code, our method learns them from sampled execution traces. We introduce the neural ranking supermartingale: we let a neural network fit an RSM over execution traces and then we verify it over the source code using satisfiability modulo theories (SMT); if the latter step produces a counterexample, we generate from it new sample traces and repeat learning in a counterexample-guided inductive synthesis loop, until the SMT solver confirms the validity of the RSM. The result is thus a sound witness of probabilistic termination. Our learning strategy is agnostic to the source code and its verification counterpart supports the widest range of probabilistic single-loop programs that any existing tool can handle to date. We demonstrate the efficacy of our method over a range of benchmarks that include linear and polynomial programs with discrete, continuous, state-dependent, multi-variate, hierarchical distributions, and distributions with undefined moments.
AB - We present the first machine learning approach to the termination analysis of probabilistic programs. Ranking supermartingales (RSMs) prove that probabilistic programs halt, in expectation, within a finite number of steps. While previously RSMs were directly synthesised from source code, our method learns them from sampled execution traces. We introduce the neural ranking supermartingale: we let a neural network fit an RSM over execution traces and then we verify it over the source code using satisfiability modulo theories (SMT); if the latter step produces a counterexample, we generate from it new sample traces and repeat learning in a counterexample-guided inductive synthesis loop, until the SMT solver confirms the validity of the RSM. The result is thus a sound witness of probabilistic termination. Our learning strategy is agnostic to the source code and its verification counterpart supports the widest range of probabilistic single-loop programs that any existing tool can handle to date. We demonstrate the efficacy of our method over a range of benchmarks that include linear and polynomial programs with discrete, continuous, state-dependent, multi-variate, hierarchical distributions, and distributions with undefined moments.
UR - http://www.scopus.com/inward/record.url?eid=2-s2.0-85115837465&partnerID=MN8TOARS
U2 - 10.1007/978-3-030-81688-9_1
DO - 10.1007/978-3-030-81688-9_1
M3 - Conference contribution
SN - 9783030816872
T3 - Theoretical Computer Science and General Issues
SP - 3
EP - 26
BT - Computer Aided Verification
A2 - Silva, Alexandra
A2 - Leino, K. Rustan M.
PB - Springer
CY - Cham
T2 - 33rd International Conference on Computer-Aided Verification
Y2 - 18 July 2021 through 24 July 2021
ER -