Bayesian Separation Logic

📅 2025-07-21
📈 Citations: 0
Influential: 0
📄 PDF
🤖 AI Summary
Existing separation logics lack support for Bayesian updating, hindering formal semantic foundations for Bayesian probabilistic programming languages (BPPLs). Method: We introduce Bayesian Separation Logic (BaSL), the first separation logic incorporating Bayesian updating, conditional distributions, and conjugate priors. Leveraging the Rokhlin–Simmons decomposition theorem, we formally prove an internal Bayesian theorem. We construct a Kripke resource monoid model over σ-finite measure spaces, integrating measure theory, separation logic, and the s-finite kernel category to interpret Hoare triples with probabilistic independence. Contribution/Results: BaSL enables modular, machine-verifiable reasoning about statistical properties of BPPL programs. We demonstrate its efficacy on canonical examples—including coin inference, collision network correlation, alarm posterior computation, parameter estimation, and Gaussian mixture models—establishing the first compositional, semantics-based verification framework for BPPLs.

Technology Category

Application Category

📝 Abstract
Bayesian probabilistic programming languages (BPPLs) let users denote statistical models as code while the interpreter infers the posterior distribution. The semantics of BPPLs are usually mathematically complex and unable to reason about desirable properties such as expected values and independence of random variables. To reason about these properties in a non-Bayesian setting, probabilistic separation logics such as PSL and Lilac interpret separating conjunction as probabilistic independence of random variables. However, no existing separation logic can handle Bayesian updating, which is the key distinguishing feature of BPPLs. To close this gap, we introduce Bayesian separation logic (BaSL), a probabilistic separation logic that gives semantics to BPPL. We prove an internal version of Bayes' theorem using a result in measure theory known as the Rokhlin-Simmons disintegration theorem. Consequently, BaSL can model probabilistic programming concepts such as Bayesian updating, unnormalised distribution, conditional distribution, soft constraint, conjugate prior and improper prior while maintaining modularity via the frame rule. The model of BaSL is based on a novel instantiation of Kripke resource monoid via $σ$-finite measure spaces over the Hilbert cube, and the semantics of Hoare triple is compatible with an existing denotational semantics of BPPL based on the category of $s$-finite kernels. Using BaSL, we then prove properties of statistical models such as the expected value of Bayesian coin flip, correlation of random variables in the collider Bayesian network, and the posterior distributions of the burglar alarm model, a parameter estimation algorithm, and the Gaussian mixture model.
Problem

Research questions and friction points this paper is trying to address.

Lack of separation logic for Bayesian updating in BPPLs
Inability to reason about expected values and variable independence
Need for modular semantics supporting Bayesian probabilistic concepts
Innovation

Methods, ideas, or system contributions that make the work stand out.

Introduces Bayesian separation logic (BaSL)
Uses Rokhlin-Simmons disintegration theorem
Models probabilistic programming concepts modularly
🔎 Similar Papers
No similar papers found.