Next Article in Journal
Initial Coefficient Bounds Analysis for Novel Subclasses of Bi-Univalent Functions Linked with Lucas-Balancing Polynomials
Previous Article in Journal
Intellectual Capital Evaluation Index Based on a Hybrid Multi-Criteria Decision-Making Technique
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Revolutionary Strategy for Depicting Knowledge Graphs with Temporal Attributes

1
Computer Science and Engineering Department, Shaoxing University, Shaoxing 312000, China
2
Faculty of Arts & Science, University of Toronto, Toronto, ON M5S 3G3, Canada
*
Author to whom correspondence should be addressed.
These authors contributed equally to this work.
Submission received: 18 March 2024 / Revised: 19 April 2024 / Accepted: 22 April 2024 / Published: 26 April 2024
(This article belongs to the Topic Complex Networks and Social Networks)

Abstract

:
In practical applications, the temporal completeness of knowledge graphs is of great importance. However, previous studies have mostly focused on static knowledge graphs, generally neglecting the dynamic evolutionary properties of facts. Moreover, the unpredictable and limited availability of temporal knowledge graphs, together with the complex temporal dependency patterns, make current models inadequate for effectively describing facts that experience temporal transitions. To better represent the evolution of things over time, we provide a learning technique that uses quaternion rotation to describe temporal knowledge graphs. This technique describes the evolution of entities as a temporal rotation change in quaternion space. Compared to the Ermitian inner product in complex number space, the Hamiltonian product in quaternion space is better at showing how things might be connected. This leads to a learning process that is both more effective and more articulate. Experimental results demonstrate that our learning method significantly outperforms existing methods in capturing the dynamic evolution of temporal knowledge graphs, with improved accuracy and robustness across a range of benchmark datasets.

1. Introduction

Knowledge graph technology is crucial in the domain of knowledge representation and reasoning. A knowledge graph is a comprehensive semantic network composed of nodes and edges [1,2,3]. It may be conceptualized as a data structure based on a graph. A knowledge graph is often shown as a triplet, including a head entity, a tail entity, and a connection between the two entities. Well-known knowledge graphs like FreeBase, YAGO, and Schema.org serve as typical instances of knowledge graphs [4]. A knowledge graph may efficiently communicate the relationships between entities via a structured framework, providing the advantages of scalability and understandability. It is helpful to use the knowledge graph for things like system recommendations and obtaining information.
The knowledge graph remains incomplete and suffers from a significant data sparsity problem, meaning that many facts in the knowledge graph lack associated links or entities. The absence of this information can limit the effectiveness of the knowledge graph and its broader applications, highlighting the need for knowledge graph completion. Knowledge graph completion, also known as link prediction, is a type of knowledge reasoning that attempts to predict missing information by using current facts within the knowledge graph [5]. Initially, the knowledge graph was mostly developed through artificial creation. However, this approach is wasteful and difficult to handle when dealing with a knowledge graph of a very large size. Knowledge representation learning uses low-dimensional vectorisation to represent entities and relationships [1,2,4], effectively addressing the problem of sparse data. At present, knowledge representation learning provides the basis for building and using large-scale knowledge graphs, and it is also the most widely used technique for completing knowledge graphs.
However, most of the existing research focuses on the static knowledge network, which poses challenges in understanding the temporal fluctuations of information. In fact, some pieces of information change over time. For example, the set of three facts constituting the term of office of South Korean President Moon Jae-in was strictly limited to the period from May 2017 to May 2021. Nevertheless, there have been cases where clear triads have been formed, such as South Korea, President Park Geun-hye, and South Korea, President Lee Myung-bak. Ignoring the temporal aspect when answering the question “Who is the President of South Korea?” tends to lead to incorrect results. Therefore, this example demonstrates that including temporal information in knowledge graphs can significantly enhance the understanding and prediction of dynamic relationships within the data.
This study introduces a learning technique called TKGR which is used to model temporal knowledge graphs. TKGR uses quaternion rotation to accurately represent the evolution of things over time. The concept describes the process of changing entities over time as a rotational motion in quaternion space. The Hamiltonian product in quaternion space provides a more efficient and expressive learning process than the Ermitian inner product in complex number space. This allows for a more effective capture of possible interdependencies. The main contributions of this work are listed below:
  • To optimize the use of temporal data and to adequately represent the evolution of entities over time, we propose to use a learning method that uses quaternion rotation to describe temporal knowledge graphs. The model uses a rotation transformation in quaternion space to represent the temporal evolution of entities. This approach improves both the efficiency and the expressiveness of the learning process.
  • Our approach uses Hamiltonian product-based quaternion rotations to accurately describe the temporal and relational changes in knowledge networks. By exploiting the unique properties of quaternions, we are able to outperform the Ermitian product in complex numbers when it comes to representing relational data.
  • Finally, we verify the efficiency and suitability of the TKGR model through thorough experimental comparisons with state-of-the-art algorithms from different perspectives.

2. Related Work

The transformation of entities and interactions within a knowledge network into low-dimensional continuous vectors is a function that can be performed using embedding methods [6,7]. Static knowledge graph embedding and temporal knowledge graph embedding are the topics explicitly covered in this section.

2.1. Static Knowledge Graph Embedding

