Unified inquiry method and system integrating question number and questions and answers for power 220kV transformer

By adopting a unified query method that integrates question data and question-answering for 220kV power transformers, the problems of multiple system jumps and information fragmentation in existing technologies have been solved. This method enables a unified response of power equipment data and knowledge, and improves the accuracy and timeliness of queries.

CN122065951APending Publication Date: 2026-05-19湖南省湘电试验研究院有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
湖南省湘电试验研究院有限公司
Filing Date
2025-12-15
Publication Date
2026-05-19

AI Technical Summary

Technical Problem

In existing technologies, the question-and-answer processing for 220kV power transformers is fragmented, requiring users to switch systems multiple times and manually summarize information. This results in poor timeliness and difficulty in ensuring consistency of conclusions. Furthermore, it is prone to misjudgment and bottlenecks in throughput and latency when dealing with complex engineering problems.

Method used

A unified query method integrating question count and question answering is adopted for 220kV power transformers. The question count branch and question answer branch are processed in parallel through two-layer hierarchical intent recognition modules. The structured answer is generated collaboratively by a large language model and context management module, and adaptive weighted fusion is performed to ensure the relevance and consistency of the answer.

Benefits of technology

This system integrates question counts and answers within a single query, improving the unified response of power equipment data and knowledge, reducing system jumps, enhancing the interactive experience and accuracy, and meeting the real-time and reliability requirements of power equipment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122065951A_ABST
    Figure CN122065951A_ABST
Patent Text Reader

Abstract

The invention discloses a unified inquiry method and system for fusing question number and questions and answers for an electric power 220kV transformer, and relates to the technical field of intelligent inquiry of power transformers, and the method comprises the steps: receiving a natural language question; semantic understanding and routing are conducted on the natural language questions, and after it is judged that the natural language questions are unified inquiry questions, question number branch processing and question and answer branch processing are started in parallel; obtaining a correlation score; and if the correlation score is not less than the correlation threshold, synthesizing the structured data snapshot and the structured answer into a unified answer. According to the method provided by the invention, the structured data verification corresponding to the question number and the knowledge reasoning and processing suggestions corresponding to the questions and answers are fused and processed in the same inquiry, so that the unified response of the data and knowledge of the power equipment is realized, and the problems of multi-round skipping and information splitting in a traditional system are avoided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent query technology for power transformers, and in particular to a unified query method and system for 220kV power transformers that integrates query data and query answers. Background Technology

[0002] Throughout the entire lifecycle of operation and maintenance, the main transformer of a 220kV substation requires both data analysis (verification and numerical query of historical test data or online monitoring data, i.e., data query / data statistics) and answers (explanation of equipment principles, fault handling suggestions, and operating procedure guidelines).

[0003] Existing technical solutions generally treat query counts (e.g., Text-to-SQL) and query answers (e.g., RAG) separately. This results in a user needing to navigate through multiple system jumps and manually compile information for a single complete query (e.g., "What is the data from the most recent test? Is it abnormal? How should it be handled?"), leading to poor timeliness and difficulty in ensuring consistent conclusions. Furthermore, existing intent recognition methods often rely on keywords or single classifiers, which can easily misclassify complex engineering problems in the power sector (e.g., "How many tests were conducted after jumping to G?") as "Jump to G diagnosis," leading to scenario mismatch. At the same time, Retrieval Enhanced Generation (RAG) often faces throughput and latency bottlenecks in engineering implementations, and real-time interactive scenarios have clear requirements for first-packet latency, streaming backhaul, and anomaly degradation.

[0004] Therefore, there is an urgent need for a unified query method and system for 220kV power transformers that integrates question counts and question answers to solve or at least alleviate some of the above-mentioned defects. This system should be able to integrate question counts and question answers in a single query, achieve accurate routing through high-precision intent recognition, reduce latency through an optimized architecture, improve the interactive experience, and ultimately form a unified answer that combines verifiable numerical conclusions with interpretable knowledge conclusions. Summary of the Invention

[0005] The main objective of this invention is to provide a unified query method and system for 220kV power transformers, integrating questions and answers. This aims to solve the technical problems in the prior art, where users need to perform multiple system jumps and manual information aggregation when making queries, resulting in poor timeliness and difficulty in ensuring the consistency of conclusions.

