Advances in Knowledge Representation, Logic Programming, and Abstract Argumentation

Volume 9060 of the series Lecture Notes in Computer Science pp 17-32

Ricochet Robots Reloaded: A Case-Study in Multi-shot ASP Solving

  • Martin GebserAffiliated withAalto UniversityUniversity of Potsdam
  • , Roland KaminskiAffiliated withUniversity of Potsdam
  • , Philipp ObermeierAffiliated withUniversity of Potsdam
  • , Torsten SchaubAffiliated withUniversity of PotsdamInria Rennes

* Final gross prices may vary according to local VAT.

Get Access


Nonmonotonic reasoning is about drawing conclusions in the absence of (complete) information. Hence, whenever new information arrives, one may have to withdraw previously drawn conclusions. In fact, Answer Set Programming is nowadays regarded as the computational embodiment of nonmonotonic reasoning. However, traditional answer set solvers do not account for changing information. Rather they are designed as one-shot solvers that take a logic program and compute its stable models, basta! When new information arrives the program is extended and the solving process is started from scratch once more. Hence the dynamics giving rise to nonmonotonicity is not reflected by such solvers and left to the user. This shortcoming is addressed by multi-shot solvers that embrace the dynamicity of nonmonotonic reasoning by allowing a reactive procedure to loop on solving while acquiring changes in the problem specification.

In this paper, we provide a hands-on introduction to multi-shot solving with clingo 4 by modeling the popular board game of Ricochet Robots. Our particular focus lies on capturing the underlying turn based playing through the procedural-declarative interplay offered by the Python-ASP integration of clingo 4. From a technical perspective, we provide semantic underpinnings for multi-shot solving with clingo 4 by means of a simple stateful semantics along with operations reflecting clingo 4 functionalities.