Knowledge graph completion method and device for relieving sparsity

CN119623598AActive Publication Date: 2025-03-14CHONGQING UNIV

Patent Information

Application Number
CN202411770810.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-04
Publication Date
2025-03-14
Estimated Expiration
2044-12-04

AI Technical Summary

Technical Problem

When dealing with problems with rare entities, existing knowledge graphs cannot provide accurate answers due to sparseness, which affects the performance of smart question-and-answer systems.

Method used

By building auxiliary triplets, using large language models to fine-tune the knowledge graph, obtain a discriminator, filter the auxiliary triplets, fuse them into the original knowledge graph, and improve model performance through message aggregation and dynamic suppression strategies.

Benefits of technology

Effectively explore entity information similar to rare entities, improve the system's ability to answer rare entity questions, and improve the performance of knowledge graph completion tasks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119623598A_ABST
    Figure CN119623598A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of artificial intelligence, and discloses a knowledge graph completion method and device for relieving sparsity, and the method comprises the steps: constructing an auxiliary triple; performing instruction fine tuning on the large language model by adopting the data of the original knowledge graph to obtain a discriminator; filtering the auxiliary triple by adopting a discriminator, and fusing the filtered triple with the original knowledge graph to obtain an enhanced knowledge graph; performing message aggregation on the enhanced knowledge graph to obtain a graph structure representation fused with neighbor information; and a dynamic suppression strategy is adopted to correct loss in a graph structure representation result fused with neighbor information, the performance of the model on a knowledge graph completion task is improved, and an adjusted knowledge graph is obtained. According to the knowledge graph completion method and device for relieving sparsity, entity information similar to a rare entity is effectively mined through construction of the similarity matrix and the auxiliary triad, so that the answering ability of a system to a rare entity problem is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology, and in particular to a knowledge graph completion method and device that alleviates sparsity. Background Art

[0002] A knowledge graph is a knowledge base that stores entities and relationships in the form of a graph. Data is stored in triples. It can provide processed prior knowledge to intelligent systems through knowledge representation and reasoning techniques, enhancing the cognitive intelligence of the system. Therefore, it is widely used in many fields, including information retrieval, question-answering systems, and recommendation systems. Although existing knowledge graphs already contain millions of facts, they still face the problem of graph incompleteness, which severely limits the performance of downstream tasks. In order to alleviate this problem, the knowledge graph completion task (KGC) came into being.

[0003] The knowledge graph completion task is to automatically predict the missing information in a given triple based on the known fact triple information in the knowledge graph, thereby mining new information to continuously expand and improve the knowledge graph.

[0004] In intelligent question-answering systems, the completeness of the knowledge graph is crucial to accurately answering complex questions raised by users. Through knowledge graph completion technology, the system can automatically infer and fill in the gaps in the knowledge graph, thereby improving the system's understanding of questions and the accuracy of its answers. However, when the intelligent question-answering system needs to answer questions about rare entities, the sparsity of the knowledge graph may cause the system to be unable to provide accurate answers. Summary of the invention

[0005] In view of the deficiencies in the prior art, the present invention proposes a knowledge graph completion method and device that alleviates sparsity, so as to solve the above-mentioned technical problems.

[0006] First, a knowledge graph completion method for alleviating sparsity is provided, including:

[0007] Construct auxiliary triples;

[0008] Use the data of the original knowledge graph to fine-tune the large language model to obtain the discriminator;

[0009] The auxiliary triples are filtered using the discriminator, and the filtered triples are fused with the original knowledge graph to obtain an enhanced knowledge graph;

[0010] Performing message aggregation on the enhanced knowledge graph to obtain a graph structure representation that integrates neighbor information;

[0011] A dynamic suppression strategy is used to correct the loss in the graph structure representation result of the fused neighbor information, improve the performance of the model in the knowledge graph completion task, and obtain an adjusted knowledge graph.

[0012] Furthermore, the constructing of the auxiliary triplet includes:

[0013] Encode the text description of the entity in the original knowledge graph to obtain an n-dimensional sentence vector;

[0014] Calculate the cosine similarity between all sentence vectors and construct a similarity matrix;

[0015] When the triple in the original knowledge graph contains sparse entities, the entity most similar to the sparse entity in the similarity matrix is ​​used to replace the head or tail entity in the original triple to construct an auxiliary triple.

[0016] Furthermore, the method of using the data of the original knowledge graph to fine-tune the large language model to obtain a discriminator includes:

