Knowledge graph enhanced large language model-based scientific research path generation method and system

By constructing a large language model based on knowledge graph enhancement, the problem of low efficiency in traditional literature retrieval is solved, and the accurate discovery of cross-domain knowledge associations and the generation of research paths are realized, thereby improving research efficiency and innovation capabilities.

CN120975231APending Publication Date: 2025-11-18FUZHOU UNIV
View PDF 0 Cites 3 Cited by

Patent Information

Application Number
CN202511075741.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-01
Publication Date
2025-11-18

AI Technical Summary

Technical Problem

Traditional literature retrieval methods are inefficient, making it difficult to extract structured knowledge from massive amounts of literature and to uncover cross-disciplinary knowledge connections, resulting in low research efficiency and difficulty in achieving breakthroughs in innovation.

Method used

We construct a large language model based on knowledge graph enhancement, generate a knowledge embedding matrix through self-supervised training of heterogeneous graph neural networks, design a semantic aligner, and generate structured research paths by combining natural language instructions.

Benefits of technology

It enables accurate and reliable cross-domain knowledge discovery, reduces the cost of manual sorting, improves the efficiency of scientific research decision-making, and provides suggestions for innovative paths.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120975231A_ABST
    Figure CN120975231A_ABST
Patent Text Reader

Abstract

The invention relates to a scientific research path generation method and system of a big language model based on knowledge graph enhancement, and belongs to the field of artificial intelligence. The method comprises the steps that a literature data set is analyzed based on a large language model, and a heterogeneous knowledge graph fusing knowledge triples and evidence metadata is constructed; performing self-supervised training on the atlas through a heterogeneous graph neural network to generate a knowledge embedding matrix; designing a semantic aligner to embed the map and align the map with the semantic space of the large language model; searching seed nodes according to user query and extracting context sub-graphs; converting the sub-graph into a graph lexical element sequence; and constructing a mixed prompt input large language model in combination with a natural language instruction, and generating a structured scientific research path. According to the method and the system, the quality and the credibility of a scientific research path can be accurately found, a literature reading sequence and an experiment reproduction sequence are clarified, and a more efficient technical engine is provided for knowledge discovery.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of artificial intelligence, specifically relating to a method and system for generating research paths based on a knowledge graph-enhanced large language model. Background Technology

[0002] In scientific research, literature retrieval and analysis are fundamental steps. With the deepening of academic research and the explosive growth in the number of documents, researchers face severe challenges: traditional literature retrieval methods often rely on simple strategies such as keyword matching, resulting in a massive number of returned documents that lack effective organization. Researchers need to spend a significant amount of time sifting through this vast amount of literature, making it difficult to quickly focus on core information. Furthermore, significant knowledge barriers exist between different research fields, and traditional literature retrieval and analysis methods struggle to overcome these boundaries, failing to effectively uncover potential cross-disciplinary knowledge connections and innovative points, thus greatly limiting the breadth and depth of knowledge discovery.

[0003] Therefore, it is crucial to develop a technical solution that can extract structured knowledge from massive amounts of literature, generate clear research paths, define the order of literature reading and experimental reproduction, and facilitate cross-disciplinary knowledge discovery. This is an important requirement for improving research efficiency and promoting innovative breakthroughs. Summary of the Invention

[0004] The purpose of this invention is to provide a research path generation method and system based on a knowledge graph-enhanced large language model, in order to solve the problems in the existing technology, such as the low efficiency of research path generation relying on manual sorting, the tendency to generate knowledge illusions when using large language models, the separation between knowledge graphs and natural language semantics, and the difficulty in mining cross-domain knowledge associations, so as to achieve accurate, reliable research path generation with cross-domain discovery capabilities.

[0005] To achieve the above objectives, the technical solution of this invention is: a method for generating research paths based on a knowledge graph-enhanced large language model, comprising:

[0006] Based on the analysis of document datasets using large language models, a heterogeneous knowledge graph integrating knowledge triples and evidence metadata is constructed.

[0007] A knowledge embedding matrix is ​​generated by self-supervised training of a heterogeneous knowledge graph using a heterogeneous graph neural network.

[0008] Design a semantic aligner to align the knowledge embedding matrix with the semantic space of a large language model;