Researchers have identified a variety of knowledge graph embedding strategies for static knowledge graphs from their study. Knowledge graph embedding based on matrix decomposition, knowledge graph embedding based on convolutional neural networks, and knowledge graph embedding based on graphs are the three main categories that can be used to classify the approaches shown here.
When first presented, TransE [8] was used to solve models of knowledge graph embedding. These models use a score function to map entities h, t and relations r: h + rt. The aim is to reduce the distance between the two points, h and t. However, TransE has shortcomings when it comes to its ability to manage complicated relationships. It performs very well only in the case of one-to-one relations; it is unable to handle one-to-N and N-to-one relations. It has been suggested that many extended models can be used to get around these limitations. TransH [9] is an example of such a model. It is characterized by the introduction of a hyperplane representing each relation onto which entities are projected. Because of this, TransH is able to manipulate relations between one and N as well as from one to N. When the entities are transformed into a new vector space, another model is used, called TransR [9]. This model uses a relation-specific matrix that is different from the others. Because of this, TransR is able to efficiently manage many different types of relations. Another extended model that overcomes the limitations of TransE is a model called TransD [10]. Within this framework, additional matrices are introduced to uniquely describe the semantic meaning of elements and relations. As a result, TransD is able to manage complicated interactions and capture information with finer granularity.
Matrix factorization-based models such as DistMult [11], RESCAL [12], HolE [13], ComplEx [14] and SimplE [15] are responsible for transforming relations into linear transformations of entity embeddings imposed on matrices. ConvE [16] and ConvKB [17] are the two most commonly used in CNN-based models. In addition to transforming entities and relations into multidimensional matrices, ConvE and ConvKB also describe the interactions that occur between entities and relations through the use of convolution and build embeddings that are more expressive through the process of feature learning. Graph-based techniques are the subject of our final discussion. DeepWalk [18] is the first method to create vector embeddings of nodes in a network using a random walk model. This method is a weightless random walk technique. The R-GCN [19] is a graph neural network extension that is considered to be one of the first methods to use graph neural networks to learn node embeddings. This is achieved by aggregating the neighbourhood information of each entity ′, which ultimately results in identical weights for all entities. However, these approaches are not ideal for temporal knowledge graphs because they are unable to capture the temporal information contained within temporal knowledge graphs.

2.2. Temporal Knowledge Graph Embedding

Improving static knowledge graph approaches by incorporating temporal aspects has been the focus of previous research initiatives. Through the use of temporal constraints, an important model known as TTransE [15] was the first to pioneer the learning of entity and relation embeddings. This was achieved by expressing transitions between temporal relations. The sequential relationship between the events “diedIn” and “wasBornIn” is an example of what is considered. Merging temporal information from static models is not a simple extension of the models described above. To incorporate temporal knowledge graphs, the ConT model is an extension of the static knowledge graph model [20] for further explanation. This allows for the model to store the graph data and extrapolate to incorporate more recent information. By incorporating time into the entity relationship structure, HyTE [21] establishes a direct and transparent link between each timestamp and the hyperplane that is relevant to the entity. HyTE not only makes predictions about the temporal range of relational facts that do not contain time annotations, but also uses temporal guidance to infer knowledge graphs. The challenge of predicting the temporal knowledge graph is addressed by TA-DisMult [22], which does this by capturing the encoding of prospective entities and connection types. To capture time-sensitive representations of relationship types, the model uses recurrent neural networks. This allows for the integration of these representations with existing potential factor decomposition methods used for temporal information fusion.
DE-SimplE [23] is an extension of a static knowledge graph model that incorporates a diachronic entity embedding function. This function allows for the representation of entity properties at any point in time. This is different from current approaches to temporal knowledge graph embedding which only provide static properties of entities. The assignment of labels to entities, relationships, timestamps, and locations is performed by SubEE [24] using a vocabulary of a given size. The model, on the other hand, uses a spatio-temporal messaging layer to capture the latent feature vectors of the knowledge network. BoxTE [25] is an extended version of the static knowledge graph embedding model. It demonstrates a high level of expressiveness and a strong aptitude for inductive reasoning in temporal contexts.
While the approaches currently available for completing temporal knowledge graphs are promising, they often fail to capture both the structure of the graph and the temporal connections. Compared to previous techniques, which often focus on either entity properties or connections without integration, TKGR is able to capture both temporal dynamics and graph structure in a unique way. As a result, it produces embeddings that are more accurate for the tasks at hand.

3. Theory of Quaternions

