Introduction
The integration of neural perception with symbolic reasoning represents a significant frontier in artificial intelligence. While neural networks excel at processing raw data, symbolic logic provides the framework for rigorous relational reasoning. Existing neurosymbolic frameworks, such as DeepProbLog and NeurASP, often struggle with "brittle" logic—failing in the presence of contradictions, complex loops (non-stratified programs), or when exact probabilities are unavailable.
dPASP (differentiable Probabilistic Answer Set Programming) is introduced to bridge these gaps. It provides a robust environment capable of handling non-deterministic reasoning, logical inconsistencies, and interval-valued "vague" probabilities, all while remaining fully differentiable for end-to-end training.
Methodology
dPASP's core innovation lies in its synthesis of neural predicates, advanced logical semantics, and differentiable learning.
System Comparison
As shown in the comparison below, dPASP distinguishes itself by supporting non-stratified programs, inconsistent logic, and imprecise probabilities (credal semantics), features often missing in contemporary systems.
Core Components
- Neural Predicates: Logic rules are linked to PyTorch models, where the model's output determines the probability of a logical atom.
- Advanced Semantics:
- Maxent Semantics: Selects the most neutral distribution among multiple valid logical models.
- Credal Semantics: Facilitates interval-valued probabilities (e.g., [0.4, 0.7]), allowing the system to model epistemic uncertainty.
- L-stable Semantics: Employs a three-valued logic (True, False, Undefined) to maintain system stability during logical contradictions.
- Differentiable Learning: Training is achieved through a Lagrange multiplier derivation for gradient ascent, ensuring probabilities remain within the [0, 1] range without ad-hoc clipping.
Experimental Evaluation
The framework was evaluated across several benchmarks including MNIST digit classification and MNIST Addition. In the addition task, the system is given two images and their sum but is never explicitly told which image represents which digit, requiring the model to learn concepts through distant supervision.
Uncertainty and Imprecision
A key feature of dPASP is its ability to quantify uncertainty through credal semantics. By outputting a probability interval, the system can distinguish between aleatory uncertainty (inherent randomness) and epistemic uncertainty (lack of knowledge or conflicting data).
Key Results and Insights
- Superior Accuracy: In the MNIST Addition task, dPASP significantly outperformed purely data-driven CNNs. By leveraging the known rules of addition, the system achieved near 100% accuracy, whereas standard CNNs struggled to reach 50%.
- Inconsistency Tolerance: Unlike "explosive" logic systems where a single contradiction invalidates the entire model, dPASP's "least undefined" semantics isolates contradictions, allowing the rest of the reasoning process to proceed correctly.
- Efficiency: Despite its high-level abstraction, dPASP's C-based core minimizes Python overhead, achieving performance comparable to pure PyTorch implementations in several tests.
Limitations and Future Work
The current implementation of dPASP relies on exact inference through the enumeration of logical models, which presents a scalability challenge ($O(2^n)$). This limits the framework to programs with approximately 4,000 probabilistic choices.
Future developments will focus on implementing scalable methods such as Sentential Decision Diagrams (SDDs), sampling, and variational inference, alongside "relevance pruning" to enhance execution speed.
Summary updated