Back to AI Research

AI Research

DeepSWIP: Quotient-WMC Counterfactuals for Neural P... | AI Research

Key Takeaways

  • DeepSWIP: Quotient-WMC Counterfactuals for Neural Probabilistic Logic Programs Neurosymbolic systems, such as DeepProbLog, combine the perceptual power of ne...
  • Neurosymbolic systems such as DeepProbLog combine neural perception with probabilistic logic, but standard inference is associational.
  • Counterfactual reasoning additionally requires a causal semantics for interventions and evidence.
  • We introduce DeepSWIP, a single-world counterfactual semantics for DeepProbLog programs.
  • Under finite grounding and unique-supported-model assumptions, DeepSWIP is exact relative to the learned materialized FCM.
Paper AbstractExpand

Neurosymbolic systems such as DeepProbLog combine neural perception with probabilistic logic, but standard inference is associational. Counterfactual reasoning additionally requires a causal semantics for interventions and evidence. We introduce DeepSWIP, a single-world counterfactual semantics for DeepProbLog programs. Using neural materialization, we reduce fixed-context neural predicates to ordinary ProbLog choices, apply Single World Intervention Programs (SWIPs), and compute counterfactuals by weighted model counting (WMC) over a single transformed program. Under finite grounding and unique-supported-model assumptions, DeepSWIP is exact relative to the learned materialized FCM. The standard quotient-WMC form of ProbLog conditionals identifies active neural probabilities and explains intervention cleaning, calibration sensitivity, and rare-evidence instability. Experiments on MPI3D confirm the transformation against a DeepTwin construction against 12,000 queries, as predicted and a 2.14$\times$ inference speedup from avoiding the Twin's endogenous duplication. A SUMO HOV experiment shows that neural calibration degradation biases plug-in estimates, while a correctly scoped randomized-policy AIPW estimator removes most first-order bias for population mean and ATE estimands. Code is at this https URL .

DeepSWIP: Quotient-WMC Counterfactuals for Neural Probabilistic Logic Programs
Neurosymbolic systems, such as DeepProbLog, combine the perceptual power of neural networks with the structured reasoning of logic programs. While these systems are excellent at making predictions, they struggle with "counterfactual" reasoning—the ability to answer questions about what would have happened if a different action had been taken (e.g., "What would the traffic delay have been if the road had not been congested?"). DeepSWIP introduces a new method to perform this type of causal reasoning by transforming complex neural-symbolic programs into a single, unified framework that can be solved using standard mathematical techniques.

Simplifying Causal Reasoning

Traditional approaches to counterfactuals in logic programs often rely on "Twin Networks," which duplicate the entire program to represent both the factual world and the counterfactual world. This is computationally expensive and can be confusing when dealing with neural components. DeepSWIP avoids this duplication by using "neural materialization." It treats neural networks as fixed probability estimators rather than active, changing components. By freezing the neural output into a set of probabilistic choices, the system converts the entire neurosymbolic program into an ordinary probabilistic logic program, making it much easier to apply surgical interventions to specific parts of the logic.

The Power of Quotient-WMC

At the heart of DeepSWIP is an algebraic approach called "Quotient-WMC" (Weighted Model Counting). Once the program is transformed, the counterfactual probability is calculated as a ratio of two values: the likelihood of the counterfactual outcome given the evidence, divided by the likelihood of the evidence itself. This mathematical representation allows the researchers to analyze why certain systems might fail. It reveals that the stability of a counterfactual answer depends heavily on how well the neural network is "calibrated"—meaning its predicted probabilities must be accurate, not just its final classifications.

Performance and Reliability

The researchers tested DeepSWIP on complex tasks, including a traffic-monitoring simulation and a 3D object-tracking dataset (MPI3D). The results showed that DeepSWIP is significantly faster than the traditional Twin Network approach, achieving a 2.14x speedup in inference because it avoids redundant calculations. Furthermore, the study highlights a phenomenon called "rare-evidence instability." When the observed evidence is very unlikely, the counterfactual calculation can become highly sensitive to even tiny errors in the neural network's probability estimates. To address this, the paper suggests using advanced statistical techniques like Double Machine Learning (DML) to help reduce bias and improve the reliability of the results.

Key Takeaways

DeepSWIP provides a rigorous way to perform counterfactual reasoning in neurosymbolic systems without the overhead of duplicating the entire program. By framing counterfactuals as a quotient of weighted model counts, the authors provide a clear diagnostic tool for understanding why a model might produce unstable results. While the method is exact for a given set of neural probabilities, it serves as a reminder that the quality of the final causal answer is fundamentally tied to the calibration of the underlying neural components.

Comments (0)

No comments yet

Be the first to share your thoughts!