POPL 2027
Sun 10 - Sat 16 January 2027 Mexico City, Mexico

Causal Inference is the statistical discipline that seeks to give quantitative answers to questions beyond Bayesian conditioning (rung 1), about causal relationships (rung 2, “does smoking cause cancer?”) and counterfactuals (rung 3, “had I not smoked, what is the probability that I would not have got cancer?”). Pearl answers such questions by syntactic surgeries on structural causal models (SCMs), which can be thought of as a restricted form of Bayesian networks. Causal probabilistic programming seeks to make these surgery operations first-class on expressive probabilistic programs, but existing systems often rely on non-standard evaluation strategies, lack semantic foundation, and only loosely relate to Pearl’s original definitions. In this paper, we give a novel semantic account of causal modelling that generalises cleanly to higher order. In analogy to Pearl’s three rungs of causality, we develop a hierarchy of three first-order probabilistic programming languages, and describe causal operations as program transformations between them. We also develop an equivalent denotational description where interventions are tracked using grading, and counterfactuals using vectorisation. Our semantic framework conservatively generalises structural causal models: each structural causal model can be compiled into a program, preserving causal operations. Moreover, thanks to the denotational semantics, our framework conservatively extends to a higher-order causal language for free, where a rich class of higher-order and cross-world interventions become expressible as ordinary functional prorgamming abstractions.