A question and answer reasoning data synthesis method and system fusing a knowledge graph and a large language model

By integrating knowledge graphs and large language models into a question-answering reasoning data synthesis method, the problems of low efficiency, high cost, and poor reliability in existing technologies are solved. This method enables the efficient generation of high-quality, interpretable question-answering reasoning data, ensuring the reliability and logical rigor of the data.

CN122133798APending Publication Date: 2026-06-02CHENGDU DOCUMENT & INFORMATION CENT OF CHINESE ACAD OF SCI +2

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHENGDU DOCUMENT & INFORMATION CENT OF CHINESE ACAD OF SCI
Filing Date
2026-02-11
Publication Date
2026-06-02

Smart Images

  • Figure CN122133798A_ABST
    Figure CN122133798A_ABST
Patent Text Reader

Abstract

The application discloses a kind of question and answer reasoning data synthesis method and system fusing knowledge graph and large language model, belong to artificial intelligence application technical field, including steps: first, the mapping and alignment of question and answer and multilevel knowledge system are carried out;Then, the key reasoning path discovery and generation in knowledge graph are carried out;Finally, the natural language reasoning chain under the guidance of knowledge path is synthesized.The application solves the inherent contradiction between efficiency, cost, quality and explainability when synthesizing the question and answer reasoning data for the existing technology in the field of scientific literature.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence application technology, and more specifically, to a method and system for synthesizing question-answering reasoning data that integrates knowledge graphs and large language models. Background Technology

[0002] In the application of artificial intelligence technology, especially in the application of Large Language Models (LLMs), high-quality training data is crucial to ensuring that the model possesses high-precision and high-reliability reasoning capabilities in specialized fields (such as science, medicine, and law). For complex question-answering and reasoning (QA&R) tasks, not only are accurate answers required, but the reasoning process must also be logically clear and verifiable. Therefore, how to efficiently and cost-effectively construct large-scale, high-quality, and interpretable question-answering and reasoning datasets is a pressing technical challenge in the field.

[0003] Existing technologies for acquiring this type of data have the following limitations: One primary approach relies on manual annotation by domain experts. This method involves manually designing questions, finding answers, and writing reasoning steps to construct the dataset. While this approach ensures the professionalism and accuracy of the data, it suffers from extremely low productivity, high labor costs, and difficulty in avoiding data inconsistencies caused by expert subjectivity. Consequently, it cannot meet the massive data requirements for training large language models and lacks feasibility for large-scale application.

[0004] To improve data production efficiency, another existing technology attempts to directly synthesize question-and-answer reasoning data using the text generation capabilities of large language models. For example, chain-of-thought prompts guide the model to generate questions, answers, and reasoning processes all at once. However, this approach suffers from inherent and insurmountable drawbacks: first, large language models are prone to "hallucination" during generation, generating erroneous content that contradicts the facts in the source text or violates domain common sense, leading to poor data reliability; second, the generated reasoning process is free-form natural language, lacking a structured and verifiable logical core, making it difficult for external parties to effectively control the correctness and rationality of its reasoning steps and conduct fact-checking, resulting in insufficient credibility of the reasoning process.

[0005] In addition, there are question-answering technologies based on knowledge graphs (KG). This technology finds answers by transforming natural language questions into queries for structured knowledge, with clear reasoning paths, verifiable results, and high accuracy. However, the application of this technology is also greatly limited: on the one hand, any knowledge graph has the problem of incomplete knowledge coverage, which prevents it from answering questions outside the scope of the graph's knowledge; on the other hand, accurately mapping complex and diverse natural language questions into structured query languages ​​is extremely difficult, limiting the flexibility and robustness of this technology in handling open and complex problems.

[0006] In summary, existing technological approaches fail to effectively balance efficiency, scale, quality, and interpretability in data synthesis. Manual methods offer high quality but are inefficient; large language model-based generation methods are efficient but unreliable; and knowledge graph-based methods offer strong interpretability but have limited application scope and flexibility. Therefore, there is an urgent need in this field for a new technological solution that can integrate the advantages of different technologies while overcoming their respective shortcomings, to achieve automated, large-scale production of high-quality, highly reliable, and verifiable reasoning data for scientific and technological literature question-and-answer systems. Summary of the Invention

[0007] The purpose of this invention is to overcome the shortcomings of the prior art and provide a method and system for synthesizing question-answering reasoning data that integrates knowledge graphs and large language models. This solves the inherent contradictions between efficiency, cost, quality and interpretability in the synthesis of question-answering reasoning data for scientific and technological literature in the prior art.

[0008] The objective of this invention is achieved through the following solution: A method for synthesizing question-answering reasoning data that integrates knowledge graphs and large language models includes the following steps: First, the mapping and alignment of question answering with multi-level knowledge systems are performed, multiple mapping methods are integrated, and domain rules are introduced for verification. The contextual understanding capability of the large language model is used as an advanced discriminator to select from multiple candidate entities. Then, rigid domain rules are used to filter and finally confirm the selection results. Next, key reasoning paths in the knowledge graph are discovered and generated. A path ranking model is trained, which learns data features to predict the probability that a massive number of candidate paths become reasonable explanations. Domain rules are used as advanced pruning and weighting tools to perform secondary filtering on the paths selected by the model, eliminating paths that do not conform to domain axioms and increasing the priority of paths that conform to the set logical pattern. Finally, a natural language reasoning chain guided by the synthetic knowledge path is introduced, and a verifiable external symbolic logic path is used as a mandatory framework to transform the large language model from an uncontrollable reasoner into a language organizer under strict supervision.

[0009] Furthermore, the mapping and alignment of question answering with a multi-level knowledge system integrates multiple mapping methods and introduces domain rules for verification. It utilizes the contextual understanding capabilities of a large language model as a high-level discriminator to select from multiple candidate entities, and then uses rigid domain rules to filter and finally confirm the selection results. Specifically, this includes the following sub-steps: Step A1: Entity extraction based on a large language model. First, a question-answer pair (Q, A) is received as input. The large language model is used to process the text of the question and answer, identify and extract a list of candidate entities. Step A2: For each entity in the candidate entity list, execute the following three-stage mapping process sequentially: Phase 1: Exact Matching. This phase processes entities with standardized and unambiguous names. Phase 2: Approximate matching. This phase processes entities whose names are not exactly the same as those in the knowledge graph, but are highly related in semantics. Phase 3: LLM selection and rule determination. This phase is the final guarantee for disambiguation and verification of complex, vague, and ambiguous entities.

[0010] Furthermore, in stage one, the processing of entities with standardized and unambiguous names specifically includes the following sub-steps: Step A1.1: Match the candidate entities with the entity names, aliases, or thesaurus in the multi-level knowledge graph; Step A1.2: If the match is successful, the entity is directly linked to the corresponding unique entity ID in the knowledge graph. The mapping process of the entity ends and it is marked as successfully mapped to the knowledge graph. Step A1.3: If the matching fails, the entity proceeds to Phase Two for processing.

[0011] Furthermore, in stage two, the processing of entities whose names are not entirely identical to those in the knowledge graph but are highly semantically related includes the following sub-steps: Step A2.1: Entity Vectorization and Semantic Similarity Calculation: First, the context text of the candidate entity and the descriptive information of all entities in the knowledge graph are encoded into high-dimensional semantic vectors using a pre-trained language model; then, the cosine similarity between the candidate entity vector and all entity vectors in the knowledge graph is calculated. Step A2.2: Similarity threshold judgment: Preset a similarity threshold and compare the candidate entity with the entity with the highest semantic similarity in the knowledge graph; Step A2.2.1: If the highest similarity is greater than the threshold, it is considered that a high-confidence match has been found. The entity is linked to the corresponding knowledge graph entity ID, the mapping process of the entity ends, and it is marked as successfully mapped to the knowledge graph. Step A2.2.2: If the highest similarity is less than the threshold, it indicates that there are multiple potential matches or the match confidence is insufficient, and there is high ambiguity. At this time, the entity, together with several candidate matching entities with high similarity, will enter stage three for final decision.

