← Latest papers
🤖 machine learning

EM-NeSy: Expectation Maximization for Neurosymbolic Learning

This paper introduces EM-NeSy, a novel neurosymbolic learning framework that leverages the Expectation-Maximization algorithm to enable scalable and efficient training without requiring the symbolic component to be differentiable, thereby supporting both exact and approximate reasoning.

Original authors: Annegret Seibt, Luc De Raedt, Giuseppe Marra

Published 2026-06-15
📖 6 min read🧠 Deep dive

Original authors: Annegret Seibt, Luc De Raedt, Giuseppe Marra

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

The Big Picture: Teaching a Robot to Think and Reason

Imagine you are trying to teach a robot two things at once:

  1. Perception: How to look at a blurry photo and guess what the objects are (like recognizing a handwritten number). This is done by a Neural Network (the "Neural" part).
  2. Reasoning: How to check if those objects make sense together according to a set of rules (like checking if a Sudoku puzzle is valid). This is done by Symbolic Logic (the "Symbolic" part).

Current methods try to teach these two parts simultaneously by connecting them with a "wire" that allows the robot to learn from its mistakes. However, this wire has a problem: if the logic part is too complex or uses a method that doesn't play nice with math (like random sampling), the "wire" breaks. The robot can't learn because it can't calculate the exact direction to fix its mistakes.

EM-NESY is a new way of teaching the robot that removes this "wire" entirely. Instead of forcing the two parts to talk to each other constantly during the learning process, it lets them take turns.


The Analogy: The Art Critic and the Apprentice

To understand how EM-NESY works, imagine an Apprentice Artist (the Neural Network) and a Strict Art Critic (the Symbolic Logic).

The Old Way (End-to-End Learning)

In the old method, the Apprentice paints a picture, and the Critic immediately yells, "That's wrong!" The Critic then tries to explain exactly which brushstroke was wrong and how to fix it.

  • The Problem: If the Critic's rules are too complicated (like a complex Sudoku puzzle) or if the Critic uses a method that is hard to explain step-by-step (like guessing randomly), the Critic gets stuck. They can't give specific instructions on how to fix the brushstrokes. The Apprentice is left confused and can't improve.

The New Way (EM-NESY)

EM-NESY changes the workflow into two distinct steps, like a rehearsal process:

Step 1: The Critic's Review (The "Expectation" Step)
The Apprentice paints a picture based on their current skill. The Critic looks at the picture and the correct answer (the label).
Instead of trying to explain how to fix the brushstrokes, the Critic simply writes down a list of corrections.

  • Example: "You thought this digit was a 3, but given the rules of Sudoku, it is actually 70% likely to be a 5 and 30% likely to be a 6."
  • Key Point: The Critic does this using any method they want. They can use complex math, random guessing, or strict logic. It doesn't matter if they can explain their reasoning step-by-step; they just need to produce the final list of probabilities (the "posterior").

Step 2: The Apprentice's Practice (The "Maximization" Step)
The Critic hands the list of corrections to the Apprentice. The Apprentice looks at their original guess and the Critic's corrections.

  • The Apprentice thinks: "I guessed 3. The Critic says I should have guessed 5 or 6. I need to adjust my brain to make 5 or 6 more likely next time."
  • The Apprentice updates their own internal settings (the neural parameters) to match the Critic's list.
  • Key Point: The Critic is not involved in this step. The Critic's list is treated as a fixed fact. The Apprentice only needs to learn how to change their own painting style.

Why is this a Big Deal?

1. It Unlocks "Unlearnable" Logic
Some logic problems are so hard that you can't calculate the exact answer, or the method to find the answer is "non-differentiable" (mathematically messy).

  • Analogy: Imagine the Critic uses a method where they roll dice to find the answer. In the old way, you couldn't teach the Apprentice because you couldn't trace the dice roll back to the brushstrokes.
  • With EM-NESY: The Critic rolls the dice, gets a result, and writes it down. The Apprentice just learns from the result. The messy dice-rolling part is completely hidden from the learning process.

2. It's Faster and Uses Less Memory
The paper shows that when the logic is simple enough to be calculated exactly, this new method is just as accurate as the old method but much faster.

  • Analogy: It's like realizing you don't need to re-calculate the entire history of the universe every time you make a mistake. You just need the final verdict. This saves a massive amount of computer memory and time, allowing the robot to solve much larger puzzles (like Sudoku grids with 100 digits) that would crash the old systems.

3. It Works with Any "Critic"
Because the Critic doesn't need to be mathematically "smooth" or differentiable, you can plug in any existing logic engine, even the ones that were previously too difficult to use with neural networks.

What the Experiments Showed

The authors tested this on three types of puzzles:

  1. Adding handwritten numbers: They showed EM-NESY could handle huge sums (100 digits) that other methods couldn't even finish, while using less memory.
  2. Visual Sudoku: They showed it could learn from puzzles where the rules were strict, even when using approximate methods (like random sampling) to solve the logic part.
  3. Pathfinding on a map: They showed it could learn to find the shortest path on a grid, a task where other methods struggled because the logic was too complex to differentiate.

The Bottom Line

The paper proposes EM-NESY, a framework that treats Neurosymbolic learning as a game of "Hot and Cold" played in turns.

  • Turn 1: The Logic engine (Critic) figures out what the correct answers should have been, using whatever tools it has.
  • Turn 2: The Neural engine (Apprentice) adjusts its brain to match those answers.

This simple switch allows AI to learn from complex, messy, or approximate logic without needing to force the logic to be mathematically perfect or differentiable. It makes building AI that can both "see" and "think" much more flexible and scalable.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →