🤖 AI Summary
This work addresses the limitation of Answer Set Programming (ASP) solvers that rely on symbolic engines (e.g., ASP/SAT). We propose the first fully numerical, end-to-end ASP solving framework. Our method reformulates logic programs, the Lin-Zhao stable model theorem, and problem constraints as a differentiable cost function in vector space, enabling direct gradient-based search for stable models. To reduce computational complexity, we introduce program pre-compression and algebraic encoding of loop formulas. Technically, we adopt matrix-based program representation and vectorized modeling, supporting efficient GPU and multi-core parallelization. Experimental evaluation on benchmark problems—including 3-coloring and Hamiltonian cycle—demonstrates effectiveness, scalability, and competitive performance. Crucially, the framework is inherently differentiable, enabling end-to-end neuro-symbolic training and seamless integration with deep learning pipelines.
📝 Abstract
We propose an end-to-end approach for answer set programming (ASP) and linear algebraically compute stable models satisfying given constraints. The idea is to implement Lin-Zhao's theorem cite{Lin04} together with constraints directly in vector spaces as numerical minimization of a cost function constructed from a matricized normal logic program, loop formulas in Lin-Zhao's theorem and constraints, thereby no use of symbolic ASP or SAT solvers involved in our approach. We also propose precomputation that shrinks the program size and heuristics for loop formulas to reduce computational difficulty. We empirically test our approach with programming examples including the 3-coloring and Hamiltonian cycle problems. As our approach is purely numerical and only contains vector/matrix operations, acceleration by parallel technologies such as many-cores and GPUs is expected.