[0012] Furthermore, in Phase Three, the final safeguard for disambiguation and verification of complex, vague, and ambiguous entities specifically includes: Step A3.1: Context selection based on the large language model LLM: Construct a structured prompt word Prompt, which provides the original sentence containing the entity to be mapped, multiple low-confidence candidate entities selected in stage two and their descriptions in the knowledge graph to the large language model. The large language model is required to select the entity that best fits the current context from the candidate list based on its context understanding ability. Step A3.2: Domain rule verification: The choices made by the large language model are not directly adopted, but are finally verified by a pre-set domain rule base, which contains axiomatic knowledge in the field of molecular sieves; Step A3.3: Final Judgment: Step A3.3.1: If the LLM selection passes the domain rule validation, the entity is successfully linked to the corresponding knowledge graph entity ID, the mapping process of the entity ends, and it is marked as successfully mapped to the knowledge graph; Step A3.3.2: If the selection of LLM fails the domain rule validation, it is considered that the entity cannot find a reliable mapping in the current knowledge system. The mapping fails, and the next entity in the list will be recorded and the process will continue.

[0013] Furthermore, the process of discovering and generating key reasoning paths in the knowledge graph involves training a path ranking model. This model learns data features to predict the probability that a massive number of candidate paths will become reasonable explanations. Domain rules are used as advanced pruning and weighting tools to perform secondary filtering on the paths selected by the model, eliminating paths that do not conform to domain axioms and increasing the priority of paths that conform to a set logical pattern. This process specifically includes the following sub-steps: Step B1: Path search, initially identifying all candidate paths connecting the question entity and the answer entity; Step B2: Path selection. Through a dual weighting and selection mechanism, the key knowledge path that best fits the domain logic is selected from the candidate paths.

[0014] Furthermore, the preliminary identification of all candidate paths connecting the question entity and the answer entity specifically includes the following sub-steps: Step B1.1: Starting with one or more entities in the question entity set E_Q and ending with one or more entities in the answer entity set E_A, perform a graph search algorithm on the knowledge graph; Step B1.2: Use a pathfinding algorithm to find all possible connection paths within a preset path length limit; Step B1.3: Output the set of candidate paths.

[0015] Furthermore, the process of selecting the key knowledge path that best fits the domain logic from candidate paths through a dual weighting and filtering mechanism specifically includes the following sub-steps: Step B2.1: Model prediction weighting. A pre-trained path ranking model is used to evaluate the logical rationality probability of each candidate path. This includes: Step B2.1.1: Model Training: Sample construction: A training sample set is constructed from domain scientific and technological literature and knowledge base. Positive samples are known, classic, and real reasoning paths that conform to the domain's causal logic. Negative samples are constructed by performing random walks on the knowledge graph or by partially modifying the positive sample paths. Constructing a feature matrix: For each sample path, extract features that can characterize its structure and semantics to form a feature vector. These features include: the length of the path, the sequence of entity types on the path, the sequence of relation types, the rarity of relations in the path, and the centrality of nodes on the path. Training the classification model: Using the feature matrix and sample labels, train a binary classification model; this model includes a gradient boosting decision tree or a small neural network, and the goal of training is to enable the model to learn whether a path is reasonable or unreasonable based on the features of the path. Step B2.1.2: Weighting the model predictions: For each candidate path found in the above steps, extract its feature vector in the same way as during training. Input the feature vector into the trained path ranking model. The model outputs a probability score, which is the rationality weight of the path predicted by the model. The higher the score, the more likely it is to be a reasoning path that conforms to the domain logic. Step B2.2: Path weighting based on domain rules. This process uses a rule base predefined by domain experts to perform rigid logical verification and weighting on candidate paths. Step B2.2.1: Rule base construction: The rule base contains axioms and heuristics in the field of molecular sieves, specifically including hard constraint rules for pruning and pattern enhancement rules for weighting; Step B2.2.2: Rule weighting: Match candidate paths with each rule in the rule base, and adjust their weights based on whether the path violates or conforms to certain rules; Step B2.3: Final screening, specifically including: Step B2.3.1: Comprehensive scoring: The model prediction weights of each candidate path are fused with the weights adjusted according to the domain rules to calculate a final comprehensive score; Step B2.3.2: Path selection: Select one or a few paths with the highest comprehensive score as the key knowledge path P_k for the final output.

[0016] Furthermore, the natural language reasoning chain guided by the synthetic knowledge path introduces a verifiable external symbolic logic path as a mandatory framework, transforming the large language model from an uncontrollable reasoner into a language organizer under strict supervision. This specifically includes the following sub-steps: Step C3.1: Construct structured prompt words containing multiple constraints, specifically including: Step C3.1.1: Input Integration: The construction of prompt words integrates two key information sources: knowledge paths and domain rules. The knowledge path uses the output symbolic path P_k as a mandatory logical framework; the domain rules introduce a portion of domain rules to guide the text generation style and the use of professional terminology. Step C3.1.2: Prompt word construction: Integrate the information from step C3.1.1 into a templated prompt word. This prompt word requires the large language model to play the role of a domain expert and strictly follow the given knowledge path to interpret each "entity-relationship-entity" link into a piece of natural language step by step. Step C3.2: Use chain-like thinking under knowledge constraints to synthesize the constructed structured prompt words and input them into the large language model; Step C3.2.1: Under the guidance of a strongly constrained framework, LLM executes controlled chain-like thinking generation; Step C3.2.2: The output is a step-by-step, detailed natural language reasoning process, where each step directly corresponds to a link in the knowledge path; Step C3.3: Generating the reasoning conclusion, specifically including: Step C3.3.1: Take the original question and the generated detailed reasoning process as input; Step C3.3.2: Call the large language model again and ask it to play the role of a summarizer. Its task is to generate a general conclusion that directly answers the question based on the given question and detailed reasoning steps. Step C3.4: Quality Control and Verification. The generated conclusions are subject to quality control using a dual verification mechanism, specifically including: Step C3.4.1: Logical verification: Design an independent verification task, and once again utilize the logical judgment capability of LLM. Provide LLM with the original question, detailed reasoning process and generated conclusion, and ask questions to perform logical verification, thus forming a self-consistency check. Step C3.4.2: Domain rule verification: Use another set of domain rule bases to verify the semantics and facts of the conclusions to ensure that even if the generated conclusions are logically consistent, they will not violate the core facts and axioms known in the domain. Step C3.5: Final output. Only conclusions that pass both logical verification and domain rule verification are considered high-quality, qualified data. Finally, the original question, qualified conclusions, and detailed reasoning process are combined into a complete, high-quality question-answering reasoning data sample.

[0017] A question-answering reasoning data synthesis system that integrates knowledge graphs and large language models includes a computer. The computer device includes a processor and a memory. The memory stores a computer program that executes the method described in any of the preceding claims when the computer program is loaded by the processor.

[0018] The beneficial effects of this invention include: (1) This invention significantly improves the reliability and factual accuracy of synthesized data. Specifically, the large language model generation process in the natural language reasoning chain synthesis guided by the knowledge path of this invention is strictly constrained by the generated symbolic knowledge path derived from the knowledge graph, and each reasoning step is based on verifiable facts (entities and relations). This "knowledge path first, then natural language" approach fundamentally suppresses the model's free association and fact fabrication, thereby systematically solving the problem of factual illusion.

