Deja vu: Contrastive Historical Modeling with Prefix-tuning for Temporal Knowledge Graph Reasoning

Miao Peng,Ben Liu,Wenjie Xu,Zihao Jiang,Jiahui Zhu,Min Peng
2024-03-26
Abstract:Temporal Knowledge Graph Reasoning (TKGR) is the task of inferring missing facts for incomplete TKGs in complex scenarios (e.g., transductive and inductive settings), which has been gaining increasing attention. Recently, to mitigate dependence on structured connections in TKGs, text-based methods have been developed to utilize rich linguistic information from entity descriptions. However, suffering from the enormous parameters and inflexibility of pre-trained language models, existing text-based methods struggle to balance the textual knowledge and temporal information with computationally expensive purpose-built training strategies. To tap the potential of text-based models for TKGR in various complex scenarios, we propose ChapTER, a Contrastive historical modeling framework with prefix-tuning for TEmporal Reasoning. ChapTER feeds history-contextualized text into the pseudo-Siamese encoders to strike a textual-temporal balance via contrastive estimation between queries and candidates. By introducing virtual time prefix tokens, it applies a prefix-based tuning method to facilitate the frozen PLM capable for TKGR tasks under different settings. We evaluate ChapTER on four transductive and three few-shot inductive TKGR benchmarks, and experimental results demonstrate that ChapTER achieves superior performance compared to competitive baselines with only 0.17% tuned parameters. We conduct thorough analysis to verify the effectiveness, flexibility and efficiency of ChapTER.
Artificial Intelligence,Computation and Language,Machine Learning
What problem does this paper attempt to address?
The paper primarily focuses on addressing the problem of Temporal Knowledge Graph Reasoning (TKGR), particularly the inference of missing facts in incomplete Temporal Knowledge Graphs (TKGs) in complex scenarios such as inductive and semi-inductive settings. Specifically, the paper addresses the following key issues: 1. **Balancing Textual and Temporal Information**: Existing text-based methods often struggle to balance the textual knowledge in Pre-Trained Language Models (PLMs) with temporal information when leveraging the rich linguistic information in entity descriptions. 2. **Handling Large Parameter Sizes and Flexibility Issues**: Due to the large parameter sizes and low flexibility of pre-trained language models, current methods are expensive and complex in terms of training strategies. 3. **Adapting to Tasks in Different Complex Scenarios**: Efficiently integrating historical information into textual knowledge and adapting to various complex scenarios of temporal knowledge graph reasoning within a unified PLM-based framework. To address the above issues, the paper proposes a new framework named ChapTER (Contrastive historical modeling with Prefix-tuning for TEmporal Reasoning). ChapTER employs a contrastive historical modeling approach and utilizes a prefix-tuning strategy to effectively fine-tune the frozen pre-trained language models. This method not only enables temporal knowledge graph reasoning in different scenarios (including inductive and semi-inductive settings) but also significantly reduces the number of parameters that need to be adjusted, requiring only 0.17% of the parameters to achieve good performance. In summary, the main contribution of this paper is the proposal of a new temporal knowledge graph reasoning framework, ChapTER, which effectively integrates historical information and textual knowledge, achieves efficient temporal reasoning in various complex scenarios, and maintains high flexibility and low computational cost.