Fixed-parameter tractable inference for discrete probabilistic programs, via string diagram algebraisation

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Peterseim, Benedikt, Lopuhaä-Zwakenberg, Milan
Format: Preprint
Published: 2026
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866917442985394176
author Peterseim, Benedikt
Lopuhaä-Zwakenberg, Milan
author_facet Peterseim, Benedikt
Lopuhaä-Zwakenberg, Milan
contents Discrete probabilistic programs (DPPs) provide a highly expressive formalism for compactly defining arbitrary finite probabilistic models. This expressivity comes at a price: DPP inference is PSPACE-hard. In this work, we show that DPP inference only takes polynomial time for programs that are 'structurally simple'. More precisely, inference can be performed in polynomial time when the primal graph of each function appearing in the probabilistic program has bounded treewidth, and the inverse acceptance probability is at most exponential in the size of the probabilistic program. Existing algorithms do not achieve this performance guarantee. Our method relies on finding suitable decompositions, algebraisations, of the string diagrams underlying DPPs, employing existing algorithms for tree decompositions. This is independent of the probabilistic setting of DPPs and has direct applications to many problems, such as evaluating queries on relational databases and cybersecurity risk assessment via attack trees.
format Preprint
id arxiv_https___arxiv_org_abs_2604_25321
institution arXiv
publishDate 2026
record_format arxiv
spellingShingle Fixed-parameter tractable inference for discrete probabilistic programs, via string diagram algebraisation
Peterseim, Benedikt
Lopuhaä-Zwakenberg, Milan
Data Structures and Algorithms
F.2.2; F.3.2; G.3
Discrete probabilistic programs (DPPs) provide a highly expressive formalism for compactly defining arbitrary finite probabilistic models. This expressivity comes at a price: DPP inference is PSPACE-hard. In this work, we show that DPP inference only takes polynomial time for programs that are 'structurally simple'. More precisely, inference can be performed in polynomial time when the primal graph of each function appearing in the probabilistic program has bounded treewidth, and the inverse acceptance probability is at most exponential in the size of the probabilistic program. Existing algorithms do not achieve this performance guarantee. Our method relies on finding suitable decompositions, algebraisations, of the string diagrams underlying DPPs, employing existing algorithms for tree decompositions. This is independent of the probabilistic setting of DPPs and has direct applications to many problems, such as evaluating queries on relational databases and cybersecurity risk assessment via attack trees.
title Fixed-parameter tractable inference for discrete probabilistic programs, via string diagram algebraisation
topic Data Structures and Algorithms
F.2.2; F.3.2; G.3
url https://arxiv.org/abs/2604.25321