[0019] (2) This invention achieves a high degree of interpretability and verifiability in the reasoning process. Specifically, each natural language reasoning chain generated by this invention corresponds to a clear and structured knowledge graph path. Users or developers can trace back this path at any time to examine whether each step of the reasoning is logical and whether it has factual basis. This makes the reasoning process no longer a black box inside the traditional large model, but a transparent and auditable white box, greatly enhancing the credibility of the data.

[0020] (3) This invention achieves efficient, large-scale, and low-cost production of high-quality inference data. Specifically, this invention designs the entire data synthesis process as an automated computational workflow, replacing the time-consuming and labor-intensive manual annotation process that relies on domain experts in traditional methods. Through the collaborative work of algorithms and models, it can process massive amounts of scientific and technological literature in a short time and generate high-quality QA&R data in batches, solving the bottleneck of the inability of manual methods to scale.

[0021] (4) This invention ensures that the synthesized data possesses breadth, depth, and logical rigor in terms of knowledge. Specifically, by using a general knowledge graph (ensuring breadth), a domain knowledge graph (ensuring accuracy), and domain rules (ensuring depth and logicality) in a coordinated manner, this invention constructs a multi-level knowledge guidance system, ensuring that the generated reasoning path not only has broad knowledge coverage but is also sufficiently in-depth and accurate within the professional domain, and does not violate the basic axioms of the domain, thus comprehensively improving the overall quality of the data. Attached Figure Description

[0022] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0023] Figure 1 A flowchart for the question-and-answer and knowledge system mapping module; Figure 2 A flowchart for the critical reasoning path discovery module; Figure 3 This is a flowchart of the natural language reasoning synthesis module. Detailed Implementation

[0024] All features disclosed in all embodiments of this specification, or steps in all methods or processes implied in the disclosure, may be combined and / or extended or replaced in any way, except for mutually exclusive features and / or steps.

[0025] The specific implementation process of this invention is as follows: In a preferred embodiment, the present invention aims to address the inherent contradictions between efficiency, cost, quality, and interpretability in the prior art when synthesizing question-answering and reasoning (QA&R) data for scientific and technological literature. Specifically, it addresses at least the following technical problems: 1) How to overcome the common problem of fact illusion when directly generating data based on large language models, and systematically improve the reliability and factual consistency of synthetic data.

[0026] 2) How to solve the problems of high cost, long cycle and difficulty in scaling of manual annotation methods, and realize the automated and batch production of high-quality question-answering reasoning data.

[0027] 3) How to make the reasoning process of synthetic data no longer a black box, but have a clear and verifiable logical path, thereby enhancing the interpretability and credibility of the data.

[0028] Further inventive concepts include at least the following improvements: Step 1: Mapping and Aligning Questions and Answers (Q&A) with a Multi-layered Knowledge System. This step is the entry point and foundation of the entire method, and its accuracy directly determines the effectiveness of all subsequent steps. The improvement of this invention lies in the integration of multiple mapping methods and the introduction of domain rules for verification. Specifically, it proposes for the first time a closed-loop mapping mode of "model pre-selection (using BERT and LLM for semantic disambiguation) + rule verification". That is, it uses the powerful contextual understanding capabilities of large language models as a high-level discriminator to select from multiple candidate entities, and then uses rigid domain rules to filter and finally confirm the selection results. This new combination proposes a new collaborative workflow aimed at improving accuracy. Furthermore, the specific models (such as the BERT model, which can be replaced with a newer pre-trained model) or similarity algorithms used in this step can be iterated according to technological developments. Some basic technical modules, such as entity matching based on dictionary or string similarity, semantic similarity calculation based on models such as BERT, and entity linking of knowledge graphs themselves, can be directly implemented using existing technologies, and will not be elaborated here.

[0029] Step 2: Discovery and generation of key reasoning paths in the knowledge graph. This step is the logical bridge connecting the "question" and the "answer," and is the fundamental basis for generating interpretable and verifiable reasoning chains. Without the structured and symbolic key paths generated in this step, subsequent natural language generation loses its factual and logical anchors and degenerates into uncontrollable black-box generation. Traditional techniques involve path searching within the graph structure (such as Dijkstra's algorithm, A*). The algorithm, etc., employs classic computer science techniques. The improvement of this invention lies in proposing a "learning + rule" dual-screening reasoning path generation mechanism. It solves the problems of "blindness" and "reasonableness" judgment in traditional path search. Specifically, it includes: 1) training a path ranking model, allowing the model to predict the probability of a massive number of candidate paths becoming a "reasonable explanation" by learning data features, achieving intelligent screening from "reachable" to "possible"; 2) using domain rules as advanced pruning and weighting tools to perform secondary filtering on the paths selected by the model, eliminating paths that do not conform to domain axioms and increasing the priority of paths that conform to specific logical patterns. This dual-guarantee system of "model predicting probability, rules guaranteeing correctness" proposed in this invention provides clear, structured knowledge graph paths, allowing users or developers to backtrack on the path at any time and examine whether each step of the reasoning is logical and has factual basis. This makes the reasoning process no longer a black box inside a traditional large model, but a transparent, auditable white box, greatly enhancing the credibility of the data.

[0030] Step 3: Synthesis of Natural Language Inference Chains Guided by Knowledge Paths. This step serves as a bridge connecting machine logic and human understanding, forming a closed-loop process to achieve the final technical effect of this invention: producing "high-quality, highly reliable, and interpretable natural language QA&R data." Through this step, this invention synthesizes a series of machine-readable symbol chains that humans cannot directly use for training into natural language inference chains guided by knowledge paths, achieving the final inference goal. Specifically, the improvement of this invention here lies in proposing a "generative paradigm based on strong constraints of external knowledge paths," and inventing a novel workflow and method. This workflow and method, by introducing a verifiable external symbolic logic path as a mandatory framework, transforms the large language model from an uncontrollable inferrer into a language organizer under strict supervision. This paradigm shift from "unconstrained / weakly constrained generation" to "strongly constrained generation" solves the reliability problem of existing CoT methods. It should be further noted that the use of Large Language Models (LLM) for natural language generation, the use of Prompt Engineering to guide the output of LLM, and the concept of Chain-of-Thought (CoT), which allows the model to think through intermediate steps, can all be achieved using existing technologies.

[0031] In a more specific implementation, based on the above embodiments, a question-answering reasoning data synthesis system and corresponding method for scientific and technological literature in the field of molecular sieves are proposed. Firstly, this question-answering reasoning data synthesis system for scientific and technological literature in the field of molecular sieves includes three main modules: 1) a question-answering and knowledge system mapping module; 2) a key reasoning path discovery module; and 3) a natural language reasoning chain synthesis module.

[0032] For details on the implementation of the question-and-answer and knowledge system mapping module, please refer to [link / reference]. Figure 1 This module aims to accurately and robustly map key entities in input question-answer pairs (Q, A) to a multi-layered knowledge system comprised of general domain knowledge graphs (such as chemical knowledge graphs) and sub-domain knowledge graphs (such as molecular sieve knowledge graphs). In this embodiment, the module employs a three-stage cascaded mapping strategy to balance mapping efficiency and accuracy, specifically including the following process: Step A1: Entity extraction based on Large Language Model (LLM). First, a question-answer pair (Q, A) is received as input. Leveraging the powerful zero-shot or few-shot information extraction capabilities of Large Language Model (LLM), the text of the question and answer is processed to automatically identify and extract a candidate entity list. For example, for the question "How does the low silica-alumina ratio in ZSM-5 molecular sieve affect its acidity?", LLM will extract the following candidate entity list: ["ZSM-5 molecular sieve", "silica-alumina ratio", "acidity"].