[0009] Based on the knowledge embedding matrix, seed nodes are retrieved according to user queries and corresponding context subgraphs are extracted from heterogeneous knowledge graphs. The context subgraphs are converted into graph lexical sequences and combined with natural language instructions to construct a hybrid prompt input large language model, generating the final structured research path.

[0010] Furthermore, the method includes the following steps:

[0011] Step S1: Based on the large language model, the document dataset is parsed to obtain knowledge triples K and evidence metadata M, and a heterogeneous knowledge graph G with document content as the core is constructed.

[0012] Step S2: Use a heterogeneous graph neural network model f GNN By performing self-supervised training on the heterogeneous knowledge graph G, a knowledge embedding matrix Z of the heterogeneous knowledge graph G is generated.

[0013] Step S3: By analyzing the knowledge embedding matrix Z and the large model f LMM Semantic alignment training is performed to obtain the semantic aligner f. P ;

[0014] Step S4: Based on the user's original request q, perform similarity retrieval from the knowledge embedding matrix Z to obtain relevant seed nodes, and extract the corresponding context subgraph G from the heterogeneous knowledge graph G. sub ;

[0015] Step S5: Transfer the context subgraph G sub Input to heterogeneous graph neural network model f GNN and semantic aligner f P To generate a graph word sequence X G ;

[0016] Step S6: Construct a graph containing natural language instructions and a sequence of generated graph lexical units X. G The mixed prompts are then fed into the large language model f. LMM This is to generate the final structured research path.

[0017] Furthermore, step S1 specifically includes the following steps:

[0018] Step S11: Using a large language model, the input document dataset is transformed into structured knowledge triples K = {k1, k2, ..., k} through named entity recognition and relation extraction techniques. n} and evidence metadata M = {m1, m2, ..., m n}, k i = <h i ,r i ,t i >, where h i For the head entity extracted from the document text, r i For the relationship between entities, t i The tail entity extracted from the document text, m i = <D i ,Li ,TS i A i >, where D i L serves as a source document identifier. i TS is a location tag within a document. i For document timestamps, A i To ensure the authority of the literature, A i ∈[0,1];

[0019] Step S12: Assign evidence labels to each knowledge triple in the document using the evidence mapping function EVI(x); the evidence mapping function EVI(x) maps knowledge triples k... i Mapped to its corresponding evidence metadata:

[0020] EVI(k i )=m i

[0021] Where, m i For k i Evidence metadata;

[0022] Step S13: Perform entity linking on all head entities h and tail entities t in the knowledge triple set K to generate a normalized entity ID, forming an entity node set V. Aggregate all knowledge triples according to their normalized entity IDs to construct a set R of relational edges connecting node pairs in the entity node set V. During the aggregation process, extract all evidence metadata m corresponding to each relational edge. i The aggregation process is performed, which comprehensively considers the authority of the source documents in the evidence metadata (A). i Document timestamp TS i and the location tag L in the document i A comprehensive confidence score is calculated to generate an edge aggregation weight matrix W that assigns a comprehensive confidence score to each relation edge. After the entity node set V is constructed, the text description corresponding to each node in V is encoded by a pre-trained language model to generate the initial feature matrix X of the node.

[0023] Step S14: Instantiate the heterogeneous knowledge graph G by combining the entity node set V, the relation edge set R, the initial node feature matrix X, and the edge aggregation weight matrix W.

[0024] G = (V, R, X, W).

[0025] Furthermore, step S2 specifically includes the following steps:

[0026] Step S21: Using a predefined composite loss function L total Heterogeneous graph neural network model f for evidence perceptionGNN Optimize the composite loss function L total Defined as:

[0027] L total =L LinkPred +L Path

[0028] L LinkPred The link prediction loss is used to optimize the local structural representation of node embeddings:

[0029]

[0030] Among them, E + E is the set of positive sample edges sampled from the heterogeneous knowledge graph G. - z is the set of negative sample edges sampled from the composite knowledge graph G. i ,z j Let i and j represent the embedding vectors of nodes i and j respectively, and σ(·) be the Sigmoid function, which maps any real number to the interval (0,1) and is used to represent the probability.

[0031] L Path The path consistency loss is used to optimize the global logical representation of node embeddings.

[0032]

