Stream-oriented temporal knowledge graph embedding and prediction method
By constructing update and read models, the problem of new entity embedding and rapid response in streaming scenarios of time-series knowledge graphs is solved, realizing flexible updates and real-time embedding representation of new entities, and improving the real-time performance and accuracy of e-commerce recommendation systems.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SICHUAN ARTIFICIAL INTELLIGENCE RESEARCH INSTITUTE (YIBIN)
- Filing Date
- 2022-05-16
- Publication Date
- 2026-04-21
AI Technical Summary
Existing time-series knowledge graphs struggle to handle the embedding representation of new entities, frequent knowledge updates, and rapid response requirements in streaming scenarios, and they cannot obtain entity embedding representations with timestamps.
Collect interactive knowledge in streaming scenarios, construct and update the embedded representations of entities that directly affect the update model and propagate the data, and read the embedded representations at the query time by reading the model, and use the scoring function to predict future knowledge.
It enables flexible embedding and updating of new entities, rapid response to query requirements, and accurate prediction of entity semantic evolution trajectory, thereby improving the real-time performance and accuracy of e-commerce recommendation systems.
Smart Images

Figure CN114896416B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of knowledge graph technology, specifically to a method for embedding and predicting time-series knowledge graphs for streaming scenarios. Background Technology
[0002] Temporal knowledge graphs, as a dynamic knowledge base system, have attracted much attention in recent years due to their significant application value and promising prospects in many fields, such as e-commerce recommendation. However, due to their implicit symbolic properties and non-Euclidean structure, existing temporal knowledge graphs are difficult for computers to directly utilize, thus severely limiting the ability of e-commerce recommendation systems to leverage and mine temporal knowledge about users. Inspired by static knowledge graph embedding methods, some researchers have attempted to use temporal knowledge graph embedding methods to simplify the use of temporal user knowledge, which has become an important research topic in this field in recent years.
[0003] While existing works can represent temporal knowledge graphs as low-dimensional vectors, they all assume that no new knowledge is added to the temporal knowledge graph. Real-world knowledge is constantly being updated, especially in e-commerce recommendation systems, where users continuously click, purchase, or comment on products and interact with other users, resulting in new interactive knowledge being continuously added to the temporal knowledge graph. This scenario is called a streaming scenario. Existing works face three main challenges when applied to streaming scenarios:
[0004] (1) New entities (products or users) will be continuously accumulated in the temporal knowledge graph as the interaction knowledge is updated. However, since existing work directly learns the fixed embedding representation of each entity, they cannot generate embedding representations for newly emerging entities.
[0005] (2) In the real world, users’ clicks, purchases or comments on products, as well as interactions between users, happen all the time. This leads to very frequent knowledge updates. Existing work needs to regenerate the embedded representation of the current moment from scratch at every moment, which makes it difficult to apply to e-commerce recommendation systems that require fast response.
[0006] (3) Existing work can only obtain embedded representations of entities (goods or users) with relevant knowledge timestamps. Summary of the Invention
[0007] To address the aforementioned shortcomings in existing technologies, this invention provides a method for embedding and predicting time-series knowledge graphs for streaming scenarios.
[0008] To achieve the above-mentioned objectives, the technical solution adopted by this invention is as follows:
[0009] On the one hand, a method for embedding and predicting time-series knowledge graphs for streaming scenarios includes the following steps:
[0010] S1. Collect interaction knowledge in the streaming scenario and preprocess it to obtain preprocessed interaction knowledge;
[0011] S2. Obtain the directly affected entities and propagated entities of the preprocessed interaction knowledge;
[0012] S3. Construct an update model and use the update model to update the embedding representations of the directly affected entities and the propagated entities, to obtain the updated directly affected entities and the propagated entities.
[0013] S4. Construct a reading model and read the updated embedded representations of directly affected entities and propagated entities at the query time based on the reading model;
[0014] S5. Calculate the confidence of each knowledge based on the embedding representation at the query time using the scoring function, and predict future knowledge based on the confidence of each knowledge.
[0015] Preferably, step S1 specifically includes:
[0016] Collect interactive knowledge in streaming scenarios, filter out interactive knowledge with new entities, construct a new memory space in the knowledge graph, and initialize the memory space using the original features of the new entity; the processed interactive knowledge and the remaining interactive knowledge after filtering are used together as preprocessed interactive knowledge.
[0017] Preferably, step S3 specifically includes:
[0018] A1. Calculate the direct impact characteristics that directly affect the entity. The formula is as follows:
[0019]
[0020] in, For t p At this moment, it directly affects entity e i The direct impact characteristics; g is the set of all knowledge in the time-series knowledge graph; (e i ,r m ,e j ,t p ) for all occurrences of t p The inclusion of time directly affects entity e i Interactive knowledge; Comp(.) is a combinatorial computation function; r m For each directly affecting the relationship between entities r m Embedded representation; To directly affect entity e j In tp The latest embedded representation before the current time;
[0021] A2. Calculate the propagation impact characteristics of entities, expressed by the following formula:
[0022]
[0023] in, For t p At any given moment, all entities that propagate and influence e k The set of paths ending in W; p The first learnable parameter matrix; [:] represents the connection operation; tanh(.) is the hyperbolic tangent function; To spread influence on entity e o In t p The latest embedding representation before the current time, r n For the relationships between entities affected by the propagation r n Embedded representation;
[0024] A3. Construct an embedding representation update function, and update the embedding representations of the directly affected entities and the propagated affected entities according to the embedding representation update function to obtain the updated directly affected entities and the propagated affected entities.
[0025] Preferably, the construction process of embedding the update expression in step A3 is represented as follows:
[0026] B1. Construct the erase quantity function, whose functional expression is as follows:
[0027]
[0028] Where z is the erasure vector; σ(.) is the sigmoid activation function; W z [:] represents the second learnable parameter matrix; [:] represents the join operation. It is entity e a The influence characteristics of entity e a It can characterize entities that directly affect or propagate their influence; b z The first parameter vector; For entity e a In t p The latest embedded representation before the current time;
[0029] B2. Construct the write function, whose function representation is as follows:
[0030]
[0031] Where c is the input vector; tanh(.) is the hyperbolic tangent function; W c b is the third learnable parameter matrix; cThe second parameter vector;
[0032] B3. Construct an embedding representation update function based on the erase and write variables, and update the embedding representations of directly affected entities and propagated entities according to the embedding representation update function to obtain the updated directly affected entities and propagated entities; the embedding representation update function is expressed as:
[0033]
[0034] in, For t p Entity e that is constantly updated a The embedded representation of , where ☉ represents the element-wise product operation.
[0035] Preferably, step S4 specifically includes:
[0036] A multi-head evolution model is constructed to simulate the updated semantic evolution trajectories of directly influencing entities and propagating entities. These semantic evolution trajectories are represented as follows:
[0037]
[0038] in, For entity e a In t q The semantic evolution trajectory at time step; K is the number of evolution heads; sin(.) is the sine function; It is entity e a In t q The timestamp of the most recent update before the current time; m k This is the evolutionary period vector; For entity e a In t p The latest embedded representation before the current time;
[0039] C2. Calculate the local state vector, which is expressed as follows:
[0040]
[0041] in, For entity e a In t q The local state vector at time t; tanh(.) is the hyperbolic tangent function; W g The fourth learnable parameter matrix; σ(.) is the sigmoid activation function; N(e q ,t q ) represents in t q Before the time and entity e a Entity e that has interacted c The set of components; μ is a hyperparameter; For entity ec In t p The latest embedded representation before the current time;
[0042] C3. Construct a reading model based on the local state vector and semantic evolution trajectory, and read the updated embedding representations of directly affected entities and propagated entities at the query time based on the reading model; their embedding representations at the query time are as follows:
[0043]
[0044] in, For entity e a In t q Embedded representation at a given moment.
[0045] The present invention has the following beneficial effects:
[0046] This invention collects and preprocesses interactive knowledge from streaming scenarios to obtain preprocessed interactive knowledge. Based on this preprocessed interactive knowledge, it identifies directly influencing entities and entities with propagating influence. An update model is constructed and used to update the embedding representations of these entities, resulting in updated directly influencing and propagating influence entities. A retrieval model is then constructed, and the updated embedding representations of these entities at the query time are retrieved. A scoring function is used to calculate the confidence level of each knowledge item based on its embedding representation at the query time, and future knowledge prediction is performed based on these confidence levels. This invention decouples entity embedding representations into external storage to preserve the historical semantics of entities. Any newly emerging entity can be flexibly initialized using its original features and updated by our update function as new knowledge arrives. The update model fully considers the direct and propagating influences of new knowledge and uses a gating mechanism to incrementally update entity embedding representations, enabling rapid generation of embedding representations to respond to query needs in real time. By constructing a retrieval model, the periodic semantic changes of the entity itself and the semantic changes of related entities are fully considered, thus accurately predicting the semantic evolution trajectory of the entity. Attached Figure Description
[0047] Figure 1 The flowchart illustrates the steps of a time-series knowledge graph embedding and prediction method for streaming scenarios provided by this invention. Detailed Implementation
[0048] The specific embodiments of the present invention are described below to enable those skilled in the art to understand the present invention. However, it should be understood that the present invention is not limited to the scope of the specific embodiments. For those skilled in the art, various changes are obvious as long as they are within the spirit and scope of the present invention as defined and determined by the appended claims. All inventions utilizing the concept of the present invention are protected.
[0049] like Figure 1 As shown, on the one hand, a temporal knowledge graph embedding method for streaming scenarios includes the following steps:
[0050] S1. Collect interaction knowledge in the streaming scenario and preprocess it to obtain preprocessed interaction knowledge;
[0051] Preferably, step S1 specifically includes:
[0052] Collect interactive knowledge in streaming scenarios, filter out interactive knowledge with new entities, construct a new memory space in the knowledge graph, and initialize the memory space using the original features of the new entity; the processed interactive knowledge and the remaining interactive knowledge after filtering are used together as preprocessed interactive knowledge.
[0053] In this embodiment of the invention, when a new interactive knowledge in the e-commerce field appears at any time, it is first identified whether it contains a new entity (a new product or a new user). If a new entity exists, a new memory space is allocated, and the memory space is initialized using the original characteristics of the entity (the text description of the product or the gender and age of the user, etc.), and then the process jumps to S2; if no new entity exists, the process jumps directly to S2.
[0054] S2. Obtain the directly affected entities and propagated entities of the preprocessed interaction knowledge;
[0055] In this embodiment of the invention, for the preprocessed interactive knowledge, we first identify entities that will directly affect it and entities that will propagate and affect it.
[0056] Among them, directly affecting entities: A new interaction knowledge represents the interaction behavior of two users or a user and a product at a certain moment. This interaction behavior will change the local graph structure of these two entities in the temporal knowledge graph. The local structure of an entity usually represents the semantics of the entity and the role it plays in the graph. Therefore, the new interaction knowledge will affect the semantics of the products or users it contains. This effect is called a direct effect, and the two entities contained in the new knowledge are called directly affecting entities.
[0057] Propagation-influence entities: Knowledge is not independent; new interactive knowledge and existing interactive knowledge may connect to the same entity (user or product), resulting in a graph-structured path between them. This path structure reflects higher-order correlations between new and old knowledge (e.g., someone who first buys a phone is likely to buy a phone case next), and can be used to model the potential impact of new knowledge on other entities. Therefore, we define entities contained in knowledge that share a common entity (common product or common user) with new knowledge over a past period as propagation-influence entities, and this potential impact propagated through paths as propagation impact.
[0058] S3. Construct an update model and use the update model to update the embedding representations of the directly affected entities and the propagated entities, to obtain the updated directly affected entities and the propagated entities.
[0059] Preferably, step S3 specifically includes:
[0060] A1. Calculate the direct impact characteristics that directly affect the entity. The formula is as follows:
[0061]
[0062] in, For t p At this moment, it directly affects entity e i The direct impact characteristics; g is the set of all knowledge in the time-series knowledge graph; (e i ,r m ,e j ,t p ) for all occurrences of t p The inclusion of time directly affects entity e i Interactive knowledge; Comp(.) is a combinatorial computation function; r m For each directly affecting the relationship between entities r m Embedded representation; To directly affect entity e j In t p The latest embedded representation before the current time;
[0063] In this embodiment of the invention, Comp(.) is a combination calculation function, which can be addition or multiplication, etc.
[0064] In this embodiment of the invention, for entities that directly affect the knowledge, a message passing mechanism can be used to pass information between the two entities contained in the new knowledge in order to calculate the corresponding direct impact features.
[0065] It's important to note that traditional messaging mechanisms only transmit entity information. However, in temporal knowledge graphs, relationships determine the type of interaction between two entities (e.g., adding a product versus clicking on a product has different implications for whether a user will purchase it). Relationships possess rich semantic information and should be considered in the messaging process. Furthermore, a product may be clicked by multiple users simultaneously, thus being directly influenced by multiple new pieces of knowledge.
[0066] A2. Calculate the propagation impact characteristics of entities, expressed by the following formula:
[0067]
[0068] in, For t p At any given moment, all entities that propagate and influence e k The set of paths ending in W; p The first learnable parameter matrix; [:] represents the connection operation; tanh(.) is the hyperbolic tangent function; To spread influence on entity e o In t p The latest embedding representation before the current time, r n For the relationships between entities affected by the propagation r n Embedded representation;
[0069] In this embodiment of the invention, for entities affected by propagation, a path composed of old and new knowledge is used as the channel for message propagation. This path expresses an indirect relationship between a user and a non-interacting product. The information contained in the path is used as the propagation impact feature of the entity at the end of the path, thereby helping the model to consider the user's potential demand for the product.
[0070] A3. Construct an embedding representation update function, and update the embedding representations of the directly affected entities and the propagated affected entities according to the embedding representation update function to obtain the updated directly affected entities and the propagated affected entities.
[0071] In this embodiment of the invention, after obtaining two impact features, the embedded representation of the affected entity can be updated based on these impact features. The update of the embedded representation can be divided into two parts: historical information erasure and new information writing. Historical information erasure and new information writing determine which of the user's historical purchase behaviors can be forgotten and which new interaction information is important and needs to be retained.
[0072] Preferably, the construction process of embedding the update expression in step A3 is represented as follows:
[0073] B1. Construct the erase quantity function, whose functional expression is as follows:
[0074]
[0075] Where z is the erasure vector; σ(.) is the sigmoid activation function; W z [:] represents the second learnable parameter matrix; [:] represents the join operation. It is entity e a The influence characteristics of entity e a It can characterize entities that directly affect or propagate their influence; b z The first parameter vector; For entity e a In t p The latest embedded representation before the current time;
[0076] In this embodiment of the invention, when the entity is only directly affected, When the entity is only affected by propagation
[0077] B2. Construct the write function, whose function representation is as follows:
[0078]
[0079] Where c is the input vector; tanh(.) is the hyperbolic tangent function; W c b is the third learnable parameter matrix; c The second parameter vector;
[0080] In this embodiment of the invention, in order to adaptively select which new interactive information needs to be written, a write quantity function is constructed to use a write vector to control the amount of new information to be written.
[0081] B3. Construct an embedding representation update function based on the erase and write variables, and update the embedding representations of directly affected entities and propagated entities according to the embedding representation update function to obtain the updated directly affected entities and propagated entities; the embedding representation update function is expressed as:
[0082]
[0083] in, For t p Entity e that is constantly updated a The embedded representation of , where ☉ represents the element-wise product operation.
[0084] S4. Construct a reading model and read the updated embedded representations of directly affected entities and propagated entities at the query time based on the reading model;
[0085] Preferably, step S4 specifically includes:
[0086] C1. Construct a multi-head evolution model to simulate the updated semantic evolution trajectories of directly influencing entities and propagating entities. These semantic evolution trajectories are represented as follows:
[0087]
[0088] in, For entity e a In t q The semantic evolution trajectory at time step; K is the number of evolution heads; sin(.) is the sine function; It is entity e a In t q The timestamp of the most recent update before the current time; m k This is the evolutionary period vector; For entity e a In t p The latest embedded representation before the current time;
[0089] In this embodiment of the invention, in order to model the semantic evolution trajectory of entities, it is necessary to first consider the periodic evolution patterns of users and goods. Specifically, goods have seasonal periodicity, such as summer clothes being less likely to be purchased in winter; while users have periodic characteristics of personal interests, such as purchasing jerseys during the World Cup.
[0090] C2. Calculate the local state vector, which is expressed as follows:
[0091]
[0092] in, For entity e a In t q The local state vector at time t; tanh(.) is the hyperbolic tangent function; W g The fourth learnable parameter matrix; σ(.) is the sigmoid activation function; N(e a ,t q ) represents in t q Before the time and entity e a Entity e that has interacted c The set of components; μ is a hyperparameter; For entity e c In t p The latest embedded representation before the current time;
[0093] In this embodiment of the invention, local state vectors are used to describe the semantic changes of related entities of an entity (product or user) over a period of time (e.g., a football enthusiast will buy more football-related products, and when the semantics of these products change due to knowledge updates, the semantics of the user should adapt to this change so that the system can continue to recommend football-related products to the user).
[0094] C3. Construct a reading model based on the local state vector and semantic evolution trajectory, and read the updated embedding representations of directly affected entities and propagated entities at the query time based on the reading model; their embedding representations at the query time are as follows:
[0095]
[0096] in, For entity e a In t q Embedded representation at a given moment.
[0097] In this embodiment of the invention, the above calculation is smooth because when the time span approaches 0, the read embedding representation will approach the most recently updated embedding representation in external storage; finally, the embedding representation can be used in existing static knowledge graph prediction methods to predict future facts in time-series knowledge graphs.
[0098] S5. Calculate the confidence of each knowledge based on the embedding representation at the query time using the scoring function, and predict future knowledge based on the confidence of each knowledge.
[0099] In this embodiment of the invention, for any head entity query (?,r,o,t) or tail entity query (s,r,?,t) of future knowledge, the entities at the missing positions are first replaced one by one with all entities in the entity set, thus obtaining a set of candidate knowledge. For each candidate knowledge, taking (e,r,o,t) as an example, its confidence level f(e,r,o,t) is calculated based on the obtained embedding representation combined with the scoring function in any static prediction method. Here, the inner product scoring function can be used as an example. The confidence level calculation formula of the knowledge is expressed as:
[0100]
[0101] The confidence levels of all candidate knowledge are then ranked from highest to lowest, and the candidate knowledge with the highest confidence level is selected as the predicted future knowledge.
[0102] In this embodiment of the invention, experiments were conducted to compare it with various embedding algorithms in the prior art, including the temporal embedding-based method DE-SimplE, “Rishab Goel, Seyed Mehran Kazemi, Marcus Brubaker, and Pascal Poupart. Diachronic embedding for temporal knowledge graph completion. In AAAI, 2020.”; the matrix factorization-based method TNTComplEX, “Timothee Lacroix, Guillaume Obozin-′ski, and Nicolas Usunier. Tensor decompositions for temporal knowledge base completion. In ICLR, 2020.”; the neural network-based method RE-NET, “WoojeongJin, Meng Qu, XisenJin, and Xiang Ren. Recurrent event network: Autoregressive structure inference over temporal knowledge graphs. In EMNLP, 2020.”; and the attention-based method x-ERTE, “Zhen Han, Peng Chen, Yunpu Ma, and Volker Tresp. Explainable subgraph reasoning for forecasting on temporal…”. Knowledge graphs. In ICLR, 2021. The results are shown in Table 1. It can be seen that the method outperforms existing methods on the future knowledge prediction task on the real-world dataset ICEWS14. In the table, all indicators are considered better the higher they are.
[0103] Table 1: Comparison of Experimental Results
[0104] method Hits@1 Hits@10 DE-SimplE 0.14 0.22 TNTComplEX 1.83 4.24 RE-NET 13.01 22.55 x-ERTE 17.44 27.57 The method of the present invention 18.13 34.21
[0105] The embodiments of the present invention have the following beneficial effects:
[0106] 1) By decoupling entity embedding representations into external storage to preserve the historical semantics of entities, any newly emerging entity can be flexibly initialized using its original features and updated by our update function as new knowledge arrives. Therefore, the method provided by this invention can effectively generate embedding representations of newly emerging entities;
[0107] 2) The updated model can fully consider the direct and propagation effects of new knowledge, and use a gating mechanism to incrementally update the entity's embedded representation. It does not need to generate the embedded representation at each time step from scratch. Therefore, the method provided by this invention can quickly generate embedded representations to respond to query requirements in real time.
[0108] 3) The reading model considers both the periodic semantic changes of the entity itself and the semantic changes of related entities, thereby accurately predicting the evolution trajectory of entity semantics. Therefore, the method provided by this invention can accurately generate embedded representations at any time.
[0109] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0110] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0111] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0112] Specific embodiments have been used to illustrate the principles and implementation methods of this invention. The descriptions of the embodiments above are only for the purpose of helping to understand the method and core ideas of this invention. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this invention. Therefore, the content of this specification should not be construed as a limitation of this invention.
[0113] Those skilled in the art will recognize that the embodiments described herein are intended to help the reader understand the principles of the invention, and should be understood that the scope of protection of the invention is not limited to such specific statements and embodiments. Those skilled in the art can make various other specific modifications and combinations based on the technical teachings disclosed in this invention without departing from the spirit of the invention, and these modifications and combinations are still within the scope of protection of this invention.
Claims
1. A method for embedding and predicting time-series knowledge graphs for streaming scenarios, characterized in that, Includes the following steps: S1. Collect interaction knowledge in the streaming scenario and preprocess it to obtain preprocessed interaction knowledge; S2. Obtain the directly influencing entities and the propagation influencing entities of the preprocessed interactive knowledge. Among them, if the new interactive knowledge will affect the semantics of the goods or users it contains, then this influence is called the direct influence, and the two entities contained in the new knowledge are called the directly influencing entities. The entities contained in the knowledge that has shared common goods or common users with the new knowledge in the past period are called the propagation influencing entities, and this potential influence that propagates through the path is called the propagation influence. S3. Construct an update model and use the update model to update the embedding representations of directly affected entities and propagating entities, obtaining the updated directly affected entities and propagating entities, specifically: A1. Calculate the direct impact characteristics of entities that directly affect them; A2. Calculate the propagation impact characteristics of entities affected by the propagation; A3. Construct an embedding representation update function, and update the embedding representations of the directly affected entities and the propagated affected entities according to the embedding representation update function to obtain the updated directly affected entities and the propagated affected entities; S4. Construct a reading model, and based on the reading model, read the updated embedding representations of the directly affected entities and the entities whose influence propagates at the time of the query, specifically as follows: C1. Construct a multi-headed evolution model to simulate the updated semantic evolution trajectories of directly influencing entities and propagating entities; C2. Calculate the local state vector; C3. Construct a reading model based on the local state vector and semantic evolution trajectory, and read the updated embedded representations of the directly affected entities and the propagated affected entities at the query time based on the reading model; S5. Calculate the confidence of each knowledge based on the embedding representation at the query time using the scoring function, and predict future knowledge based on the confidence of each knowledge.
2. The method for embedding and predicting time-series knowledge graphs for streaming scenarios according to claim 1, characterized in that, Step S1 is as follows: Collect interactive knowledge in streaming scenarios, filter out interactive knowledge with new entities, construct a new memory space in the knowledge graph, and initialize the memory space using the original features of the new entity. The processed interaction knowledge and the remaining interaction knowledge after filtering are used together as preprocessed interaction knowledge.
3. The method for embedding and predicting time-series knowledge graphs for streaming scenarios according to claim 1, characterized in that, In A1, the specific calculation method for the direct impact features that directly affect the entity is as follows: in, for Directly affecting the entity at this moment The direct impact characteristics; It is a collection of all knowledge in a time-series knowledge graph; For all that happens The inclusion of time directly affects the entity Interactive knowledge; This is a combined computation function; This is an embedded representation of the relationships between entities that directly affect each other; To directly affect the entity exist The latest embedded representation before the current time; In A2, the specific calculation method for the propagation impact characteristics of the propagation impact entity is as follows: in, for At any given moment, all entities that spread influence The set of paths ending in ; [:] represents the first learnable parameter matrix; [:] represents the join operation; It is the hyperbolic tangent function; To spread influence entities exist The latest embedded representation before the current moment, This represents the embedded representation of the relationships between entities that are affected by the propagation.
4. The method for embedding and predicting time-series knowledge graphs for streaming scenarios according to claim 1, characterized in that, The construction process of embedding the update expression in step A3 is represented as follows: B1. Construct the erase quantity function, whose functional expression is as follows: in, The erase vector; It is the sigmoid activation function; [:] represents the second learnable parameter matrix; [:] represents the join operation. It is a physical entity The characteristics of influence, i.e., entities It can characterize entities that directly affect or spread their influence to entities; The first parameter vector; For entities exist The latest embedded representation before the current time; B2. Construct the write function, whose function representation is as follows: in, To write a vector; It is the hyperbolic tangent function; This is the third learnable parameter matrix; The second parameter vector; B3. Construct an embedding representation update function based on the erase and write variables, and update the embedding representations of directly affected entities and propagated entities according to the embedding representation update function to obtain the updated directly affected entities and propagated entities; the embedding representation update function is expressed as: in, for Entities that are constantly updated Embedded representation, This is an element-wise product operation.
5. The method for embedding and predicting time-series knowledge graphs for streaming scenarios according to claim 1, characterized in that, In C1, the semantic evolution trajectory is represented as follows: in, For entities exist Semantic evolution trajectory at any given moment; K The number of evolutionary heads; It is a sine function; It is a physical entity exist The timestamp of the most recent update before the current time; This is the evolutionary period vector; For entities exist The latest embedded representation before the current time; In C3, the embedding representation at the query time is as follows: in, For entities exist Embedded representation at a given moment.
Citation Information
Patent Citations
Time sequence knowledge graph representation learning method based on co-evolution modeling
CN112860918A
Building field document recommendation system and method based on knowledge graph attention network
CN114064936A