[0006] To achieve the above objectives, this invention provides a unified query method for merging questions and answers for 220kV power transformers, comprising the following steps:

[0007] S10, receiving natural language questions for a 220kV power transformer;

[0008] S20 performs semantic understanding and routing for natural language questions. After determining that the natural language question is a unified query, it initiates question-number branch processing and question-answer branch processing in parallel. Question-number branch processing includes: verifying and querying numerical data for 220kV transformer test data or monitoring data; parsing the natural language time expression in the natural language question to generate a time window; extracting data from a multi-source test library based on the time window to generate query data results; and constructing a structured data snapshot based on the query data results. Question-answer branch processing includes: the context management module integrates various structured data snapshots to generate a context package; the context package is injected into the question-answering model as a controlled input; and the question-answering model completes reasoning based on the context package to generate a structured answer.

[0009] S30: Obtain the question-branch relevance score between the structured data snapshot and the natural language question; obtain the question-answer branch relevance score between the natural language question and the structured answer; obtain the context consistency score between the natural language question and the previous answer; adaptively weight and fuse the question-branch relevance score, the question-answer branch relevance score, and the context consistency score to obtain the relevance score R.

[0010] S40: If the relevance score R is not less than the relevance threshold, then the structured data snapshot and the structured answer are combined into a unified answer; if the relevance score R is less than the relevance threshold, then proceed to step S20 and repeat steps S20 to S40 until a unified answer is obtained.

[0011] Furthermore, in step S20,

[0012] The first processing layer performs overall semantic understanding of the natural language problem through the intent understanding model, and obtains the first probability distribution of each candidate intent;

[0013] The second processing layer obtains the second probability distribution through enhanced semantic analysis and lightweight vector matching;

[0014] Using the formula P(i|x)=λ·P llm (i|x)+(1-λ)·P sem The fusion probability is obtained by fusion calculation using (i|x), where P(i|x) is the fusion probability, and P... llm Let P be the first probability distribution. sem Let λ be the second probability distribution, and λ be the fusion coefficient.

[0015] If the fusion probability is greater than the fusion threshold, the natural language question is determined to be a unified query, and the slot is extracted.

[0016] Furthermore, in step S20,

[0017] The context management module includes a context budget allocator and a consistency checker:

[0018] The context budget allocator is used to calculate the semantic relevance under the constraint of a given segmentation unit budget, and select the set of context segments based on the semantic relevance.

[0019] The consistency checker is used to perform conflict detection and consistency checks on the selected segments, removing contradictory or noisy content to obtain the context packet.

[0020] Furthermore, in step S30,

[0021] Using the formula R=σ(α·r) num +β·r qa +γ·r ctx The relevance score R is calculated, where r num The branch relevance score represents the number of questions, r. qa The question-answering branch relevance score, r ctx σ(·) represents the context consistency score, α, β, and γ are the weight coefficients corresponding to the question-branch relevance score, the question-answer branch relevance score, and the context consistency score, respectively.

[0022] Furthermore, the context consistency score r ctx Including slot consistency score c slot Consistency score of evidence (c) evd Time consistency score c time Safety consistency score c sec .

[0023] Furthermore, natural language questions are further subdivided, with α weight increased when the type is data verification or numerical query, and β weight increased when the type is principle explanation or handling suggestion.

[0024] Furthermore, the start event, fragment event, and completion event are pushed in a streaming manner using server-sent events (SSE) until the output is complete. The first packet response of the start event is no more than 0.1 seconds.

[0025] Furthermore, a start event is pushed at T=0.08s, a query data result is pushed at T=0.4s, a structured answer is pushed at T=0.9s, and a completion event is pushed at T=1.3s, where T is the response time.

[0026] This invention also provides a unified query system for 220kV power transformers that integrates question and answer functions, including a two-layer hierarchical intent recognition module, a parallel processing module, a context management module, a large language model, an adaptive weighted fusion module, and a central processing module. The two-layer hierarchical intent recognition module is used to perform intent recognition to determine whether a natural language question is a unified query.