[0033] Where γ is the marginal loss threshold, P + and P - Let P+ and P- be the consistent path set and the inconsistent path set, respectively. p+ is a specific, logically consistent path sample extracted from the consistent path set P+; p- is a specific, logically inconsistent path sample extracted from the inconsistent path set P-; and S(·) is the path scoring function.

[0034] The path scoring function S(·) is implemented based on an LSTM model scorer. The LSTM model generates a logical coherence score by processing the embedding vector sequence of nodes in the path.

[0035]

[0036] This represents the input sequence formed by arranging the embedding vectors of all nodes in path p in order; the Sigmoid function is used to map the raw score output by the LSTM model scorer after processing the path sequence to the (0,1) interval, thereby obtaining a standardized score that represents the strength of the logical coherence of the path.

[0037] Consistent path set P +Its structure is as follows: First, the citation chain path p is extracted from the heterogeneous knowledge graph G using an algorithm. citation Technology dependency path p dependency As high-confidence core samples, the large language model f is used. LLM Generate additional path combinations to increase sample diversity; inconsistent path set P - Its structure is: the set of consistent paths P + As input, the instruction-based large language model f LLM The process involves disrupting the sample, including replacing nodes of the same type and reversing the timing logic, to generate negative samples. The overall process is as follows:

[0038] P + ={p citation ∪p dependency}∪f LLM (Generate|Domain)

[0039] P - =f LLM (Corrupt|P + Domain)

[0040] Among them, f LLM (·) indicates an expression for invoking instructions to the large language model. Generate represents a generation instruction, which instructs the large language model to generate a citation chain path p of the core sample based on its internal knowledge. citation Technology dependency path p dependency A logically consistent, new research path. `Domain` represents the domain scope specified for the model, such as "biomedicine" or "quantum computing." This parameter constrains the knowledge boundary of the generation operation, ensuring that the newly generated path is highly relevant to the specified research domain. `Corrupt` represents a disruptive instruction, which instructs the large language model to take the consistent path set P+ as input and logically modify it, including but not limited to replacing nodes of the same type and reversing temporal logic to generate negative samples.

[0041] Furthermore, step S3 specifically includes the following steps:

[0042] Step S31: Randomly sample a series of general subgraphs G from the heterogeneous knowledge graph G. sample As training data, it is input into f GNN In this process, we obtain its node embedding matrix.

[0043] Step S32: Embed the node matrix Perform a linear transformation to generate a graph word sequence X. G Construct a graph word sequence XG A mixed suggestion of a list of disordered text descriptions, and input it into f LMM In order to make it output a value based on X G A speculative, ordered list of textual descriptions, in which

[0044] X G =f P (H sample )=H sample ·W P +b P

[0045] W P b P These are the weight parameters and the bias parameters, respectively.

[0046] Step S33, f LLM The output sorting result is compared with the actual text description order. A scalar loss value is calculated using a cross-entropy loss function, and W is optimized through gradient update via backpropagation. P b P After training, the semantic aligner f is obtained. P .

[0047] Furthermore, step S4 specifically includes the following steps:

[0048] Step S41: Encode the user request q into a query vector Z q By calculating Z q With the knowledge embedding matrix Z, the embedding vectors of all nodes z i The cosine similarity is used, and the top-K nodes with the highest similarity scores are selected as seed nodes. The similarity calculation formula is as follows:

[0049]

[0050] Step S42: Based on these seed nodes, extract the context subgraph G that is highly relevant to the current query from the heterogeneous knowledge graph G. sub .

[0051] Furthermore, step S5 specifically includes the following steps:

[0052] Step S51: Transfer the context subgraph G sub Enter to f GNN To generate its corresponding node embedding matrix H sub ;

[0053] Step S52: Embed the nodes into matrix H sub Input to semantic aligner f P To generate a graph word sequence X G .

[0054] Furthermore, step S6 specifically includes the following steps:

[0055] Step S61: Combine the user's original request q (natural language instruction) with the graph lexical sequence X. G Concatenate the components to create a mixed prompt:

[0056] Step S62: Enter the mixed prompt into f LLM It reasons and outputs the final structured research path text.

[0057] The present invention also provides a research path generation system based on a knowledge graph-enhanced large language model, including a memory, a processor, and computer program instructions stored in the memory and executable by the processor. When the processor executes the computer program instructions, it can implement the steps of any of the methods described above.

