ApproxASP – a Scalable Approximate Answer Set Counter


  • Mohimenul Kabir National University of Singapore
  • Flavio O Everardo Tec de Monterrey Puebla Campus
  • Ankit K Shukla JKU
  • Markus Hecher TU Wien
  • Johannes Klaus Fichte TU Wien
  • Kuldeep S Meel National University of Singapore



Knowledge Representation And Reasoning (KRR), Constraint Satisfaction And Optimization (CSO)


Answer Set Programming (ASP) is a framework in artificial intelligence and knowledge representation for declarative modeling and problem solving. Modern ASP solvers focus on the computation or enumeration of answer sets. However, a variety of probabilistic applications in reasoning or logic programming require counting answer sets. While counting can be done by enumeration, simple enumeration becomes immediately infeasible if the number of solutions is high. On the other hand, approaches to exact counting are of high worst-case complexity. In fact, in propositional model counting, exact counting becomes impractical. In this work, we present a scalable approach to approximate counting for answer set programming. Our approach is based on systematically adding XOR constraints to ASP programs, which divide the search space. We prove that adding random XOR constraints partitions the answer sets of an ASP program. In practice, we use a Gaussian elimination-based approach by lifting ideas from SAT to ASP and integrating it into a state of the art ASP solver, which we call ApproxASP. Finally, our experimental evaluation shows the scalability of our approach over the existing ASP systems.




How to Cite

Kabir, M., Everardo, F. O., Shukla, A. K., Hecher, M., Fichte, J. K., & Meel, K. S. (2022). ApproxASP – a Scalable Approximate Answer Set Counter. Proceedings of the AAAI Conference on Artificial Intelligence, 36(5), 5755-5764.



AAAI Technical Track on Knowledge Representation and Reasoning