[0027] The parallel processing module is used to initiate question count branch processing and question answer branch processing in parallel after determining that the natural language question is a unified query;

[0028] The context management module is used to dynamically construct context packages containing five types of context information. The context management module includes a context budget allocator and a consistency checker.

[0029] Question-answering models are used to receive context packets and complete inference;

[0030] The adaptive weighted fusion module is used to fuse the outputs of multiple branches to obtain the correlation score R;

[0031] The central processing module is used to implement the steps of the unified query method for fusion of questions and answers for 220kV power transformers.

[0032] Compared with existing technologies, the unified query method for merging questions and answers for 220kV power transformers provided by this invention has the following beneficial effects:

[0033] This invention provides a unified query method integrating question counting and question answering for 220kV power transformers. First, it receives natural language questions related to 220kV power transformers. Semantic understanding and routing are performed on the natural language questions. After determining that the natural language question is a unified query, question counting branch processing and question answering branch processing are initiated in parallel. Question counting branch processing generates query data results and ultimately constructs a structured data snapshot. Question answering branch processing employs a collaborative mechanism of "context management module as external brain and large language model as main brain." Before generation, the external brain dynamically constructs a context package containing instructions, dialogue, knowledge, tools, and state information, and injects the context package as controlled input into the main brain. The main brain completes reasoning based on the context package to generate a structured answer. Finally, the question counting branch relevance score, question answering branch relevance score, and context consistency score are adaptively weighted and fused to obtain a relevance score R. If the relevance score R is not less than a relevance threshold, the query data results and structured answer are combined into a unified answer. If the relevance score R is less than the relevance threshold, the steps are repeated until a unified answer is obtained. The present invention proposes a unified query method for 220kV power transformers that integrates question-based data verification and question-answering. This method integrates the structured data verification corresponding to the question with the knowledge reasoning and processing suggestions corresponding to the question and answer in the same query, achieving a unified response of power equipment data and knowledge, and avoiding the problems of multi-round jumps and information fragmentation in traditional systems. By adopting a collaborative architecture of a main brain and an external brain, the external brain can dynamically construct context packages and perform consistency checks, thereby ensuring the integrity and credibility of the main brain's reasoning input and realizing controllable knowledge enhancement generation. Attached Figure Description

[0034] 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 the structures shown in these drawings without creative effort.

[0035] Figure 1 This is a flowchart illustrating a unified query method for integrating questions and answers for 220kV power transformers, as described in one embodiment of the present invention.

[0036] Figure 2 This is a schematic diagram of the structure of a unified query system for 220kV power transformers that integrates question and answer functions, according to one embodiment of the present invention.

[0037] The objectives, features, and advantages of this invention will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation

[0038] It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.

[0039] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present invention.

[0040] It should be noted that all directional indications (such as up, down, left, right, front, back, etc.) in the embodiments of the present invention are only used to explain the relative positional relationship and movement of each component in a certain specific posture (as shown in the figure). If the specific posture changes, the directional indication will also change accordingly.

[0041] Furthermore, the use of terms such as "first" and "second" in this invention is for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of technical features indicated. Therefore, a feature defined with "first" or "second" may explicitly or implicitly include at least one of that feature. Additionally, the technical solutions of the various embodiments can be combined with each other, but only on the basis of being achievable by those skilled in the art. When the combination of technical solutions is contradictory or impossible to implement, such a combination of technical solutions should be considered non-existent and not within the scope of protection claimed by this invention.

[0042] Please refer to the appendix. Figure 1 This invention provides a unified query method for integrating questions and answers for 220kV power transformers, comprising the following steps:

[0043] S10, receiving natural language questions for a 220kV power transformer;

[0044] S20 performs semantic understanding and routing on natural language questions. After determining that the natural language question is a unified query, the question count branch processing and question answering branch processing are started in parallel.

[0045] The data processing includes: verifying and querying test or monitoring data of 220kV transformers; parsing the natural language time expression in natural language questions to generate time windows; extracting data from a multi-source test library based on the time windows to generate query data results; and constructing a structured data snapshot based on the query data results.

[0046] The question-answering branching process includes: the context management module integrates various structured data snapshots to generate a context package, which is then injected into the question-answering model as a controlled input; the question-answering model then uses the context package to perform reasoning and generate a structured answer.

