VRKG4Rec: Virtual Relational Knowledge Graph for Recommendation

Lingyun Lu, Bang Wang, Zizhuo Zhang, Shenghao Liu, Han Xu

TL;DR

This paper introduces VRKG4Rec, a novel recommendation system that addresses the challenge of noisy and sparse relations in knowledge graphs (KGs). By clustering similar relations into "virtual relations" and constructing Virtual Relational Knowledge Graphs (VRKGs), VRKG4Rec effectively captures nuanced item relationships, leading to improved recommendation performance.

What Problem Does This Paper Address?

Traditional recommendation systems often struggle with data sparsity, leading to suboptimal recommendations. Knowledge graphs (KGs) offer a rich source of side information to alleviate this problem by providing relational context between items. However, existing KG-based recommendation methods often treat each relation type independently, which can be problematic. Real-world KGs suffer from a "long-tail" distribution of relations, meaning many relations appear infrequently and might be noisy or semantically similar to others. Directly using all these relations can lead to suboptimal item representations and hinder recommendation accuracy. This paper aims to tackle this issue by intelligently grouping similar relations to create more robust and informative representations.

Methods

The core innovation of VRKG4Rec lies in its Virtual Relational Knowledge Graph (VRKG) construction and the Local Weighted Smoothing (LWS) mechanism.

  1. VRKG Construction: Instead of using the original KG directly, VRKG4Rec first clusters the relations. It initializes "virtual relations" and iteratively assigns original relations to the closest virtual relation based on their embeddings. This process creates a set of K VRKGs, where each VRKG focuses on a group of semantically similar relations. This unsupervised clustering helps to filter out noise and consolidate similar relational information.
  2. Local Weighted Smoothing (LWS): This is a novel aggregation scheme designed to learn node representations within each VRKG. LWS iteratively updates a node's embedding by considering the weighted embeddings of its direct neighbors. The weights are determined by the similarity between the node and its neighbors, ensuring that more relevant neighbors contribute more to the update. This mechanism is applied to each VRKG independently, allowing for different aspects of item representation to be learned.
  3. Representation Learning: The item embeddings learned from each VRKG are then fused using an attention mechanism, where the attention weights are learned during training, indicating the importance of each virtual relation. The LWS mechanism is also applied to a user-item bipartite graph to learn user representations, leveraging the enriched item embeddings.

Datasets

The proposed VRKG4Rec model was evaluated on two public datasets:

  • Last.FM: A music listening dataset.
  • MovieLens-1M: A movie recommendation dataset.

The paper also mentions using Microsoft Satori to construct knowledge graphs for these datasets by matching item IDs with head entities in triples.

Key Insights and Ideas

  • The "long-tail" problem in KGs is a significant hurdle for recommendation systems. Simply using all relations, especially infrequent ones, can introduce noise and dilute the signal.
  • Clustering similar relations into "virtual relations" is a powerful way to denoise and consolidate KG information. This allows the model to focus on more meaningful relational patterns.
  • Semantic similarity between relations matters. Relations like "screenwriter" and "director" might be semantically similar in the context of movie recommendations, even if they are distinct types. VRKG4Rec captures this by grouping them.
  • Local Weighted Smoothing (LWS) provides a flexible and effective way to aggregate neighbor information. By weighting neighbors based on similarity, it ensures that more relevant connections have a stronger influence on node embeddings.
  • Not all relations are equally beneficial for recommendation. The paper shows that discarding virtual relation clustering (Variant-1) or constructing VRKGs based on every single original relation type (Variant-2) leads to worse performance, highlighting the importance of the proposed clustering approach.

Key Results

  • VRKG4Rec consistently outperforms state-of-the-art KG-based recommendation approaches (FM, NFM, CKE, KGAT, KGIN) on both Last.FM and MovieLens-1M datasets across various metrics (Recall, NDCG, HR) and recommendation list lengths.
  • For example, on the Last.FM dataset, VRKG4Rec achieved a Recall@20 of 28.05%, which is a significant improvement over KGIN (24.96%) and KGAT (12.56%).
  • The number of virtual relations (K) is a crucial hyperparameter, with K=3 showing optimal performance on both datasets, suggesting a sweet spot for capturing relevant relational patterns without over-segmentation.
  • The LWS mechanism's iteration depth (Q) and GNN layer depth (L) are also important, with performance generally improving up to a certain point before degrading, indicating the need for careful tuning to avoid over-smoothing or missing higher-order information.

Limitations and Future Work

  • Manual selection of the number of virtual relations (K) is labor-intensive. The authors suggest that future work should investigate methods for automatically learning the optimal number of VRKGs.
  • The paper mentions that the model was implemented in PyTorch and that they plan to explore using their model on the MindSpore deep learning framework.
  • Further research could explore more sophisticated ways to fuse information from different VRKGs and investigate the impact of different similarity functions for relation clustering.

Summary updated

Abstract

Incorporating knowledge graph as side information has become a new trend in recommendation systems. Recent studies regard items as entities of a knowledge graph and leverage graph neural networks to assist item encoding, yet by considering each relation type individually. However, relation types are often too many and sometimes one relation type involves too few entities. We argue that it is not efficient nor effective to use every relation type for item encoding. In this paper, we propose a VRKG4Rec model (Virtual Relational Knowledge Graphs for Recommendation), which explicitly distinguish the influence of different relations for item representation learning. We first construct virtual relational graphs (VRKGs) by an unsupervised learning scheme. We also design a local weighted smoothing (LWS) mechanism for encoding nodes, which iteratively updates a node embedding only depending on the embedding of its own and its neighbors, but involve no additional training parameters. We also employ the LWS mechanism on a user-item bipartite graph for user representation learning, which utilizes encodings of items with relational knowledge to help training representations of users. Experiment results on two public datasets validate that our VRKG4Rec model outperforms the state-of-the-art methods. The implementations are available at https://github.com/lulu0913/VRKG4Rec.
BibTeX
@inproceedings{lu2023vrkg,
  author = {Lingyun Lu and Bang Wang and Zizhuo Zhang and Shenghao Liu and Han Xu},
  title = {{VRKG4Rec: Virtual Relational Knowledge Graph for Recommendation}},
  booktitle = {WSDM},
  year = {2023},
  doi = {10.1145/3539597.3570482},
}
Figure