[0058] The present invention also provides a computer-readable storage medium having stored thereon computer program instructions executable by a processor, wherein when the processor executes the computer program instructions, it can implement the steps of any of the methods described above.

[0059] Compared with the prior art, the present invention has the following beneficial effects:

[0060] (1) This invention constructs a heterogeneous knowledge graph containing evidence metadata and calculates the confidence of relation edges by combining information such as document authority and timestamps, providing a traceable source of knowledge for scientific research paths and effectively alleviating the knowledge illusion problem of large language models.

[0061] (2) This invention achieves complementary advantages by integrating large language models and graph neural networks (GNNs): LLMs enhance text semantic understanding and generalization capabilities, while GNNs provide structural information processing capabilities, thereby enabling accurate capture of deep relationships between entities, in-depth mining of potential entity relationships and research clues across disciplines, and providing researchers with innovative path suggestions that go beyond traditional literature retrieval.

[0062] (3) This invention can be applied to automated document parsing, knowledge graph construction and path generation processes, which greatly reduces the cost of manually sorting through massive amounts of documents; at the same time, the generated structured research path combines natural language instructions and graph structured information, which is more in line with the actual needs of researchers and improves the efficiency of scientific research decision-making. Attached Figure Description

[0063] Figure 1 This is a flowchart illustrating the method implementation of an embodiment of the present invention. Detailed Implementation

[0064] The technical solution of the present invention will now be described in detail with reference to the accompanying drawings.

[0065] It should be noted that the following detailed descriptions are exemplary and intended to provide further explanation of this application. Unless otherwise specified, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains.

[0066] It should be noted that the terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the exemplary embodiments according to this application. As used herein, the singular form is intended to include the plural form as well, unless the context clearly indicates otherwise. Furthermore, it should be understood that when the terms "comprising" and / or "including" are used in this specification, they indicate the presence of features, steps, operations, devices, components, and / or combinations thereof.

[0067] This invention provides a method for generating research paths based on a knowledge graph-enhanced large language model, comprising:

[0068] Based on the analysis of document datasets using large language models, a heterogeneous knowledge graph integrating knowledge triples and evidence metadata is constructed.

[0069] A knowledge embedding matrix is ​​generated by self-supervised training of a heterogeneous knowledge graph using a heterogeneous graph neural network.

[0070] Design a semantic aligner to align the knowledge embedding matrix with the semantic space of a large language model;

[0071] Based on the knowledge embedding matrix, seed nodes are retrieved according to user queries and corresponding context subgraphs are extracted from heterogeneous knowledge graphs. The context subgraphs are converted into graph lexical sequences and combined with natural language instructions to construct a hybrid prompt input large language model, generating the final structured research path.

[0072] The following is a detailed implementation process of the present invention.

[0073] This embodiment provides a method for generating research paths based on a knowledge graph-enhanced large language model, including the following steps:

[0074] Step S1: Based on the large language model, the document dataset is parsed to obtain knowledge triples K and evidence metadata M, and a heterogeneous knowledge graph G with document content as the core is constructed.

[0075] In this embodiment, step S1 specifically includes the following steps:

[0076] Step S11: Using a large language model, the input document dataset is transformed into structured knowledge triples K = {k1, k2, ..., k} through named entity recognition and relation extraction techniques. n} and evidence metadata M = {m1, m2, ..., m n}, k i = <h i ,r i ,t i >, where h i For the head entity extracted from the document text, r i For the relationship between entities, t i The tail entity extracted from the document text, m i = <D i ,L i ,TS i A i >, where D i L serves as a source document identifier. i TS is a location tag within a document. i For document timestamps, A i To ensure the authority of the literature, A i ∈[0,1];

[0077] Step S12: Assign evidence labels to each knowledge triple in the document using the evidence mapping function EVI(x); the evidence mapping function EVI(x) maps knowledge triples k... i Mapped to its corresponding evidence metadata:

[0078] EVI(k i )=m i

[0079] Where, m i For k i Evidence metadata;

