Evaluating Hybrid Graph Pattern Queries Using Runtime Index Graphs

Xiaoying Wu, Dimitri Theodoratos, Nikos Mamoulis, Michael Lan

Abstract

Graph pattern matching is a fundamental task in data science, yet existing methods often struggle with "hybrid" queries that combine direct edge relationships with reachability constraints. This paper introduces GM, a high-performance framework designed to evaluate these complex patterns efficiently. By utilizing a lightweight Runtime Index Graph (RIG) and a novel Double Simulation pruning technique, GM achieves query evaluation speeds up to three orders of magnitude faster than state-of-the-art join-based and tree-based approaches. Experimental results on diverse real-world datasets demonstrate GM's superior scalability and robustness, particularly for large-scale graphs and complex path-based constraints.

Introduction: The Challenge of Hybrid Patterns

Graph pattern matching is essential for applications ranging from social network analysis to fraud detection. However, real-world queries are increasingly "hybrid," requiring the system to find both exact edge matches (isomorphism/homomorphism) and reachability paths (can node A reach node B?). For instance, a money-laundering investigation might seek a specific individual who eventually transferred funds through a complex chain of accounts to a known criminal.

Example hybrid graph patterns $Q_1$ and $Q_2$ representing complex relationships and reachability constraints in supply chains and banking.

Evaluating these hybrid patterns is NP-hard. Reachability edges exponentially expand the search space, often leading to an "intermediate result explosion." Traditional systems spend excessive time processing partial matches that never culminate in a final solution, frequently resulting in out-of-memory errors or timeouts.

The GM Framework: Runtime Indexing and Pruning

To address these complexities, the authors propose the GM framework, which centers on three core innovations:

1. Runtime Index Graph (RIG)

Instead of searching the raw data graph directly, GM constructs a compact, $k$-partite summary graph on-the-fly. This RIG losslessly encodes all potential matches, serving as a restricted search space that eliminates the need for expensive disk-based storage. By summarizing potential endpoints first, the system defers expensive path calculations until a node is confirmed to be structurally viable.

The process of constructing a Runtime Index Graph (RIG) from a graph pattern $Q$ and data graph $G$, showing how the RIG summarizes potential matches.

2. Double Simulation Pruning

To further refine the RIG, the framework employs a "Double Simulation" technique. Unlike standard label filtering or older "dual simulation" methods, Double Simulation performs both forward and backward structural checks. This captures specific ancestor and descendant constraints of the query, filtering out data nodes that cannot possibly participate in a final match. An optimized version, FBSim, exploits the structure of Directed Acyclic Graphs (DAGs) for faster convergence.

3. Multi-way Join (MJoin)

Standard query engines typically rely on binary joins, which are inefficient for complex graph structures. GM utilizes MJoin, a "worst-case optimal" multi-way join strategy. By intersecting adjacency lists directly from the RIG, MJoin enumerates results without generating the massive intermediate tables that plague traditional join-based methods.

Experimental Evaluation and Results

The researchers evaluated GM against seven diverse datasets, including biological networks (Yeast, Human), social graphs (Epinions, DBLP), and large-scale knowledge bases (DBpedia with 15 million edges).

Key findings include:

  • Performance: GM outperformed join-based (JM) and tree-based (TM) methods by 2 to 3 orders of magnitude in query time.
  • Robustness: While competing methods frequently crashed on complex cyclic queries, GM successfully evaluated nearly all test cases.
  • Scalability: The framework scaled gracefully to queries with up to 32 nodes and datasets with millions of edges. As the proportion of reachability edges increased, GM's performance advantage became even more pronounced.

Conclusion and Future Directions

The GM framework demonstrates that summarization and intelligent pruning are more effective than raw materialization for hybrid graph queries. By prioritizing structural viability through the RIG and Double Simulation, GM provides a robust solution for modern graph analytics. Future work includes extending the framework to dynamic graphs, where matches must be updated incrementally as the underlying data changes, and further refining cardinality estimation for query optimization.

Summary updated

BibTeX
@inproceedings{wu2023evaluating,
  author = {Xiaoying Wu and Dimitri Theodoratos and Nikos Mamoulis and Michael Lan},
  title = {{Evaluating Hybrid Graph Pattern Queries Using Runtime Index Graphs}},
  booktitle = {EDBT},
  year = {2023},
  doi = {10.48786/edbt.2023.59},
}
Figure