[0033] Step A2: For each entity in the candidate entity list, execute the three-stage mapping process sequentially: Phase 1: Exact Matching. This phase aims to efficiently handle entities with standardized and unambiguous names.

[0034] Step A1.1: Perform strict string matching between the candidate entity (such as "ZSM-5 molecular sieve") and the entity name, alias, or thesaurus in the multi-level knowledge graph.

[0035] Step A1.2: If the match is successful, the entity is directly linked to the corresponding unique entity ID in the knowledge graph. The mapping process of the entity ends and is marked as "Mapping to the knowledge graph was successful".

[0036] Step A1.3: If the match fails (for example, the entity has a spelling variant, abbreviation, or no identical string in the knowledge graph), the entity proceeds to Phase 2 for processing.

[0037] Phase 2: Approximate matching. This phase is used to process entities whose names are not exactly the same as those in the knowledge graph, but are highly related semantically.

[0038] Step A2.1: Entity Vectorization and Semantic Similarity Calculation: First, using a pre-trained language model (such as SciBERT or a BERT model fine-tuned based on domain literature), the contextual text of the candidate entities and the descriptive information of all entities in the knowledge graph are encoded into high-dimensional semantic vectors. Then, the cosine similarity between the candidate entity vector and all entity vectors in the knowledge graph is calculated.

[0039] Step A2.2: Similarity Threshold Determination: Preset a similarity threshold (e.g., 0.9). Compare the candidate entity with the entity with the highest semantic similarity in the knowledge graph.

[0040] Step A2.2.1: If the highest similarity is greater than the threshold, it is considered that a high-confidence match has been found. The entity is then linked to the corresponding knowledge graph entity ID, the mapping process for that entity ends, and it is marked as "Mapping to knowledge graph successfully".

[0041] Step A2.2.2: If the highest similarity score is less than the threshold, it indicates that there are multiple potential matches or the match confidence is insufficient, resulting in high ambiguity. In this case, the entity, along with several candidate matching entities with high similarity scores, will proceed to Stage Three for final decision-making.

[0042] Phase 3: LLM selection and rule determination. This phase is the final guarantee for disambiguation and verification of complex, ambiguous, and unclear entities.

[0043] Step A3.1: LLM-based Context Selection: Construct a structured prompt that provides the original sentence containing the entity to be mapped, multiple low-confidence candidate entities selected in Stage 2, and their descriptions in the knowledge graph to the Large Language Model (LLM). The LLM is required to leverage its strong contextual understanding capabilities to select the entity from the candidate list that best fits the current context. For example, for the entity "acidity," the LLM can determine from the context "...proton acid centers formed by skeletal aluminum and bridging hydroxyl groups..." that it should select the Brønsted Acid Site (B-site) from the knowledge graph rather than the Lewis Acid Site (L-site).

[0044] Step A3.2: Domain Rule Validation: The choices made by LLM are not directly adopted, but are ultimately validated by a pre-defined domain rule base. This rule base contains axiomatic knowledge in the molecular sieve domain, such as: "If an entity is selected as Brønsted_Acid_Site, then it must be associated with concepts such as Framework_Al or Proton in the original context."

[0045] Step A3.3: Final Judgment: Step A3.3.1: If the LLM selection passes the domain rule validation, the entity is successfully linked to the corresponding knowledge graph entity ID, the mapping process of the entity ends, and it is marked as "Mapped to knowledge graph successfully".

[0046] Step A3.3.2: If the selection of LLM fails the domain rule validation, it is considered that the entity cannot find a reliable mapping in the current knowledge system. The mapping fails, and the system will record and continue to process the next entity in the list.

[0047] Through the three-stage mapping strategy described above, the method of the above embodiments of the present invention can refine the processing of complex and ambiguous entities while ensuring high efficiency, which greatly improves the accuracy and robustness of mapping entities to multi-level knowledge graphs and lays a solid foundation for the discovery of subsequent high-quality reasoning paths.