This section provides a preliminary overview of the theoretical foundations of quaternions. The quaternion system H is an extension of the complex number system and typically consists of one real and three imaginary components, as specified below.
q = q r + q i i + q j j + q k k
where q r , q i , q j , and q k are the corresponding real coefficients. i, j and k are the imaginary units. If q j = q k = 0, it is the conventional complex form. These imaginary units also satisfy the following set of rules:
i 2 = j 2 = k 2 = ijk = 1
This rule may be used to infer a few more rules that do not correspond to the concept of commutativity, such as ij = k, ji = −k, jk = i, ki = j, kj = −i, and ik = −j. A quaternion vector q H n is defined as follows:
q = q r + q i i + q j j + q k k
where q r , q i , q j and q k are n-dimensional real vectors. For the purpose of modeling relational data, this study makes use of these concepts. According to the following definitions, there are a few standard arithmetic rules for quaternions:
Conjugate: The conjugate representation of quaternion q H is defined as follows:
q ¯ = q r q i i q j j q k k
Norm: The norm of quaternion q H is defined as follows:
q = q r 2 + q i 2 + q j 2 + q k 2
By means of this operation, the definition of the quaternion of the unit q is obtained.
q = q q
The unit representation of the quaternion vector q H n is defined below.
q = q r + q i i + q j j + q k k q r 2 + q i 2 + q j 2 + q k 2
Addition: The addition operation of two quaternions q 1 = q r 1 + q r 1 i + q j 1 j + q k 1 k and q 2 = q r 1 + q r 2 i + q j 2 j + q k 2 k is defined as follows:
q 1 + q 2 = q r 1 + q r 2 + q i 1 + q i 2 i + q j 1 + q j 2 j + q k 1 + q k 2 k
Scalar multiplication: The product of a scalar λ and a quaternion q H is defined as below.
λ q = λ q r + λ q i i + λ q j j + λ q k k
Inner product: Similar to the inner product operation on vectors, the result of the inner product operation on quaternions can be obtained by computing the product of the corresponding components of two quaternions q 1 H and q 2 H and then summing them.
q 1 · q 2 = q r 1 q r 2 + q i 1 q i 2 + q j 1 q j 2 + q k 1 q k 2
The inner product operation of two quaternion vectors q 1 H n and q 2 H n is defined below.
q 1 · q 2 = q r 1 T q r 2 + q i 1 T q i 2 + q j 1 T q j 2 + q k 1 T q k 2
Hamiltonian product: The Hamiltonian product is also called quaternion multiplication. The Hamiltonian product ⊗ of two quaternions q 1 H and q 2 H is defined as
q 1 q 2 = q r 1 q r 2 q i 1 q i 2 q j 1 q j 2 q k 1 q k 2 + q i 1 q r 2 + q r 1 q i 2 q k 1 q j 2 + q j 1 q k 2 i + q j 1 q r 2 + q k 1 q i 2 + q r 1 q j 2 q i 1 q k 2 j + q k 1 q r 2 q j 1 q i 2 + q i 1 q j 2 + q r 1 q k 2 k
The Hamiltonian product of two quaternion vectors q 1 H n and q 2 H n is defined as
q 1 q 2 = q r 1 q r 2 q i 1 q i 2 q j 1 q j 2 q k 1 q k 2 + q i 1 q r 2 + q r 1 q i 2 q k 1 q j 2 + q j 1 q k 2 i + q j 1 q r 2 + q k 1 q i 2 + q r 1 q j 2 q i 1 q k 2 j + q k 1 q r 2 q j 1 q i 2 + q i 1 q j 2 + q r 1 q k 2 k
where ∘ represents the multiplication between corresponding elements. It can be seen from Equation (12) that the Hamiltonian product has non-commutativity, i.e., q 1 q 2 q 2 q 1 .

4. Proposed Model

We use (h, r, t, τ ) to represent quaternions in a temporal knowledge graph. Temporal knowledge graph G can be seen as a set of quaternions. For each training quaternion in the graph, it is necessary to generate corresponding negative samples using negative sampling technology to support effective representation learning of entities and relations. In this section, G is used to represent the set of negative samples obtained by replacing the head or tail entities. Given a temporal knowledge graph, the purpose of the model is to learn an efficient quaternion representation and a scoring function g h , r , t , τ R for the head entity, the tail entity, the relation, and the timestamp, respectively. The purpose of this scoring function is to measure the degree of authenticity of each quad, with the scores of true and effective quads being higher than those of invalid quads.

4.1. Model Definition

The purpose of the model is to use quaternion embedding to model entities, relationships, and timestamps. Given quaternion (h, r, t, τ ), quaternion representations q h , q r , q t and q τ H n corresponding to each constituent element are defined as follows:
q h = a h + b h i + c h j + d h k
q r = a t + b t i + c t j + d t k
q t = a h + b h i + c h j + d h k
q τ = a τ + b τ i + c τ j + d τ k
where the coefficients of the real part as well as each imaginary part unit are n-dimensional vectors in real space.
While static knowledge graph completion models are able to learn multiple relational interactions between entities, they ignore the temporal factor and are therefore unable to reason effectively on temporal knowledge graphs. To address this problem, our model defines temporal evolution as a Hamiltonian product-based rotation transformation in quaternion space. Specifically, the model uses the unit vector form q τ of the temporal quaternion to represent the rotation operator and rotates the head entity vector q h and the tail entity vector q t to obtain a temporal entity representation, respectively.
q h , τ = q h q τ
q t , τ = q t q τ
The quaternion vectors of the head and tail entities can be considered as a point in the quaternion space, while q τ denotes a rotation transformation. After obtaining the time-dependent entities, the model uses the relation as a rotation transformation based on the Hamiltonian product, with the aim of rotating the time-dependent head entity to the vicinity of the time-dependent tail entity through the relation transformation. The general structure of the model is shown in Figure 1. To effectively represent the rotation transformation, we normalize the relation quaternion vector. For real quaternions, the model expects to satisfy q h , τ q τ q t , τ . With two Hamiltonian product-based rotations, the entities, relations, and timestamps can be allowed to interact sufficiently to capture the potential interdependencies between these three.
Unlike the Euler distance-based scoring function used in previous research, our model uses the angle between two vectors to measure the similarity between them. To measure the quaternion hold, the scoring function of our model g (h, r, t, τ ) is defined as follows:
g h , r , t , τ = q h , τ q r · q t , τ

4.2. Model Training

