Below and Above Why-Provenance for Datalog Queries
Datalog is a well-established rule-based language that allows us to express complex recursive queries. As for every other query language, explaining why a result to a Datalog query is obtained is an essential task towards explainable and transparent query evaluation. A standard way of explaining a query result is the so-called why-provenance, which provides information about the witnesses to a query result in the form of subsets of the input database that as a whole can be used to derive that result. The data complexity of why-provenance for Datalog queries has been recently studied and it was shown to be intractable, namely NP-complete even if the recursion is linear. An interesting question that comes up is whether we can ensure tractable data complexity by considering a slightly less informative notion of provenance, in particular, whyminimal-provenance that keeps only subset-minimal witnesses to a query result. Another interesting question is whether we can adopt a more informative notion of provenance than why-provenance, in particular, whymultiplicity-provenance that also keeps track of how many times a certain fact occurs in a witness to a query result, without paying a price in data complexity. This work provides definitive answers to the above questions: (i) whyminimal-provenance ensures tractable data complexity, and (ii) whymultiplicity-provenance can be adopted without paying a price in complexity, apart from one surprising case where the data complexity becomes PSPACE-complete.
Authors
- Marco Calautti (ORCID: https://orcid.org/0000-0003-0921-4040)
- Andréas Pieris (ORCID: https://orcid.org/0000-0003-4779-3469)
- Ester Livshits (ORCID: https://orcid.org/0000-0003-3485-9887)
- Markus Schneider (ORCID: https://orcid.org/0000-0001-8338-5660)
Institutions
- King's College London (GB)
- University of Milan (IT)
- University of Cyprus (CY)
- University of Edinburgh (GB)
Publication Details
- Journal
- Proceedings of the ACM on Management of Data
- Published
- 2024-11-04
- DOI
- https://doi.org/10.1145/3695829
- Primary Topic
- Scientific Computing and Data Management
- Type
- article
- Field-Weighted Citation Impact
- 0.00
Funders
- European Commission
- Engineering and Physical Sciences Research Council