Relation prediction is a task designed for knowledge graph completion which aims to predict missing relationships between entities. Recent subgraph-based models for inductive relation prediction have received increasing attention, which can predict relation for unseen entities based on the extracted subgraph surrounding the candidate triplet. However, they are not completely inductive because of their disability of predicting unseen relations. Moreover, they fail to pay sufficient attention to the role of relation as they only depend on the model to learn parameterized relation embedding, which leads to inaccurate prediction on long-tail relations. In this paper, we introduce Relation-dependent Contrastive Learning (ReCoLe) for inductive relation prediction, which adapts contrastive learning with a novel sampling method based on clustering algorithm to enhance the role of relation and improve the generalization ability to unseen relations. Instead of directly learning embedding for relations, ReCoLe allocates a pre-trained GNN-based encoder to each relation to strengthen the influence of relation. The GNN-based encoder is optimized by contrastive learning, which ensures satisfactory performance on long-tail relations. In addition, the cluster sampling method equips ReCoLe with the ability to handle both unseen relations and entities. Experimental results suggest that ReCoLe outperforms state-of-the-art methods on commonly used inductive datasets.
翻译:关系预测是知识图完成的一项任务,旨在预测实体间缺失的关系。最近用于感化关系预测的子图基础模型受到越来越多的关注,这可以预测基于候选人三进制子图的隐形实体之间的关系。然而,它们并非完全具有启发性,因为它们无法预测隐形关系。此外,它们没有足够重视关系的作用,因为它们仅仅依赖于学习参数化关系嵌入的模型,从而导致对长尾关系作出不准确的预测。在本文中,我们引入了基于关系预测的基于关系预测的基于关系的子模型(ReCoLe),这种模型可以根据基于集群算法的新型抽样方法调整对比性学习,以加强关系的作用,提高隐形关系的一般化能力。 ReCole没有直接学习嵌入关系,而是为每一种关系配置了事先经过训练的GNNN的编码器,以加强关系的影响。基于GNNN的编码器通过对比性学习加以优化,从而确保长尾关系方面的满意性业绩。此外,集群取样方法使RECRECA模型能够处理常规数据。