Graph-Based Attention for Differentiable MaxSAT Solving

Sota Moriyama, Katsumi InoueNeurIPS 2025

Introduction

Boolean Satisfiability (SAT) and its optimization variant, Maximum Satisfiability (MaxSAT), are foundational NP-hard problems in artificial intelligence. While traditional discrete solvers are highly optimized, there is a growing interest in differentiable solvers that can be integrated directly into deep learning pipelines for Neuro-symbolic AI.

However, existing neural solvers often face three major hurdles:

  1. Scalability: Many Graph Neural Network (GNN)-based solvers struggle to process large, real-world problem instances.
  2. Stability: Training neural networks to solve hard combinatorial constraints is notoriously unstable.
  3. Weighted Constraints: Most neural SAT research ignores weights, yet real-world optimization often requires prioritizing certain constraints over others.

To bridge this gap, researchers have introduced SAT-based Graph Attention Networks (SGATs). SGAT is a novel GNN architecture designed to solve (weighted) MaxSAT problems differentiably. By structurally mimicking greedy local search and utilizing fuzzy logic, SGATs achieve state-of-the-art performance among continuous solvers while being orders of magnitude more parameter-efficient and scalable than previous neural approaches.

The SGAT Architecture

The core contribution of this work is the SGAT architecture, which operates on a bipartite graph where nodes represent variables and clauses. Rather than acting as a "black box," the network is structurally designed to approximate the logic of local search algorithms.

Architectural Diagram of SGATs showing the T-norm, SGAT, and Normalization layers.

The architecture consists of three specialized layers:

  • T-norm Layer: Instead of standard neural activations, this layer uses t-norms (fuzzy logic operators like Gödel or Product t-norms) to compute how "satisfied" a clause is based on continuous variable assignments.
  • SGAT Layer: This acts as the "brain" of the model. Unsatisfied clauses send messages to their connected variables, "requesting" them to change their values. An attention mechanism learns which clauses are most important to satisfy at any given step, effectively learning a search heuristic.
  • Normalization Layer: A sigmoid-based function ensures variable valuations stay well-distributed between 0 and 1, preventing the model from collapsing into uninformative states.

The authors also introduce LS-GNN, a local search algorithm that uses SGAT as a backbone. It iteratively refines variable assignments and uses techniques like early stopping and random restarts to escape local optima.

Key Insights and Theoretical Grounding

  • Structural Mimicry: SGAT aligns its architecture with known effective algorithms, achieving a better inductive bias for combinatorial optimization.
  • Extreme Parameter Efficiency: While typical neural solvers use hundreds of thousands of parameters, SGAT achieves state-of-the-art results with only 898 parameters. This simplicity is the secret to its massive scalability.
  • The Power of T-norms: The choice of t-norm is critical. The authors found that the Gödel t-norm is particularly effective because it provides stable gradients and ensures update messages stay within the $[0, 1]$ range without aggressive clamping.
  • Theoretical Grounding: The authors prove that a single-layer SGAT can achieve a 1/2-approximation ratio for unweighted Max-EkSAT, providing a deterministic baseline for its performance.

Experimental Results

The model was evaluated on rigorous benchmarks, including MaxSAT Evaluations (2018, 2020–2024), SR(U(40,200)) for synthetic-to-practical generalization, and WMS+(2MB) for training efficiency.

SGATs significantly outperformed existing neural architectures like NeuroSAT and GGNN. In training tests, SGAT was the only model able to learn effectively from practical instances, while others remained near baseline performance.

Comparison of training stability and performance between SGAT and other GNN architectures.

In head-to-head comparisons with other continuous solvers (like FourierSAT and the Mixing method) on the 2020–2024 benchmarks, SGAT demonstrated clear superiority:

  • Performance: SGAT achieved the highest "incomplete scores" (a measure of solution quality) across almost all years and categories.
  • Scalability: SGAT successfully handled problem instances exceeding 100MB, whereas previous neural models typically failed or timed out on files larger than 30MB.
  • Initialization: Using SGAT to provide an initial "guess" for state-of-the-art discrete solvers (like NuWLS or SPB) consistently improved their performance, proving its utility as a powerful heuristic generator.

Limitations and Future Work

While SGAT marks a significant step forward, it has a few limitations. First, the current framework does not explicitly support "hard" clauses (clauses that must be satisfied in Partial MaxSAT), as the soft nature of t-norms makes enforcing strict constraints challenging. Second, while the authors proved a 1/2-approximation for unweighted cases, extending these guarantees to weighted or partial MaxSAT remains an open theoretical problem. Finally, like all learned solvers, performance can still vary based on how well the training data represents the target problem domain.

Summary updated

BibTeX
@inproceedings{moriyama2025graph,
  author = {Sota Moriyama and Katsumi Inoue},
  title = {{Graph-Based Attention for Differentiable MaxSAT Solving}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2025},
  url = {https://openreview.net/forum?id=g9XLUU3TaG},
}
Figure