[0080] Step S13: Perform entity linking on all head entities h and tail entities t in the knowledge triple set K to generate a normalized entity ID, forming an entity node set V. Aggregate all knowledge triples according to their normalized entity IDs to construct a set R of relational edges connecting node pairs in the entity node set V. During the aggregation process, extract all evidence metadata m corresponding to each relational edge. i The aggregation process is performed, which comprehensively considers the authority of the source documents in the evidence metadata (A). i Document timestamp TS i and the location tag L in the document i A comprehensive confidence score is calculated to generate an edge aggregation weight matrix W that assigns a comprehensive confidence score to each relation edge. After the entity node set V is constructed, the text description corresponding to each node in V is encoded by a pre-trained language model to generate the initial feature matrix X of the node.

[0081] Step S14: Instantiate the heterogeneous knowledge graph G by combining the entity node set V, the relation edge set R, the initial node feature matrix X, and the edge aggregation weight matrix W.

[0082] G = (V, R, X, W).

[0083] Step S2: Use a heterogeneous graph neural network model f GNN By performing self-supervised training on the heterogeneous knowledge graph G, a knowledge embedding matrix Z of the heterogeneous knowledge graph G is generated.

[0084] In this embodiment, step S2 specifically includes the following steps:

[0085] Step S21: Using a predefined composite loss function L total Heterogeneous graph neural network model f for evidence perception GNN Optimize the composite loss function L total Defined as:

[0086] L total =L LinkPred +L Path

[0087] L LinkPred The link prediction loss is used to optimize the local structural representation of node embeddings:

[0088]

[0089] Among them, E + E is the set of positive sample edges sampled from the heterogeneous knowledge graph G. - z is the set of negative sample edges sampled from the composite knowledge graph G. i ,z j Let i and j represent the embedding vectors of nodes i and j respectively, and σ(·) be the Sigmoid function, which maps any real number to the interval (0,1) and is used to represent the probability.

[0090] L Path The path consistency loss is used to optimize the global logical representation of node embeddings.

[0091]

[0092] Where γ is the marginal loss threshold, P + and P - Let P+ and P- be the consistent path set and the inconsistent path set, respectively. P+ is a specific, logically consistent path sample extracted from the consistent path set P+; P- is a specific, logically inconsistent path sample extracted from the inconsistent path set P-. S(·) is the path scoring function.

[0093] The path scoring function S(·) is implemented based on an LSTM model scorer. The LSTM model generates a logical coherence score by processing the embedding vector sequence of nodes in the path.

[0094]

[0095] This represents the input sequence formed by arranging the embedding vectors of all nodes in path p in order; the Sigmoid function is used to map the raw score output by the LSTM model scorer after processing the path sequence to the (0,1) interval, thereby obtaining a standardized score that represents the strength of the logical coherence of the path.

[0096] Consistent path set P + The inconsistent path set P is constructed by extracting citation chains and technology dependency chains from the graph using algorithms and combining them with a large language model to generate diverse samples. - P through the instruction big language model + The path is generated by logically breaking the path, specifically: a consistent path set P. + Its structure is as follows: First, the citation chain path p is extracted from the heterogeneous knowledge graph G using an algorithm. citation Technology dependency path p dependency As high-confidence core samples, the large language model f is used. LLM Generate additional path combinations to increase sample diversity; inconsistent path set P - Its structure is: the set of consistent paths P + As input, the instruction-based large language model f LLM The process involves disrupting the sample, including replacing nodes of the same type and reversing the timing logic, to generate negative samples. The overall process is as follows:

[0097] P + ={p citation ∪p dependency}∪f LLM (Generate|Domain)

[0098] P - =f LLM (Corrupt|P + Domain)

[0099] Among them, f LLM (·) indicates an expression for invoking instructions to the large language model. Generate represents a generation instruction, which instructs the large language model to generate a citation chain path p of the core sample based on its internal knowledge. citation Technology dependency path p dependencyA logically consistent, new research path. `Domain` represents the domain scope specified for the model, such as "biomedicine" or "quantum computing." This parameter constrains the knowledge boundary of the generation operation, ensuring that the newly generated path is highly relevant to the specified research domain. `Corrupt` represents a disruptive instruction, which instructs the large language model to take the consistent path set P+ as input and logically modify it, including but not limited to replacing nodes of the same type and reversing temporal logic to generate negative samples.

[0100] Step S3: By analyzing the knowledge embedding matrix Z and the large model f LMM Semantic alignment training is performed to obtain the semantic aligner f. P ;

[0101] In this embodiment, step S3 specifically includes the following steps:

