Abstract
The paper presents BiMetaTrans(Prolog, RuleML), an invertible bidirectional metalogical translator across subsets of ISO Prolog and RuleML/XML 1.02 on the level of Negation-as-failure Horn logic with Equality. BiMetaTrans, itself written in Prolog, introduces a tighter integration between RuleML and Prolog, which enables the reuse of, e.g., RuleML Knowledge Bases (KBs) and query engines. A Prolog/ā$Vā encoding is defined as the BiMetaTrans translation source-and-target counterpart to RuleML/XML. This metalogical encoding, along with the introduction of the split translation pattern, allows BiMetaTrans to build upon the abstraction of Definite Clause Grammars (DCGs), supporting invertible bi-translation. The BiMetaTrans DCG is explored and an invertibility proof is outlined. BiMetaTrans is exemplified for knowledge representation and querying applied to an Air Traffic Control KB.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Notes
- 1.
- 2.
See penultimate row of http://deliberation.ruleml.org/1.02/relaxng/#anchor table. Also note row for NafNegHornlogEq on the sublanguage path to NafFologEq. Our initial version of BiMetaTrans ā like Prolog ā assumes ordered conjunctions, disjunctions, and rulebases, although the corresponding RuleML/XML formula edges with index="1", index="2", ... attributes (http://wiki.ruleml.org/index.php/Glossary_of_Deliberation_RuleML_1.02#.40index) are omitted for simplicity.
- 3.
- 4.
- 5.
- 6.
Complementing RuleMLās xsi:type, we introduce iso:type for ISO Prolog types.
- 7.
The <RuleML> root is assumed by BiMetaTrans(Prolog/ā$Vā, RuleML/XML), thus simplifying its various (KB-only, query-only, KB&query) translation uses.
- 8.
A conclusion compound with function symbol ā=ā is not permissible in an ISO Prolog KB, but we are concerned only with Prolog/ā$Vā encodings as ground terms.
- 9.
- 10.
In the Emacs text editor, the reification can be done by the interactive command M-x query-replace-regexp with basically as the matching expression and as the transform. Such a command could also be named as an Emacs Lisp function.
- 11.
- 12.
References
Iamnitchi, A., Trunfio, P., Ledlie, J., Schintke, F.: Peer-to-peer computing. In: DāAmbra, P., Guarracino, M., Talia, D. (eds.) Euro-Par 2010. LNCS, vol. 6271, pp. 444ā445. Springer, Heidelberg (2010). https://doi.org/10.1007/978-3-642-15277-1_42
Kravari, K., Bassiliades, N., Boley, H.: Cross-community interoperation between knowledge-based multi-agent systems: a study on EMERALD and Rule Responder. Expert Syst. Appl 39(10), 9571ā9587 (2012)
Sterling, L., Shapiro, E.Y.: The Art of Prolog: Advanced Programming Techniques. MIT Press, Cambridge (1994)
Mitsikas, T., Stefaneas, P., Ouranos, I.: A rule-based approach for air traffic control in the vicinity of the airport. In: Lambropoulou, S., Theodorou, D., Stefaneas, P., Kauffman, L.H. (eds.) AlModTopCom 2015. SPMS, vol. 219, pp. 423ā438. Springer, Cham (2017). https://doi.org/10.1007/978-3-319-68103-0_20
Mitsikas, T., Almpani, S., Stefaneas, P., Frangos, P., Ouranos, I.: Formalizing air traffic control regulations in PSOA RuleML. In: Proceedings of the Doctoral Consortium and Challenge@ RuleML+ RR 2018 hosted by 2nd International Joint Conference on Rules and Reasoning, vol. 2204, CEUR Workshop Proceedings (2018)
Deryck, M., et al.: Aligning, interoperating, and co-executing air traffic control rules across PSOA RuleML and IDP. In: Fodor, P., Montali, M., Calvanese, D., Roman, D. (eds.) RuleML+RR 2019. LNCS, vol. 11784, pp. 52ā66. Springer, Cham (2019). https://doi.org/10.1007/978-3-030-31095-0_4
Boley, H., Zou, G.: Perspectival knowledge in PSOA RuleML: representation, model theory, and translation. CoRR abs/1712.02869, v3 (2019)
Boley, H.: The RuleML knowledge-interoperation hub. In: Alferes, J.J.J., Bertossi, L., Governatori, G., Fodor, P., Roman, D. (eds.) RuleML 2016. LNCS, vol. 9718, pp. 19ā33. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-42019-6_2
ISO: ISO/IEC 13211ā1:1995: Information technology ā programming languages ā prolog ā part 1: general core (1995)
Basin, D.A., Constable, R.L.: Metalogical frameworks. In: Proceedings of the Second Annual Workshop on Logical Frameworks, Edinburgh, UK, June 1991
Pereira, F., Warren, D.H.D.: Definite clause grammars for language analysis - a survey of the formalism and a comparison with augmented transition networks. Artif. Intell. 13, 231ā278 (1980)
Boley, H.: RIF RuleML Rosetta Ring: round-tripping the Dlex subset of Datalog RuleML and RIF-Core. In: Governatori, G., Hall, J., Paschke, A. (eds.) RuleML 2009. LNCS, vol. 5858, pp. 29ā42. Springer, Heidelberg (2009). https://doi.org/10.1007/978-3-642-04985-9_6
Rendel, T., Ostermann, K.: Invertible syntax descriptions: unifying parsing and pretty printing. SIGPLAN Not. 45(11), 1ā12 (2010)
DuregĆ„rd, J., Jansson, P.: Embedded parser generators. ACM SIGPLAN Not. 46(12), 107ā117 (2011)
Matsuda, K., Wang, M.: FliPpr: a prettier invertible printing system. In: Felleisen, M., Gardner, P. (eds.) ESOP 2013. LNCS, vol. 7792, pp. 101ā120. Springer, Heidelberg (2013). https://doi.org/10.1007/978-3-642-37036-6_6
Al Manir, M.S., Riazanov, A., Boley, H., Baker, C.J.O.: PSOA RuleML API: a tool for processing abstract and concrete syntaxes. In: Bikakis, A., Giurca, A. (eds.) RuleML 2012. LNCS, vol. 7438, pp. 280ā288. Springer, Heidelberg (2012). https://doi.org/10.1007/978-3-642-32689-9_23
Author information
Authors and Affiliations
Corresponding authors
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
Ā© 2020 Springer Nature Switzerland AG
About this paper
Cite this paper
Thom, M., Boley, H., Mitsikas, T. (2020). Invertible Bidirectional Metalogical Translation Between Prolog and RuleML for Knowledge Representation and Querying. In: GutiƩrrez-Basulto, V., Kliegr, T., Soylu, A., Giese, M., Roman, D. (eds) Rules and Reasoning. RuleML+RR 2020. Lecture Notes in Computer Science(), vol 12173. Springer, Cham. https://doi.org/10.1007/978-3-030-57977-7_8
Download citation
DOI: https://doi.org/10.1007/978-3-030-57977-7_8
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-030-57976-0
Online ISBN: 978-3-030-57977-7
eBook Packages: Computer ScienceComputer Science (R0)