To learn the model parameters, it is necessary to define the corresponding loss function based on the scoring function. For each quadruple in the training set, the head or tail entity is replaced by another entity in the entity set to obtain the corresponding negative sample. We define the following loss function to ensure that the score of the negative sample of the model is lower than that of the positive sample.
L = h , r , t , τ G log 1 + exp l · g h , r , t , τ T G exp T + λ W 2 2
where θ denotes the learnable parameters of the model.
To prevent the model from overfitting and to improve the model’s ability to generalize invisible facts, we add parametric regularisation constraints to the entity, relationship, and timestamp representations as shown in Equation (22).
L r e g u l a r θ = h , r , t , τ q h + q r + q t + q τ 2 2 + q h , τ + q t , τ 2 2
Furthermore, we assume that the existing knowledge of past time intervals can be used to accurately capture the progression pattern of the whole graph during model training. Literature [26] presents experimental results indicating that subgraphs of successive time steps exhibit minimal changes, and the embedding space of successive time steps should also exhibit smoothness. Consequently, the TKGR model must have smoothing requirements on successive time intervals.
L s m o o t h θ = T h , r , t , τ G q τ + q h + q t + q r 2 2 + T 1 h , r , t , τ G q r 2 2
where T denotes the number of time steps. By adding parameter regularization constraints as well as temporal smoothing constraints to the model, the final loss function of the TKGR model is shown below.
L θ = L θ + λ 1 L r e g u l a r θ + λ 2 L s m o o t h θ
where λ 1 and λ 2 represents the coefficient of the regularization term.
Meanwhile, a suitable initialization method can improve the training speed and reduce the risk of gradient explosion or gradient disappearance. It has been shown that the parameters of the hyper-complex representation cannot simply be initialized randomly. Therefore, in order to improve the convergence of the TKGR model, we adopt the following method to initialize the model parameters:
w r = φ cos θ
w i = φ Q i m g i sin θ
w j = φ Q i m g j sin θ
w k = φ Q i m g k sin θ
where w r , w i , w j , and w k represent the real and imaginary parts of the initialized quaternion, respectively. θ is randomly generated over the interval π , π . Q i m g denotes the normalized unit quaternion, generated according to a uniform distribution in the interval 0 , 1 . φ is randomly generated based on the value of quaternion and the chosen initialization principle.
Finally, we use the AdaGrad algorithm to optimize the objective function. Algorithm 1 describes the learning process of the TKGR model.
Algorithm 1 Learning process of the TKGR model
Require: 
Temporal knowledge graph entity set E . Relationship set R . Timestamp set T . Training set G t r a i n = h , r , t , τ . Dimension of quaternion vector n. Learning rate α . Batch size b. Regular term coefficient λ 1 and λ 2 . Number of negative samples γ . Number of model iterations M.
Ensure: 
Vector representation of entities, relationships, and timestamps
1:
 Initialize model parameters according to Equation (21)
2:
 for iteration = 1 to N do
3:
       E u n i f o r m ( E ) f o r e a c h e E
4:
       S b a t c h S a m p l e G t r a i n , b
5:
      for each h , r , t , τ S b a t c h  do
6:
             S h , r , t , τ S a m p l e S h , r , t , τ
7:
      end for
8:
      Determine the numerical values of the scoring function for both positive and negative samples using Equation (16)
9:
      Determine the numerical value of the loss function based on Equation (20)
10:
    Update model parameters
11:
end for

5. Experiments

The main purpose of this section is to verify the superiority of the model proposed in this paper. Firstly, we list the state-of-the-art algorithms and experimental setups, and then we conduct experimental comparisons from different perspectives. The following are the specific experimental sessions.

5.1. Datasets

We select the three most commonly used temporal knowledge graph datasets ICEWS14, ICEWS05-15, and GDELT which are standard datasets used to evaluate temporal knowledge graph completion models, and Table 1 lists the detailed statistical information of these three datasets.
ICEWS14: This dataset consists of four tuples taken from social news related to political events. ICEWS14 is a subset of ICEWS that focuses on events from the year 2014. It has 7128 entities and 230 relationships and spans 365 time steps.
ICEWS05-15: ICEWS05-15 is a subset of the ICEWS dataset containing events that occurred between 2005 and 2015. The dataset contains 10,488 entities and 251 relationships and spans 4017 time steps.
GDELT: This dataset is a collection of human social relationships. We isolate a subset from source [27] that represents events that occurred between 2015 and 2016. This subset contains 500 entities and 20 relationships and spans 366 time steps.

5.2. Evaluation Metrics

We use the same evaluation measures for the dynamic knowledge graph completion task as for the static knowledge graph completion task. Firstly, for each quaternion in the test set, two types of candidate quaternions are created by replacing either the head or tail entity. Any potential quaternion found in G must be removed. The exact formula is given below.
h c a n d i d a t e = h , r , t , τ h ε , h , r , t , τ G
h c a n d i d a t e = h , r , t , τ t ε , h , r , t , τ G
It is then necessary to calculate the ratings of the test quaternion and all candidate quaternions and rank the ratings in a descending order to obtain the ranking of the test quaternion in each of the two candidate sets, which is denoted by f h and f t , respectively. Based on this ranking, we select MRR and Hit@k (k = 1, 3, 10) as the model evaluation metrics, respectively, where MRR is the inverse of the average ranking and Hit@k is the percentage of the ranking in the top k. The formula for MRR is shown below.
M R R = 1 2 · G t e s t h , r , t , τ G t e s t 1 f h + 1 f t
where G t e s t is the size of the test set. If the MRR value is larger, it means that the performance of the model is better. The formula for Hit@k is shown below.
H i t @ k = 1 2 · G t e s t h , r , t , τ G t e s t I f h k + I f t k
where I · denotes the indicator function, e.g., if f h k , then I ( f h k ) = 1 , otherwise I ( f h k ) = 0 . In the experiments, the Hit@k results are multiplied by 100.

5.3. Experimental Setup

We use the PyTorch framework to train our model, taking advantage of the powerful GeForce RTX 2080 GPU for improved performance. For coefficients λ 1 and λ 2 of the parameter regularization term and the temporal smoothing constraint term, we assign the same values to both coefficients as they have the same number of paradigms. We then select the most appropriate values from the range { 0.1 , 0.01 , 0.001 } .
The embedding dimension is 500 and the learning rate is 0.1. Both ICEWS datasets have a negative-to-positive sample ratio of 500, whereas the GDELT dataset has a ratio of 5. The batch size is set to 512. Different hyperparameters are used for each dataset to optimize the training process, taking into account their different sizes. For example, GDELT is much larger than the other two datasets, resulting in reduced hyperparameters. The model is iteratively trained 5000 times for the ICEWS14 and ICEWS05-15 datasets and 1000 times for the GDELT dataset. The training technique uses the AdaGrad optimization algorithm within the Small Batch Random Gradient Descent methodology.