[0017] Train the triples in the original knowledge graph to obtain the structural embedding representation of the triples;

[0018] Project the structure embedding representation of the triple into the text token representation space of the large language model to construct the instruction prefix;

[0019] The input sequence with the instruction prefix is ​​used to fine-tune the instruction of the large language model to obtain a discriminator. Further, the auxiliary triples are filtered by the discriminator, and the filtered triples are merged with the original knowledge graph to obtain an enhanced knowledge graph, including:

[0020] Input the constructed auxiliary triples into the discriminator, predict the authenticity of the auxiliary triples, and obtain the auxiliary triples whose discriminant results are true;

[0021] The true auxiliary triples are fused with the original knowledge graph to obtain the enhanced knowledge graph.

[0022] Furthermore, the message aggregation is performed on the enhanced knowledge graph to obtain a graph structure representation integrating neighbor information, including:

[0023] Calculate the importance of neighbor triples to the entities in the enhanced knowledge graph, i.e., the attention score;

[0024] Normalize the attention scores to obtain the weight coefficients;

[0025] The weight coefficient is used to perform weighted summation on the embedding representations of neighbor entities and merge them with the embedding representation of the current entity to obtain the updated entity embedding representation;

[0026] Repeat the above steps until the embedding representations of all entities are updated, and a graph structure representation that integrates neighbor information is obtained.

[0027] Furthermore, the dynamic suppression strategy is used to correct the loss in the graph structure representation result of the fused neighbor information, thereby improving the performance of the model in the knowledge graph completion task, and obtaining an adjusted knowledge graph, including:

[0028] Define input query pairs, including entities and relations, and corresponding labels;

[0029] According to the input query pairs and labels, construct positive sample sets, negative sample sets and auxiliary triple sample sets for enhancing the knowledge graph;

[0030] Introduce weights to correct the loss and adjust the strength of knowledge graph enhancement, where the value of the weight is dynamically adjusted according to the sample type and its loss size;

[0031] When a sample belongs to the auxiliary triplet sample set and its loss is greater than a preset threshold, the weight of the corresponding sample is reduced;

[0032] According to the modified dynamic loss function, the entire model is trained until the predetermined training termination condition is reached to obtain the adjusted knowledge graph.

[0033] In a second aspect, a knowledge graph completion device for alleviating sparsity is provided, characterized in that it includes:

[0034] Building modules, used to build auxiliary triples;

[0035] The fine-tuning module is used to fine-tune the large language model using the data of the original knowledge graph to obtain the discriminator;

[0036] A filtering module, used to filter the auxiliary triples using the discriminator, and fuse the filtered triples with the original knowledge graph to obtain an enhanced knowledge graph;

[0037] An aggregation module, used to aggregate messages on the enhanced knowledge graph to obtain a graph structure representation that integrates neighbor information;

[0038] The correction module is used to correct the loss in the graph structure representation result of the fused neighbor information by adopting a dynamic suppression strategy, improve the performance of the model in the knowledge graph completion task, and obtain an adjusted knowledge graph.

[0039] Furthermore, a knowledge graph completion device for alleviating sparsity includes a processor and a memory storing program instructions, wherein the processor is used to execute a knowledge graph completion method for alleviating sparsity as described in any one of the foregoing items when running the program instructions.

[0040] In a third aspect, an electronic device is provided, comprising a knowledge graph completion device for alleviating sparsity as described above.

[0041] The invention adopting the above technical solution has the following advantages:

[0042] The present invention effectively mines entity information similar to rare entities through the construction of similarity matrix and auxiliary triples, thereby improving the system's ability to answer rare entity questions. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] In order to more clearly illustrate the specific implementation of the present invention, the following will briefly introduce the drawings required for use in the specific implementation. In all the drawings, each element or part is not necessarily drawn according to the actual scale.

[0044] Figure 1 This is a flow chart of a knowledge graph completion method for alleviating sparsity in the present invention;

[0045] Figure 2 It is a flow chart of a knowledge graph enhancement module and a loss-constrained KGE model in a knowledge graph completion method for alleviating sparsity of the present invention;

[0046] Figure 3 This is a flow chart of a knowledge graph completion device for alleviating sparsity according to the present invention. DETAILED DESCRIPTION

[0047] The following embodiments of the technical solution of the present invention are described in detail in conjunction with the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solution of the present invention, and are therefore only used as examples, and cannot be used to limit the protection scope of the present invention.