[0048] For details on the implementation of the critical reasoning path discovery module, please refer to [link / reference]. Figure 2 This module receives the precisely mapped set of question entities and answer entities from the aforementioned modules, and discovers and generates one or more logically sound and professional symbolic reasoning paths connecting the two within the knowledge graph. The core of this module lies in its innovative "learning + rule" dual-filtering mechanism, ensuring that the path is not only "reachable" but also "rational." Specifically, it includes the following process: Step B1: Path Search. This step aims to initially identify all candidate paths connecting the question entity and the answer entity, specifically including: Step B1.1: Begin with one or more entities in the problem entity set E_Q ( Figure 2 The “Q” in the answer entity set E_A is the endpoint of one or more entities in the answer entity set. Figure 2 The "A" in the graph refers to the graph search algorithm performed on the knowledge graph.

[0049] Step B1.2: Use a bidirectional breadth-first search or similar pathfinding algorithm to efficiently find all possible connection paths within a preset path length limit (e.g., no more than 5 hops).

[0050] Step B1.3: The output of this step is a large set of candidate paths. These paths only guarantee connectivity between entities, but the vast majority of them are meaningless or illogical in the domain logic.

[0051] Step B2: Path Filtering. This is the core step of this module. It uses a dual weighting and filtering mechanism to select the key knowledge path that best fits the domain logic from a massive number of candidate paths. This mechanism includes two parallel processing flows: model prediction weighting and domain rule weighting.

[0052] Step B2.1: Model Prediction Weighting. This process uses a pre-trained path ranking model to evaluate the "logical plausibility" probability of each candidate path.

[0053] Step B2.1.1: Model training (offline): Sample Construction: A training sample set is constructed from a large amount of domain-specific scientific literature and existing knowledge bases. Positive samples are known, classic, and true reasoning paths that conform to the causal logic of the domain (e.g., in the field of molecular sieves, "template agent -> influence -> pore structure -> determination -> shape-selective catalytic performance"). Negative samples can be constructed by performing random walks on the knowledge graph or by partially modifying the positive sample paths (e.g., replacing relationships or shuffling the order).

[0054] Constructing the feature matrix: For each sample path, extract a series of features that can characterize its structure and semantics to form a feature vector. These features preferably include: the length of the path, the sequence of entity types on the path, the sequence of relation types, the rarity of relations in the path (inverse document frequency), and the centrality of nodes on the path (such as PageRank value), etc.

[0055] Training the classification model: Using the feature matrix and sample labels (positive / negative) described above, train a binary classification model. This model can be a gradient boosting decision tree (such as XGBoost, LightGBM) or a small neural network. The goal of training is to teach the model to determine whether a path is "reasonable" or "unreasonable" based on its features.

[0056] Step B2.1.2: Weighting Model Predictions (performed online): For each candidate path found in the above steps, extract its feature vector in the same way as during training.

[0057] The feature vector is input into the trained path ranking model, and the model outputs a probability score (e.g., between 0 and 1). This score is the "reasonableness" weight of the path predicted by the model. The higher the score, the more likely it is to be a reasoning path that conforms to the domain logic.

[0058] Step B2.2: Path weighting based on domain rules. This process utilizes a rule base predefined by domain experts to perform rigid logical verification and weighting on candidate paths.

[0059] Step B2.2.1: Rule Base Construction: The rule base contains a series of axioms and heuristics in the field of molecular sieves. For example: Hard constraint rule (for pruning): "Entities of type 'catalytic performance' cannot be the cause of entities of type 'synthetic method' in a path." Paths that violate this rule will be assigned zero weight or eliminated. Model enhancement rule (for weighting): "For any path that conforms to the model 'structural parameters -> influence -> physicochemical properties -> determination -> catalytic application performance', its weight should be multiplied by a coefficient greater than 1 (e.g., 1.5)".

[0060] Step B2.2.2: Rule Weighting: Match candidate paths using each rule in the rule base. Adjust (increase or decrease) the weight of a path based on whether it violates or conforms to certain rules.

[0061] Step B2.3: Final screening. This includes: Step B2.3.1: Comprehensive Score: The model prediction weights of each candidate path are fused with the weights adjusted according to the domain rules to calculate a final comprehensive score. The fusion method can be weighted summation, product, or other preset functions.

[0062] Step B2.3.2: Path selection: Select one or a few paths with the highest comprehensive score as the key knowledge path P_k for the final output.

[0063] Through the dual screening mechanism of "machine learning predicting probability and domain rules ensuring correctness", the above embodiments of the present invention can efficiently and accurately discover truly valuable reasoning patterns from complex knowledge networks, providing a solid and reliable logical framework for the subsequent generation of high-quality, interpretable natural language reasoning chains.

[0064] For details on the implementation of the natural language reasoning synthesis module, please refer to... Figure 3 This module is the final stage of the entire data synthesis process. Its goal is to receive the symbolic key knowledge paths generated by the modules above and transform them into high-quality, highly readable, and logically rigorous natural language reasoning data. This module creatively decomposes this process into two independent subtasks: reasoning process generation and reasoning conclusion generation and verification, to ensure the integrity and reliability of the final output data. Specifically, it includes the following process: Step C3.1: Structured Cue Engineering. This step is the cornerstone of ensuring the quality of the generated code, and its core is to build a structured cue that includes multiple constraints.

[0065] Step C3.1.1: Input Integration: The construction of the prompt words integrates two key information sources: Knowledge Path: The symbolic path P_k output by the above modules (e.g., [Entity A] -> [Relation R1] -> [Entity B] -> [Relation R2] -> [Entity C]) is used as a mandatory logical framework.

[0066] Domain Rules: A set of domain rules are introduced to guide the style of text generation and the use of technical terms. For example, "When describing catalytic mechanisms, technical terms such as 'active site' and 'carbocation' must be used," and "When describing the influence of parameters, it should be clearly indicated whether the influence is 'positively correlated' or 'negatively correlated'."

[0067] Step C3.1.2: Cue Word Construction: Integrate the above information into a templated cue word. This cue word explicitly requires the large language model to play the role of a domain expert and strictly follow the given knowledge path to interpret each "entity-relationship-entity" link into a piece of natural language step by step. This is a strong constraint that limits the model's freedom of expression.

[0068] Step C3.2: Chain Thinking (CoT) Synthesis under Knowledge Constraints 3.2.1 Input the constructed structured prompt words into the large language model.

[0069] Step C3.2.1: Under the guidance of a strongly constrained framework, the LLM executes a "controlled" chain-of-thought (CoT) generation. Unlike the traditional CoT model that autonomously creates logical steps, the LLM in this invention is more like a "logic translator," whose task is to accurately and fluently "translate" pre-verified symbolic logic into professional natural language.

[0070] Step C3.2.2: The output of this step is a step-by-step, detailed natural language reasoning process (R_process). Each step of this reasoning process directly corresponds to a link in the knowledge path, thus its factual and logical nature is fundamentally guaranteed.

[0071] This module aims to generate a concise and accurate final conclusion based on the detailed reasoning process already generated, and to rigorously verify its quality.

[0072] Step C3.3: Generating the reasoning conclusion, specifically including: Step C3.3.1: Take the original question (Q) and the detailed reasoning process (R_process) generated in the previous step as input.

[0073] Step C3.3.2: Call the large language model again and ask it to play the role of "summarizer". The task is to "generate a general conclusion (A_conclusion) that directly answers the question based on the given question and detailed reasoning steps".

[0074] Step C3.3.3: This step ensures that the final answer (conclusion) is derived entirely from a credible reasoning process, rather than being fabricated out of thin air.

[0075] Step C3.4: Quality Control and Verification. This step involves final, automated quality control of the generated conclusion (A_conclusion), employing a dual verification mechanism, specifically including: Step C3.4.1: Logical Verification: Design an independent verification task to leverage the logical judgment capabilities of the LLM again. Provide the LLM with the original question Q, the detailed reasoning process R_process, and the generated conclusion A_conclusion, and ask: "Is conclusion A_conclusion a reasonable and consistent logical inference of the reasoning process R_process? Please answer 'yes' or 'no' and explain your reasoning." Only when the LLM answers "yes" does the conclusion pass the logical verification. This constitutes an effective self-consistency check.

[0076] Step C3.4.2: Domain Rule Validation: Use another set of higher-order domain rules to validate the semantics and facts of the conclusion. For example, a rule could stipulate that "the direction of the influence of the 'Si / Al ratio' on 'acidity' in the conclusion must be consistent with the [Si / Al_Ratio] --(negatively_correlates_with)-->[Acidity] relationship defined in the knowledge graph." This step ensures that even if the generated conclusion is logically consistent, it will not violate the core facts and axioms known in the domain.

[0077] Step C3.5: Final Output. Only conclusions that pass both logical and domain rule validations are considered high-quality, qualified data. Finally, the system combines the original question Q, the qualified conclusion A (A_conclusion), and the detailed reasoning process R_process into a complete, high-quality output.<Q, A, R_process> Question-and-answer reasoning data sample.

[0078] Through the modular generation and verification process described above, this invention not only generates a detailed reasoning process, but also ensures the quality of the final conclusion, forming a complete, end-to-end automated, high-quality question-answering reasoning data synthesis closed loop.

[0079] Therefore, the execution flow of the above system is as follows: 1) Question-and-answer and knowledge system mapping module: Identify and map entities: “ZSM-5” -> KG_ID:ZSM-5, “Si / Al ratio” -> KG_ID:Si / Al_Ratio, “Catalytic activity” -> KG_ID:Catalytic_Activity, “Brønsted acid site” -> KG_ID:Bronsted_Acid_Site, “Alkane cracking” -> KG_ID:Alkane_Cracking.

[0080] 2) Critical reasoning path discovery module: A search was conducted starting with KG_ID:Si / Al_Ratio and KG_ID:ZSM-5, and ending with KG_ID:Catalytic_Activity and KG_ID:Alkane_Cracking. After double screening, a knowledge path P_k of the highest quality was found: [KG_ID:Si / Al_Ratio] --(determines)-->[KG_ID:Framework_Al_Content] --(creates)-->[KG_ID:Bronsted_Acid_Site] --(is_active_site_for)-->[KG_ID:Alkane_Cracking] 3) Natural Language Inference Chain Synthesis Module: Constructing prompts based on P_k, the core constraint is: "...Your reasoning must strictly adhere to the following logic: 1. Explain how the Si / Al ratio determines the skeletal aluminum content. 2. Explain how the skeletal aluminum content generates Brønsted acid centers. 3. Explain the role of Brønsted acid centers in alkane cracking reactions..." Based on this constraint, LLM generates a professional natural language reasoning chain (R): "1. In the framework structure of ZSM-5 molecular sieve, the Si / Al ratio is the decisive chemical parameter. When the Si / Al ratio decreases, it means that the four-coordinated silicon atoms are replaced by more aluminum atoms, resulting in an increase in the aluminum content in the framework."

[0081] 2. To balance the negative charge generated by aluminum atoms replacing silicon atoms, cations (usually protons H+) are needed to compensate, which forms Brønsted acid centers. Therefore, increasing the skeletal aluminum content directly leads to an increase in the density of Brønsted acid centers.