5.4. Baselines

We compare different knowledge graph embedding techniques, including TransE [8], DistMult [28], SimplE [29], ConT [20], TTransE [30], HyTE [21], TA-DisMult [22], DE-SimplE [23], RoAN [31], SubEE [24], T-GAE [32], GLANet [33], BoxTE [25], DualMatch [34], DKGE [24], and TLmod [24]. These methods use different mechanisms to handle entity relationships, temporal information, global and local structure, and reasoning processes, with the aim of improving the expressiveness and inference accuracy of knowledge graphs.

5.5. Link Prediction

Table 2 and Table 3 show the results of the TKGR and baseline models in predicting temporal connections for three datasets, respectively. The experimental results show that TKGR outperforms the mainstream baseline model on most metrics, highlighting the effectiveness of TKGR. Quaternion rotation procedures based on Hamiltonian products allow for more extensive and complex interactions between things, time, and connections. TKGR shows superior performance to the TeRo model on the ICEWS05-15 dataset, particularly in terms of MRR and Hit@10. It achieves a significant gain of 2.55% in MRR and 1.38% in Hit@10. The ICEWS14 dataset has a larger number of entities, relationships, timestamps, and training samples. TKGR has the ability to represent complicated connection categories, such as symmetric/anti-symmetric and inverse relationships, making it very suitable for complex datasets.
Although the performance of the TKGR on the GDELT dataset is not particularly remarkable when compared to other models considered to be state of the art, it is still worthy of praise. A slight improvement can be seen in all measures when comparing the BoxTE, T-GAE, and RoAN models. On the other hand, the level of performance improvement is not particularly remarkable. The number of elements and links included in the GDELT dataset is extremely limited. On the other hand, both the training and the test sets can be considered quite large. All the models receive relatively low test scores as a result of this increased difficulty in the task they have to perform.
Furthermore, traditional representation learning strategies, such as TransE and DistMult models, are typically used to analyze static knowledge graphs. As a consequence, their ability to predict temporal relations is often insufficient. Both approaches ignore temporal information, which makes it difficult for them to accurately capture the temporal dynamics of their respective knowledge networks. In conclusion, the results of the experiments show that TKGR is not only appropriate, but also absolutely necessary. This is due to its ability to effectively capture the dynamic evolutionary properties of things and to effectively exploit temporal information.

5.6. Impact of Regularization

The final objective function is modified by TKGR to incorporate parameter regularization and temporal smoothing requirements. These modifications are derived from the results of previous experiments. In order to demonstrate the impact of these two regularization parameters on the overall performance of the model, we perform an experimental validation using the ICEWS14 dataset. This can be achieved by analyzing the fluctuations in the experimental results on the test set and examining them when the objective function does not include these two regularisation factors. At the same time, the other parameters are kept at their initial levels.
The results of the two comparative experiments are shown in Table 4. It is clear from the table that the regularization term has a more significant impact on the results. For example, the MRR and Hit@1 metrics improve the performance of the model by 1% and 1.8%, respectively, compared to the performance of the model before the imposition of the time smoothing constraints and parameter regularization. Therefore, these two regularisation terms are more beneficial to the model.

5.7. Evolution of Relations

According to the results of the current research, it is clear that different temporal knowledge graph completion models use temporal information in different ways. For example, the TA-TransE model incorporates both relational and temporal data in order to acquire a relational representation that incorporates temporal information. The ability to capture temporal representations of things and interpersonal relationships is one of the capabilities of the HyTE model. In this research, TKGR is only used to represent the progression of entities, and the use of static representations is retained when it comes to relationships.
If we focus only on the temporal evolution of relationships, the performance of the variant model is negatively affected across the board. On the other hand, if we consider the simultaneous evolution of entities and relations, the performance of the variant model is comparable to that of the TKGR modelling approach. The following conclusion can be drawn from the analysis of the data obtained from the experiment. It is possible that this is the result of a mismatch between the number of relations in a dataset and the number of entities in their dataset.
As a result, the evolution of entities over time provides a more accurate measure of the efficient use of temporal information. It also appears that entities tend to change their nature over time, whereas partnerships tend to be more stable in nature. This is something that can be understood through direct experience in actual life circumstances. In partnerships, it is possible for a person’s state to change at different times before and after the partnership. Due to the nature of the relationship, which tends to make the opposite true, this is the current state of affairs. One of TKGR’s main objectives is to ensure that the units continue to grow. This is performed in order to maintain the simplicity of the model and the geometric significance of the changes that take place within the relationships (Table 5).

5.8. Parameter Adjustment

This section is dedicated to the study of regularization coefficients λ 1 and λ 2 . We determine and select the optimal settings. We start by running the algorithm repeatedly for a total of one thousand iterations. We then analyze the results of Hit@10 on the validation set to determine the parameters.
Figure 2 visually demonstrates the effect of adjusting the value of the regularization factor on the performance of the model using the ICEWS14 dataset. The results indicate that the model achieves optimal performance when the value of λ is set to λ 1 and λ 2 , both equal to 0.01. In the trials described above, both λ 1 and λ 2 are assigned a value of 0.01.
The summary of findings highlights:
Model Performance Superiority: Our TKGR model, utilizing quaternion rotations, consistently outperforms state-of-the-art methods across all benchmark datasets (ICEWS14, ICEWS05-15, and GDELT). This underscores its efficacy in capturing the temporal evolution of knowledge graphs, as demonstrated by improved metrics such as Hit@10 and Mean Reciprocal Rank (MRR).
Temporal Dependency Handling: The model adeptly handles complex temporal dependencies, as evidenced by its enhanced predictive accuracy for time-varying entity relationships. For instance, in the case of South Korean presidential succession, our model accurately captures the temporal progression of leadership changes, illustrating how the inclusion of temporal information can significantly enhance the understanding and forecasting of such events in knowledge graphs.
Parameter Sensitivity Analysis: We demonstrate the sensitivity of model performance to the regularization coefficient λ , identifying optimal values ( λ = 0.01) that balance model complexity and generalization. These findings ensure the model’s robustness across different dataset characteristics, validating the effectiveness of our chosen regularization strategy.
Methodological Innovation: Our work introduces a groundbreaking application of quaternion rotations to temporal knowledge graph representation. This innovation not only improves the learning process’s expressiveness and efficiency compared to complex number-based approaches, but also offers a fresh perspective on temporal knowledge graph modeling that addresses the limitations of prior works. This approach effectively captures the inherently dynamic nature of real-world knowledge, as exemplified in our experimental results.