[0048] like Figure 1 to Figure 3 As shown, a knowledge graph completion method for alleviating sparsity of the present invention includes:

[0049] Step S01, constructing an auxiliary triplet;

[0050] Step S02: Use the data of the original knowledge graph to fine-tune the large language model to obtain a discriminator;

[0051] Step S03: Use a discriminator to filter the auxiliary triples, and fuse the filtered triples with the original knowledge graph to obtain an enhanced knowledge graph;

[0052] Step S04: Aggregate messages on the enhanced knowledge graph to obtain a graph structure representation that integrates neighbor information;

[0053] Step S05: Use a dynamic suppression strategy to correct the loss in the graph structure representation result of the fused neighbor information, improve the performance of the model in the knowledge graph completion task, and obtain an adjusted knowledge graph.

[0054] Specifically, the present invention effectively mines entity information similar to rare entities through the construction of similarity matrix and auxiliary triples, thereby improving the system's ability to answer rare entity questions.

[0055] Specifically, the knowledge graph completion method proposed in the present invention mainly includes two modules. The first module is the knowledge graph enhancement module, which focuses on building useful auxiliary triples based on the structure and text description of sparse entities using a large language model to enhance the knowledge graph and promote message transmission between sparse entities. The second module is the loss-constrained KGE model, which introduces an adaptive message aggregation mechanism and a loss constraint strategy to enable the model to focus on more important neighbor information and dynamically adjust the enhancement strength of the knowledge graph to effectively perform the knowledge graph completion task.

[0056] In some embodiments, constructing an auxiliary triplet includes:

[0057] Encode the text description of the entity in the original knowledge graph to obtain an n-dimensional sentence vector;

[0058] Calculate the cosine similarity between all sentence vectors and construct a similarity matrix;

[0059] When the triple in the original knowledge graph contains sparse entities, the entity most similar to the sparse entity in the similarity matrix is ​​used to replace the head or tail entity in the original triple to construct an auxiliary triple.

[0060] Specifically, the knowledge graph enhancement module

[0061] First, for entities in sparse areas, the steps of automatically constructing auxiliary triples designed by the present invention are as follows:

[0062] The Sentence-Bert model is used to encode the text descriptions of all entities to obtain n-dimensional sentence vectors.

[0063] Calculate the cosine similarity between all sentence vectors to obtain a similarity matrix A sim ∈R N×N , where N = |ε| is the number of all entities. This process is expressed as follows:

[0064]

[0065] Among them, D i The sentence vector obtained by encoding the description text of entity i through the Sentence-Bert model.

[0066] Then, in a triple, when the head / tail entity is a sparse entity, the tail / head entity is replaced by its top k most similar entities to construct an auxiliary triple.

[0067] For example, when k is 1, in the triple (London, / location / location / contains, University of London), the “University of London” entity is a sparse entity.

[0068] According to the similarity matrix A sim , the entity “City of London” has the most similar semantics to “London”. By replacing “London” with “City of London”, a new auxiliary triple (City of London, / location / location / contains,University of London) is obtained, thus enriching the structural information of the sparse entity “University of London”.

[0069] In some embodiments, the data of the original knowledge graph is used to fine-tune the instruction of the large language model to obtain a discriminator, including:

[0070] Train the triples in the original knowledge graph to obtain the structural embedding representation of the triples;

[0071] Project the structure embedding representation of the triple into the text token representation space of the large language model to construct the instruction prefix;

[0072] The large language model is fine-tuned using input sequences with instruction prefixes to obtain the discriminator.

[0073] In some embodiments, a discriminator is used to filter the auxiliary triples, and the filtered triples are fused with the original knowledge graph to obtain an enhanced knowledge graph, including:

[0074] Input the constructed auxiliary triples into the discriminator, predict the authenticity of the auxiliary triples, and obtain the auxiliary triples whose discriminant results are true;

[0075] The true auxiliary triples are fused with the original knowledge graph to obtain the enhanced knowledge graph.

[0076] Specifically, the steps designed by the present invention to use the large model as a discriminator to filter the triples constructed in the above steps are as follows:

[0077] First, the RotatE model is trained on all triples of the knowledge graph to obtain the structural embedding representation of entities and relations. At this stage, the optimization objectives are as follows:

[0078]

[0079] Among them, γ is a fixed boundary parameter, σ1 represents the sigmoid activation function, (s' i ,r,o' i ) represents the i-th negative sample of the triple (s, r, o). The scoring function is defined as follows:

[0080]

[0081] in, Denotes the Hadmard product.

[0082] After obtaining the structural embedding representation of entities and relations, the knowledge graph data is used to perform instruction tuning on the large language model Alpaca.

[0083] When fine-tuning Alpaca, each triplet is taken as a sample.

[0084] Taking the triple (s, r, o) as an example, the prefix adapter P is used to project the structural embedding of s, r, o into the text tag representation space of Alpaca to obtain a virtual text tag.

[0085] These virtual tokens are then placed at the beginning of the original input sequence as prefixes to the instructions. The final input sequence for the Alpaca model is as follows:

[0086]

[0087] in, represents the splicing operation, I it is a directive tag embed from a directive template. represent the text token embeddings from entity s, relation r, and text name of entity o, respectively.

[0088] When fine-tuning the instructions, the output of the Alpaca model is "True" or "False". The output indicates the authenticity of the input triple.

[0089] After fine-tuning, a discriminator with the ability to distinguish true from false triples is obtained.

[0090] Then, the auxiliary triples constructed in the above content are input into the large model discriminator to predict the authenticity of each auxiliary triplet and perform filtering operations on all auxiliary triples.

[0091] Finally, the triples whose discriminant results are true are retained and fused with the original knowledge graph to enhance the knowledge graph.

[0092] In some embodiments, the enhanced knowledge graph is aggregated to obtain a graph structure representation that integrates neighbor information, including:

[0093] Calculate the importance of neighbor triples to the entities in the enhanced knowledge graph, i.e., the attention score;

[0094] Normalize the attention scores to obtain the weight coefficients;

[0095] The weight coefficient is used to perform weighted summation on the embedding representations of neighbor entities and merge them with the embedding representation of the current entity to obtain the updated entity embedding representation;

[0096] Repeat the above steps until the embedding representations of all entities are updated, and a graph structure representation that integrates neighbor information is obtained.

[0097] Specifically, the loss-constrained KGE module

[0098] The adaptive message aggregation mechanism designed by the present invention is used to automatically learn and focus on neighbors that are critical to the central entity. The steps are as follows:

[0099] Given an entity s, the set of its directly connected neighbors is The set of directly connected relationships is Represents the edge connecting entity s and its neighbor entity u.

[0100] First, calculate the importance of each neighbor triple to entity s, that is, the attention score b s,r,o . Concatenate the node representation of entity s, the representation of relationship r, and the node representation of entity o, and pass the concatenated representation through W attn Perform a linear transformation and finally obtain the attention score b after the σ2 activation function s,r,o The formula is as follows:

[0101] b s,r,o =aσ2(W attn [h s ||h r ||h o ])

[0102] Among them, || represents the concatenation operation, σ2 represents the LeakyReLU activation function, and Represents a linear transformation.

[0103] Then, the attention score b s,r,oPerform Softmax normalization to obtain the weight coefficient α s,r,o :

[0104]

[0105] Next, the node representation h of the adjacent entity o o The corresponding relationship r is represented by h r Perform a combination operation and pass the combined operation representation through W r Perform a linear transformation. Then, according to the weight coefficient α obtained in the previous step s,r,o After weighted summation, and W res h s Add. Finally, a Tanh activation function is used to obtain the updated node representation of entity s. The message aggregation method of entity s is uniformly defined as:

[0106]

[0107] Among them, σ3 represents the Tanh activation function, and the combination operator is a cyclic correlation operation, which is defined as follows:

[0108] (h o ,h r )=h o ★h r

[0109] W res ∈R d×d is the self-loop relation parameter, W r are relation type specific parameters and are defined as follows:

[0110]

[0111] Among them, W O Indicates the parameter corresponding to the positive relationship, W I Indicates the parameters corresponding to the inverse relationship.

[0112] Finally, after the embedding representation of the entity is updated, the embedding representation of the relationship is updated. The formula is as follows:

[0113] h′ r =W rel h r

[0114] Among them, W rel ∈R d×d is the trainable parameter matrix of relation embedding.

[0115] In some embodiments, a dynamic suppression strategy is used to correct the loss in the graph structure representation result of the fused neighbor information, so as to improve the performance of the model in the knowledge graph completion task and obtain an adjusted knowledge graph, including:

[0116] Define input query pairs, including entities and relations, and corresponding labels;