[0047] S30: Obtain the question-branch relevance score between the structured data snapshot and the natural language question; obtain the question-answer branch relevance score between the natural language question and the structured answer; obtain the context consistency score between the natural language question and the previous answer; adaptively weight and fuse the question-branch relevance score, the question-answer branch relevance score, and the context consistency score to obtain the relevance score R.

[0048] S40: If the relevance score R is not less than the relevance threshold, then the structured data snapshot and the structured answer are combined into a unified answer; if the relevance score R is less than the relevance threshold, then proceed to step S20 and repeat steps S20 to S40 until a unified answer is obtained.

[0049] This invention provides a unified query method integrating question counting and question answering for 220kV power transformers. First, it receives natural language questions related to 220kV power transformers. Semantic understanding and routing are performed on the natural language questions. After determining that the natural language question is a unified query, question counting branch processing and question answering branch processing are initiated in parallel. Question counting branch processing generates query data results and ultimately constructs a structured data snapshot. Question answering branch processing employs a collaborative mechanism of "context management module as external brain and large language model as main brain." Before generation, the external brain dynamically constructs a context package containing instructions, dialogue, knowledge, tools, and state information, and injects the context package as controlled input into the main brain. The main brain completes reasoning based on the context package to generate a structured answer. Finally, the question counting branch relevance score, question answering branch relevance score, and context consistency score are adaptively weighted and fused to obtain a relevance score R. If the relevance score R is not less than a relevance threshold, the query data results and structured answer are combined into a unified answer. If the relevance score R is less than the relevance threshold, the steps are repeated until a unified answer is obtained. The present invention proposes a unified query method for 220kV power transformers that integrates question-based data verification and question-answering. This method integrates the structured data verification corresponding to the question with the knowledge reasoning and processing suggestions corresponding to the question and answer in the same query, achieving a unified response of power equipment data and knowledge, and avoiding the problems of multi-round jumps and information fragmentation in traditional systems. By adopting a collaborative architecture of a main brain and an external brain, the external brain can dynamically construct context packages and perform consistency checks, thereby ensuring the integrity and credibility of the main brain's reasoning input and realizing controllable knowledge enhancement generation.

[0050] Understandably, in the question-and-answer branch processing of step S20, the query data result refers to the raw data retrieved from external media such as databases, which may contain a lot of useless information. For example, a table may have 100 fields, some of which are unrelated to the current question and answer. The structured data snapshot integrates and extracts the raw content of the query data result, selects the relevant and useful content, forms a data snapshot, reduces prompt words, and focuses the model's attention.

[0051] Furthermore, in step S20,

[0052] The first processing layer performs overall semantic understanding of the natural language problem through the intent understanding model, and obtains the first probability distribution of each candidate intent;

[0053] The second processing layer obtains the second probability distribution through enhanced semantic analysis and lightweight vector matching;

[0054] Using the formula P(i|x)=λ·P llm (i|x)+(1-λ)·P sem The fusion probability is obtained by fusion calculation using (i|x), where P(i|x) is the fusion probability, and P... llm Let P be the first probability distribution. sem Let λ be the second probability distribution, and λ be the fusion coefficient.

[0055] If the fusion probability is greater than the fusion threshold, the natural language question is determined to be a unified query, and the slot is extracted.

[0056] Understandably, the first processing layer employs a large model layer, and the second processing layer employs a semantic analysis layer. In a specific embodiment of the present invention, the context packet is injected into the large language model as a controlled input. The large language model completes reasoning based on the context packet to generate a structured answer. The first processing layer performs overall semantic understanding of the natural language question through the large language model to obtain the first probability distribution of each candidate intent. In the present invention, the intent model and the question-answering model can be trained separately, or the intent and question-answering models can be trained simultaneously based on the large language model, that is, the large language model includes the intent model and the question-answering model.

[0057] Furthermore, in step S20,

[0058] The context management module includes a context budget allocator and a consistency checker:

[0059] The context budget allocator is used to calculate the semantic relevance under the constraint of a given segmentation unit budget, and select the set of context segments based on the semantic relevance.