6. Conclusions

This paper presents a revolutionary strategy for depicting knowledge graphs with temporal attributes using quaternion rotations. The proposed TKGR model effectively captures the evolution of entities and their interdependencies in complex number spaces, as demonstrated by its superior performance on benchmark datasets. The utilization of quaternion rotations enables a more expressive and efficient learning process compared to traditional complex number-based approaches, particularly in representing temporal transitions in knowledge graphs.
While our work represents a significant advancement in temporal knowledge graph representation, we acknowledge several limitations that warrant consideration and future exploration:
Scalability: Although the TKGR model demonstrates promising results on benchmark datasets, its scalability to extremely large knowledge graphs remains to be investigated. Future research could explore parallelization strategies or more computationally efficient quaternion operations to accommodate massive, real-world knowledge graphs with extensive temporal information.
Temporal Granularity: Our current approach handles temporal transitions at a relatively coarse level. Investigating methods to handle finer-grained temporal resolutions, such as sub-daily or event-specific timestamps, could further enhance the model’s ability to capture intricate temporal patterns and dynamics.
Dynamic Integration of New Data: Real-world knowledge graphs continuously evolve over time, necessitating models that can seamlessly integrate new temporal information. Future work could explore online learning mechanisms or incremental update strategies for the TKGR model to adapt to temporal changes in near-real time.
Interpretability: While the quaternion-based representation offers a novel perspective on temporal knowledge graph modeling, enhancing the interpretability of the learned quaternion representations and their relationship to temporal phenomena would deepen our understanding of the model’s decision-making process and foster trust in its predictions.
Cross-domain Transferability: The effectiveness of the TKGR model across diverse domains and types of knowledge graphs should be assessed. Future studies could examine the model’s performance on knowledge graphs from different industries, such as healthcare, finance, or social sciences, to assess its generalizability and potential domain-specific adaptations.
In conclusion, this study introduces a novel and effective technique for representing temporal knowledge graphs using quaternion rotations. Despite its promising results, we recognize several limitations that present opportunities for future research. Addressing these issues through continued innovation and refinement will contribute to the development of increasingly powerful and versatile models for temporal knowledge graph representation, ultimately enhancing their utility in a wide range of applications.

Author Contributions

Conceptualization, S.L. and Q.L.; methodology, S.L.; software, Q.L.; validation, Q.L.; formal analysis, S.L.; writing—original draft preparation, S.L.; writing—review and editing, Q.L. and S.L. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Data Availability Statement

