Abstract
Knowledge Base Completion (KBC) models often suffer from predicting entities that are type-incompatible with a given relation. We present TypeDM and TypeComplex, models that learn latent entity types and relation requirements simultaneously from raw triples without external supervision. By decoupling entity identity from latent type and using a multiplicative scoring function, our approach achieves a 7% improvement in Mean Reciprocal Rank (MRR) on standard benchmarks and discovers semantically meaningful latent types.
Introduction
Large-scale Knowledge Bases (KBs) such as Freebase and YAGO are essential for many AI tasks but remain incomplete. KBC models aim to predict missing facts by learning embeddings for entities and relations. However, state-of-the-art models like DistMult (DM) and Complex (CX) frequently make "type-incompatible" errors—for instance, predicting a "film" for a relation that expects a "religion."
Analysis of the FB15K dataset reveals that nearly 20% of top predictions by standard models are of the wrong type. While previous attempts to solve this relied on external type catalogs, these are often incomplete or unavailable. This work explores whether a model can learn to respect types using only the existing facts in the KB.
Methodology
The core innovation lies in modifying the scoring functions of DM and Complex to incorporate latent type compatibility.
Dual Embeddings
Instead of a single vector, each entity $e$ is represented by two vectors:
- $a_e$: Represents the entity's specific identity.
- $u_e$: Represents the entity's latent "type."
Similarly, each relation $r$ is assigned three vectors: $b_r$ (the standard relation embedding), $v_r$ (the expected type for the subject), and $w_r$ (the expected type for the object).
Multiplicative Scoring Function
The new score $f'(s, r, o)$ is calculated as the product of the base model score and two compatibility terms:
- Base Score: Measures how well the identities of $s$ and $o$ fit relation $r$.
- Subject Compatibility: A sigmoid-activated dot product between $u_s$ and $v_r$.
- Object Compatibility: A sigmoid-activated dot product between $u_o$ and $w_r$.
This multiplicative structure acts as a logical AND gate: a triplet is only highly scored if the entities fit the relation's identity requirements and match the relation's type expectations. To ensure a fair comparison with baseline models, the authors reduced the dimensions of the identity embeddings to accommodate the new type embeddings, maintaining a similar total parameter count.
Evaluation
The models were evaluated on FB15K, FB15K-237, and YAGO3-10. WN18 was excluded as its generic relations (e.g., "hypernym") do not provide sufficient evidence for distinct latent types.
Results
TypeDM and TypeComplex consistently outperformed their base versions. On FB15K, TypeDM reached an MRR of 0.750, a significant jump from DM's 0.674.
Beyond performance, the latent vectors $u_e$ were found to cluster by actual semantic categories (e.g., People, Locations) when visualized via PCA. Furthermore, these latent vectors were significantly better at predicting "real" symbolic types from supervised catalogs than standard identity vectors, confirming that the model successfully decoupled identity from type.
Conclusion
By integrating latent type discovery directly into the KBC scoring function, TypeDM and TypeComplex significantly reduce type-incompatible errors without requiring external supervision. This approach demonstrates that relational patterns alone are sufficient to learn meaningful semantic categories, setting a new standard for unsupervised knowledge base inference.
Summary updated