Embedding s(CASP) in Prolog

Jan Wielemaker*, Mikko Tiihonen

*Corresponding author for this work

Research output: Chapter in Book / Report / Conference proceedingConference contributionAcademicpeer-review

Abstract

The original s(CASP) implementation is a stand-alone program implemented in Ciao Prolog. It reads the s(CASP) source using a dedicated parser, resolves the query embedded in the source and emits the results in a format dictated by commandline options. Typical applications require composing a s(CASP) program, solving a query and reasoning about the bindings, model and/or justification. This is often done in some external language, e.g., Python. In this paper we propose a closer integration with Prolog. The s(CASP) program is simply a Prolog program that has to respect certain constraints. The scasp library can be used to solve a query using s(CASP) semantics, making the bindings available in the normal Prolog way and providing access to the model and justification as Prolog terms. This way, we can exploits Prolog’s power for manipulating (Prolog) terms for construction the s(CASP) program and interpreting the results.

Original languageEnglish
Title of host publicationICLP Workshops 2022 International Conference on Logic Programming 2022 Workshops
Subtitle of host publicationProceedings of the International Conference on Logic Programming 2022 Workshops co-located with the 38th International Conference on Logic Programming (ICLP 2022) Haifa, Israel, July 31st - August 1st, 2022
EditorsJoaquin Arias, Roberta Calegari, Luke Dickens, Wolfgang Faber, Jorge Fandinno, Gopal Gupta, Markus Hecher, Daniela Inclezan, Emily LeBlanc, Michael Morak, Elmer Salazar, Jessica Zangari
Pages1-8
Number of pages8
Publication statusPublished - 22 Aug 2022
Event38th International Conference on Logic Programming Workshops, ICLP Workshops 2022 - Haifa, Israel
Duration: 31 Jul 20221 Aug 2022

Publication series

NameCEUR Workshop Proceedings
PublisherCEUR
Volume3193
ISSN (Print)1613-0073

Conference

Conference38th International Conference on Logic Programming Workshops, ICLP Workshops 2022
Country/TerritoryIsrael
CityHaifa
Period31/07/221/08/22

Bibliographical note

Publisher Copyright:
© 2022 Copyright for this paper by its authors.

Keywords

  • answer set programming
  • multi-paradigm
  • Prolog
  • s(CASP)

Fingerprint

Dive into the research topics of 'Embedding s(CASP) in Prolog'. Together they form a unique fingerprint.

Cite this