[0102] Step S31: Randomly sample a series of general subgraphs G from the heterogeneous knowledge graph G. sample As training data, it is input into f GNN In this process, we obtain its node embedding matrix.

[0103] Step S32: Embed the node matrix Perform a linear transformation to generate a graph word sequence X. G Construct a graph word sequence X G A mixed suggestion of a list of disordered text descriptions, and input it into f LMM In order to make it output a value based on X G A speculative, ordered list of textual descriptions, in which

[0104] X G =f P (H sample )=H sample ·W P +b P

[0105] W P b P These are the weight parameters and the bias parameters, respectively.

[0106] Step S33, f LLM The output sorting result is compared with the actual text description order. A scalar loss value is calculated using a cross-entropy loss function, and W is optimized through gradient update via backpropagation. P b P After training, the semantic aligner f is obtained. P .

[0107] Step S4: Based on the user's original request q, perform similarity retrieval from the knowledge embedding matrix Z to obtain relevant seed nodes, and extract the corresponding context subgraph G from the heterogeneous knowledge graph G. sub ;

[0108] In this embodiment, step S4 specifically includes the following steps:

[0109] Step S41: Encode the user request q into a query vector Z q By calculating Z q With the knowledge embedding matrix Z, the embedding vectors of all nodes z i The cosine similarity is used, and the top-K nodes with the highest similarity scores are selected as seed nodes. The similarity calculation formula is as follows:

[0110]

[0111] Step S42: Based on these seed nodes, extract the context subgraph G that is highly relevant to the current query from the heterogeneous knowledge graph G. sub .

[0112] Step S5: Transfer the context subgraph G sub Input to heterogeneous graph neural network model f GNN and semantic aligner f P To generate a graph word sequence X G ;

[0113] In this embodiment, step S5 specifically includes the following steps:

[0114] Step S51: Transfer the context subgraph G sub Enter to f GNN To generate its corresponding node embedding matrix H sub ;

[0115] Step S52: Embed the nodes into matrix H sub Input to semantic aligner f P To generate a graph word sequence X G .

[0116] Step S6: Construct a graph containing natural language instructions and a sequence of generated graph lexical units X. G The mixed prompts are then fed into the large language model f. LMM This is to generate the final structured research path.

[0117] In this embodiment, step S6 specifically includes the following steps:

[0118] Step S61: Combine the user's original request q (natural language instruction) with the graph lexical sequence X. GConcatenate the components to create a mixed prompt:

[0119] Step S62: Enter the mixed prompt into f LLM It reasons and outputs the final structured research path text.

[0120] The present invention also provides a research path generation system based on a knowledge graph-enhanced large language model, including a memory, a processor, and computer program instructions stored in the memory and executable by the processor. When the processor executes the computer program instructions, it can implement the steps of any of the methods described above.

[0121] The present invention also provides a computer-readable storage medium having stored thereon computer program instructions executable by a processor, wherein when the processor executes the computer program instructions, it can implement the steps of any of the methods described above.

[0122] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0123] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. 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... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0124] 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.

[0125] 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.

[0126] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention in any other way. Any person skilled in the art may make changes or modifications to the above-disclosed technical content to create equivalent embodiments. However, any simple modifications, equivalent changes, and modifications made to the above embodiments based on the technical essence of the present invention without departing from the scope of the present invention shall still fall within the protection scope of the present invention.

Claims

1. A method for generating research paths based on a knowledge graph-enhanced large language model, characterized in that, include: Based on the analysis of document datasets using large language models, a heterogeneous knowledge graph integrating knowledge triples and evidence metadata is constructed. A knowledge embedding matrix is ​​generated by self-supervised training of a heterogeneous knowledge graph using a heterogeneous graph neural network. Design a semantic aligner to align the knowledge embedding matrix with the semantic space of a large language model; Based on the knowledge embedding matrix, seed nodes are retrieved according to user queries and corresponding context subgraphs are extracted from heterogeneous knowledge graphs. The context subgraphs are converted into graph lexical sequences and combined with natural language instructions to construct a hybrid prompt input large language model, generating the final structured research path.

