Evaluating regular path queries on compressed adjacency matrices

被引:0
|
作者
Arroyuelo, Diego [1 ,2 ]
Gomez-Brandon, Adrian [3 ,4 ]
Navarro, Gonzalo [5 ,6 ]
机构
[1] Pontificia Univ Catolica Chile, Escuela Ingn, DCC, Santiago, Chile
[2] Pontificia Univ Catolica Chile, Escuela Ingn, DCC, Santiago, Chile
[3] Univ A Coruna, ECOBAS, La Coruna, Spain
[4] Univ A Coruna, CITIC, La Coruna, Spain
[5] Univ Chile, IMFD, Santiago, Chile
[6] Univ Chile, DCC, Santiago, Chile
来源
VLDB JOURNAL | 2025年 / 34卷 / 01期
关键词
Regular path queries on graph databases; Compact data structures for adjacency matrices; Sparse matrices; Sparse Boolean matrices; EFFICIENT TRANSITIVE CLOSURE; ALGORITHM; MULTIPLICATION; ALGEBRA; WEB;
D O I
10.1007/s00778-024-00885-6
中图分类号
TP3 [计算技术、计算机技术];
学科分类号
0812 ;
摘要
Regular Path Queries (RPQs), which are essentially regular expressions to be matched against the labels of paths in labeled graphs, are at the core of graph database query languages like SPARQL and GQL. A way to solve RPQs is to translate them into a sequence of operations on the adjacency matrices of each label. We design and implement a Boolean algebra on sparse matrix representations and, as an application, use them to handle RPQs. Our baseline representation uses the same space and time as the previously most compact index for RPQs, outperforming it on the hardest types of queries-those where both RPQ endpoints are unspecified. Our more succinct structure, based on k2\documentclass[12pt]{minimal} \usepackage{amsmath} \usepackage{wasysym} \usepackage{amsfonts} \usepackage{amssymb} \usepackage{amsbsy} \usepackage{mathrsfs} \usepackage{upgreek} \setlength{\oddsidemargin}{-69pt} \begin{document}$$k<^>2$$\end{document}-trees, is 4 times smaller than any existing representation that handles RPQs. While slower, it still solves complex RPQs in a few seconds and slightly outperforms the smallest previous structure on the hardest RPQs. Our new sparse-matrix-based solutions dominate a good portion of the space/time tradeoff map, being outperformed only by representations that use much more space. They also implement an algebra of Boolean matrices that is of independent interest beyond solving RPQs.
引用
收藏
页数:28
相关论文
共 50 条
  • [31] Algebraic rewritings for optimizing regular path queries
    Grahne, G
    Thomo, A
    THEORETICAL COMPUTER SCIENCE, 2003, 296 (03) : 453 - 471
  • [32] New rewritings and optimizations for regular path queries
    Grahne, G
    Thomo, A
    DATABASE THEORY ICDT 2003, PROCEEDINGS, 2003, 2572 : 242 - 258
  • [33] Nested Regular Path Queries in Description Logics
    Bienvenu, Meghyn
    Calvanese, Diego
    Ortiz, Magdalena
    Simkus, Mantas
    FOURTEENTH INTERNATIONAL CONFERENCE ON THE PRINCIPLES OF KNOWLEDGE REPRESENTATION AND REASONING, 2014, : 218 - 227
  • [34] Answering Regular Path Queries through Exemplars
    Chauhan, Komal
    Jain, Kartik
    Ranu, Sayan
    Bedathur, Srikanta
    Bagchi, Amitabha
    PROCEEDINGS OF THE VLDB ENDOWMENT, 2021, 15 (02): : 299 - 311
  • [35] Jumping Evaluation of Nested Regular Path Queries
    Niehren, Joachim
    Salvati, Sylvain
    Azimov, Rustam
    ELECTRONIC PROCEEDINGS IN THEORETICAL COMPUTER SCIENCE, 2022, 364 : 79 - 92
  • [36] Containment of Simple Conjunctive Regular Path Queries
    Figueira, Diego
    Godbole, Adwait
    Krishna, S.
    Martens, Wim
    Niewerth, Matthias
    Trautner, Tina
    KR2020: PROCEEDINGS OF THE 17TH INTERNATIONAL CONFERENCE ON PRINCIPLES OF KNOWLEDGE REPRESENTATION AND REASONING, 2020, : 371 - 380
  • [37] Regular path queries under approximate semantics
    Grahne, G
    Thomo, A
    ANNALS OF MATHEMATICS AND ARTIFICIAL INTELLIGENCE, 2006, 46 (1-2) : 165 - 190
  • [38] Answering Regular Path Queries on Workflow Provenance
    Huang, Xiaocheng
    Bao, Zhuowei
    Davidson, Susan B.
    Milo, Tova
    Yuan, Xiaojie
    2015 IEEE 31ST INTERNATIONAL CONFERENCE ON DATA ENGINEERING (ICDE), 2015, : 375 - 386
  • [39] Conjunctive Regular Path Queries with String Variables
    Schmid, Markus L.
    PODS'20: PROCEEDINGS OF THE 39TH ACM SIGMOD-SIGACT-SIGAI SYMPOSIUM ON PRINCIPLES OF DATABASE SYSTEMS, 2020, : 361 - 374
  • [40] Conjunctive Regular Path Queries with Capture Groups
    Schmid, Markus L.
    ACM TRANSACTIONS ON DATABASE SYSTEMS, 2022, 47 (02):