Knowledge graph question and answer reasoning method and system based on self-adaptive double-feature fusion
By using an adaptive dual-mode feature fusion module and multi-scale feature processing, the problems of low accuracy and slow response to simple questions in knowledge graph question answering systems under complex multi-hop reasoning scenarios are solved, achieving efficient feature fusion and fast response.
Patent Information
- Application Number
- CN202511753028.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-26
- Publication Date
- 2026-04-24
AI Technical Summary
Existing knowledge graph question answering methods have low accuracy in complex multi-hop reasoning scenarios and are difficult to effectively integrate information from multiple entities, resulting in incomplete or incorrect reasoning results. At the same time, they are slow to respond to simple questions and have unreasonable allocation of computing resources.
An adaptive dual-mode feature fusion module is introduced, which dynamically adjusts the computation strategy through lightweight and standard modes, and improves the flexibility and efficiency of feature fusion by combining multi-scale feature processing and cross-instruction interactive attention mechanism.
It improves the accuracy of knowledge graph question answering systems in complex reasoning scenarios and accelerates response speed in simple questions, achieving efficient utilization of computing resources and full mining of feature interactions.
Smart Images

Figure CN121920512A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of knowledge graph reasoning technology, and in particular to a knowledge graph question-answering reasoning method and system based on adaptive dual-feature fusion. Background Technology
[0002] Knowledge graphs, as a crucial infrastructure in the field of artificial intelligence, play a key role in applications such as intelligent question answering, recommendation systems, and decision support. Knowledge graph question answering tasks aim to find the correct answer entity within a knowledge graph through reasoning based on a user's natural language question. This process typically involves identifying the topic entity from the question, then performing multi-hop reasoning within the knowledge graph, ultimately arriving at the answer entity along the correct relational path.
[0003] Traditional knowledge graph question answering methods mainly fall into two categories. The first category is based on semantic parsing. These methods convert natural language questions into structured query statements, such as SPARQL or logical expressions, and then execute the query on the knowledge graph. The advantage of this type of method is its strong interpretability, but its disadvantages include a high dependence on semantic parsers and difficulty in handling complex natural language expressions and the incompleteness of the knowledge graph. The second category is based on information retrieval. These methods treat the question answering task as a ranking problem within a set of candidate answers, selecting the best answer by calculating the similarity between the question and the candidate answer paths. This type of method offers greater flexibility, but its performance is limited in multi-hop reasoning scenarios.
[0004] However, with the development of deep learning technology, Graph Neural Networks (GNNs) have provided a powerful technical foundation for knowledge graph reasoning. Graph Convolutional Networks (GCNs) laid the foundation for GNNs to learn representations on graph-structured data. This method defines convolution operations on the graph, enabling nodes to aggregate information from their neighbors, thereby learning richer node representations and providing important technical support for subsequent knowledge graph reasoning methods. Graph Attention Networks (GATs) further introduce an attention mechanism, allowing nodes to adaptively assign different weights to different neighbors, performing weighted aggregation based on the importance of neighboring nodes, significantly improving the expressive power and flexibility of GNNs.
[0005] Based on the theoretical foundation of these graph neural networks, knowledge graph reasoning methods based on graph neural networks have gradually become mainstream. Representative methods include GraftNet, NSM, and ReaRev. For example, ReaRev is relatively simple, and it only performs linear combination of the node representations generated by K instructions. It cannot fully capture the complex interaction relationships and complementary information between different reasoning instructions, which limits the performance of the model in complex multi-hop reasoning scenarios. Summary of the Invention
[0006] To address the aforementioned technical problems, the present invention aims to provide a knowledge graph question-answering reasoning method and system based on adaptive dual-feature fusion, which can improve the accuracy of knowledge graph question-answering systems in complex reasoning scenarios and the response speed for simple questions.
[0007] The first technical solution adopted in this invention is: a knowledge graph question-answering reasoning method based on adaptive dual-feature fusion, comprising the following steps: Collect users' natural language questions; An adaptive dual-mode feature fusion module is introduced to construct a knowledge graph reasoning question answering model; Based on a knowledge graph-based reasoning question-answering model, the system reasons about the user's natural language questions and generates the answer and reasoning path.
[0008] Furthermore, the knowledge graph reasoning question-answering model specifically includes an input layer, a question encoding layer, a subgraph extraction layer, a reasoning instruction generation layer, a multi-round iterative reasoning layer, and an output layer. The input layer, the question encoding layer, the subgraph extraction layer, the reasoning instruction generation layer, the multi-round iterative reasoning layer, and the output layer are connected sequentially, wherein: The multi-round iterative inference layer integrates an adaptive dual-mode feature fusion module, which includes a lightweight mode and a standard mode.
[0009] Furthermore, the step of reasoning about the user's natural language question based on the knowledge graph reasoning question-answering model and generating the user's question answer and reasoning path specifically includes: Input the user's natural language question into the knowledge graph-based reasoning and question-answering model; The input layer of the knowledge graph-based reasoning question-answering model receives users' natural language questions. Based on the knowledge graph reasoning question answering model, the question encoding layer uses a pre-trained RelBERT model to vectorize the user's natural language questions, resulting in a high-dimensional question vector representation. The subgraph extraction layer based on the knowledge graph reasoning question answering model performs entity link recognition on the high-dimensional question vector representation, obtains the question subject and performs knowledge graph matching, and outputs candidate answer entities and their associations. The reasoning instruction generation layer based on the knowledge graph reasoning question answering model generates several reasoning instructions based on the high-dimensional question vector representation. Based on a knowledge graph reasoning question answering model, a multi-round iterative reasoning layer performs iterative enhanced feature fusion reasoning on candidate answer entities, relationships, and several reasoning instructions to generate user question answers and reasoning paths. The output layer of the knowledge graph-based reasoning question-answering model outputs the user's question answer and reasoning path.
[0010] Furthermore, the multi-round iterative reasoning layer based on the knowledge graph reasoning question-answering model, which iteratively enhances feature fusion reasoning on candidate answer entities and their relationships, as well as several reasoning instructions, to generate the user's question answer and reasoning path, specifically includes: The multi-round iterative reasoning layer based on the knowledge graph reasoning question answering model receives several reasoning instructions and performs message propagation operations of graph neural networks on candidate answer entities and related relationships, and calculates the interaction between relation features and query instruction features; Based on the interactive calculation process of relation features and query instruction features, the adaptive dual-mode feature fusion module is called to perform enhanced fusion processing to obtain enhanced fusion inference instruction features. The enhanced fusion inference instruction features are aggregated and updated with messages to obtain several sets of node representations. Several sets of node representations are aggregated and merged, and their matching degree is calculated with the high-dimensional question vector representation to obtain the probability distribution of each entity as the answer; The system updates several inference instructions based on the probability distribution of each entity as an answer, and performs cyclic feature interaction calculations based on the updated inference instructions until the preset number of iterations is met, outputting the user's question answer and inference path.
[0011] Furthermore, the interactive calculation process based on relation features and query instruction features, which calls the adaptive dual-mode feature fusion module for enhanced fusion processing to obtain enhanced fused inference instruction features, specifically includes the following steps: The interactive calculation process based on relation features and query command features calls the adaptive dual-mode feature fusion module, selects the processing mode according to the configuration parameters for enhanced fusion processing, and the processing mode includes lightweight mode and standard mode. Based on a lightweight model, relation features and query command features are divided into fixed groups, and a simplified attention mechanism and fixed gating coefficients are used for fusion. Based on the standard model, relation features and query instruction features are divided into preset groups. Cross-group context is extracted through a global encoder, cross-dimensional interactive attention is calculated, and a learning gating network is used to dynamically adjust the fusion weights. Based on the fusion inference instructions in lightweight mode or standard mode, the enhanced fusion inference instruction features are output.
[0012] Furthermore, the lightweight mode specifically includes: The relation features and query command features are divided into subspaces with fixed values, and the features in each subspace are averaged and pooled to obtain a group-level representative vector. The attention weights of the group-level representative vectors are calculated by element-wise multiplication to obtain the attention weight values of the inference instructions. The attention weight values of the inference instructions are broadcast back to the original dimension to obtain an enhanced representation, and then gating fusion is performed using fixed coefficients to obtain a fusion result of several inference instruction features. The fusion results of several inference instruction features are weighted and normalized to obtain fused inference instructions in lightweight mode.
[0013] Furthermore, the standard mode specifically includes: The relation features and query instruction features are divided into subspaces with preset values to obtain the grouped inference instruction features; Global context information is injected into the grouped inference instruction features to enhance semantic expression, resulting in local features after global context injection. The local features after injecting global context are reduced in dimensionality by a learnable matrix to obtain the dimensionality-reduced local features. Based on the local features after dimensionality reduction, intra-group attention and inter-instruction attention are calculated separately to obtain the intra-group attention value and inter-group attention value of the inference instruction. The fusion ratio is dynamically generated through a learning-based gating network; Based on the fusion ratio, the intra-group attention value and inter-group attention value of the inference instruction are weighted and fused to obtain the fused inference instruction in the standard mode.
[0014] The second technical solution adopted in this invention is: a knowledge graph question-answering reasoning system based on adaptive dual-feature fusion, comprising: The first module is used to collect users' natural language questions; The second module is used to introduce an adaptive dual-mode feature fusion module to build a knowledge graph reasoning question answering model. The third module is used to reason about the user's natural language questions based on the knowledge graph reasoning question answering model, and generate the user's question answer and reasoning path.
[0015] The beneficial effects of the method and system of this invention are as follows: This invention collects users' natural language questions, further introduces an adaptive dual-mode feature fusion module, constructs a knowledge graph reasoning question-answering model, and designs an adaptive dual-mode feature fusion mechanism, enabling the system to dynamically adjust the calculation strategy according to the complexity of the input features. For simple questions, a lightweight fast processing mode is adopted, while for complex questions, a standard deep processing mode is adopted. This ensures the reasoning quality of complex questions while improving the response speed of simple questions. Finally, based on the knowledge graph reasoning question-answering model, the system reasons about users' natural language questions, generates the user's question answer and reasoning path, and improves the accuracy of the knowledge graph question-answering system in complex reasoning scenarios and the response speed of simple questions. Attached Figure Description
[0016] Figure 1 This is a flowchart illustrating the steps of the knowledge graph question-answering reasoning method based on adaptive dual-feature fusion of the present invention. Figure 2 This is a structural block diagram of the knowledge graph question answering reasoning system based on adaptive dual-feature fusion of the present invention; Figure 3 This is a schematic diagram of a knowledge graph reasoning system architecture based on adaptive dual-mode feature fusion provided in a specific embodiment of the present invention; Figure 4 This is a schematic diagram of an example of elderly frailty care questions and answers based on a medical knowledge graph, provided in a specific embodiment of the present invention. Detailed Implementation
[0017] The present invention will now be described in further detail with reference to the accompanying drawings and specific embodiments. The step numbers in the following embodiments are only for ease of explanation and do not limit the order of the steps. The execution order of each step in the embodiments can be adapted according to the understanding of those skilled in the art.
[0018] First, it's important to note that with the development of deep learning technology, graph neural networks (GNNs) have provided a powerful technical foundation for knowledge graph reasoning. Graph Convolutional Networks (GCNs) laid the groundwork for GNNs to learn representations on graph-structured data. This method defines convolution operations on the graph, enabling nodes to aggregate information from their neighbors, thereby learning richer node representations and providing crucial technical support for subsequent knowledge graph reasoning methods. Graph Attention Networks (GATs) further introduce an attention mechanism, allowing nodes to adaptively assign different weights to different neighbors, performing weighted aggregation based on the importance of neighboring nodes, significantly improving the expressive power and flexibility of graph neural networks.
[0019] Based on the theoretical foundations of these graph neural networks, knowledge graph reasoning methods based on graph neural networks have gradually become mainstream. These methods represent knowledge graphs as graph-structured data, utilizing graph neural networks for message propagation and feature aggregation on the graph to learn representations of entities and relationships, and finding the answer through multiple rounds of iterative reasoning. Representative methods include GraftNet, NSM, and ReaRev. Early methods like GraftNet used graph convolutional networks to encode subgraphs related to the question, aggregating neighbor node information through multi-layer graph convolutional operations, and finally calculating the answer distribution across all candidate entities. The NSM method introduced the concept of a neural symbolic machine, modeling the reasoning process as program execution on the knowledge graph, navigating from the topic entity to the answer entity step-by-step by learning the sequence of reasoning operations. The ReaRev method introduced a more refined multi-reasoning instruction mechanism and a dynamic instruction update strategy, achieving significant performance improvements and becoming an important benchmark in this field. The core advantage of ReaRev lies in exploring multiple reasoning directions simultaneously through a multi-reasoning instruction mechanism, avoiding error propagation along a single path. However, its feature fusion method is relatively simple, and it only performs linear combination of the node representations generated by K instructions, which cannot fully capture the complex interaction relationships and complementary information between different inference instructions. This limits the performance of the model in complex multi-hop inference scenarios.
[0020] While existing state-of-the-art methods like ReaRev have achieved good performance on knowledge graph question answering tasks, key technical bottlenecks still exist in practical applications, limiting their performance in complex reasoning scenarios. In multi-hop complex reasoning scenarios, the model's accuracy decreases significantly with increasing reasoning depth. For example, in medical knowledge graphs, in three-hop reasoning tasks—from patient symptom reasoning to diagnostic assessment to treatment plan—the accuracy of existing methods is often lower than that of single-hop or two-hop reasoning. More importantly, in scenarios with multiple concurrent entities, when the question involves multiple diseases or symptoms simultaneously, the model struggles to effectively integrate information from multiple entities, leading to incomplete or erroneous reasoning results. The root cause of this problem lies in the overly simplistic and fixed feature fusion mechanism of ReaRev, which fails to fully capture the complex interactions between different reasoning instructions.
[0021] Through in-depth analysis of existing technologies, including ReaRev, we have identified a core flaw in knowledge graph reasoning methods based on graph neural networks. This flaw severely restricts the performance of knowledge graph question-answering systems in practical applications. The main core flaw is the fixed and singular nature of the attention fusion mechanism. Existing methods use the same attention calculation method and feature fusion strategy for all questions, regardless of their complexity. When handling feature fusion for multiple reasoning instructions, ReaRev typically employs simple feature concatenation or weighted averaging, without dynamically adjusting the calculation strategy based on the complexity of the question and the current reasoning state. This one-size-fits-all approach leads to three serious problems: 1) Insufficient Feature Interaction. Simple linear transformations and weighted averaging operations cannot fully capture the complex interactions and complementary information between different inference instructions. For complex problems involving multiple entities and relationships, the node representations generated by different inference instructions contain rich semantic complementarity, but existing methods cannot effectively mine and utilize this complementarity. For example, in a medical knowledge graph, one inference instruction focuses on disease features, another on treatment methods, and a third on assessment tools. There are complex semantic relationships between these three, and simple linear fusion cannot capture these relationships, resulting in insufficient information utilization and limited inference accuracy.
[0022] 2) Inefficient allocation of computational resources. For simple single-hop or two-hop problems, even complex feature fusion calculations fail to deliver significant performance improvements, instead incurring unnecessary computational overhead and slowing down the system's response time. Conversely, for complex multi-hop inference problems, simple fusion strategies cannot provide sufficient representational power. The lack of an adaptive resource allocation mechanism prevents the system from flexibly adjusting computational intensity according to the actual needs of the problem, resulting in a dilemma where simple problems are slow to respond and complex problems are ineffective.
[0023] 3) Lack of multi-scale feature processing capabilities. Different inference instructions and problems of varying complexity require feature representations of different granularities. Simple problems may only require coarse-grained overall semantic features, while complex problems require fine-grained local semantics and the coordinated processing of global context. Existing methods employ a single-scale feature processing approach, which cannot adapt to the differentiated requirements of feature granularity for different problems, thus limiting the model's performance in different scenarios.
[0024] These technical shortcomings are particularly evident in real-world applications. Take a medical knowledge graph question-answering system as an example. When a doctor asks a question involving multi-hop reasoning, such as "What assessment tools are included in the nutritional management plan for elderly diabetic patients?", the system needs to integrate information from multiple reasoning instructions. Due to the fixed nature of the attention fusion mechanism, when dealing with complex questions involving multiple diseases and symptoms, the model cannot fully utilize the complementary information between different reasoning instructions, leading to incomplete or incorrect answers. Meanwhile, for simple questions like "What is the purpose of the MNA scale?", the system spends the same amount of computation time as for complex questions, resulting in slow response times and a poor user experience.
[0025] Based on this, this invention provides a knowledge graph question answering reasoning method based on adaptive dual-mode feature fusion. While retaining the advantages of the ReaRev multi-turn reasoning framework, this method introduces the core innovation of an adaptive dual-mode feature fusion module. Without significantly increasing the number of model parameters and computational overhead, it can significantly improve the accuracy of the knowledge graph question answering system in complex reasoning scenarios and the response speed of simple questions through an adaptive multi-scale feature fusion strategy.
[0026] Specifically, this invention first designs an adaptive dual-mode feature fusion mechanism, enabling the system to dynamically adjust its computational strategy based on the complexity of the input features. A lightweight, fast processing mode is used for simple problems, while a standard deep processing mode is employed for complex problems, thus improving the response speed for simple problems while ensuring the reasoning quality for complex problems. Secondly, by introducing multi-scale feature processing and a cross-instruction interactive attention mechanism, the complementary information between different reasoning instructions is fully exploited, improving the accuracy of multi-hop reasoning, especially in complex reasoning scenarios with three or more hops.
[0027] Reference Figure 1 This invention provides a knowledge graph question-answering reasoning method based on adaptive dual-feature fusion, which includes the following steps: S100, Collect users' natural language questions; S200 introduces an adaptive dual-mode feature fusion module to construct a knowledge graph reasoning question answering model; In this embodiment, the knowledge graph reasoning question answering model specifically includes an input layer, a question encoding layer, a subgraph extraction layer, a reasoning instruction generation layer, a multi-round iterative reasoning layer, and an output layer. The input layer, the question encoding layer, the subgraph extraction layer, the reasoning instruction generation layer, the multi-round iterative reasoning layer, and the output layer are connected sequentially. The multi-round iterative reasoning layer integrates an adaptive dual-mode feature fusion module, which includes a lightweight mode and a standard mode.
[0028] S300, based on a knowledge graph reasoning question-answering model, reasons about the user's natural language questions and generates the user's question answers and reasoning paths.
[0029] S310. Input the user's natural language question into the knowledge graph-based reasoning question-answering model; S320, the input layer based on the knowledge graph reasoning question answering model, receives the user's natural language questions; S330, Question encoding layer based on knowledge graph reasoning question answering model, uses a pre-trained RelBERT model to vectorize the user's natural language questions to obtain a high-dimensional question vector representation; S340, Subgraph extraction layer based on knowledge graph reasoning question answering model, performs entity link recognition on high-dimensional question vector representation, obtains question subject and performs knowledge graph matching, outputs candidate answer entities and association relationships; S350, a reasoning instruction generation layer based on a knowledge graph reasoning question answering model, which generates several reasoning instructions based on a high-dimensional question vector representation; S360, a multi-round iterative reasoning layer based on a knowledge graph reasoning question answering model, performs iterative enhanced feature fusion reasoning on candidate answer entities and their relationships, as well as several reasoning instructions, to generate the user's question answer and reasoning path; Specifically, the multi-round iterative reasoning layer based on the knowledge graph reasoning question answering model receives several reasoning instructions and performs message propagation operations of the graph neural network on candidate answer entities and their relationships, calculating the interaction between relationship features and query instruction features. Based on the interaction calculation process of relationship features and query instruction features, an adaptive dual-mode feature fusion module is called for enhanced fusion processing to obtain enhanced fused reasoning instruction features. Message aggregation and node updates are performed on the enhanced fused reasoning instruction features to obtain several sets of node representations. The several sets of node representations are summarized and fused, and the matching degree is calculated with the high-dimensional question vector representation to obtain the probability distribution of each entity as an answer. Based on the probability distribution of each entity as an answer, several reasoning instructions are updated, and cyclic feature interaction calculations are performed based on the updated reasoning instructions until the preset number of iterations is met, outputting the user's question answer and reasoning path.
[0030] In this embodiment, the adaptive dual-mode feature fusion module is designed to address the problem of a fixed and singular feature fusion mechanism in existing ReaRev methods, achieving efficient utilization of computational resources and full exploitation of feature interactions. This module borrows the grouping processing idea of Efficient Multi-scale Attention, but has made significant improvements and optimizations specifically for the characteristics of multi-instruction reasoning tasks in knowledge graphs. It adopts a dual-mode architecture design, flexibly selecting between lightweight or standard processing modes through configuration parameters, achieving an optimal balance between efficiency and accuracy.
[0031] This module is integrated into the message propagation process of the graph neural network to enhance the interaction between relation features and query features. When the system performs multi-round inference, the K inference instructions generate node representations after message propagation through the graph neural network. , Each The dimensions are B×N×D (B is the batch size, N is the number of nodes, and D is the feature dimension). This module deeply fuses these features through multi-scale grouping and attention mechanisms to generate enhanced interactive features for subsequent message aggregation and node updates.
[0032] For lightweight mode: The lightweight mode follows the design principle of "minimum computation, maximum retention" and is designed specifically for fast inference scenarios. This mode first divides the D-dimensional feature space into a fixed G subspaces (G=4), and performs mean pooling on the features in each subspace to obtain group-level representative vectors, compressing the original D-dimensional features into G-dimensional group-level representations, reducing the computational complexity from O(D) to O(G).
[0033] The attention weights are then calculated using element-wise multiplication, with the following formula: ; in Indicates the first The instruction in the Group attention weights Indicates the first The instruction in the The characteristic mean of the group The problem vector is represented at the th... The characteristic mean of the group This represents element-wise multiplication.
[0034] Next, the attention weights are broadcast back to the original dimension to obtain the enhanced representation, and gating fusion is performed using fixed coefficients. The fusion formula is as follows: ; in This indicates the fusion output of the lightweight mode. This represents the feature representation after attention enhancement. The gating coefficient is fixed.
[0035] Finally, the final output is obtained through weighted fusion, and the calculation formula is as follows: ; in This represents the module's final output. Indicates the first The fusion weights of the instructions are obtained by softmax normalization. This represents the total number of inference instructions. The computational complexity of the entire lightweight mode is O(n). This can reduce the amount of computation by approximately 75%.
[0036] For standard mode: The standard pattern achieves deep semantic modeling through adaptive grouping, global context injection, dimensionality reduction, cross-dimensional interactive attention, and learning-based gating, making it suitable for complex reasoning scenarios. The number of groups in this pattern... Based on the number of instructions and feature dimensions Adaptive determination ensures full feature interaction capabilities.
[0037] After grouping, the system injects global context information to enhance semantic expression; the calculation formula is as follows: ; in This represents local features after injection into the global context. Indicates the characteristics after grouping. This represents the global mean of the grouped features.
[0038] Then, dimensionality reduction is performed using a learnable matrix, and the reduced feature representation is calculated using the following formula: ; in This represents the feature representation after dimensionality reduction. Let represent the learnable dimensionality reduction matrix. Based on the dimensionality reduction features, the system calculates intra-group attention and inter-instruction attention separately, using the following formulas: ; in Indicates the first Intra-group attention to instructions Indicates the first Instruction No. Attention between instructions This represents the feature dimension after dimensionality reduction.
[0039] Finally, the overall attention is obtained through weighted fusion, and the calculation formula is as follows: ; in Indicates the first Comprehensive attention to each instruction This is the balancing coefficient. In the feature fusion stage, the standard model uses a learning-based gating network to dynamically determine the fusion ratio. The gating calculation formula is: ; in Indicates the first Gating weight of each instruction and Let represent the weight matrix and bias vector of the gating network, respectively. Feature fusion is performed based on the gating weights, and the fusion formula is as follows: ; in This represents the fused output of the standard mode. The module output is obtained through group normalization, calculated using the following formula: ; in This represents the module's final output. Indicates the first The fusion weight of the instructions, GroupNorm represents the group normalization operation.
[0040] To ensure stable operation of the module under various feature dimension configurations, this invention designs an intelligent adaptive parameter management mechanism. When the feature dimension D is not divisible by the number of groups G, the system automatically selects from... The closest value that divides D is selected as the actual number of groups. When the dimensionality is reduced... When the value is less than 1, the system automatically adjusts the dimensionality reduction ratio r to ensure... This ensures the effectiveness of attention calculation. This adaptive mechanism allows the module to adapt to different network architectures and parameter configurations, improving the versatility and robustness of the technical solution.
[0041] After multi-layer GNN processing and multi-instruction fusion, the system obtains the final node representation. , and the problem vector The score for the answer is calculated using the following formula: ; in Indicates the first Each entity is used as a score for the answer. Represents the scoring function. Indicates the first The final representation of an entity, Represents the problem vector. This represents the probability distribution of the answer. The resulting probability distribution... It is not only used to predict answers, but also drives the update of the next round of reasoning instructions, forming a complete reasoning loop and realizing end-to-end optimization from feature fusion to reasoning decision.
[0042] S370, the output layer based on the knowledge graph reasoning question answering model, outputs the user's question answer and reasoning path.
[0043] In this embodiment, firstly, the system receives a user's natural language question and encodes it using a pre-trained RelBERT model to obtain a vector representation of the question. Simultaneously, the system identifies the topic entities mentioned in the question using named entity recognition technology and locates these entities in the knowledge graph. Then, the system extracts data from the knowledge graph centered on these topic entities. The subgraph within the jump range contains entities and relationships relevant to the problem. The value of is typically between 2 and 3. Next, the system generates an initial set of inference instructions (usually 3 instructions) based on the question vector, with each instruction corresponding to a specific relation type or semantic direction.
[0044] Upon entering the first round of inference, for each inference instruction, the system independently executes the message propagation operation of the graph neural network on the subgraph. The message propagation process employs a graph attention network or a graph convolutional network, typically containing three layers. During message propagation at each layer, when calculating the interaction between relation features and query instruction features, the system invokes an adaptive dual-mode feature fusion module for enhancement processing. This module selects a processing mode based on configuration parameters: the lightweight mode divides features into four fixed groups, using a simplified attention mechanism and fixed gating coefficients for fusion, reducing computation by approximately 75%; the standard mode employs more refined grouping (4 to 16 groups), extracts cross-group context through a global encoder, performs cross-dimensional interactive attention calculation, and uses a learning-based gating network to dynamically adjust the fusion weights, fully leveraging the complementary information between features. The enhanced features are used for subsequent message aggregation and node updates. After three layers of message propagation, each inference instruction generates a set of node representations.
[0045] The system aggregates and merges the node representations generated by multiple inference commands, calculates the matching degree with the question vector, and obtains the probability distribution of each entity as an answer. Based on the current answer distribution, the system updates the inference commands, adjusts the focus of the commands, and then proceeds to the next round of inference.
[0046] In the second round of inference, the system uses updated inference instructions to execute message propagation in the graph neural network again, leveraging an adaptive bimodal feature fusion module for feature enhancement at each layer. Since the inference instructions have been adjusted based on the results of the first round, the message propagation in the second round is more focused on possible answer paths. The system recalculates the answer probability distribution. Depending on the preset number of inference rounds (usually 2-3 rounds), the system continues with subsequent inference iterations, or terminates inference after reaching the maximum number of rounds.
[0047] This process continues, with each round of reasoning intelligently enhancing feature interactions at each layer of the graph neural network using an adaptive dual-mode feature fusion module, and dynamically updating the reasoning instructions based on the current answer distribution. Ultimately, the system outputs the answer entity with the highest probability, along with a complete reasoning path, including the relationships and intermediate entities focused on in each round, as well as the attention weight distribution learned by the feature fusion module, providing users with interpretable reasoning evidence.
[0048] like Figure 3 As shown, for the input layer: it receives natural language questions from users, such as "What assessment tools should be used for the nutritional management of elderly diabetic patients?"
[0049] For the question encoding layer: the pre-trained RelBERT model is used to vectorize the question, converting natural language into a high-dimensional dense vector representation, providing a semantic foundation for subsequent reasoning.
[0050] For the subgraph extraction layer: First, the topic entities in the question (such as "diabetes" and "elderly patients") are identified through entity linking technology. Then, with the topic entities as the center, relevant subgraphs within a 2-3 hop range are extracted from the complete knowledge graph. These subgraphs contain candidate answer entities and their relationships.
[0051] For the reasoning instruction generation layer: multiple reasoning instructions (3 by default) are generated based on the question vector. Each instruction represents a specific reasoning direction or focus, guiding the model to explore the knowledge graph from different angles.
[0052] For multi-round iterative inference layers: An adaptive dual-mode feature fusion module is integrated into the message propagation process of the graph neural network. This module selects a processing mode based on configuration parameters: a lightweight mode (fixed 4 groups, simplified attention calculation, fixed gating coefficient of 0.7, reducing computation by 75%) is suitable for fast inference, while a standard mode (4-16 adaptive groups, global context encoding, cross-dimensional interactive attention, learning-based gating network, group normalization processing) is suitable for deep inference of complex problems. This module enhances the interaction between relational features and query features in each GNN layer, fully mining complementary information between features through multi-scale grouping processing. The system executes a preset number of inference iterations (default 2-3 rounds), calculating the answer probability distribution after each round and updating the inference instructions based on the current candidate answer, guiding the next round of inference to focus on more relevant subgraph regions. Inference terminates after reaching the maximum number of rounds.
[0053] For the output layer: it outputs Top-K answer entities and provides a complete reasoning path, including the key relationships and intermediate entities passed through each round, as well as the attention weight distribution learned by the feature fusion module, providing users with an interpretable reasoning basis.
[0054] Based on the above explanation, such as Figure 4 As shown, the following is an explanation with reference to specific embodiments: Specific Implementation Example 1: Question and Answer System for Frailty Care of the Elderly Based on Medical Knowledge Graph
[0055] This embodiment demonstrates the application of the method of the present invention in a medical knowledge graph question-answering scenario. Assume the medical knowledge graph contains 100,000 entity nodes and 500,000 relational edges, covering medical concepts such as diseases, symptoms, drugs, treatment methods, and assessment tools, and their interrelationships. A user raises the question: "What assessment tools should be used for the nutritional management of elderly diabetic patients?"
[0056] The system first encodes the question, using a pre-trained RelBERT model for the medical domain to convert it into a 768-dimensional vector representation. Through named entity recognition, the system identifies the subject entities in the question as "elderly patients" and "diabetes." Centering on these two entities, the system extracts a subgraph within a two-hop range from the knowledge graph, containing approximately 500 entities and 1200 relational edges.
[0057] The system generates three initial inference instructions based on the question vector, corresponding to the three semantic directions of "disease characteristics," "management methods," and "assessment tools," respectively. The system is configured to use the standard feature fusion mode (ema_lightweight=False) to fully extract the semantic information of complex questions.
[0058] Upon entering the first round of inference, the system executes a three-layer graph neural network message propagation. During message propagation at each layer, when calculating the interaction between relational features and query instruction features, the system invokes the standard mode of the adaptive dual-mode feature fusion module for processing. This module divides the features into eight groups, enhances semantic representation through global context injection, performs dimensionality reduction (32x reduction ratio), captures fine-grained interactions between features through cross-dimensional matrix attention calculation, and finally uses a learning-based gating network to dynamically adjust the fusion weights. The enhanced features are then used for subsequent message aggregation and node updates.
[0059] After three layers of message propagation, the three inference instructions generate three sets of node representations. The system aggregates and merges these three sets of representations, calculates the matching degree with the question vector, and obtains the probability distribution of the answer. The probability of the "nutrition management" entity is 0.65, and the probability of the "drug treatment" entity is 0.22. Based on the candidate answer "nutrition management", the system updates the inference instructions, generates new instructions, focuses on relationships such as "nutrition management uses tools", and enters the second round of inference.
[0060] In the second round of inference, the system uses updated inference instructions to execute the 3-layer graph neural network message propagation again, enhancing the relationship-query feature interaction at each layer through a standard pattern feature fusion module. After the graph neural network performs message propagation, the representation of the node "Nutritional Status Assessment" is strengthened. In the aggregated probability distribution, the probability of the "MNA Nutritional Assessment Scale" entity reaches 0.78. The system continues to update the inference instructions, entering the third round of inference.
[0061] The system enters the third round of reasoning (reaching the preset maximum number of rounds, 3), again executing 3-layer graph neural network message propagation and using standard pattern feature fusion. After feature enhancement, the probability of "MNA Nutrition Assessment Scale" in the answer probability distribution increases to 0.91, the probability of "MUST Nutrition Screening Tool" is 0.06, and the probabilities of other entities are very low. After completing 3 rounds of reasoning, the system outputs "MNA Nutrition Assessment Scale" as the answer. The reasoning path is: elderly patient - diabetes - nutrition management - nutrition status assessment - MNA scale, with a total reasoning time of 0.9 seconds.
[0062] Specific Implementation Example 2: Rapid Reasoning for Simple Problems.
[0063] This embodiment demonstrates the ability of the method of the present invention to handle simple queries directly. The user asks: "What is the Morse scale?"
[0064] The system encodes the question, identifies the topic entity "Morse scale," and extracts a subgraph containing approximately 80 entities and 150 relations. It generates two inference instructions, corresponding to "definition" and "usefulness," respectively. The system is configured to use a lightweight feature fusion mode (ema_lightweight=True) for rapid response.
[0065] In the first round of inference, the system executes a 3-layer graph neural network message propagation. Within each layer, a lightweight feature fusion mode divides relational and query features into four fixed groups, using simplified mean pooling and element-level attention computation, with a fixed gating coefficient of 0.7 for fusion, reducing computational cost by approximately 75%. After rapid feature enhancement and message propagation, two inference instructions generate two sets of node representations. In the fused probability distribution, the probability of the "Fall Risk Assessment Tool" entity reaches 0.89. The system updates the inference instructions and enters the second round of inference.
[0066] Entering the second round of reasoning (reaching the preset maximum number of rounds, 2), the feature fusion and message propagation in lightweight mode are executed again. In the answer probability distribution, the probability of "Fall Risk Assessment Tool" increases to 0.94. After completing 2 rounds of reasoning, the system outputs "Fall Risk Assessment Tool" as the answer, with a total reasoning time of 0.4 seconds, saving approximately 55% of the computation time compared to the standard mode.
[0067] Specific Implementation Example 3: Reasoning for Complex Problems with Multiple Entities in Concurrency.
[0068] This embodiment demonstrates the ability of the present invention's method to handle complex problems involving multiple entities. A user posed the question: "An 80-year-old patient with cognitive impairment, diabetes, and heart failure, and a recent history of falls, should use which assessment tools for a comprehensive evaluation?"
[0069] The system identified four thematic entities: "cognitive impairment," "diabetes," "heart failure," and "fall," extracting a subgraph containing approximately 1200 entities and 2800 relationships. Five inference instructions were generated, each corresponding to a different disease and assessment direction. The system was configured to use a standard feature fusion mode, with a maximum of four inference rounds to handle high complexity.
[0070] In the first round of inference, the system executes a three-layer graph neural network message propagation, using a standard pattern feature fusion module at each layer to enhance the relationship-query feature interaction. The standard pattern uses 16 groups for deep feature interaction, fully mining the complementary information between multiple inference instructions through global context injection, cross-dimensional attention, and learning-based gating. After the first round of inference, candidate answers include "cognitive assessment," "fall assessment," and "nutritional assessment," with a relatively balanced probability distribution, reflecting a comprehensive consideration of multiple disease dimensions.
[0071] After the second and third rounds of reasoning, the system gradually focused on specific assessment tools. In each round, the standard pattern feature fusion fully utilized multi-scale grouping and cross-dimensional interaction, enabling the effective fusion of information from different assessment dimensions. After the third round of reasoning, the probabilities of the three entities—"MMSE Cognitive Assessment Scale," "Morse Fall Risk Assessment Scale," and "MNA Nutritional Assessment Scale"—reached 0.31, 0.35, and 0.28, respectively. Although the probability of a single answer was not particularly high, the three answers collectively covered the patient's main risk points.
[0072] The system continued with a fourth round of reasoning (reaching the preset maximum of four rounds), again performing standard pattern feature fusion and message propagation, further enhancing the association between the three assessment tools and their corresponding diseases. Ultimately, the probabilities of the three assessment tools increased to 0.33, 0.37, and 0.30, respectively. After completing four rounds of reasoning, the system outputs a set of answers containing the three assessment tools, with a reasoning time of 1.1 seconds, accurately covering the patient's multi-dimensional assessment needs.
[0073] Specific Implementation Example 4: The number of groups in the feature fusion module is adaptively adjusted.
[0074] This embodiment demonstrates the application effect of the adaptive adjustment mechanism for the number of groups in the standard attention fusion model under different complexity scenarios. For the simple task "What assessment tool should be used for elderly patients experiencing memory decline?", the system extracts a subgraph containing approximately 150 entities, generates two inference instructions, and automatically calculates and determines to use five groups. These five groups effectively balance fine-grained feature decomposition and information density, avoiding feature sparsity caused by excessive grouping. After two rounds of inference, the system accurately outputs the "MMSE Cognitive Assessment Scale," and the overall inference is completed efficiently.
[0075] As task complexity increases, the adaptive grouping mechanism demonstrates a more significant advantage. For the moderately complex problem "What comprehensive assessments are needed for elderly patients with diabetes and heart failure?", the system extracts a subgraph containing approximately 450 entities, generates four inference instructions, and automatically sets the number of groups to 12. These 12 groups enable more refined multi-scale feature parsing, fully capturing the correlation features between different disease dimensions. After three rounds of inference, the system outputs "diabetic complication assessment" and "cardiac function classification assessment," maintaining good efficiency throughout the inference process.
[0076] For the highly complex task of "An 80-year-old patient with cognitive impairment, diabetes, heart failure, hypertension, and osteoporosis, at risk of falls and malnutrition, should undergo comprehensive assessments?", the system extracted a subgraph containing approximately 950 entities, generated 6 inference instructions, and automatically set the number of groups to 16 (reaching the upper limit). These 16 groups achieve the finest feature decomposition, fully exploring the complex interactions between multiple disease factors. After four rounds of inference, the system outputs comprehensive assessment solutions including "MMSE cognitive assessment," "Morse fall risk assessment," "MNA nutritional assessment," and "cardiac function assessment," meeting real-time requirements while ensuring accuracy.
[0077] Through the above comparison and verification, the adaptive grouping strategy can automatically optimize the grouping configuration according to the task size and complexity, avoid computational waste in simple tasks, provide sufficient accuracy in complex tasks, and effectively improve the system's adaptability to different inference tasks.
[0078] In summary, the embodiments of the present invention differ from the prior art in the following technical features: 1) A Knowledge Graph Question Answering Reasoning Method Based on Adaptive Dual-Mode Feature Fusion: This method presents a complete technical solution for multi-instruction reasoning tasks in knowledge graphs. By integrating an adaptive dual-mode feature fusion mechanism into the message propagation process of the graph neural network, it flexibly selects between lightweight and standard processing modes based on configuration parameters. This systematically addresses the problem of fixed and singular feature fusion mechanisms in existing methods, achieving efficient utilization of computing resources and full exploitation of feature interactions. The integration scheme of this method with the ReaRev multi-turn reasoning framework includes the arrangement of modules in the reasoning process, data flow, and collaborative working mechanisms.
[0079] 2) Core Technical Architecture of the Adaptive Dual-Mode Feature Fusion Module: The feature fusion module adopts a dual-mode architecture of lightweight and standard modes, achieving an optimal balance between efficiency and accuracy based on application scenario requirements. The lightweight mode reduces computation by approximately 75% through simplification strategies such as a fixed number of groups (G=4), mean pooling, element-level attention computation, and fixed gating coefficients, making it suitable for fast inference scenarios. The standard mode uses adaptive grouping (G=4)... Deep feature fusion strategies, such as global context injection, dimensionality reduction, cross-dimensional interactive attention computation, learning-based gating networks, and group normalization, fully utilize the complementary information of multi-scale features and are suitable for complex multi-hop reasoning problems.
[0080] 3) Intelligent Parameter Management and Application Scenario Adaptation Mechanism: The adaptive parameter management mechanism can automatically verify and adjust parameters such as the number of groups and the dimensionality reduction ratio, ensuring stable operation of the module under various feature dimension configurations. By flexibly controlling the behavior of the feature fusion module through parameter configuration, the system can adapt to the performance requirements of different application scenarios. It can also be applied to multiple fields such as medical knowledge graph question answering, geriatric frailty care decision support, and general knowledge graph question answering.
[0081] Therefore, the embodiments of the present invention have the following advantages compared with the prior art: This invention, based on the ReaRev multi-turn inference framework, systematically solves the problem of fixed and singular feature fusion mechanisms in existing methods by introducing an adaptive dual-mode feature fusion mechanism, achieving a significant performance improvement. Comprehensive comparative experiments were conducted on the WebQSP standard dataset, selecting three representative baseline methods in the knowledge graph question answering field for performance comparison: GraftNet, NSM, and ReaRev. The comparative experimental results show that GraftNet's Hit@1 accuracy is 66%, and its F1 score is 62%; NSM's Hit@1 accuracy is 68%, and its F1 score is 63%; the ReaRev baseline method's Hit@1 accuracy is 75%, and its F1 score is 70%; while the method of this invention achieves a Hit@1 accuracy of 78% and an F1 score of 73%.
[0082] The comparative data shows that the method of this invention achieves a significant improvement of approximately 10% in Hit@1 accuracy and F1 score compared to the GraftNet and NSM methods. Compared to the ReaRev baseline model, the Hit@1 accuracy of this embodiment improves from 75% to 78%, and the F1 score improves from 70% to 73%, both indicators showing a stable improvement of 3 percentage points, fully validating the effectiveness of the adaptive dual-mode feature fusion mechanism. The main source of the performance improvement lies in the fact that the dual-mode feature fusion module enhances the relationship-query feature interaction in each layer of the graph neural network's message propagation. Through multi-scale grouping processing, global context injection, cross-dimensional interactive attention, and learning-based gating, it fully exploits the complementary information between different inference instructions, significantly improving the accuracy of complex multi-hop inference problems.
[0083] Finally, in summary, the overall technical architecture of this invention inherits the design concept of multi-round iterative inference and multiple inference instructions from ReaRev, while making innovative improvements in the feature fusion stage. First, the system receives a natural language question input by the user, converts the question into a vector representation using a question encoder (employing a pre-trained RelBERT model), and identifies the topic entities within the question. Then, the system extracts a subgraph centered on the topic entities from the knowledge graph, containing entities and relationships related to the question. The system generates multiple inference instructions (usually three) based on the question vector, each corresponding to a specific inference direction or focus.
[0084] In each round of inference, the system first performs independent message propagation for each inference instruction using a graph neural network, updating the node representation. This step employs a graph attention network or graph convolutional network to perform multi-layer (typically 3 layers) message propagation operations on the subgraph, aggregating neighbor node information layer by layer. The key innovation lies in the intelligent fusion of multiple sets of node representations generated by multiple inference instructions using an adaptive dual-mode feature fusion module. This module selects either a lightweight mode or a standard mode for feature fusion based on configuration parameters. The lightweight mode uses a simplified computation process for fast inference; the standard mode, on the other hand, fully leverages complementary information between different inference instructions through comprehensive multi-scale processing. The fused node representations are then used to calculate the probability distribution of each entity as the answer.
[0085] The system executes a preset number of inference iterations (usually 2-3 rounds). After each round of inference, it updates the inference instructions based on the current answer distribution, making the inference direction more accurate. After multiple rounds of inference, the system outputs the final answer entity and its confidence score, and can also output the complete inference path, providing users with interpretable reasoning evidence.
[0086] This invention first designs an adaptive dual-mode feature fusion mechanism for multi-instruction reasoning tasks in knowledge graphs, which can dynamically select processing strategies based on the feature complexity during the reasoning process. Secondly, it proposes differentiated design strategies for lightweight and standard operating modes, achieving an optimal balance between efficiency and accuracy. Reference Figure 2 A knowledge graph question-answering reasoning system based on adaptive dual-feature fusion includes: The first module 201 is used to collect users' natural language questions; The second module 202 is used to introduce an adaptive dual-mode feature fusion module to build a knowledge graph reasoning question answering model. The third module 203 is used to reason about the user's natural language questions based on the knowledge graph reasoning question answering model, and generate the user's question answer and reasoning path.
[0087] The content of the above method embodiments is applicable to this system embodiment. The specific functions implemented in this system embodiment are the same as those in the above method embodiments, and the beneficial effects achieved are also the same as those achieved in the above method embodiments.
[0088] The above is a detailed description of the preferred embodiments of the present invention. However, the present invention is not limited to the embodiments described. Those skilled in the art can make various equivalent modifications or substitutions without departing from the spirit of the present invention. All such equivalent modifications or substitutions are included within the scope defined by the claims of this application.
Claims
1. A knowledge graph question-answering reasoning method based on adaptive dual-feature fusion, characterized in that, Includes the following steps: Collect users' natural language questions; An adaptive dual-mode feature fusion module is introduced to construct a knowledge graph reasoning question answering model; Based on a knowledge graph-based reasoning question-answering model, the system reasons about the user's natural language questions and generates the answer and reasoning path.
2. The knowledge graph question answering reasoning method based on adaptive dual-feature fusion according to claim 1, characterized in that, The knowledge graph reasoning question-answering model specifically includes an input layer, a question encoding layer, a subgraph extraction layer, a reasoning instruction generation layer, a multi-round iterative reasoning layer, and an output layer. The input layer, the question encoding layer, the subgraph extraction layer, the reasoning instruction generation layer, the multi-round iterative reasoning layer, and the output layer are connected sequentially, wherein: The multi-round iterative inference layer integrates an adaptive dual-mode feature fusion module, which includes a lightweight mode and a standard mode.
3. The knowledge graph question answering reasoning method based on adaptive dual-feature fusion according to claim 2, characterized in that, The step of using a knowledge graph-based reasoning question-answering model to reason about a user's natural language question and generate the answer and reasoning path specifically includes: Input the user's natural language questions into a knowledge graph-based reasoning and question-answering model; The input layer of the knowledge graph-based reasoning question-answering model receives users' natural language questions. Based on the knowledge graph reasoning question answering model, the question encoding layer uses a pre-trained RelBERT model to vectorize the user's natural language questions, resulting in a high-dimensional question vector representation. The subgraph extraction layer based on the knowledge graph reasoning question answering model performs entity link recognition on the high-dimensional question vector representation, obtains the question subject and performs knowledge graph matching, and outputs candidate answer entities and their associations. The reasoning instruction generation layer based on the knowledge graph reasoning question answering model generates several reasoning instructions based on the high-dimensional question vector representation. Based on a knowledge graph reasoning question answering model, a multi-round iterative reasoning layer performs iterative enhanced feature fusion reasoning on candidate answer entities, relationships, and several reasoning instructions to generate user question answers and reasoning paths. The output layer of the knowledge graph-based reasoning question-answering model outputs the user's question answer and reasoning path.
4. The knowledge graph question answering reasoning method based on adaptive dual-feature fusion according to claim 3, characterized in that, The multi-round iterative reasoning layer based on the knowledge graph reasoning question-answering model performs iterative enhanced feature fusion reasoning on candidate answer entities and their relationships, as well as several reasoning instructions, to generate the user's question answer and reasoning path. This step specifically includes: The multi-round iterative reasoning layer based on the knowledge graph reasoning question answering model receives several reasoning instructions and performs message propagation operations of graph neural networks on candidate answer entities and related relationships, and calculates the interaction between relation features and query instruction features; Based on the interactive calculation process of relation features and query instruction features, the adaptive dual-mode feature fusion module is called to perform enhanced fusion processing to obtain enhanced fused inference instruction features. The enhanced fusion inference instruction features are aggregated and updated with messages to obtain several sets of node representations. Several sets of node representations are aggregated and merged, and their matching degree is calculated with the high-dimensional question vector representation to obtain the probability distribution of each entity as the answer; The system updates several inference instructions based on the probability distribution of each entity as an answer, and performs cyclic feature interaction calculations based on the updated inference instructions until the preset number of iterations is met, outputting the user's question answer and inference path.
5. The knowledge graph question answering reasoning method based on adaptive dual-feature fusion according to claim 4, characterized in that, The interactive calculation process based on relational features and query instruction features, specifically including the step of calling the adaptive dual-mode feature fusion module for enhanced fusion processing to obtain enhanced fused inference instruction features, includes: The interactive calculation process based on relation features and query command features calls the adaptive dual-mode feature fusion module, selects the processing mode according to the configuration parameters for enhanced fusion processing, and the processing mode includes lightweight mode and standard mode. Based on a lightweight model, relation features and query command features are divided into fixed groups, and a simplified attention mechanism and fixed gating coefficients are used for fusion. Based on the standard model, relation features and query instruction features are divided into preset groups. Cross-group context is extracted through a global encoder, cross-dimensional interactive attention is calculated, and a learning gating network is used to dynamically adjust the fusion weights. Based on the fusion inference instructions in lightweight mode or standard mode, the enhanced fusion inference instruction features are output.
6. The knowledge graph question answering reasoning method based on adaptive dual-feature fusion according to claim 5, characterized in that, The lightweight mode specifically includes: The relation features and query command features are divided into subspaces with fixed values, and the features in each subspace are averaged and pooled to obtain a group-level representative vector. The attention weights of the group-level representative vectors are calculated by element-wise multiplication to obtain the attention weight values of the inference instructions. The attention weight values of the inference instructions are broadcast back to the original dimension to obtain an enhanced representation, and then gating fusion is performed using fixed coefficients to obtain a fusion result of several inference instruction features. The fusion results of several inference instruction features are weighted and normalized to obtain fused inference instructions in lightweight mode.
7. The knowledge graph question answering reasoning method based on adaptive dual-feature fusion according to claim 5, characterized in that, The standard mode specifically includes: The relation features and query instruction features are divided into subspaces with preset values to obtain the grouped inference instruction features; Global context information is injected into the grouped inference instruction features to enhance semantic expression, resulting in local features after global context injection. The local features after injecting global context are reduced in dimensionality by a learnable matrix to obtain the dimensionality-reduced local features. Based on the local features after dimensionality reduction, intra-group attention and inter-instruction attention are calculated separately to obtain the intra-group attention value and inter-group attention value of the inference instruction. The fusion ratio is dynamically generated through a learning-based gating network; Based on the fusion ratio, the intra-group attention value and inter-group attention value of the inference instruction are weighted and fused to obtain the fused inference instruction in the standard mode.
8. A knowledge graph question-answering reasoning system based on adaptive dual-feature fusion, characterized in that, Includes the following modules: The first module is used to collect users' natural language questions; The second module is used to introduce an adaptive dual-mode feature fusion module to build a knowledge graph reasoning question answering model. The third module is used to reason about the user's natural language questions based on the knowledge graph reasoning question answering model, and generate the user's question answer and reasoning path.