[0117] According to the input query pairs and labels, construct positive sample sets, negative sample sets and auxiliary triple sample sets for enhancing the knowledge graph;

[0118] Introduce weights to correct the loss and adjust the strength of knowledge graph enhancement.

[0119] Among them, the value of the weight is dynamically adjusted according to the sample type and its loss size;

[0120] When a sample belongs to the auxiliary triplet sample set and its loss is greater than a preset threshold, the weight of the corresponding sample is reduced;

[0121] According to the modified dynamic loss function, the entire model is trained until the predetermined training termination condition is reached to obtain the adjusted knowledge graph.

[0122] Specifically, the dynamic loss suppression strategy designed by the present invention is used to correct the loss, adjust the enhancement strength of the knowledge graph, and train the entire model. The specific steps are as follows:

[0123] First, define the input query pair as (e s ,r), where entity e s ∈ε, the relationship

[0124] Label in N is the number of entities |ε|.

[0125] For label y, samples can be divided into the following three types:

[0126]

[0127] in, represents the positive sample set, represents the negative sample set, Represents the auxiliary triplet sample set used to enhance the knowledge graph.

[0128] Next, we introduce a weight β i Correct the loss, adjust the strength of knowledge graph enhancement, and reduce The impact of false positive samples in the sample set on training. The modified dynamic loss function is defined as follows:

[0129]

[0130] in, represents the triplets in the same training batch, φ is the scoring function ConvE, and BCELoss(·) represents the binary cross entropy loss.

[0131] Dynamically adjust the weight β during training i The size of the sample belongs to When the loss of the sample is greater than the threshold R (t) When the corresponding weight β i Will decrease.

[0132]

[0133] Among them, t represents the number of iterations of the current training, and the threshold R (t) is the loss set The loss value is as large as [(t-1) / 30·γ]% in the first half of the graph, where γ is a hyperparameter that determines the growth rate of dynamic loss suppression.

[0134] Specifically, the knowledge graph completion method according to the present invention can effectively improve the prediction performance of the model in sparse areas and alleviate the impact of sparsity.

[0135] At the same time, the method proposed in the present invention of using a fine-tuned large model as a triple discriminator to enhance the knowledge graph is different from the traditional graph enhancement method. It does not require manual design of complex rules to construct triples, but instead uses the discriminator to filter to obtain reliable auxiliary triples.

[0136] In addition, the enhancement strategy proposed in the present invention is model-independent, so the enhanced knowledge graph data can be used in any other knowledge graph embedding model.

[0137] In some other embodiments, a knowledge graph completion device for alleviating sparsity is provided, including:

[0138] Building modules, used to build auxiliary triples;

[0139] The fine-tuning module is used to fine-tune the large language model using the data of the original knowledge graph to obtain the discriminator;

[0140] The filtering module is used to filter the auxiliary triples using a discriminator, and fuse the filtered triples with the original knowledge graph to obtain an enhanced knowledge graph;

[0141] The aggregation module is used to aggregate messages on the enhanced knowledge graph to obtain a graph structure representation that integrates neighbor information;

[0142] The correction module is used to correct the loss in the graph structure representation result of the fused neighbor information by adopting a dynamic suppression strategy, improve the performance of the model in the knowledge graph completion task, and obtain the adjusted knowledge graph.

[0143] In some embodiments, a knowledge graph completion device for alleviating sparsity includes a processor and a memory storing program instructions, and the processor is used to execute a knowledge graph completion method for alleviating sparsity as any of the above items when running the program instructions.

[0144] In other embodiments, an electronic device (such as a mobile phone, a computer) is provided, including a knowledge graph completion device for alleviating sparsity as described above.

[0145] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein by equivalents. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present invention, and they should all be included in the scope of the claims and specification of the present invention.

Claims

1. A knowledge graph completion method for alleviating sparsity, characterized in that: include: Construct auxiliary triples; Use the data of the original knowledge graph to fine-tune the large language model to obtain the discriminator; The auxiliary triples are filtered using the discriminator, and the filtered triples are fused with the original knowledge graph to obtain an enhanced knowledge graph; Performing message aggregation on the enhanced knowledge graph to obtain a graph structure representation that integrates neighbor information; A dynamic suppression strategy is used to correct the loss in the graph structure representation result of the fused neighbor information, improve the performance of the model in the knowledge graph completion task, and obtain an adjusted knowledge graph.