[0082] 3. Brønsted acid centers are typical protic acids, providing active sites for the protonation of alkanes, which is the initiating step in carbocation-mediated catalytic cracking reactions. Therefore, more Brønsted acid centers mean more catalytically active sites, thereby improving the catalytic activity for alkane cracking. Ultimately, the system described above can output high-quality, highly professional, and logically rigorous QA&R data. In this way, the present invention can automatically generate high-quality training data for highly specialized scientific fields such as molecular sieves, providing a crucial data foundation for training larger, more scientifically sound, and reliable professional domain models.

[0083] It should be noted that, within the scope of protection defined in the claims of this invention, the following embodiments can be combined and / or extended or replaced in any logical manner from the above specific embodiments, such as the disclosed technical principles, disclosed technical features or implicitly disclosed technical features.

[0084] Example 1 A method for synthesizing question-answering reasoning data that integrates knowledge graphs and large language models includes the following steps: First, the mapping and alignment of question answering with multi-level knowledge systems are performed, multiple mapping methods are integrated, and domain rules are introduced for verification. The contextual understanding capability of the large language model is used as an advanced discriminator to select from multiple candidate entities. Then, rigid domain rules are used to filter and finally confirm the selection results. Next, key reasoning paths in the knowledge graph are discovered and generated. A path ranking model is trained, which learns data features to predict the probability that a massive number of candidate paths become reasonable explanations. Domain rules are used as advanced pruning and weighting tools to perform secondary filtering on the paths selected by the model, eliminating paths that do not conform to domain axioms and increasing the priority of paths that conform to the set logical pattern. Finally, a natural language reasoning chain guided by the synthetic knowledge path is introduced, and a verifiable external symbolic logic path is used as a mandatory framework to transform the large language model from an uncontrollable reasoner into a language organizer under strict supervision.

[0085] Example 2 Building upon Example 1, the mapping and alignment of question-and-answer with a multi-level knowledge system involves fusing multiple mapping methods and introducing domain rules for validation. It utilizes the contextual understanding capabilities of a large language model as a high-level discriminator to select from multiple candidate entities. Rigid domain rules are then used to filter and finally confirm the selection results. Specifically, this includes the following sub-steps: Step A1: Entity extraction based on a large language model. First, a question-answer pair (Q, A) is received as input. The large language model is used to process the text of the question and answer, identify and extract a list of candidate entities. Step A2: For each entity in the candidate entity list, execute the following three-stage mapping process sequentially: Phase 1: Exact Matching. This phase processes entities with standardized and unambiguous names. Phase 2: Approximate matching. This phase processes entities whose names are not exactly the same as those in the knowledge graph, but are highly related in semantics. Phase 3: LLM selection and rule determination. This phase is the final guarantee for disambiguation and verification of complex, vague, and ambiguous entities.

[0086] Example 3 Based on Example 2, in Phase 1, the processing of entities with standardized and unambiguous names specifically includes the following sub-steps: Step A1.1: Match the candidate entities with the entity names, aliases, or thesaurus in the multi-level knowledge graph; Step A1.2: If the match is successful, the entity is directly linked to the corresponding unique entity ID in the knowledge graph. The mapping process of the entity ends and it is marked as successfully mapped to the knowledge graph. Step A1.3: If the matching fails, the entity proceeds to Phase Two for processing.

[0087] Example 4 Building upon Example 1, in Phase 2, the processing of entities whose names are not entirely identical to those in the knowledge graph but are highly semantically related includes the following sub-steps: Step A2.1: Entity Vectorization and Semantic Similarity Calculation: First, the context text of the candidate entity and the descriptive information of all entities in the knowledge graph are encoded into high-dimensional semantic vectors using a pre-trained language model; then, the cosine similarity between the candidate entity vector and all entity vectors in the knowledge graph is calculated. Step A2.2: Similarity threshold judgment: Preset a similarity threshold and compare the candidate entity with the entity with the highest semantic similarity in the knowledge graph; Step A2.2.1: If the highest similarity is greater than the threshold, it is considered that a high-confidence match has been found. The entity is linked to the corresponding knowledge graph entity ID, the mapping process of the entity ends, and it is marked as successfully mapped to the knowledge graph. Step A2.2.2: If the highest similarity is less than the threshold, it indicates that there are multiple potential matches or the match confidence is insufficient, and there is high ambiguity. At this time, the entity, together with several candidate matching entities with high similarity, will enter stage three for final decision.

[0088] Example 5 Based on Example 1, in Phase 3, the final safeguard for disambiguation and verification of complex, vague, and ambiguous entities specifically includes: Step A3.1: Context selection based on the large language model LLM: Construct a structured prompt word Prompt, which provides the original sentence containing the entity to be mapped, multiple low-confidence candidate entities selected in stage two and their descriptions in the knowledge graph to the large language model. The large language model is required to select the entity that best fits the current context from the candidate list based on its context understanding ability. Step A3.2: Domain rule verification: The choices made by the large language model are not directly adopted, but are finally verified by a pre-set domain rule base, which contains axiomatic knowledge in the field of molecular sieves; Step A3.3: Final Judgment: Step A3.3.1: If the LLM selection passes the domain rule validation, the entity is successfully linked to the corresponding knowledge graph entity ID, the mapping process of the entity ends, and it is marked as successfully mapped to the knowledge graph. Step A3.3.2: If the selection of LLM fails the domain rule validation, it is considered that the entity cannot find a reliable mapping in the current knowledge system. The mapping fails, and the next entity in the list will be recorded and the process will continue.

[0089] Example 6 Building upon Example 1, the process of discovering and generating key reasoning paths in the knowledge graph involves training a path ranking model. This model learns data features to predict the probability that a massive number of candidate paths will become reasonable explanations. Domain rules are used as advanced pruning and weighting tools to perform secondary filtering on the paths selected by the model, eliminating paths that do not conform to domain axioms and increasing the priority of paths that conform to a set logical pattern. This process specifically includes the following sub-steps: Step B1: Path search, initially identifying all candidate paths connecting the question entity and the answer entity; Step B2: Path selection. Through a dual weighting and selection mechanism, the key knowledge path that best fits the domain logic is selected from the candidate paths.

[0090] Example 7 Based on Example 6, the preliminary identification of all candidate paths connecting question entities and answer entities specifically includes the following sub-steps: Step B1.1: Starting with one or more entities in the question entity set E_Q and ending with one or more entities in the answer entity set E_A, perform a graph search algorithm on the knowledge graph; Step B1.2: Use a pathfinding algorithm to find all possible connection paths within a preset path length limit; Step B1.3: Output the set of candidate paths.

[0091] Example 8 Based on Example 1, the selection of the key knowledge path that best conforms to the domain logic from the candidate paths through a dual weighting and filtering mechanism specifically includes the following sub-steps: Step B2.1: Model prediction weighting. A pre-trained path ranking model is used to evaluate the logical rationality probability of each candidate path. This includes: Step B2.1.1: Model Training: Sample construction: A training sample set is constructed from domain scientific and technological literature and knowledge base. Positive samples are known, classic, and real reasoning paths that conform to the domain's causal logic. Negative samples are constructed by performing random walks on the knowledge graph or by partially modifying the positive sample paths. Constructing a feature matrix: For each sample path, extract features that can characterize its structure and semantics to form a feature vector. These features include: the length of the path, the sequence of entity types on the path, the sequence of relation types, the rarity of relations in the path, and the centrality of nodes on the path. Training the classification model: Using the feature matrix and sample labels, train a binary classification model; this model includes a gradient boosting decision tree or a small neural network, and the goal of training is to enable the model to learn whether a path is reasonable or unreasonable based on the features of the path. Step B2.1.2: Weighting the model predictions: For each candidate path found in the above steps, extract its feature vector in the same way as during training. Input the feature vector into the trained path ranking model. The model outputs a probability score, which is the rationality weight of the path predicted by the model. The higher the score, the more likely it is to be a reasoning path that conforms to the domain logic. Step B2.2: Path weighting based on domain rules. This process uses a rule base predefined by domain experts to perform rigid logical verification and weighting on candidate paths. Step B2.2.1: Rule base construction: The rule base contains axioms and heuristics in the field of molecular sieves, specifically including hard constraint rules for pruning and pattern enhancement rules for weighting; Step B2.2.2: Rule weighting: Match candidate paths with each rule in the rule base, and adjust their weights based on whether the path violates or conforms to certain rules; Step B2.3: Final screening, specifically including: Step B2.3.1: Comprehensive scoring: The model prediction weights of each candidate path are fused with the weights adjusted according to the domain rules to calculate a final comprehensive score; Step B2.3.2: Path selection: Select one or a few paths with the highest comprehensive score as the key knowledge path P_k for the final output.

