Knowledge Graph Embedding in E-commerce Applications: Attentive Reasoning, Explanations, and Transferable Rules

Wen Zhang, Shumin Deng, Mingyang Chen, Liang Wang, Qiang Chen, Feiyu Xiong, Xiangwen Liu, Huajun Chen

Introduction

Knowledge Graphs (KGs) are fundamental to modern e-commerce, structuring vast amounts of relational data to power search, recommendation, and categorization systems. However, industrial-scale KGs—such as Alibaba’s, which contains over 70 billion triples—pose significant challenges for standard Knowledge Graph Embedding (KGE) techniques. Traditional KGE models often struggle with task-specific reasoning, lack explainability (functioning as "black boxes"), and fail to produce transferable logic rules necessary for rapidly evolving systems.

To address these hurdles, researchers from Zhejiang University and Alibaba Group introduced an Explainable Knowledge Graph Attention Network. This framework moves beyond isolated triple analysis to model correlations between triples, providing attentive reasoning that enhances both predictive accuracy and human interpretability.

System Overview

The proposed framework is designed to handle diverse e-commerce tasks by identifying task-relevant subgraphs and extracting high-level logic. By focusing on specific relations—such as brand identification or lifestyle categorization—the model avoids the computational overhead of processing the entire global graph while improving task performance.

Framework for e-commerce knowledge graph reasoning across multiple business tasks.

Methodology

The core of the approach is a graph attention mechanism built upon the "translation" assumption (TransE), where the relationship between a head entity ($h$) and a tail entity ($t$) is represented as $h + r \approx t$.

  1. Graph Attention Layers: The model aggregates information from an entity's local neighborhood. It calculates attention weights to determine the relative importance of neighboring triples to the target entity's representation.
  2. Stackable Architecture: By stacking these attention layers, the model can capture multi-hop relational paths, allowing it to reason about complex, indirect connections within the KG.
  3. Explanation and Rule Induction: The attention weights serve as a roadmap for explainability. The model identifies the most influential neighbor triples to generate human-readable explanations (paths of facts). By abstracting specific entities into variables, the system automatically induces transferable logic rules that can be applied across different systems.

Results and Discussion

Empirical evaluation on a real-world Alibaba KG subset (72,849 entities and 789 relations) demonstrated the model's superiority over classic baselines like TransE, TransH, and DistMult.

Predictive Performance

The model achieved a 36.8% improvement in Mean Reciprocal Rank (MRR) and a 16.7% increase in Hit@10 for partial link prediction compared to the best-performing baselines. Notably, the model proved highly data-efficient, achieving these results using only 0.25% to 2.23% of the total training data by focusing on local neighborhood information.

Explainability and Human Productivity

The quality of the generated explanations was a key highlight. The model provided valid explanations for over 95% of test cases. In practical applications, providing these explanations to human experts reduced the time required for manual triple verification by approximately 43%.

Comparison of Recall and Average Support for explanations between the proposed model and TransE.

As shown in the performance metrics, the proposed model significantly outperforms TransE in both recall and average support for explanations, particularly as the number of selected explanations per triple increases. Furthermore, the system successfully induced 9,560 rules, with over 31% meeting high-quality thresholds, outperforming specialized rule-mining tools like AMIE.

Conclusion and Future Work

This research bridges the gap between connectionist AI (embeddings) and symbolic AI (rules) within the e-commerce domain. While highly effective, the model currently employs neighbor filtering to manage density and limits rule body length to two hops. Future work will explore deeper relational paths and the generalizability of these attentive mechanisms to other domains, such as medical or scientific knowledge graphs.

Summary updated

Abstract

Knowledge Graphs (KGs), representing facts as triples, have been widely adopted in many applications. Reasoning tasks such as link prediction and rule induction are important for the development of KGs. Knowledge Graph Embeddings (KGEs) embedding entities and relations of a KG into continuous vector spaces, have been proposed for these reasoning tasks and proven to be efficient and robust. But the plausibility and feasibility of applying and deploying KGEs in real-work applications has not been well-explored. In this paper, we discuss and report our experiences of deploying KGEs in a real domain application: e-commerce. We first identity three important desiderata for e-commerce KG systems: 1) attentive reasoning, reasoning over a few target relations of more concerns instead of all; 2) explanation, providing explanations for a prediction to help both users and business operators understand why the prediction is made; 3) transferable rules, generating reusable rules to accelerate the deployment of a KG to new systems. While non existing KGE could meet all these desiderata, we propose a novel one, an explainable knowledge graph attention network that make prediction through modeling correlations between triples rather than purely relying on its head entity, relation and tail entity embeddings. It could automatically selects attentive triples for prediction and records the contribution of them at the same time, from which explanations could be easily provided and transferable rules could be efficiently produced. We empirically show that our method is capable of meeting all three desiderata in our e-commerce application and outperform typical baselines on datasets from real domain applications.
BibTeX
@inproceedings{zhang2021knowledge,
  author = {Wen Zhang and Shumin Deng and Mingyang Chen and Liang Wang and Qiang Chen and Feiyu Xiong and Xiangwen Liu and Huajun Chen},
  title = {{Knowledge Graph Embedding in E-commerce Applications: Attentive Reasoning, Explanations, and Transferable Rules}},
  booktitle = {IJCKG},
  year = {2021},
  url = {https://openreview.net/forum?id=KH73lkBuyFb},
}
Figure