Abstract
Knowledge Graph Embedding (KGE) aims to represent entities and relations in a continuous vector space to facilitate tasks like link prediction. Traditional models, such as TransE, often struggle with "multiple relation semantics," where a single relation label encompasses several distinct meanings. We present TransG, a generative model that leverages a Bayesian non-parametric mixture to explicitly model these latent semantics. By utilizing a Chinese Restaurant Process (CRP), TransG automatically determines the optimal number of semantic components for each relation. Our evaluation on standard benchmarks demonstrates that TransG achieves state-of-the-art performance in link prediction and triple classification while maintaining high computational efficiency.
Introduction
Most Knowledge Graph Embedding models follow the translation-based paradigm introduced by TransE, where the tail entity ($t$) is expected to be close to the head entity ($h$) plus a relation vector ($r$), formulated as $h + r \approx t$. While effective for simple relations, this approach fails to account for relation ambiguity. In large-scale knowledge bases like Freebase, a single relation often serves multiple semantic roles. For instance, the relation HasPart might denote physical composition (Table, HasPart, Leg) or geographical containment (Atlantic, HasPart, New York Bay). Forcing these disparate meanings into a single translation vector $r$ creates a "semantic mixture" that degrades the quality of the embeddings and leads to inaccurate predictions.
The TransG Model
To overcome the limitations of single-vector representations, TransG treats each relation as a mixture of multiple component vectors, allowing it to capture the nuanced meanings inherent in complex relations.
Generative Process and Non-Parametric Clustering
TransG assumes that for every triple $(h, r, t)$, the entities are drawn from normal distributions. The core innovation lies in the selection of the "semantic component" for the relation, which is governed by a Chinese Restaurant Process (CRP). The CRP is a Bayesian non-parametric model that allows the number of clusters to grow with the data. If a new triple does not align well with existing semantic clusters, the model can adaptively "open a new table," creating a new semantic component for that relation.
Score Function and Training
The model's score function is defined as the probability of a triple existing across all its relation's semantic components. In practice, the component that best fits the triple dominates the score due to exponential decay. This mechanism effectively denoises the embedding by allowing the model to ignore irrelevant semantic components for a specific entity pair. Training is conducted by maximizing the likelihood of "golden" (true) triples while minimizing the likelihood of corrupted (false) triples.
Experimental Evaluation
TransG was evaluated on four standard benchmarks: WN18, WN11, FB15K, and FB13. These datasets provide a rigorous testbed for link prediction and triple classification tasks.
Key Results
TransG demonstrated a significant performance leap over previous state-of-the-art models:
- Link Prediction: On FB15K, TransG achieved a HITS@10 (Filter) of 88.2%, far surpassing TransE (47.1%) and even the more complex TransR (68.7%).
- Triple Classification: The model reached an average accuracy of 87.4% across WN11 and FB13, outperforming all other tested models, including the Neural Tensor Network (NTN).
- Efficiency: Despite its complexity, TransG remains highly efficient. On FB15K, it requires only 4.8 seconds per iteration, making it orders of magnitude faster than CTransR (136.8 seconds), which relies on a separate pre-clustering step.
Discussion and Insights
The success of TransG stems from its adaptive complexity. As shown in the experimental results, the model discovers varying numbers of semantic components based on the inherent complexity of the relation. For simple relations like Gender, it may find only one component, whereas broad relations like Type Of may require dozens. By allowing a triple to be represented by its most relevant semantic component, the model prevents the "wrong" meanings of a relation from interfering with the embedding of a specific fact.
One limitation noted by the authors is data sparsity. In cases where entity-relation pairs in the test set never appeared during training (roughly 0.5% of WN18), the model lacks the necessary data to assign or form clusters, leading to a higher Mean Rank in those specific instances.
Conclusion
TransG is the first generative model to explicitly address relation ambiguity in KGE through a mixture-of-experts approach. By automatically discovering latent semantics, it provides a more nuanced and accurate representation of knowledge graphs. Future work may extend these generative principles to address entity polysemy, where entities themselves possess multiple meanings depending on the context.
Summary updated