[0092] Example 9 Building upon Example 8, the natural language reasoning chain guided by the synthetic knowledge path introduces a verifiable external symbolic logic path as a mandatory framework, transforming the large language model from an uncontrollable reasoner into a language organizer under strict supervision. This specifically includes the following sub-steps: Step C3.1: Construct structured prompt words containing multiple constraints, specifically including: Step C3.1.1: Input Integration: The construction of prompt words integrates two key information sources: knowledge paths and domain rules. The knowledge path uses the output symbolic path P_k as a mandatory logical framework; the domain rules introduce a portion of domain rules to guide the text generation style and the use of professional terminology. Step C3.1.2: Prompt word construction: Integrate the information from step C3.1.1 into a templated prompt word. This prompt word requires the large language model to play the role of a domain expert and strictly follow the given knowledge path to interpret each "entity-relationship-entity" link into a piece of natural language step by step. Step C3.2: Use chain-like thinking under knowledge constraints to synthesize the constructed structured prompt words and input them into the large language model; Step C3.2.1: Under the guidance of a strongly constrained framework, LLM executes controlled chain-like thinking generation; Step C3.2.2: The output is a step-by-step, detailed natural language reasoning process, where each step directly corresponds to a link in the knowledge path; Step C3.3: Generating the reasoning conclusion, specifically including: Step C3.3.1: Take the original question and the generated detailed reasoning process as input; Step C3.3.2: Call the large language model again and ask it to play the role of a summarizer. Its task is to generate a general conclusion that directly answers the question based on the given question and detailed reasoning steps. Step C3.4: Quality Control and Verification. The generated conclusions are subject to quality control using a dual verification mechanism, specifically including: Step C3.4.1: Logical verification: Design an independent verification task, and once again utilize the logical judgment capability of LLM. Provide LLM with the original question, detailed reasoning process and generated conclusion, and ask questions to perform logical verification, thus forming a self-consistency check. Step C3.4.2: Domain rule verification: Use another set of domain rule bases to verify the semantics and facts of the conclusions to ensure that even if the generated conclusions are logically consistent, they will not violate the core facts and axioms known in the domain. Step C3.5: Final output. Only conclusions that pass both logical verification and domain rule verification are considered high-quality, qualified data. Finally, the original question, qualified conclusions, and detailed reasoning process are combined into a complete, high-quality question-answering reasoning data sample.

[0093] Example 10 A question-answering reasoning data synthesis system that integrates knowledge graphs and large language models includes a computer. The computer device includes a processor and a memory. The memory stores a computer program. When the computer program is loaded by the processor, it executes the method described in any one of Embodiments 1 to 9 above.

[0094] The units described in the embodiments of the present invention can be implemented in software or hardware, and the described units can also be located in a processor. The names of these units do not necessarily limit the specific unit itself.

[0095] According to one aspect of the present invention, a computer program product or computer program is provided, the computer program product or computer program including computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and executes the computer instructions, causing the computer device to perform the methods provided in the various optional implementations described above.

[0096] In another aspect, embodiments of the present invention also provide a computer-readable medium, which may be included in the electronic device described in the above embodiments; or it may exist independently and not assembled into the electronic device. The computer-readable medium carries one or more programs, which, when executed by the electronic device, cause the electronic device to perform the methods described in the above embodiments.

Claims

1. A method for synthesizing question-answering reasoning data that integrates knowledge graphs and large language models, characterized in that, Includes the following steps: First, the mapping and alignment of question answering with multi-level knowledge systems are performed, multiple mapping methods are integrated, and domain rules are introduced for verification. The contextual understanding capability of the large language model is used as an advanced discriminator to select from multiple candidate entities. Then, rigid domain rules are used to filter and finally confirm the selection results. Next, key reasoning paths in the knowledge graph are discovered and generated. A path ranking model is trained, which learns data features to predict the probability that a massive number of candidate paths become reasonable explanations. Domain rules are used as advanced pruning and weighting tools to perform secondary filtering on the paths selected by the model, eliminating paths that do not conform to domain axioms and increasing the priority of paths that conform to the set logical pattern. Finally, a natural language reasoning chain guided by the synthetic knowledge path is introduced, and a verifiable external symbolic logic path is used as a mandatory framework to transform the large language model from an uncontrollable reasoner into a language organizer under strict supervision.

2. The question-answering reasoning data synthesis method integrating knowledge graphs and large language models according to claim 1, characterized in that, The process of mapping and aligning question-and-answer with a multi-layered knowledge system involves integrating multiple mapping methods and introducing domain rules for validation. It utilizes the contextual understanding capabilities of a large language model as a high-level discriminator to select from multiple candidate entities, and then uses rigid domain rules to filter and finally confirm the selection results. Specifically, this includes the following sub-steps: Step A1: Entity extraction based on a large language model. First, a question-answer pair (Q, A) is received as input. The large language model is used to process the text of the question and answer, identify and extract a list of candidate entities. Step A2: For each entity in the candidate entity list, execute the following three-stage mapping process sequentially: Phase 1: Exact Matching. This phase processes entities with standardized and unambiguous names. Phase 2: Approximate matching. This phase processes entities whose names are not exactly the same as those in the knowledge graph, but are highly related in semantics. Phase 3: LLM selection and rule determination. This phase is the final guarantee for disambiguation and verification of complex, vague, and ambiguous entities.

3. The question-answering reasoning data synthesis method integrating knowledge graphs and large language models according to claim 2, characterized in that, In Phase One, the processing of entities with standardized and unambiguous names specifically includes the following sub-steps: Step A1.1: Match the candidate entities with the entity names, aliases, or thesaurus in the multi-level knowledge graph; Step A1.2: If the match is successful, the entity is directly linked to the corresponding unique entity ID in the knowledge graph. The mapping process of the entity ends and it is marked as successfully mapped to the knowledge graph. Step A1.3: If the matching fails, the entity proceeds to Phase Two for processing.

4. The question-answering reasoning data synthesis method integrating knowledge graphs and large language models according to claim 1, characterized in that, In Phase Two, the processing involves entities whose names are not entirely identical to those in the knowledge graph but are highly semantically related. This specifically includes the following sub-steps: Step A2.1: Entity Vectorization and Semantic Similarity Calculation: First, the context text of the candidate entity and the descriptive information of all entities in the knowledge graph are encoded into high-dimensional semantic vectors using a pre-trained language model; then, the cosine similarity between the candidate entity vector and all entity vectors in the knowledge graph is calculated. Step A2.2: Similarity threshold judgment: Preset a similarity threshold and compare the candidate entity with the entity with the highest semantic similarity in the knowledge graph; Step A2.2.1: If the highest similarity is greater than the threshold, it is considered that a high-confidence match has been found. The entity is linked to the corresponding knowledge graph entity ID, the mapping process of the entity ends, and it is marked as successfully mapped to the knowledge graph. Step A2.2.2: If the highest similarity is less than the threshold, it indicates that there are multiple potential matches or the match confidence is insufficient, and there is high ambiguity. At this time, the entity, together with several candidate matching entities with high similarity, will enter stage three for final decision.