2. A knowledge graph completion method for alleviating sparsity according to claim 1, characterized in that: The constructing of the auxiliary triplet includes: Encode the text description of the entity in the original knowledge graph to obtain an n-dimensional sentence vector; Calculate the cosine similarity between all sentence vectors and construct a similarity matrix; When the triple in the original knowledge graph contains sparse entities, the entity most similar to the sparse entity in the similarity matrix is ​​used to replace the head or tail entity in the original triple to construct an auxiliary triple.

3. A knowledge graph completion method for alleviating sparsity according to claim 2, characterized in that: The method uses the data of the original knowledge graph to fine-tune the large language model to obtain a discriminator, including: Train the triples in the original knowledge graph to obtain the structural embedding representation of the triples; Project the structure embedding representation of the triple into the text token representation space of the large language model to construct the instruction prefix; The large language model is fine-tuned using input sequences with instruction prefixes to obtain the discriminator.

4. A knowledge graph completion method for alleviating sparsity according to claim 3, characterized in that: The method of filtering the auxiliary triples by using the discriminator and fusing the filtered triples with the original knowledge graph to obtain an enhanced knowledge graph includes: Input the constructed auxiliary triples into the discriminator, predict the authenticity of the auxiliary triples, and obtain the auxiliary triples whose discriminant results are true; The true auxiliary triples are fused with the original knowledge graph to obtain the enhanced knowledge graph.

5. A knowledge graph completion method for alleviating sparsity according to claim 4, characterized in that: The step of aggregating messages on the enhanced knowledge graph to obtain a graph structure representation of fused neighbor information includes: Calculate the importance of neighbor triples to the entities in the enhanced knowledge graph, i.e., the attention score; Normalize the attention scores to obtain the weight coefficients; The weight coefficient is used to perform weighted summation on the embedding representations of neighbor entities and merge them with the embedding representation of the current entity to obtain the updated entity embedding representation; Repeat the above steps until the embedding representations of all entities are updated, and a graph structure representation that integrates neighbor information is obtained.

6. A knowledge graph completion method for alleviating sparsity according to claim 5, characterized in that: The dynamic suppression strategy is used to correct the loss in the graph structure representation result of the fused neighbor information, improve the performance of the model in the knowledge graph completion task, and obtain the adjusted knowledge graph, including: Define input query pairs, including entities and relations, and corresponding labels; According to the input query pairs and labels, construct positive sample sets, negative sample sets and auxiliary triple sample sets for enhancing the knowledge graph; Introduce weights to correct the loss and adjust the strength of knowledge graph enhancement, where the value of the weight is dynamically adjusted according to the sample type and its loss size; When a sample belongs to the auxiliary triplet sample set and its loss is greater than a preset threshold, the weight of the corresponding sample is reduced; According to the modified dynamic loss function, the entire model is trained until the predetermined training termination condition is reached to obtain the adjusted knowledge graph.

7. A knowledge graph completion device for alleviating sparsity, characterized in that: include: Building modules, used to build auxiliary triples; The fine-tuning module is used to fine-tune the large language model using the data of the original knowledge graph to obtain the discriminator; A filtering module, used to filter the auxiliary triples using the discriminator, and fuse the filtered triples with the original knowledge graph to obtain an enhanced knowledge graph; An aggregation module, used to aggregate messages on the enhanced knowledge graph to obtain a graph structure representation that integrates neighbor information; The correction module is used to correct the loss in the graph structure representation result of the fused neighbor information by adopting a dynamic suppression strategy, improve the performance of the model in the knowledge graph completion task, and obtain an adjusted knowledge graph.

8. A knowledge graph completion device for alleviating sparsity, comprising a processor and a memory storing program instructions, characterized in that: The processor is used to execute a knowledge graph completion method for alleviating sparsity as described in any one of claims 1 to 6 when running the program instructions.

9. An electronic device, characterized in that: It includes a knowledge graph completion device for alleviating sparsity as described in claim 7 or 8.

Citation Information

Patent Citations

  • Knowledge graph completion-oriented link prediction method

    CN112883200A

  • Knowledge graph completion method and device based on improved TextRank

    CN115422369A

  • Operation and maintenance data analysis method, device and equipment

    CN118069867A

  • Knowledge graph representation learning method of fusion graph structure based on pre-training language model

    CN118210927A

  • Drug repositioning method and system fusing multi-source knowledge graph

    WO2024138803A1

Cited By

  • Knowledge graph knowledge expansion method

    CN119917701A