TL;DR
Atrapos is a high-performance framework designed to evaluate metapath query workloads on large-scale Heterogeneous Information Networks (HINs) in real time. By combining optimized sparse matrix multiplication with a novel "Overlap Tree" data structure, it identifies and caches frequent sub-metapaths, achieving significant speedups over state-of-the-art graph databases and research prototypes.
What Problem Does This Paper Address?
Heterogeneous Information Networks (HINs) are powerful models for representing complex data where nodes and edges have different types (e.g., a scholarly network with Authors, Papers, and Venues). To extract knowledge, researchers use metapaths—sequences of node and edge types that define specific relationships, such as "Authors who published in the same Venue."
Evaluating these queries on web-scale HINs is computationally brutal. The standard approach involves a series of matrix multiplications. In exploratory data science, users rarely issue a single query; they issue workloads of related queries. Current systems treat these queries in isolation, ignoring the fact that many metapaths overlap (e.g., Author-Paper-Topic and Author-Paper-Venue share the Author-Paper prefix). This leads to massive amounts of redundant, expensive computation.
Methods
Atrapos introduces a three-pronged strategy to tackle workload evaluation:
- Sparse Matrix Optimization: Unlike previous methods that relied on dense matrix representations, Atrapos uses sparse matrix structures (specifically Compressed Sparse Column). It employs a cost-estimation model to determine the most efficient order of multiplications, which is particularly effective for "constrained" metapaths (e.g., filtering for papers published only after 2020).
- The Overlap Tree: The core innovation is a dynamic data structure inspired by generalized suffix trees. As queries arrive, Atrapos builds an Overlap Tree to track the frequency and computational cost of metapath suffixes and overlaps. Example of an Overlap Tree tracking query overlaps
- Atrapos-OTree Caching: Standard caching policies like LRU (Least Recently Used) fail here because the "cost" of a cache miss and the "size" of the result vary wildly between different metapaths. Atrapos uses a cost-aware policy that accounts for interdependence. If a long metapath is cached, its constituent sub-metapaths become "cheaper" to compute. The system uses the Overlap Tree to decide which intermediate results are most valuable to keep.
Datasets
The authors evaluated Atrapos using two massive, real-world HINs that are two orders of magnitude larger than those used in prior studies:
- Scholarly HIN: Based on AMiner’s DBLP dataset and EU Horizon 2020 projects. It includes nodes for Papers, Authors, Organizations, Venues, Topics, and Projects, totaling up to 190 million edges.
- News Articles HIN: Derived from the GDELT Project and the Panama Papers scandal. It connects Articles, Persons, Organizations, Locations, and Companies, totaling nearly 300 million edges. Schemas for the Scholarly and News HINs
Key Insights and Ideas
- Exploiting Redundancy: In real-world exploratory analysis, query overlaps are not just common—they are the norm. By caching the "middle" of a computation, Atrapos avoids re-doing the heaviest lifting.
- Sparsity as an Advantage: Adding constraints (like date filters) makes the underlying matrices even sparser. Atrapos turns these constraints into diagonal matrices that accelerate the multiplication process rather than slowing it down.
- Hierarchy-Aware Caching: The most "surprising" insight is that a cache replacement policy must understand the tree structure of the queries. Evicting a "parent" node in the Overlap Tree changes the re-computation cost of all its "children," a factor Atrapos manages explicitly.
Key Results
Atrapos demonstrates clear dominance in real-time scenarios:
- Vs. Single-Query Methods: It is over one order of magnitude faster than Neo4j and two orders of magnitude faster than HRank (a dense-matrix research prototype) on dataset subsets.
- Caching Efficiency: Compared to a version of itself without caching (HRank-S), Atrapos provides a 23-27% speedup on full-scale datasets simply by reusing intermediate results.
- Superior Replacement Policy: The custom Atrapos-OTree policy consistently outperformed standard LRU and other cost-aware baselines (like PGDS), especially when memory was limited. It proved particularly robust when query distributions were skewed (Zipfian), which is typical of human behavior.
Limitations and Future Work
While Atrapos excels at exact query evaluation, the authors note that in some scenarios, users might tolerate small errors for even faster results. Integrating truncation strategies (zeroing out very small values in the matrices) could be a future optimization. Additionally, while the system handles real-time streams of queries effectively, there may be further gains to be had by performing offline batch optimization if the workload is known in advance. Finally, the current model focuses on node property constraints; extending this to edge property constraints is a logical next step.
Summary updated