Dynamic Subgraph Matching via Cost-Model-based Vertex Dominance Embeddings (Technical Report)

Yutong Ye, Xiang Lian, Nan Zhang, Mingsong Chen

Abstract

In many real-world applications such as social network analysis, knowledge graph discovery, biological network analytics, and so on, graph data management has become increasingly important and has drawn much attention from the database community. While many graphs (e.g., Twitter, Wikipedia, etc.) are usually involving over time, it is of great importance to study the dynamic subgraph matching (DSM) problem, a fundamental yet challenging graph operator, which continuously monitors subgraph matching results over dynamic graphs with a stream of edge updates. To efficiently tackle the DSM problem, we carefully design a novel vertex dominance embedding approach, which effectively encodes vertex labels that can be incrementally maintained upon graph updates. Inspire by low pruning power for high-degree vertices, we propose a new degree grouping technique over basic subgraph patterns in different degree groups (i.e., groups of star substructures), and devise degree-aware star substructure synopses (DAS^3) to effectively facilitate our designed vertex dominance and range pruning strategies. We develop efficient algorithms to incrementally maintain dynamic graphs and answer DSM queries. Through extensive experiments, we confirm the efficiency of our proposed approaches over both real and synthetic graphs.

Introduction: The Challenge of Dynamic Subgraph Matching

Subgraph matching—finding all instances of a small "query" pattern within a massive "data" graph—is a fundamental but computationally expensive task (NP-complete). While well-studied for static graphs, real-world data like social networks, transaction logs, and biological pathways are dynamic, with edges appearing and disappearing every millisecond.

The challenge in Continuous Subgraph Matching (CSM) is latency. A global search cannot be re-run every time a single edge changes. Existing methods either struggle with the "curse of dimensionality" when using graph embeddings or fail to prune the search space effectively when dealing with high-degree vertices (the "hubs" of a network). The authors aim to bridge this gap by creating an embedding-based approach that is both incrementally maintainable and highly efficient at filtering out false candidates.

Figure 1: Illustration of a query graph (a) and a dynamic collaboration network (b) with edge updates.

The DIVINE Framework

The core of this research is the DynamIc Vertex DomINance Embedding (DIVINE) framework. It maps vertex neighborhoods into a specialized embedding space where subgraph relationships translate into "dominance" queries, achieving search speeds 1 to 5 orders of magnitude faster than current state-of-the-art methods. Its architecture consists of three main components:

1. Vertex Dominance Embeddings

Each vertex is assigned a vector based on its label and the labels of its neighbors. The authors use SPUR (Seeded PseUdo Random) vectors for labels and SPAN (SPUR Aggregated Neighbor) vectors for the neighborhood. Crucially, if a query vertex matches a data vertex, the query’s embedding must "dominate" the data vertex’s embedding in the vector space. This turns a graph problem into a geometric search problem: if vector $A \le$ vector $B$ across all dimensions, $B$ can be immediately discarded as a candidate for $A$.

2. Degree Grouping & DAS³

High-degree vertices usually have poor "pruning power" because their neighborhoods are too diverse. To address this, the authors decompose high-degree star patterns into smaller substructures and store them in Degree-Aware Star Substructure Synopses (DAS³)—a grid-based index that allows for fast range pruning.

Figure 4: Decomposition of a unit star subgraph (a) into possible star substructures (b) for improved pruning.

3. Cost-Model-Guided Optimization

Instead of using a standard uniform distribution for embeddings, the authors developed a cost model showing that a Zipf distribution (low mean, high variance) maximizes pruning efficiency. This ensures that the embedding space is mathematically optimized to reject false matches quickly.

Experimental Evaluation

The authors evaluated DIVINE against six real-world datasets (Yeast, HPRD, Reddit, DBLP, Youtube, and US Patents) and synthetic ones generated using the Newman-Watts-Strogatz model. The largest graphs contained up to 10 million vertices and over 57 million edges.

Key Results

  • Performance: DIVINE outperformed five major baselines (Graphflow, SJ-Tree, TurboFlux, SymBi, and IEDyn) and a GNN-based approach (GNN-PE) by 1 to 5 orders of magnitude in wall-clock time.
  • Pruning Power: The strategies ruled out 85% to 99.5% of candidate vertices before the expensive refinement step began.
  • Scalability: The system showed near-linear scalability. On a graph with 10 million vertices, update and query times remained under 1.05 seconds.
  • Robustness: The framework handled "adversarial" queries and "bursty" updates without significant performance degradation.

Conclusion and Future Work

DIVINE demonstrates that subgraph matching can be effectively treated as a multi-dimensional dominance search. By breaking hubs into star substructures and optimizing embedding distributions, it maintains high performance even in dense, rapidly evolving graphs. Because the embeddings are based on local 1-hop neighborhoods, edge updates only affect two vertices, making the maintenance phase extremely lightweight.

Future work includes supporting the insertion/deletion of isolated vertices and extending the framework to directed and edge-labeled graphs. Additionally, exploring different geometric distributions (like $L_2$-norm) for base vector design could further refine the embedding space.

Summary updated

Abstract

In many real-world applications such as social network analysis, knowledge graph discovery, biological network analytics, and so on, graph data management has become increasingly important and has drawn much attention from the database community. While many graphs (e.g., Twitter, Wikipedia, etc.) are usually involving over time, it is of great importance to study the dynamic subgraph matching (DSM) problem, a fundamental yet challenging graph operator, which continuously monitors subgraph matching results over dynamic graphs with a stream of edge updates. To efficiently tackle the DSM problem, we carefully design a novel vertex dominance embedding approach, which effectively encodes vertex labels that can be incrementally maintained upon graph updates. Inspire by low pruning power for high-degree vertices, we propose a new degree grouping technique over basic subgraph patterns in different degree groups (i.e., groups of star substructures), and devise degree-aware star substructure synopses (DAS^3) to effectively facilitate our designed vertex dominance and range pruning strategies. We develop efficient algorithms to incrementally maintain dynamic graphs and answer DSM queries. Through extensive experiments, we confirm the efficiency of our proposed approaches over both real and synthetic graphs.
BibTeX
@misc{ye2024dynamic,
  author = {Yutong Ye and Xiang Lian and Nan Zhang and Mingsong Chen},
  title = {{Dynamic Subgraph Matching via Cost-Model-based Vertex Dominance Embeddings (Technical Report)}},
  year = {2024},
  eprint = {2407.16660},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2407.16660},
}
Figure