[0060] The consistency checker is used to perform conflict detection and consistency checks on the selected segments, removing contradictory or noisy content to obtain the context packet.

[0061] Understandably, in the solution of this invention, the context budget allocator is used to select the context fragment set preferentially under the constraint of a given segmentation unit budget, using a selection algorithm based on relevance gain and timeliness weight. Specifically, the large language model directly selects based on prompt words, which can be information such as, "You are a context selection expert, you will select useful information, and you should prioritize useful information. Useful information includes, but is not limited to: the user's explicitly expressed needs and preferences; important decision nodes and reasons; recurring problems and solutions; basic information such as the user's role, responsibilities, and technology stack."

[0062] Furthermore, in step S30,

[0063] Using the formula R=σ(α·r) num +β·r qa +γ·r ctx The relevance score R is calculated, where r num The branch relevance score represents the number of questions, r. qa The question-answering branch relevance score, r ctx σ(·) represents the context consistency score, α, β, and γ are the weight coefficients corresponding to the question-branch relevance score, the question-answer branch relevance score, and the context consistency score, respectively.

[0064] Understandably, contextual consistency scoring primarily considers the relevance of consecutive questions and answers, measuring the consistency between multiple questions and comprehensively considering the integration of the current question with the previous answer. In this invention, the analysis is conducted from three dimensions: question-branch relevance score, question-answer branch relevance score, and contextual consistency score, each considering its relevance to natural language questions.

[0065] Furthermore, the context consistency score r ctx Including slot consistency score c slot Consistency score of evidence (c) evd Time consistency score c time Safety consistency score c sec .

[0066] Furthermore, natural language questions are further subdivided, with α weight increased when the type is data verification or numerical query, and β weight increased when the type is principle explanation or handling suggestion.

[0067] Furthermore, the start event, fragment event, and completion event are pushed in a streaming manner using server-sent events (SSE) until the output is complete. The first packet response of the start event is no more than 0.1 seconds.

[0068] Furthermore, a start event is pushed during the first duration, query data results are pushed during the second duration, a structured answer is pushed during the third duration, and a completion event is pushed during the fourth duration, wherein the first duration < the second duration < the third duration < the fourth duration.

[0069] In one specific embodiment of the present invention, a start event is pushed when T = 0.08s, a query data result is pushed when T = 0.4s, a structured answer is pushed when T = 0.9s, and a completion event is pushed when T = 1.3s, where T is the response time. Understandably, the system will push multiple events sequentially, and T records the timing information of the response to each event.

[0070] The specific implementation of the suggestions provided by this invention regarding the verification and handling of winding DC resistance data after a 220kV main transformer trip is as follows:

[0071] The system receives natural language questions related to 220kV power transformers. One such question is: "Is the DC resistance of the windings of transformer A (ID:T-101) abnormal compared to the same period last year within 48 hours after the trip? What actions need to be taken?"

[0072] The two-layered intent recognition module is activated, P llm The layer (large model layer) understands semantics and identifies multiple intents such as "data query", "data comparison", "anomaly diagnosis", and "action suggestions". sem The semantic analysis layer matches the entities "Transformer A", "Winding DC Resistance", and the time sequence terms "48 hours after tripping" and "last year's data"; the formula P(i|x) = λ·P is used. llm (i|x)+(1-λ)·P sem (i|x) is used to perform fusion calculations to obtain the fusion probability. Based on the comparison with the fusion threshold, it is determined to be a "unified inquiry" intent, and the slot `transformer_id = T-101` and `test_name = DC resistance` are extracted. The system starts "question number branch processing" and "question answer branch processing" in parallel.

[0073] The specific data processing includes: Time analysis: analyzing "48 hours after tripping" (relative time window) and "the same period last year" (comparative time window); Data extraction: extracting "winding DC resistance" data of T-101 within the above two time windows from the test library; Snapshot construction: performing key temperature correction (converting resistance values ​​at different temperatures to the same reference temperature), performing field alignment and outlier detection, and constructing a structured data snapshot; Indicator calculation: calculating the difference, three-phase imbalance, significance and trend, and generating chart rendering parameters.