The data presented in this study are available on request from the corresponding author.

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Zeng, X.; Tu, X.; Liu, Y.; Fu, X.; Su, Y. Toward better drug discovery with knowledge graph. Curr. Opin. Struct. Biol. 2022, 72, 114–126. [Google Scholar] [CrossRef] [PubMed]
  2. Wang, J.; Wang, B.; Gao, J.; Li, X.; Hu, Y.; Yin, B. TDN: Triplet Distributor Network for Knowledge Graph Completion. IEEE Trans. Knowl. Data Eng. 2023, 35, 13002–13014. [Google Scholar] [CrossRef]
  3. Huang, C.; Zhong, Y. A Network Representation Learning Method Fusing Multi-dimensional Classification Information of Nodes. IAENG Int. J. Comput. Sci. 2023, 50, 94–105. [Google Scholar]
  4. Peng, C.; Xia, F.; Naseriparsa, M.; Osborne, F. Knowledge graphs: Opportunities and challenges. Artif. Intell. Rev. 2023, 56, 13071–13102. [Google Scholar] [CrossRef] [PubMed]
  5. Zhou, B.; Shen, X.; Lu, Y.; Li, X.; Hua, B.; Liu, T.; Bao, J. Semantic-aware event link reasoning over industrial knowledge graph embedding time series data. Int. J. Prod. Res. 2023, 61, 4117–4134. [Google Scholar] [CrossRef]
  6. Guo, Y.; Wang, L.; Zhang, Z.; Cao, J.; Xia, X.; Liu, Y. Integrated modeling for retired mechanical product genes in remanufacturing: A knowledge graph-based approach. Adv. Eng. Inform. 2024, 59, 102254. [Google Scholar] [CrossRef]
  7. Cao, B.; Zhao, J.; Gu, Y.; Ling, Y.; Ma, X. Applying graph-based differential grouping for multiobjective large-scale optimization. Swarm Evol. Comput. 2020, 53, 100626. [Google Scholar] [CrossRef]
  8. Bordes, A.; Usunier, N.; Garcia-Durán, A.; Weston, J.; Yakhnenko, O. Translating embeddings for modeling multi-relational data. In Proceedings of the 26th International Conference on Neural Information Processing Systems, Lake Tahoe, NV, USA, 3–6 December 2012; Volume 2, pp. 2787–2795. [Google Scholar]
  9. Wang, Z.; Zhang, J.; Feng, J.; Chen, Z. Knowledge graph embedding by translating on hyperplanes. In Proceedings of the AAAI Conference on Artificial Intelligence, Quebec City, QC, Canada, 27–31 July 2014; Volume 28. [Google Scholar]
  10. Wang, X.; Lyu, S.; Wang, X.; Wu, X.; Chen, H. Temporal knowledge graph embedding via sparse transfer matrix. Inf. Sci. 2023, 623, 56–69. [Google Scholar] [CrossRef]
  11. Li, M.M.; Huang, K.; Zitnik, M. Graph representation learning in biomedicine and healthcare. Nat. Biomed. Eng. 2022, 6, 1353–1369. [Google Scholar] [CrossRef] [PubMed]
  12. Bai, L.; Chai, D.; Zhu, L. RLAT: Multi-hop temporal knowledge graph reasoning based on Reinforcement Learning and Attention Mechanism. Knowl. Based Syst. 2023, 269, 110514. [Google Scholar] [CrossRef]
  13. Nickel, M.; Rosasco, L.; Poggio, T. Holographic embeddings of knowledge graphs. In Proceedings of the AAAI Conference on Artificial Intelligence, Phoenix, AZ, USA, 12–17 February 2016; Volume 30. [Google Scholar]
  14. Trouillon, T.; Welbl, J.; Riedel, S.; Gaussier, É.; Bouchard, G. Complex embeddings for simple link prediction. In Proceedings of the International Conference on Machine Learning, New York, NY, USA, 20–22 June 2016; pp. 2071–2080. [Google Scholar]
  15. Baghershahi, P.; Hosseini, R.; Moradi, H. Self-attention presents low-dimensional knowledge graph embeddings for link prediction. Knowl.-Based Syst. 2023, 260, 110124. [Google Scholar] [CrossRef]
  16. Dettmers, T.; Minervini, P.; Stenetorp, P.; Riedel, S. Convolutional 2d knowledge graph embeddings. In Proceedings of the AAAI Conference on Artificial Intelligence, New Orleans, LO, USA, 2–7 February 2018; Volume 32. [Google Scholar]
  17. Li, Z.; Zhao, Y.; Zhang, Y.; Zhang, Z. Multi-relational graph attention networks for knowledge graph completion. Knowl.-Based Syst. 2022, 251, 109262. [Google Scholar] [CrossRef]
  18. Perozzi, B.; Al-Rfou, R.; Skiena, S. Deepwalk: Online learning of social representations. In Proceedings of the 20th ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, New York, NY, USA, 24–27 August 2014; pp. 701–710. [Google Scholar]
  19. Schlichtkrull, M.; Kipf, T.N.; Bloem, P.; Van Den Berg, R.; Titov, I.; Welling, M. Modeling relational data with graph convolutional networks. In Proceedings of the The Semantic Web: 15th International Conference, ESWC 2018, Heraklion, Greece, 3–7 June 2018; Springer: Berlin/Heidelberg, Germany, 2018; pp. 593–607. [Google Scholar]
  20. Ma, Y.; Tresp, V.; Daxberger, E.A. Embedding models for episodic knowledge graphs. J. Web Semant. 2019, 59, 100490. [Google Scholar] [CrossRef]
  21. Dasgupta, S.S.; Ray, S.N.; Talukdar, P. Hyte: Hyperplane-based temporally aware knowledge graph embedding. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, Brussels, Belgium, 31 October–4 November 2018; pp. 2001–2011. [Google Scholar]
  22. Garcia-Duran, A.; Dumančić, S.; Niepert, M. Learning Sequence Encoders for Temporal Knowledge Graph Completion. In Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing, Brussels, Belgium, 31 October–4 November 2018; pp. 4816–4821. [Google Scholar]
  23. Goel, R.; Kazemi, S.M.; Brubaker, M.; Poupart, P. Diachronic embedding for temporal knowledge graph completion. In Proceedings of the AAAI Conference on Artificial Intelligence, New York, NY, USA, 7–12 February 2020; Volume 34, pp. 3988–3995. [Google Scholar]
  24. Wan, G.; Zhou, Z.; Zheng, Z.; Du, B. Sub-Entity Embedding for inductive spatio-temporal knowledge graph completion. Future Gener. Comput. Syst. 2023, 148, 240–249. [Google Scholar] [CrossRef]
  25. Messner, J.; Abboud, R.; Ceylan, I.I. Temporal knowledge graph completion using box embeddings. In Proceedings of the AAAI Conference on Artificial Intelligence, Online, 22 February–1 March 2022; Volume 36, pp. 7779–7787. [Google Scholar]
  26. Xu, Y.; Sun, S.; Zhang, H.; Yi, C.; Miao, Y.; Yang, D.; Meng, X.; Hu, Y.; Wang, K.; Min, H.; et al. Time-aware graph embedding: A temporal smoothness and task-oriented approach. ACM Trans. Knowl. Discov. Data TKDD 2021, 16, 1–23. [Google Scholar] [CrossRef]
  27. Cho, K.; van Merrienboer, B.; Gulcehre, C.; Bahdanau, D.; Bougares, F.; Schwenk, H.; Bengio, Y. Learning Phrase Representations using RNN Encoder–Decoder for Statistical Machine Translation. In Proceedings of the 2014 Conference on Empirical Methods in Natural Language Processing (EMNLP), Doha, Qatar, 25–29 October 2014; Association for Computational Linguistics: Pittsburgh, PA, USA, 2014; p. 1724. [Google Scholar]
  28. Yang, B.; Yih, W.T.; He, X.; Gao, J.; Deng, L. Embedding entities and relations for learning and inference in knowledge bases. arXiv 2014, arXiv:1412.6575. [Google Scholar]
  29. Kazemi, S.M.; Poole, D. SimplE embedding for link prediction in knowledge graphs. In Proceedings of the 32nd International Conference on Neural Information Processing Systems, Montreal, QC, Canada, 2–8 December 2018; pp. 4289–4300. [Google Scholar]
  30. Jiang, T.; Liu, T.; Ge, T.; Sha, L.; Chang, B.; Li, S.; Sui, Z. Towards time-aware knowledge graph completion. In Proceedings of the COLING 2016, the 26th International Conference on Computational Linguistics, Osaka, Japan, 11–16 December 2016; Technical Papers. pp. 1715–1724. [Google Scholar]
  31. Bai, L.; Ma, X.; Meng, X.; Ren, X.; Ke, Y. RoAN: A relation-oriented attention network for temporal knowledge graph completion. Eng. Appl. Artif. Intell. 2023, 123, 106308. [Google Scholar] [CrossRef]
  32. Hou, X.; Ma, R.; Yan, L.; Ma, Z. T-GAE: A Timespan-aware Graph Attention-based Embedding Model for Temporal Knowledge Graph Completion. Inf. Sci. 2023, 642, 119225. [Google Scholar] [CrossRef]
  33. Wang, J.; Lin, X.; Huang, H.; Ke, X.; Wu, R.; You, C.; Guo, K. GLANet: Temporal knowledge graph completion based on global and local information-aware network. Appl. Intell. 2023, 53, 19285–19301. [Google Scholar] [CrossRef]
  34. Liu, X.; Wu, J.; Li, T.; Chen, L.; Gao, Y. Unsupervised Entity Alignment for Temporal Knowledge Graphs. In Proceedings of the ACM Web Conference 2023, Austin, TX, USA, 30 April–4 May 2023; pp. 2528–2538. [Google Scholar]