2. The research path generation method based on a knowledge graph-enhanced large language model according to claim 1, characterized in that, The method includes the following steps: Step S1: Based on the large language model, the document dataset is parsed to obtain knowledge triples K and evidence metadata M, and a heterogeneous knowledge graph G with document content as the core is constructed. Step S2: Use a heterogeneous graph neural network model f GNN By performing self-supervised training on the heterogeneous knowledge graph G, a knowledge embedding matrix Z of the heterogeneous knowledge graph G is generated. Step S3: By analyzing the knowledge embedding matrix Z and the large model f LMM Semantic alignment training is performed to obtain the semantic aligner f. P ; Step S4: Based on the user's original request q, perform similarity retrieval from the knowledge embedding matrix Z to obtain relevant seed nodes, and extract the corresponding context subgraph G from the heterogeneous knowledge graph G. sub ; Step S5: Transfer the context subgraph G sub Input to heterogeneous graph neural network model f GNN and semantic aligner f P To generate a graph word sequence X G ; Step S6: Construct a graph containing natural language instructions and a sequence of generated graph lexical units X. G The mixed prompts are then fed into the large language model f. LMM This is to generate the final structured research path.

3. The research path generation method based on a knowledge graph-enhanced large language model according to claim 2, characterized in that, Step S1 specifically includes the following steps: Step S11: Using a large language model, the input document dataset is transformed into structured knowledge triples K = {k1, k2, ..., k} through named entity recognition and relation extraction techniques. n } and evidence metadata M = {m1, m2, ..., m n }, k i = <h i ,r i ,t i >, where h i For the head entity extracted from the document text, r i For the relationship between entities, t i The tail entity extracted from the document text, m i = <D i ,L i ,TS i A i >, where D i L serves as a source document identifier. i TS is a location tag within a document. i For document timestamps, A i To ensure the authority of the literature, A i ∈[0,1]; Step S12: Assign evidence labels to each knowledge triple in the document using the evidence mapping function EVI(x); the evidence mapping function EVI(x) maps knowledge triples k... i Mapped to its corresponding evidence metadata: EVI(k i )=m i Where, m i For k i Evidence metadata; Step S13: Perform entity linking on all head entities h and tail entities t in the knowledge triple set K to generate a normalized entity ID, forming an entity node set V. Aggregate all knowledge triples according to their normalized entity IDs to construct a set R of relational edges connecting node pairs in the entity node set V. During the aggregation process, extract all evidence metadata m corresponding to each relational edge. i The aggregation process is performed, which comprehensively considers the authority of the source documents in the evidence metadata (A). i Document timestamp TS i and the location tag L in the document i A comprehensive confidence score is calculated to generate an edge aggregation weight matrix W that assigns a comprehensive confidence score to each relation edge. After the entity node set V is constructed, the text description corresponding to each node in V is encoded by a pre-trained language model to generate the initial feature matrix X of the node. Step S14: Instantiate the heterogeneous knowledge graph G by combining the entity node set V, the relation edge set R, the initial node feature matrix X, and the edge aggregation weight matrix W. G = (V, R, X, W).

4. The research path generation method based on a knowledge graph-enhanced large language model according to claim 2, characterized in that, Step S2 specifically includes the following steps: Step S21: Using a predefined composite loss function L total Heterogeneous graph neural network model f for evidence perception GNN Optimize the composite loss function L total Defined as: L total L LinkPred +L Path L LinkPred The link prediction loss is used to optimize the local structural representation of node embeddings: Among them, E + E is the set of positive sample edges sampled from the heterogeneous knowledge graph G. - z is the set of negative sample edges sampled from the composite knowledge graph G. i ,z j Let i and j represent the embedding vectors of nodes i and j respectively, and σ(·) be the Sigmoid function, which maps any real number to the interval (0,1) and is used to represent the probability. L Path The path consistency loss is used to optimize the global logical representation of node embeddings. Where γ is the marginal loss threshold, P + and P - Let P+ and P- be the consistent path set and the inconsistent path set, respectively. p+ is a specific, logically consistent path sample extracted from the consistent path set P+; p- is a specific, logically inconsistent path sample extracted from the inconsistent path set P-; and S(·) is the path scoring function. The path scoring function S(·) is implemented based on an LSTM model scorer. The LSTM model generates a logical coherence score by processing the embedding vector sequence of nodes in the path. S(·)=Sigmoid(LSTM([z v1 ,z v2 ,…,z vn ])) [z v1 ,z v2 ,…,z vn ]: This represents the input sequence formed by arranging the embedding vectors of all nodes in path p in order; the Sigmoid function is used to map the raw score output by the LSTM model scorer after processing the path sequence to the (0,1) interval to obtain a standardized score that represents the strength of the logical coherence of the path. Consistent path set P + Its structure is as follows: First, the citation chain path p is extracted from the heterogeneous knowledge graph G using an algorithm. citation Technology dependency path p dependency As high-confidence core samples, the large language model f is used. LLM Generate additional path combinations to increase sample diversity; inconsistent path set P - Its structure is: the set of consistent paths P + As input, the instruction-based large language model f LLM The process involves disrupting the sample, including replacing nodes of the same type and reversing the timing logic, to generate negative samples. The overall process is as follows: P + ={p citation ∪p dependency }∪f LLM (Generate|Domain) P - =f LLM (Corrupt|P + ,Domain) Generate represents a generation instruction that directs the large language model to generate a citation chain path p of the core samples based on its internal knowledge. citation Technology dependency path p dependency A logically consistent, new research path; Domain represents the domain scope specified for the model. This parameter is used to constrain the knowledge boundary of the generation operation to ensure that the newly generated path is highly relevant to the specified research domain; Corrupt represents a disruptive instruction, which instructs the large language model to take the consistent path set P+ as input and logically modify it, including replacing nodes of the same type and reversing the temporal logic to generate negative samples.