[0074] The question-and-answer branching process includes: initiating the collaborative mechanism of the "main brain (large language model) and external brain (context management module)", with the context management module starting to build a context package; knowledge retrieval: RAG retrieves knowledge fragments such as "winding DC resistance temperature correction procedure DL / T 596", "DC resistance three-phase imbalance criterion", "connection fault mechanism", and "retesting procedure"; consistency verification: the external brain's consistency verifier finds that the "question-and-answer branching process" uses 75℃ as the reference temperature, while a fragment recalled by RAG mentions the old procedure of 20℃, and the external brain downgrades or removes the conflicting fragment; context package construction and injection: the external brain combines the verified knowledge fragments, tool (chart rendering API) descriptions, dialogue status (T-101), etc. into a context package and injects it into the main brain (LLM); main brain reasoning: the main brain generates a structured answer based on the context package: "[1. anomaly judgment] + [2. evidence (based on data corrected to 75℃)] + [3. handling suggestions (retesting and calibration, checking terminals, verifying temperature control)]".

[0075] Fusion and Output: The adaptive weighted fusion module adaptively weights and fuses the results of the two branches; Branch Optimization: The system identifies the problem type as "data verification as the primary focus, and handling suggestions as secondary focus," and increases the weight α of the question-based branch; Consistency Score: Due to the successful verification in the previous steps, the c_evd (evidence consistency) score is high, and the overall r_ctx score is high; Fusion Calculation: The fusion is calculated using the formula R = σα·r num +β·r qa +γ·r ctx Calculate the total score and synthesize a unified answer; if the relevance score R is not less than the relevance threshold, then synthesize the query data results and the structured answer into a unified answer; if the relevance score R is less than the relevance threshold, repeat the steps until a unified answer is obtained.

[0076] SSE streaming output: T = 0.08s: push stream_start (start event), satisfying the first packet ≤ 0.1s; T = 0.4s: push num_chunk (statistical indicators and chart parameters of "DC resistance anomaly" calculated by the question-and-answer branch); T = 0.9s: push qa_chunk ("handling suggestions" fragment generated by the question-and-answer branch); T = 1.3s: push complete (complete event).

[0077] The specific embodiments of the present invention regarding the explanation of abnormal trends and causes in the chromatogram of 220kV main transformer oil are as follows:

[0078] The system receives natural language questions related to a 220kV power transformer, specifically: "How many times has the oil chromatography of transformer B (ID:T-102) shown abnormalities in the past three months? What are the main causes? Please provide a maintenance suggestion?"

[0079] The two-layered intent recognition module is activated via the formula P(i|x)=λ·P llm (i|x)+(1-λ)·P sem (i|x) fusion, identified as "unified query (data statistics + cause explanation)"; the system starts "question data branch processing" and "question answer branch processing" in parallel.

[0080] The specific processing of the data branch includes: parsing the "last three months" as a dynamic time window; extracting oil chromatographic component data and procedure thresholds such as H2, CH4, C2H2, C2H4, and C2H6 from T-102; snapshot construction and calculation: performing anomaly detection and group statistics, and outputting charts and statistical segments with "Number of anomalies: 3 times", "Main abnormal component: C2H2", and "Comparison with the same period: Increased by 20%".

[0081] The question-and-answer branch processing includes: initiating the collaborative mechanism of the "main brain (large language model) and external brain (context management module)", and the context management module begins to construct context packages; knowledge recall: RAG retrieves fragments such as "oil chromatography diagnostic method (three ratio method)", "fault type corresponding to C2H2 exceeding the standard (arc discharge)", and "maintenance strategy (internal inspection, oil filtration)"; consistency verification: the consistency verifier of the external brain performs c_evd (evidence consistency) check and finds that "main abnormal component: C2H2" reported by the "question number branch processing" is highly consistent with "C2H2 exceeding the standard corresponds to arc discharge" recalled by the "question-and-answer branch" RAG. At the same time, it finds that another RAG fragment mentions "CH4 exceeding the standard corresponds to overheating", which is inconsistent with the result of the question number branch processing. This fragment is downgraded; injection and reasoning: the main brain receives highly consistent context packages and generates in streaming: "[1. Cause diagnosis: there is a risk of arc discharge] + [2. Verification path: combined with partial discharge detection] + [3. Recommendation: arrange power outage for internal inspection and sampling retest]".