5. The question-answering reasoning data synthesis method integrating knowledge graphs and large language models according to claim 1, characterized in that, In Phase Three, the final safeguard for disambiguation and verification of complex, vague, and ambiguous entities specifically includes: Step A3.1: Context selection based on the large language model LLM: Construct a structured prompt word Prompt, which provides the original sentence containing the entity to be mapped, multiple low-confidence candidate entities selected in stage two and their descriptions in the knowledge graph to the large language model. The large language model is required to select the entity that best fits the current context from the candidate list based on its context understanding ability. Step A3.2: Domain rule verification: The choices made by the large language model are not directly adopted, but are finally verified by a pre-set domain rule base, which contains axiomatic knowledge in the field of molecular sieves; Step A3.3: Final Judgment: Step A3.3.1: If the LLM selection passes the domain rule validation, the entity is successfully linked to the corresponding knowledge graph entity ID, the mapping process of the entity ends, and it is marked as successfully mapped to the knowledge graph. Step A3.3.2: If the selection of LLM fails the domain rule validation, it is considered that the entity cannot find a reliable mapping in the current knowledge system. The mapping fails, and the next entity in the list will be recorded and the process will continue.

6. The question-answering reasoning data synthesis method integrating knowledge graphs and large language models according to claim 1, characterized in that, The process involves discovering and generating key reasoning paths in a knowledge graph, training a path ranking model to predict the probability of a massive number of candidate paths becoming reasonable explanations by learning data features, and using domain rules as advanced pruning and weighting tools to perform secondary filtering on the paths selected by the model, eliminating paths that do not conform to domain axioms and increasing the priority of paths that conform to a set logical pattern. This process specifically includes the following sub-steps: Step B1: Path search, initially identifying all candidate paths connecting the question entity and the answer entity; Step B2: Path selection. Through a dual weighting and selection mechanism, the key knowledge path that best fits the domain logic is selected from the candidate paths.

7. The question-answering reasoning data synthesis method integrating knowledge graphs and large language models according to claim 6, characterized in that, The initial identification of all candidate paths connecting question entities and answer entities specifically includes the following sub-steps: Step B1.1: Starting with one or more entities in the question entity set E_Q and ending with one or more entities in the answer entity set E_A, perform a graph search algorithm on the knowledge graph; Step B1.2: Use a pathfinding algorithm to find all possible connection paths within a preset path length limit; Step B1.3: Output the set of candidate paths.

8. The question-answering reasoning data synthesis method integrating knowledge graphs and large language models according to claim 1, characterized in that, The process of selecting the key knowledge path that best fits the domain logic from candidate paths through a dual weighting and filtering mechanism includes the following sub-steps: Step B2.1: Model prediction weighting. A pre-trained path ranking model is used to evaluate the logical rationality probability of each candidate path. This includes: Step B2.1.1: Model Training: Sample construction: A training sample set is constructed from domain scientific and technological literature and knowledge base. Positive samples are known, classic, and real reasoning paths that conform to the domain's causal logic. Negative samples are constructed by performing random walks on the knowledge graph or by partially modifying the positive sample paths. Constructing a feature matrix: For each sample path, extract features that can characterize its structure and semantics to form a feature vector. These features include: the length of the path, the sequence of entity types on the path, the sequence of relation types, the rarity of relations in the path, and the centrality of nodes on the path. Training the classification model: Using the feature matrix and sample labels, train a binary classification model; this model includes a gradient boosting decision tree or a small neural network, and the goal of training is to enable the model to learn whether a path is reasonable or unreasonable based on the features of the path. Step B2.1.2: Weighting the model predictions: For each candidate path found in the above steps, extract its feature vector in the same way as during training. Input the feature vector into the trained path ranking model. The model outputs a probability score, which is the rationality weight of the path predicted by the model. The higher the score, the more likely it is to be a reasoning path that conforms to the domain logic. Step B2.2: Path weighting based on domain rules. This process uses a rule base predefined by domain experts to perform rigid logical verification and weighting on candidate paths. Step B2.2.1: Rule base construction: The rule base contains axioms and heuristics in the field of molecular sieves, specifically including hard constraint rules for pruning and pattern enhancement rules for weighting; Step B2.2.2: Rule weighting: Match candidate paths with each rule in the rule base, and adjust their weights based on whether the path violates or conforms to certain rules; Step B2.3: Final screening, specifically including: Step B2.3.1: Comprehensive scoring: The model prediction weights of each candidate path are fused with the weights adjusted according to the domain rules to calculate a final comprehensive score; Step B2.3.2: Path selection: Select one or a few paths with the highest comprehensive score as the key knowledge path P_k for the final output.

9. The question-answering reasoning data synthesis method integrating knowledge graphs and large language models according to claim 8, characterized in that, The natural language reasoning chain guided by the synthetic knowledge path introduces a verifiable external symbolic logic path as a mandatory framework, transforming the large language model from an uncontrollable reasoner into a language organizer under strict supervision. This specifically includes the following sub-steps: Step C3.1: Construct structured prompt words containing multiple constraints, specifically including: Step C3.1.1: Input Integration: The construction of prompt words integrates two key information sources: knowledge paths and domain rules. The knowledge path uses the output symbolic path P_k as a mandatory logical framework; the domain rules introduce a portion of domain rules to guide the text generation style and the use of professional terminology. Step C3.1.2: Prompt word construction: Integrate the information from step C3.1.1 into a templated prompt word. This prompt word requires the large language model to play the role of a domain expert and strictly follow the given knowledge path to interpret each "entity-relationship-entity" link into a piece of natural language step by step. Step C3.2: Use chain-like thinking under knowledge constraints to synthesize the constructed structured prompt words and input them into the large language model; Step C3.2.1: Under the guidance of a strongly constrained framework, LLM executes controlled chain-like thinking generation; Step C3.2.2: The output is a step-by-step, detailed natural language reasoning process, where each step directly corresponds to a link in the knowledge path; Step C3.3: Generating the reasoning conclusion, specifically including: Step C3.3.1: Take the original question and the generated detailed reasoning process as input; Step C3.3.2: Call the large language model again and ask it to play the role of a summarizer. Its task is to generate a general conclusion that directly answers the question based on the given question and detailed reasoning steps. Step C3.4: Quality Control and Verification. The generated conclusions are subject to quality control using a dual verification mechanism, specifically including: Step C3.4.1: Logical verification: Design an independent verification task, and once again utilize the logical judgment capability of LLM. Provide LLM with the original question, detailed reasoning process and generated conclusion, and ask questions to perform logical verification, thus forming a self-consistency check. Step C3.4.2: Domain rule verification: Use another set of domain rule bases to verify the semantics and facts of the conclusions to ensure that even if the generated conclusions are logically consistent, they will not violate the core facts and axioms known in the domain. Step C3.5: Final output. Only conclusions that pass both logical verification and domain rule verification are considered high-quality, qualified data. Finally, the original question, qualified conclusions, and detailed reasoning process are combined into a complete, high-quality question-answering reasoning data sample.

10. A question-answering reasoning data synthesis system integrating knowledge graphs and large language models, characterized in that, The device includes a computer, the computer device comprising a processor and a memory, the memory storing a computer program that, when loaded by the processor, executes the method as described in any one of claims 1 to 9.