5. The research path generation method based on a knowledge graph-enhanced large language model according to claim 2, characterized in that, Step S3 specifically includes the following steps: Step S31: Randomly sample a series of general subgraphs G from the heterogeneous knowledge graph G. sample As training data, it is input into f GNN In this process, we obtain its node embedding matrix H. Gsample ; Step S32: For the node embedding matrix H... Gsample Perform a linear transformation to generate a graph word sequence X. G Construct a graph word sequence X G A mixed suggestion of a list of disordered text descriptions, and input it into f LMM In order to make it output a value based on X G A speculative, ordered list of textual descriptions, in which X G =f P (H sample )=H sample ·W P +b P W P b P These are the weight parameters and the bias parameters, respectively; Step S33, f LLM The output sorting result is compared with the actual text description order. A scalar loss value is calculated using a cross-entropy loss function, and W is optimized through gradient update via backpropagation. P b P After training, the semantic aligner f is obtained. P .

6. The research path generation method based on a knowledge graph-enhanced large language model according to claim 2, characterized in that, Step S4 specifically includes the following steps: Step S41: Encode the user request q into a query vector Z q By calculating Z q With the knowledge embedding matrix Z, the embedding vectors of all nodes z i The cosine similarity is used, and the top-K nodes with the highest similarity scores are selected as seed nodes. The similarity calculation formula is as follows: Step S42: Based on these seed nodes, extract the context subgraph G that is highly relevant to the current query from the heterogeneous knowledge graph G. sub .

7. The research path generation method based on a knowledge graph-enhanced large language model according to claim 2, characterized in that, Step S5 specifically includes the following steps: Step S51: Transfer the context subgraph G sub Enter to f GNN To generate its corresponding node embedding matrix H sub ; Step S52: Embed the nodes into matrix H sub Input to semantic aligner f P To generate a graph word sequence X G .

8. The research path generation method based on a knowledge graph-enhanced large language model according to claim 2, characterized in that, Step S6 specifically includes the following steps: Step S61: Combine the natural language instruction of the user's original request q with the graph lexical sequence X. G Concatenate the components to create a mixed prompt: Step S62: Enter the mixed prompt into f LLM It reasons and outputs the final structured research path text.

9. A research path generation system based on a knowledge graph-enhanced large language model, characterized in that, It includes a memory, a processor, and computer program instructions stored in the memory and executable by the processor, which, when executed by the processor, enable the implementation of the steps of the method as described in any one of claims 1-8.

10. A computer-readable storage medium having stored thereon computer program instructions executable by a processor, wherein when the processor executes the computer program instructions, it is able to implement the steps of the method as described in any one of claims 1-8.

Citation Information

Cited By

  • Biomedical knowledge discovery method and system

    CN121393570A

  • Scientific and technological expert multi-dimensional weight analysis method and system based on large model

    CN121413959A

  • Experimental scheme automatic generation system based on knowledge graph and large language model

    CN121638472A