Limit Datalog: A declarative query language for data analysis - Grau, BC; Horrocks, I; Kaminski, M; Kostylev, EV; Motik, B (Association for Computing Machinery, 2020)
Motivated by applications in declarative data analysis, we study DatalogZ-an extension of Datalog with stratified negation and arithmetics over integers. Reasoning in this language is undecidable, so we present a fragment, called limit DatalogZ, that is powerful enough to naturally capture many important data analysis tasks. In limit DatalogZ, all intensional predicates with a numeric argument are limit predicates that keep only the maximal or minimal bounds on numeric values. Reasoning in limit DatalogZ is decidable if multiplication is used in a way that satisfies our linearity condition. Moreover, fact entailment in limit-linear DatalogZ is ΔEXP 2 -complete in combined and ΔP2 -complete in data complexity, and it drops to coNEXP and coNP, respectively, if only (semi-)positive programs are considered. We also propose an additional stability requirement, for which the complexity drops to EXP and P, matching the bounds for usual Datalog. Limit DatalogZ thus provides us with a unified logical framework for declarative data analysis and can be used as a basis for understanding the expressive power of the key data analysis constructs.