EM-NeSy: Expectation Maximization for Neurosymbolic Learning
About
Neurosymbolic (NeSy) models integrate neural networks and symbolic reasoning for robust and interpretable AI. State-of-the-art NeSy models require that the symbolic component is expressed in a differentiable way, often complicating the use of approximate inference. We propose EM-NeSy which casts probabilistic NeSy learning as an instance of the Expectation-Maximization (EM) algorithm. In the expectation step, we compute the posterior over the neurally predicted symbols conditioned on the label via probabilistic inference. In the maximization step, we update the neural parameters based on this posterior using gradient descent only through the neural component. This formulation unlocks the full potential of the EM algorithm for NeSy learning. It allows NeSy to extend naturally to approximate reasoning without any additional modifications or differentiability requirements of the symbolic component. Furthermore, it recovers the standard end-to-end gradient-based NeSy setting under exact inference. Our experimental results demonstrate the scalability and computational efficiency of EM-NeSy.
Related benchmarks
| Task | Dataset | Result | Rank | |
|---|---|---|---|---|
| Sudoku Classification | Visual Sudoku 9x9 | Accuracy53.3 | 9 | |
| Visual Sudoku Solving | Visual Sudoku 4x4 | -- | 7 | |
| MNIST Addition | MNISTAdd 4 digits | Accuracy92.53 | 6 | |
| MNIST Addition | MNISTAdd 15 digits | Accuracy74.85 | 5 | |
| Warcraft path-planning | Warcraft path-planning 12 x 12 grid | Accuracy98.8 | 5 | |
| MNIST Addition | MNISTAdd 100 digits | Accuracy9.2 | 4 | |
| Warcraft path-planning | Warcraft path-planning 30 x 30 grid | Accuracy69.6 | 4 |