Abstract
The number and size of RDF knowledge graphs grows continuously. Efficient storage solutions for these graphs are indispensable for their use in real applications. We present such a storage solution dubbed Tentris. Our solution represents RDF knowledge graphs as sparse order-3 tensors using a novel data structure, which we dub hypertrie. It then uses tensor algebra to carry out SPARQL queries by mapping SPARQL operations to Einstein summation. By being able to compute Einstein summations efficiently, Tentris outperforms the commercial and open-source RDF storage solutions evaluated in our experiments by at least 1.8 times with respect to the average number of queries it can serve per second on three datasets of up to 1 billion triples. Our code, evaluation setup, results, supplementary material and the datasets are provided at https://tentris.dice-research.org/iswc2020.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Similar content being viewed by others
Notes
- 1.
- 2.
- 3.
Note that indexes for different collation orders are crucial for the performance of triple stores. They determine which join orders are possible and which triple patterns are cheap to resolve. However, building indexes comes at a cost: each index takes additional time to build and update. It also requires additional memory. Consequently, there is always a trade-off between querying speed on the one hand and memory consumption and maintenance cost on the other hand.
- 4.
Tensors can be defined in a more general manner than provided herein, see [2] for details.
- 5.
Technically, SPARQL semantics define solution mappings as partial functions f. Our formal model is equivalent and simply maps all variables for which f is not defined to \(\epsilon \).
- 6.
It may not be defined if t contains any resource that is not in \(\mathinner {\mathrm {dom}}(id)\).
- 7.
The full setup is available as Ansible playbook at https://github.com/dice-group/tentris-paper-benchmarks/releases/tag/v1.0.
- 8.
We used this version because of query logs being available for FEASIBLE.
- 9.
For each template one query was generated. Additionally, queries not projecting all variables were included with and without DISTINCT.
- 10.
Virtuoso has a limit of \(2^{20}\) results for queries answered via HTTP (see issue https://github.com/openlink/virtuoso-opensource/issues/700).
- 11.
All queries can be found in the supplementary material.
- 12.
We extended TripleBit to support entering SPARQL queries via command-line interface directly. This modification was necessary to use TripleBit with IGUANA. Code available at: https://github.com/dice-group/TripleBit/releases/tag/2020-03-03.
- 13.
As IGUANA requires SPARQL Protocol conformance, we fixed the HTTP request handling of gStore, i.e., parsing requests, naming of parameters, and response content-type. With respect to benchmark execution, we set the timeout to 3 min, and the thread limit to 32 and raised the total memory limit to \(800\)GB. Code available at: https://github.com/dice-group/gStore-1/releases/tag/3b4fe58-mod.
References
Abdelaziz, I., Harbi, R., Khayyat, Z., Kalnis, P.: A survey and experimental comparison of distributed SPARQL engines for very large RDF data. Proc. VLDB Endow. 10(13), 2049–2060 (2017)
Abraham, R., Marsden, J.E., Ratiu, T.: Manifolds, Tensor Analysis, and Applications. Springer, New York (1988)
Aluç, G., Hartig, O., Özsu, M.T., Daudjee, K.: Diversified stress testing of RDF data management systems. In: Mika, P., et al. (eds.) ISWC 2014. LNCS, vol. 8796, pp. 197–212. Springer, Cham (2014). https://doi.org/10.1007/978-3-319-11964-9_13
Atre, M., Chaoji, V., Zaki, M.J., Hendler, J.A.: Matrix “bit” loaded: a scalable lightweight join query processor for RDF data. In: WWW, pp. 41–50 (2010)
Conrads, F., Lehmann, J., Saleem, M., Morsey, M., Ngonga Ngomo, A.-C.: IGUANA: a generic framework for benchmarking the read-write performance of triple stores. In: d’Amato, C., et al. (eds.) ISWC 2017. LNCS, vol. 10588, pp. 48–65. Springer, Cham (2017). https://doi.org/10.1007/978-3-319-68204-4_5
De La Briandais, R.: File searching using variable length keys. In: Western Joint Computer Conference, IRE-AIEE-ACM 1959 (Western), pp. 295–298 (1959)
Einstein, A.: Die Grundlage der allgemeinen Relativitätstheorie. Annalen der Physik 354, 769–822 (1916)
Erling, O.: Virtuoso, a hybrid RDBMS/graph column store. http://vos.openlinksw.com/owiki/wiki/VOS/VOSArticleVirtuosoAHybridRDBMSGraphColumnStore. Accessed 17 Mar 2018
Ermilov, I., Lehmann, J., Martin, M., Auer, S.: LODStats: the data web census dataset. In: Groth, P., et al. (eds.) ISWC 2016. LNCS, vol. 9982, pp. 38–46. Springer, Cham (2016). https://doi.org/10.1007/978-3-319-46547-0_5
Apache Software Foundation: Apache Jena documentation - TDB - store parameters (2019). https://jena.apache.org/documentation/tdb/store-parameters. Accessed 25 Apr 2019
Google Ireland Limited: tf.einsum | TensorFlow core r2.0 | TensorFlow (2019). https://pytorch.org/docs/stable/torch.html#torch.einsum. Accessed 06 Aug 2019
Jamour, F., Abdelaziz, I., Chen, Y., Kalnis, P.: Matrix algebra framework for portable, scalable and efficient query engines for RDF graphs. In: Proceedings of the Fourteenth EuroSys Conference 2019, EuroSys 2019. ACM (2019)
Kjolstad, F., Kamil, S., Chou, S., Lugato, D., Amarasinghe, S.: The tensor algebra compiler. In: Proceedings of the ACM on Programming Languages, 1(OOPSLA), October 2017
Motik, B., Nenov, Y., Piro, R., Horrocks, I., Olteanu, D.: Parallel materialisation of datalog programs in centralised, main-memory RDF systems. In: Proceedings of the Twenty-Eighth AAAI Conference on Artificial Intelligence, AAAI 2014, pp. 129–137. AAAI Press (2014)
Neumann, T., Weikum, G.: RDF-3X: a RISC-style engine for RDF. Proc. VLDB Endow. 1(1), 647–659 (2008)
Ngo, H.Q., Ré, C., Rudra, A.: Skew strikes back: new developments in the theory of join algorithms. SIGMOD Rec. 42, 5–16 (2013)
Nickel, M., Tresp, V., Kriegel, H.-P.: Factorizing YAGO: scalable machine learning for linked data. In: WWW, pp. 271–280 (2012)
Noy, N., Gao, Y., Jain, A., Narayanan, A., Patterson, A., Taylor, J.: Industry-scale knowledge graphs: lessons and challenges. Queue 17(2), 48–75 (2019)
Inc. Ontotext USA: Storage – GraphDB free 8.9 documentation. http://graphdb.ontotext.com/documentation/free/storage.html#storage-literal-index. Accessed 16 Apr 2019
MMG Ricci and Tullio Levi-Civita: Méthodes de calcul différentiel absolu et leurs applications. Mathematische Annalen 54(1–2), 125–201 (1900)
Saleem, M., Ali, M.I., Hogan, A., Mehmood, Q., Ngomo, A.-C.N.: LSQ: the linked SPARQL queries dataset. In: Arenas, M., et al. (eds.) ISWC 2015. LNCS, vol. 9367, pp. 261–269. Springer, Cham (2015). https://doi.org/10.1007/978-3-319-25010-6_15
Saleem, M., Kamdar, M.R., Iqbal, A., Sampath, S., Deus, H.F., Ngomo Ngomo, A.-C.: Big linked cancer data: Integrating linked TCGA and PubMed. JWS (2014)
Saleem, M., Mehmood, Q., Ngonga Ngomo, A.-C.: FEASIBLE: a feature-based SPARQL benchmark generation framework. In: Arenas, M., et al. (eds.) ISWC 2015. LNCS, vol. 9366, pp. 52–69. Springer, Cham (2015). https://doi.org/10.1007/978-3-319-25007-6_4
SYSTAP, LLC. Bigdata Database Architecture - Blazegraph (2013). https://blazegraph.com/docs/bigdata_architecture_whitepaper.pdf. Accessed 29 Nov 2019
The SciPy community: numpy.einsum – NumPy v1.17 manual (2019). https://docs.scipy.org/doc/numpy/reference/generated/numpy.einsum.html. Accessed 6 Aug 2019
Torch Contributors: torch – PyTorch master documentation (2018). https://pytorch.org/docs/stable/torch.html#torch.einsum. Accessed 06 Aug 2019
De Virgilio, R.: A linear algebra technique for (de)centralized processing of SPARQL queries. In: Conceptual Modeling, pp. 463–476, October 2012
Pingpeng Yuan, P., Liu, B.W., Jin, H., Zhang, W., Liu, L.: TripleBit: a fast and compact system for large scale RDF data. Proc. VLDB Endow. 6(7), 517–528 (2013)
Zou, L., Özsu, M.T., Chen, L., Shen, X., Huang, R., Zhao, D.: gStore: a graph-based SPARQL query engine. VLDB J. 23(4), 565–590 (2014)
Acknowledgments
The authors would like to thank Lennart Austenfeld for automating the evaluation setup. This work has been supported by the German Federal Ministry for Economic Affairs and Energy (BMWi) within the project RAKI under the grant no 01MD19012D, by the German Federal Ministry of Education and Research (BMBF) within the project DAIKIRI under the grant no 01IS19085B, and by the EU H2020 Marie Skłodowska-Curie project KnowGraphs under the grant agreement no 860801.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2020 Springer Nature Switzerland AG
About this paper
Cite this paper
Bigerl, A., Conrads, F., Behning, C., Sherif, M.A., Saleem, M., Ngonga Ngomo, AC. (2020). Tentris – A Tensor-Based Triple Store. In: Pan, J.Z., et al. The Semantic Web – ISWC 2020. ISWC 2020. Lecture Notes in Computer Science(), vol 12506. Springer, Cham. https://doi.org/10.1007/978-3-030-62419-4_4
Download citation
DOI: https://doi.org/10.1007/978-3-030-62419-4_4
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-030-62418-7
Online ISBN: 978-3-030-62419-4
eBook Packages: Computer ScienceComputer Science (R0)