[0082] The adaptive weighted fusion module performs adaptive weighted fusion of the two branch results; Consistency score: due to the high mutual verification between "C2H2" and "arc discharge" in the previous steps, r_ctx obtains a high score; Fusion calculation: using the formula R=σ(α·r num +β·r qa +γ·r ctx Adaptive weighting is applied, and a high `r_ctx` increases the confidence of the final answer.

[0083] SSE streaming output: The system prioritizes pushing the numerical conclusion of "Number of anomalies: 3 times", and then streams the knowledge conclusions of "Cause Diagnosis" and "Maintenance Suggestions".

[0084] Although the steps are described in the claims and specification using S-numbers such as S10, S20, S30, etc., those skilled in the art should understand that, unless otherwise expressly stated, these numbers are for ease of description only and do not constitute a mandatory limitation on the order of execution of the steps. In some embodiments, some steps may be performed in parallel, in a different order, or omitted without departing from the core technical solution of the present invention, as long as the technical effects of the present invention can be achieved.

[0085] The advantages of this invention are:

[0086] For the first time, "question count" (structured data verification) and "question answer" (knowledge reasoning and handling suggestions) are integrated into a single query, achieving a unified response of power equipment data and knowledge, avoiding the problems of multi-round jumps and information fragmentation in traditional systems. By proposing a "two-layer hierarchical intent recognition" mechanism, combined with the probability distribution of a large language model and semantic enhancement matching results, the accuracy of intent recognition in complex power scenarios can be significantly improved, reducing misjudgments and scenario mismatches. A "main brain + external brain" collaborative architecture is adopted, in which the external brain can dynamically construct context packets and perform consistency checks, thereby ensuring the integrity and credibility of the main brain's reasoning input and achieving controllable knowledge enhancement generation. The proposed uncertainty-based adaptive weighted fusion algorithm can dynamically adjust the weights of the question count branch and the question answer branch according to different question types, achieving adaptive optimization of result credibility. The system supports the SSE streaming output mechanism, which can respond to the first packet within 0.1 seconds, meeting the high requirements of power intelligent query for real-time performance and interactive experience.

[0087] Please refer to Figure 2 This invention provides a unified query system that integrates question and answer functions for 220kV power transformers.

[0088] It includes a two-layer hierarchical intent recognition module, a parallel processing module, a context management module, a large language model, an adaptive weighted fusion module, and a central processing module. The large language model includes an intent model and a question-answering model.

[0089] The two-layered intent recognition module is used to determine whether a natural language question is a unified query.

[0090] The parallel processing module is used to initiate question count branch processing and question answer branch processing in parallel after determining that the natural language question is a unified query;

[0091] The context management module is used to dynamically construct context packages containing five types of context information. The context management module includes a context budget allocator and a consistency checker.

[0092] Question-answering models are used to receive context packets and complete inference;

[0093] The adaptive weighted fusion module is used to fuse the outputs of multiple branches to obtain the correlation score R;

[0094] The central processing module is used to implement the steps of the unified query method for fusion of questions and answers for 220kV power transformers.

[0095] The above embodiments are merely illustrative of several implementation methods of this application, and their descriptions are relatively specific and detailed. However, they should not be construed as limiting the scope of this application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A unified query method integrating question and answer for 220kV power transformers, characterized in that, Includes the following steps: S10, receiving natural language questions for a 220kV power transformer; S20, perform semantic understanding and routing on the natural language question, and after determining that the natural language question is a unified query, start the question number branch processing and question answer branch processing in parallel; The question-and-data branching process includes: verifying and querying 220kV transformer test data or monitoring data; parsing the natural language time expression in the natural language question to generate a time window; extracting data from a multi-source test library based on the time window to generate query data results; and constructing a structured data snapshot based on the query data results. The question-answering branching process includes: a context management module integrating each of the structured data snapshots to generate a context package, which is then injected into the question-answering model as a controlled input; and the question-answering model performing reasoning based on the context package to generate a structured answer. S30, obtain the question-branch relevance score between the structured data snapshot and the natural language question; obtain the question-answer branch relevance score between the natural language question and the structured answer; obtain the context consistency score between the natural language question and the previous answer; perform adaptive weighted fusion of the question-branch relevance score, the question-answer branch relevance score, and the context consistency score to obtain the relevance score R; S40, if the relevance score R is not less than the relevance threshold, then the structured data snapshot and the structured answer are combined into a unified answer; if the relevance score R is less than the relevance threshold, then proceed to step S20, and repeat steps S20 to S40 until the unified answer is obtained.

2. The unified query method for merging questions and answers for 220kV power transformers according to claim 1, characterized in that, In step S20, The first processing layer performs overall semantic understanding of the natural language problem through the intent understanding model, and obtains the first probability distribution of each candidate intent; The second processing layer obtains the second probability distribution through enhanced semantic analysis and lightweight vector matching; Using the formula P(i|x)=λ·P llm (i|x)+(1-λ)·P sem The fusion probability is obtained by fusion calculation using (i|x), where P(i|x) is the fusion probability, and P... llm Let P be the first probability distribution. sem Let λ be the second probability distribution, and λ be the fusion coefficient. If the fusion probability is greater than the fusion threshold, the natural language question is determined to be a unified query, and the slot is extracted.

3. The unified query method for merging questions and answers for 220kV power transformers according to claim 1, characterized in that, In step S20, The context management module includes a context budget allocator and a consistency checker: The context budget allocator is used to calculate the semantic relevance degree using a selection algorithm based on relevance gain and timeliness weight under the constraint of a given word segmentation unit budget, and select a set of context fragments based on the semantic relevance degree. The consistency checker is used to perform conflict detection and consistency verification on the selected segments, remove contradictory or noisy content, and obtain the context packet.

4. The unified query method for integrating questions and answers for 220kV power transformers according to claim 1, characterized in that, In step S30, Using the formula R=σ(α·r) num +β·r qa +γ·r ctx The correlation score R is calculated by , where r num The number of branches represents the relevance score of the question, r. qa The relevance score of the question-and-answer branch is represented by r. ctx The context consistency score is represented by σ(·), which is the Sigmoid function. α, β, and γ are the weighting coefficients corresponding to the question-branch relevance score, the question-answer branch relevance score, and the context consistency score, respectively.

5. The unified query method for merging questions and answers for 220kV power transformers according to claim 4, characterized in that, The context consistency score r ctx Including slot consistency score c slot Consistency score of evidence (c) evd Time consistency score c time Safety consistency score c sec .

6. The unified query method for merging questions and answers for 220kV power transformers according to claim 4, characterized in that, The natural language problem is further subdivided, and the α weight is increased when the type is data verification or numerical query, and the β weight is increased when the type is principle explanation or handling suggestion.

7. The unified query method for merging questions and answers for 220kV power transformers according to any one of claims 1 to 4, characterized in that, The start event, fragment event, and completion event are pushed in a streaming manner using server-sent events (SSE) until the output is complete, wherein the first packet response of the start event is no longer than 0.1 seconds.

8. The unified query method for merging questions and answers for 220kV power transformers according to claim 7, characterized in that, The first duration is used to push the start event, the second duration is used to push the query data results, the third duration is used to push the structured answer, and the fourth duration is used to push the completion event, wherein the first duration < the second duration < the third duration < the fourth duration.

9. A unified query system integrating question and answer for 220kV power transformers, characterized in that, It includes a two-layered intent recognition module, a parallel processing module, a context management module, a large language model, an adaptive weighted fusion module, and a central processing module. The two-layered intent recognition module is used to perform intent recognition to determine whether the natural language question is a unified query. The parallel processing module is used to initiate question count branch processing and question answer branch processing in parallel after determining that the natural language question is a unified query; The context management module is used to dynamically construct a context package containing five types of context information. The context management module includes a context budget allocator and a consistency checker. The question-answering model is used to receive the context packet and complete inference; The adaptive weighted fusion module is used to fuse the multi-branch outputs to obtain a correlation score R; The central processing module is used to implement the steps of the unified query method for fusion of questions and answers for 220kV power transformers as described in any one of claims 1 to 8.