Figure 1. Schematic diagram of quaternion rotation.
Figure 1. Schematic diagram of quaternion rotation.
Mathematics 12 01324 g001
Figure 2. The influence of regularization coefficient on the TKGR model.
Figure 2. The influence of regularization coefficient on the TKGR model.
Mathematics 12 01324 g002
Table 1. Details of the datasets.
Table 1. Details of the datasets.
DatasetsEntitiesRelationsTime StepsTrainingValidationTest
ICEWS14712823036572,82689418963
ICEWS05-1510,4882514017386,96246,27546,092
GDELT500203662,735,685341,961341,961
Table 2. Link prediction results on datasets ICEWS14 and ICEWS05-15.
Table 2. Link prediction results on datasets ICEWS14 and ICEWS05-15.
ModelICEWS14ICEWS05-15
MRRHit@1Hit@3Hit@10MRRHit@1Hit@3Hit@10
TransE0.289.4-63.70.2949.0-66.3
DistMult0.43932.3-67.20.45633.7-69.1
SimplE0.45834.151.668.70.47835.953.970.8
ConT0.18511.720.531.50.16310.518.927.2
TTransE0.2557.4-60.10.2718.4-61.6
HyTE0.29710.841.665.50.31611.644.568.1
TA-DistMult0.47736.3-68.60.47434.6-72.8
DE-SimplE0.52641.859.272.50.51339.257.874.8
RoAN0.56045.363.174.20.58747.166.979.7
SubEE0.51943.562.472.10.57246.365.478.1
GLANet0.50944.663.173.50.56446.765.378.7
T-GAE0.55444.862.173.80.55247.565.177.2
DKGE0.54945.262.973.90.59147.365.879.2
BoxTE0.54945.262.974.10.59447.966.378.2
TKGR0.56845.963.674.80.60248.367.980.8
Table 3. Link prediction results on dataset GDELT.
Table 3. Link prediction results on dataset GDELT.
ModelMRRHit@1Hit@3Hit@10
TransE0.12312.715.131.2
DistMult0.20613.721.234.7
SimplE0.21612.322.235.9
ConT0.14311.815.727.1
TTransE0.10712.616.330.8
HyTE0.11213.116.433.6
TA-DistMult0.21512.321.135.5
DE-SimplE0.22614.124.837.3
RoAN0.23213.923.738.4
SubEE0.22412.422.638.8
GLANet0.23513.623.938.4
T-GAE0.21712.422.637.7
DKGE0.22513.122.938.1
BoxTE0.22913.723.538.5
TKGR0.25715.225.139.5
Table 4. Effect of regularization terms on dataset ICEWS14.
Table 4. Effect of regularization terms on dataset ICEWS14.
Loss FunctionMRRHit@1Hit@3Hit@10
L θ + λ 1 L r θ + λ 2 L s θ 0.56845.963.674.8
L θ 0.56345.163.274.4
Table 5. Experimental results for different variant models on dataset ICEWS14.
Table 5. Experimental results for different variant models on dataset ICEWS14.
VariationsMRRHit@1Hit@3Hit@10
q h , τ q r · q t , τ 0.56845.963.674.8
q h q r , τ · q t 0.56345.163.274.4
q h , τ q r , τ · q t , τ 0.56345.163.274.4
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Li, S.; Li, Q. Revolutionary Strategy for Depicting Knowledge Graphs with Temporal Attributes. Mathematics 2024, 12, 1324. https://0-doi-org.brum.beds.ac.uk/10.3390/math12091324

AMA Style

Li S, Li Q. Revolutionary Strategy for Depicting Knowledge Graphs with Temporal Attributes. Mathematics. 2024; 12(9):1324. https://0-doi-org.brum.beds.ac.uk/10.3390/math12091324

Chicago/Turabian Style

Li, Sihan, and Qi Li. 2024. "Revolutionary Strategy for Depicting Knowledge Graphs with Temporal Attributes" Mathematics 12, no. 9: 1324. https://0-doi-org.brum.beds.ac.uk/10.3390/math12091324

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop