Abstract
Knowledge graphs (KGs) represent facts in structured forms, and KG completion aims to discover new facts from existing ones. While the Translation-based embedding model (TransE) is efficient, it is often criticized for its inability to encode complex relation patterns like symmetry or reflexivity. This paper challenges that notion, demonstrating that these limitations are largely a byproduct of ignoring the role of the loss function. By analyzing the "region of truth" defined by various loss functions, we show that proper selection can mitigate these theoretical constraints. We introduce TransComplEx, a model that leverages complex space and specific loss functions to achieve state-of-the-art performance with high efficiency.
Introduction
Knowledge Graph Embedding (KGE) models represent entities and relations as low-dimensional vectors to predict missing links. The classic TransE model ($h + r \approx t$) is favored for its simplicity but is mathematically argued to fail at encoding logical patterns like symmetry. For instance, in a symmetric relation, TransE's logic traditionally forces the relation vector to zero, collapsing the embedding space.
This research argues that these perceived limitations only exist if one assumes a perfect score of zero is required for a fact to be true. In practice, models are trained with loss functions that allow for a margin of error. By reinvestigating these boundaries through the lens of the loss function, we reveal that simpler models possess greater representational capacity than previously assumed.
The Role of Loss Functions and the "Region of Truth"
The core theoretical contribution of this work is the categorization of loss functions based on how they bound the scores of positive and negative samples. If a loss function defines a "region of truth"—a sphere of radius $\gamma_1$ around the target rather than a single point—the classic limitations of translation-based models vanish.
By reformulating training as a constrained optimization problem, the loss function becomes a fundamental part of the model's representational capacity. This visualization shows how truth can be represented as a volume, allowing symmetric relations to be encoded even within a translation-based framework.
The TransComplEx Model
To build on these insights, we propose TransComplEx, which performs translation in complex space. Specifically, it translates the head entity vector to the conjugate of the tail entity vector. This approach allows the model to distinguish between subject and object roles while remaining computationally leaner than models like ComplEx, requiring only four vector operations instead of eight. Additionally, we derive algebraic formulae for symmetry, inversion, and implication to be used as regularization terms, explicitly injecting these patterns into the model.
Experimental Evaluation
We evaluated TransComplEx on four standard benchmarks: FB15k, WN18, and their more challenging counterparts, FB15k-237 and WN18RR (which remove inverse relations to prevent data leakage).
Key Results
- Superior Performance: TransComplEx, paired with a "limit-based" loss function (e.g., RPTransComplEx6), significantly outperformed standard TransE and complex models like TorusE and R-GCN on challenging datasets.
- Efficiency: The model achieved competitive results using smaller embedding dimensions ($d=200$) compared to RotatE ($d=1,000$) or TorusE ($d=10,000$).
- Theoretical Validation: Experiments confirmed that the choice of loss function directly impacts the model's ability to handle specific relation patterns, validating our theoretical proofs.
Conclusion
This paper rehabilitates the translation-based class of KGE models by highlighting the critical role of the loss function. By defining a "region of truth," we show that models like TransE and the proposed TransComplEx can overcome traditional theoretical hurdles. Future work will explore automated loss selection and extending these theories to other distance-based models like RotatE to further mitigate the challenges of Many-to-Many (M-N) relations.
Summary updated