An electric power service-based method and system for question answering by an agent

CN122432385APending Publication Date: 2026-07-21GUANGZHOU POWER SUPPLY BUREAU GUANGDONG POWER GRID CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
GUANGZHOU POWER SUPPLY BUREAU GUANGDONG POWER GRID CO LTD
Filing Date
2026-04-29
Publication Date
2026-07-21

Smart Images

  • Figure CN122432385A_ABST
    Figure CN122432385A_ABST
Patent Text Reader

Abstract

The application discloses an intelligent agent question and answer method and system based on power services, and belongs to the field of intelligent agent question and answer. A power system CIM / XML file is acquired, binary classification analysis is carried out on the file based on device entities and topological relations, and standardization mapping of device entity class names and device attribute names is completed relying on a preset Chinese-English mapping table. Based on the mapped related information and combined with the topological relation information, a device entity table and a topological relation table are generated, a single topological connection description is obtained through a preset text generation template, and after integration according to a power feeder level, a power topological natural language textual description is formed. A user power service question is received, which is input into a preset power operation and maintenance intelligent agent together with the textual description, the power topological structure is recognized by the intelligent agent and reasoning is completed, and finally, a power service question and answer result is output. The application effectively solves the problem that the prior art cannot accurately and efficiently answer the power services of the power system based on the intelligent agent.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent agent question answering, and in particular to an intelligent agent question answering method and system based on power business. Background Technology

[0002] Power topology CIM / XML data is core data for power operation and maintenance. However, this format is machine-readable and cannot be directly recognized and used by large-scale intelligent agents. It needs to be converted into natural language text descriptions. In existing technologies, textual descriptions of power topology mostly rely on manual writing, which is inefficient, error-prone, and has inconsistent description formats, making it unsuitable as standardized input for large-scale intelligent agents. A few automated textualization methods process CIM / XML data based on general XML parsing tools. The parsed data structure is chaotic, lacking standardized equipment attributes and topology relationship classifications. The generated text descriptions are semantically ambiguous and lack information, failing to support power business reasoning for large-scale intelligent agents.

[0003] Meanwhile, existing CIM / XML parsing lacks standardized Chinese-English mapping for device class names and attributes, resulting in text descriptions containing numerous technical English terms and poor readability. Furthermore, the parsed data lacks text-based structuring, hindering accurate text matching of "device-connection relationship-device." Large-scale power model agents cannot accurately identify power topology structures based on this text, making it difficult to generate effective outage operation procedures, fault analysis suggestions, and other maintenance decisions. In addition, existing power large-scale model agents lack standardized topology information input methods, with topology information primarily consisting of unstructured text. These shortcomings prevent current technologies from accurately and efficiently answering questions about power system operations based on the agent. Summary of the Invention

[0004] This invention provides an intelligent agent question-answering method and system based on power business, in order to solve the problem in the prior art that it is impossible to accurately and efficiently answer questions about power business in the power system based on intelligent agents.

[0005] Firstly, this application provides an intelligent agent question-answering method based on power business, including: Obtain the CIM / XML file of the power system, wherein the CIM / XML file includes power equipment entities, attribute parameters, and topology connection relationships; Based on the equipment entities and topology relationships of the power system, the equipment entity class names, equipment attribute names and topology relationship information in the CIM / XML file are extracted, and the equipment entity class names and equipment attribute names are standardized and mapped based on a preset Chinese-English mapping table. Based on the standardized mapping of device entity class names and device attribute names, combined with the topology relationship information, a device entity table and a topology relationship table are generated. Based on the device entity table and topology relationship table, and combined with the preset text generation template, a single topology connection description is generated, and the single topology connection description is integrated according to the power feeder level to obtain a natural language textual description of the power topology. The system receives power service questions input by the user, and inputs the power service questions and the natural language text description together into a preset power operation and maintenance intelligent agent. The power operation and maintenance intelligent agent identifies the power topology based on the natural language text description, infers the power service questions based on the power topology, and outputs power service question-and-answer results.

[0006] This application acquires CIM / XML files and performs binary classification parsing for textual descriptions of power topology. Combined with standardized Chinese-English mapping, it generates structured equipment entity tables and topology relationship tables, transforming machine-readable raw data into standardized tabular data containing Chinese equipment attributes and precise connection relationships. This solves the problems of chaotic data structure and poor readability in existing technologies. Based on this, and using preset text generation templates and feeder-level integration processing, it automatically generates natural language topology descriptions following a unified semantic format of "equipment-connection node-equipment," replacing manual writing and significantly improving textualization efficiency and format standardization. Furthermore, power business questions are input along with this standardized topology text into a power operation and maintenance intelligent agent, enabling the agent to accurately identify the power topology structure and reason based on upstream and downstream connection relationships, ultimately outputting accurate question-and-answer results. This achieves end-to-end automation from unstructured power data to highly reliable intelligent question-and-answer, effectively solving the problem that existing technologies cannot accurately and efficiently answer power business questions based on intelligent agents.

[0007] Furthermore, the step of extracting the equipment entity class name, equipment attribute name, and topology relationship information from the CIM / XML file based on the equipment entities and topology relationships of the power system specifically involves: Scan the CIM / XML file node by node to locate the device entity nodes and topology connection nodes; Based on the device entity node, the device entity class tag is located by regular expression matching, and the device identification information, device name information and rated parameter information in the device entity class tag are extracted. The device entity class name is determined based on the device name information, and the device attribute name is determined based on the rated parameter information; Based on the topology data in the CIM / XML file, the connection node type is identified and the connection node identifier is recorded. Based on the connection node identifier, the associated device identifier is retrieved, the device pair associated with the connection node is determined, and the device identifier in the device pair and the connection node identifier are constructed into a triple to form the topology information.

[0008] This application precisely locates equipment entity class tags by scanning CIM / XML files node by node and using regular expression matching. This allows for the rapid extraction of equipment identifiers, names, and rated parameters, resulting in accurate equipment entity class names and attribute names. Simultaneously, by identifying connection node types and retrieving associated equipment pairs based on unique connection node identifiers, the application constructs triples from equipment identifiers and connection node identifiers, forming precise topology relationship information. This binary classification parsing method avoids the data structure chaos caused by general XML parsing tools, ensuring clear separation and complete information between equipment entities and topology relationships. This provides a reliable data foundation for the subsequent generation of standardized equipment entity tables and topology relationship tables, thereby improving the accuracy and automation efficiency of power topology textual descriptions. Ultimately, it ensures that large-scale intelligent agents can perform reasoning based on the correct topology structure, significantly improving the reliability of power business question answering.

[0009] Furthermore, the standardization mapping process for the device entity class name and device attribute name based on the preset Chinese-English mapping table is as follows: Based on a preset Chinese-English mapping table, the device entity class name and device attribute name are converted from English to Chinese to obtain Chinese-language device entity information; the Chinese-English mapping table includes the correspondence between English device class names and Chinese device class names, as well as the correspondence between English attribute names and Chinese attribute names; Based on the Chinese-language device entity information and the topology relationship information, the data is structured according to the preset CSV field definitions to generate a device entity table and a topology relationship table. The device entity table includes device identifier, Chinese device type, and Chinese attribute parameters. The topology relationship table includes starting device identifier, ending device identifier, Chinese connection relationship, and connection node identifier.

[0010] This application uses a pre-defined English-Chinese mapping table containing the correspondence between English and Chinese to convert equipment entity class names and equipment attribute names from English to Chinese, resulting in Chinese-language equipment entity information. This eliminates the readability issues caused by the large number of professional English terms in the original CIM / XML data, making the generated text descriptions more in line with the understanding habits of power business personnel. Based on this, the Chinese-language equipment entity information and topology relationship information are structured according to pre-defined CSV field definitions, generating an equipment entity table containing equipment identifiers, Chinese equipment types, and Chinese attribute parameters, as well as a topology relationship table containing starting equipment identifiers, ending equipment identifiers, Chinese connection relationships, and connection node identifiers. This standardized tabular data structure achieves precise separation of equipment attributes and topology connections, providing a clear and unambiguous data source for subsequent text generation templates. It avoids semantic ambiguity and information loss caused by chaotic data structures, thus significantly improving the accuracy and consistency of the natural language textual description of power topology. Ultimately, this enables large-scale intelligent models to accurately identify power topology structures based on standardized input and output reliable business question-and-answer results.

[0011] Furthermore, based on the device entity table and topology relationship table, and combined with a preset text generation template, a single topology connection description is generated. This single topology connection description is then integrated and processed according to the power feeder level to obtain a natural language textual description of the power topology, specifically: Based on the starting device identifier, ending device identifier, and connection node identifier in the topology table, query the device entity table to obtain the Chinese names of the starting device, ending device, and connection node. Based on a preset text generation template, the Chinese names of the starting device, the connecting node, and the terminating device are filled into the template to generate a single topology connection description. Based on the relationship between the equipment and the power feeder in the equipment entity table, the single topology connection description is divided into the corresponding group using the power feeder identifier as the grouping key, thus obtaining a set of single topology connection descriptions under each power feeder. Based on the device identifiers in the single topology connection description set, the device entity table is queried, the queried devices are deduplicated and sorted by voltage level and device type to generate a device list; Following the topological connectivity order from upstream to downstream, each individual topological connection description in the set of individual topological connection descriptions is sequentially assembled. Duplicate connection relationships in the loop structure and branch point structure are deduplicated to form the whole feeder topological description. Integrate the equipment list and the feeder topology description to output a natural language textual description of the power topology.

[0012] This application obtains the Chinese names of the starting device, ending device, and connecting node by querying the device entity table based on the starting device identifier, ending device identifier, and connecting node identifier in the topology relationship table. It then uses a preset text generation template to fill these Chinese names into the template, generating a single topology connection description that follows a unified semantic format of "device-connecting node-device," thus solving the problems of low efficiency and inconsistent formatting associated with manual writing. Based on this, the application divides the single description into corresponding groups using the power feeder identifier as the grouping key. It then queries the device entity table based on the device identifier, deduplicating the devices and sorting them by voltage level and device type to generate a clear device list. Simultaneously, it sequentially assembles each single description according to the topology connectivity order from upstream to downstream, deduplicating duplicate connections in loops and branch points to form a complete feeder topology description. Finally, it integrates the device list and the complete feeder topology description to output a complete natural language text description. This series of steps ensures that the generated text contains a complete list of all devices on the feeder line, accurately reconstructs the topological relationships between devices according to the physical connection order, and avoids redundancy and ambiguity. This provides a standardized input with complete information, clear semantics, and unified structure for large model agents, significantly improving the accuracy of agents in recognizing power topology structures and the reliability of subsequent business question answering.

[0013] Furthermore, the step of receiving the user's input power service question and inputting the power service question along with the natural language text description into a preset power operation and maintenance intelligent agent specifically involves: The system receives power service questions input by users and parses the query granularity of the power service questions; the query granularity includes single device granularity, single relationship granularity, and feeder granularity. When the query granularity is single device granularity or single relation granularity, a single topology connection description corresponding to the power business problem is selected from the natural language text description as the input text; When the query granularity is the feeder granularity, the whole feeder topology description corresponding to the power business problem is selected from the natural language text description as the input text. The text to be input is concatenated with the power business question according to a preset prompt instruction format to generate an input instruction that conforms to the input interface specification of the power operation and maintenance intelligent agent, and the input instruction is sent to the power operation and maintenance intelligent agent.

[0014] This application receives user-inputted power service questions and analyzes their query granularity. It automatically identifies whether the question is at the single-device, single-relationship, or feeder granularity level, thus accurately matching the corresponding input text for each granularity: for single-device or single-relationship granularity questions, a single topology connection description is selected as the input text, avoiding interference from irrelevant information; for feeder granularity questions, a complete feeder topology description is selected as the input text, ensuring the integrity of global topology information. Based on this, the input text and the power service question are concatenated according to a preset prompt instruction format to generate an input instruction conforming to the power operation and maintenance intelligent agent input interface specification, which is then sent to the intelligent agent. This mechanism of adaptively selecting input text based on query granularity avoids both excessive input of irrelevant topology information leading to decreased reasoning efficiency and insufficient input information resulting in missing reasoning basis. It allows the intelligent agent to achieve an optimal balance between information density and information integrity, significantly improving the agent's response speed and reasoning accuracy for power service questions of different granularities, ultimately achieving efficient and accurate intelligent question answering for power services.

[0015] Furthermore, the step of enabling the power operation and maintenance intelligent agent to identify the power topology based on the natural language textual description specifically involves: The power operation and maintenance intelligent agent receives the natural language textual description and performs semantic parsing on the natural language textual description; Extract device names, connection node names, and connection relationship terms between devices from the parsing results; Based on the device name, connection node name, and connection relation terms, a semantic topology graph is constructed with devices as nodes and connection relations as edges, which serves as the power topology structure identified by the power operation and maintenance intelligent agent.

[0016] This application utilizes a power operation and maintenance intelligent agent to receive natural language textual descriptions and perform semantic parsing. From these descriptions, device names, connection node names, and connection relationship terms between devices are extracted. Based on this information, a semantic topology graph is constructed, with devices as nodes and connection relationships as edges, serving as the power topology structure recognized by the intelligent agent. This process transforms unstructured natural language text into a structured graph model, enabling the intelligent agent to accurately understand upstream and downstream connections, branch points, and loop structures between devices. This avoids structural recognition errors caused by semantic ambiguity or missing information in traditional methods. Based on this semantic topology graph, the intelligent agent can subsequently perform efficient reasoning operations such as path search and impact range analysis. This provides a reliable topological cognitive foundation for power business Q&A, including power outage operation procedure generation and fault analysis suggestions, significantly improving the agent's accuracy in recognizing complex power topologies and the effectiveness of subsequent reasoning.

[0017] Furthermore, the step of reasoning about the power business problem based on the power topology and outputting the power business question-and-answer result specifically involves: The power operation and maintenance intelligent agent analyzes the power business problem and extracts the target device identifier or target operation type from the power business problem; Based on the target device identifier, locate the target device node in the power topology; A propagation path search is performed along the upstream and downstream connections of the target device node in the power topology to determine the set of influencing devices associated with the target device node. Based on the target operation type and the set of affected devices, an operation step sequence or analysis suggestion statement is generated according to the preset power operation and maintenance business rules, and output as the power business Q&A result.

[0018] This application utilizes a power operation and maintenance intelligent agent to analyze power business issues, extracting target device identifiers or target operation types. Based on the target device identifier, it precisely locates the target device node in a constructed semantic topology graph. Then, it searches for propagation paths along the upstream and downstream connections of this node in the topology, determining the set of influencing devices associated with the target device node, thus comprehensively understanding the target device's influence range in the power network. On this basis, according to the target operation type and the set of influencing devices, it generates a sequence of operation steps or analysis suggestions according to preset power operation and maintenance business rules, outputting the power business question-and-answer results. This process enables the intelligent agent to perform causal reasoning and impact analysis based on a precise topology structure, avoiding misjudgments or omissions caused by the lack of structured topology information in traditional methods. It achieves automated and accurate answers to complex business issues such as power outage operation procedures and fault propagation paths, significantly improving the security and efficiency of power operation and maintenance decision-making, and providing reliable technical support for intelligent question-and-answer in power business.

[0019] Secondly, this application provides an intelligent agent question-answering system based on power business. The intelligent agent question-answering system based on power business includes: The acquisition module is used to acquire the CIM / XML file of the power system, wherein the CIM / XML file includes power equipment entities, attribute parameters, and topology connection relationships; The extraction module is used to extract the equipment entity class name, equipment attribute name and topology relationship information from the CIM / XML file based on the equipment entity and topology relationship of the power system, and to perform standardized mapping processing on the equipment entity class name and equipment attribute name based on a preset Chinese-English mapping table. The first generation module is used to generate a device entity table and a topology relationship table based on the standardized mapping process of the device entity class name and device attribute name, combined with the topology relationship information. The second generation module is used to generate a single topology connection description based on the device entity table and the topology relationship table, combined with a preset text generation template, and to integrate the single topology connection description according to the power feeder level to obtain a natural language textual description of the power topology. The output module is used to receive power service questions input by the user, input the power service questions and the natural language text description together into a preset power operation and maintenance intelligent agent, so that the power operation and maintenance intelligent agent can identify the power topology based on the natural language text description, reason about the power service questions based on the power topology, and output power service question and answer results.

[0020] This application acquires CIM / XML files through an acquisition module, extracts the files using a binary classification parsing module and performs standardized Chinese-English mapping, and generates a structured equipment entity table and topology relationship table based on these. A second generation module, based on these tables and combining them with a text generation template and feeder hierarchy integration, automatically outputs a natural language textual description of the power topology. The output module receives user questions and inputs this standardized text into a power operation and maintenance intelligent agent, enabling the agent to accurately identify the topology structure and perform reasoning and question answering. These modules collaborate to achieve end-to-end automated intelligent question answering, from unstructured raw power data to standardized tables and then to semantically clear textual topology descriptions. This solves the problems of chaotic data structures, low efficiency of manual coding, and missing input information for large models in existing technologies, significantly improving the accuracy and automation level of power business question answering. Attached Figure Description

[0021] Figure 1 : A schematic flowchart of an embodiment of the intelligent agent question-answering method based on power business provided in this application; Figure 2 : A schematic diagram of an embodiment of the intelligent agent question-answering system based on power business provided in this application. Detailed Implementation

[0022] 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 some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0023] Example 1 Please refer to Figure 1In order to solve the problem that existing technologies cannot accurately and efficiently answer questions about power system services based on intelligent agents, this invention provides an intelligent agent question-answering method based on power services, including steps S01-S05.

[0024] S01: Obtain the CIM / XML file of the power system, wherein the CIM / XML file includes power equipment entities, attribute parameters, and topology connection relationships; In a preferred embodiment of this invention, the acquisition of the CIM / XML file of the power system, wherein the CIM / XML file includes power equipment entities, attribute parameters, and topology connection relationships, specifically involves: In this embodiment, the first step is to obtain the CIM / XML file of the power system. The obtained CIM / XML file is a standardized power data file that conforms to the international power standards of IEC 61970 and IEC 61968. It is the core data carrier for the operation and maintenance management of the power system. The file stores the topology-related data of the power system in the Extensible Markup Language format, specifically covering three core types of information: power equipment entities, attribute parameters, and topology connection relationships. The power equipment entities include various conventional power equipment bodies such as transformers, circuit breakers, switches, cables, busbars, and distribution transformers within the power system. The attribute parameters are the inherent characteristic parameters corresponding to each power equipment entity, specifically including key parameter information that can characterize the equipment's own attributes, such as equipment identification, equipment name, rated voltage, rated capacity, power supply area, and equipment specifications. The topology connection relationship is the physical and electrical connection association information between various power equipment entities, specifically including the association relationship between equipment and connection nodes, the direct connection correspondence between equipment, and the equipment connectivity arrangement relationship at the feeder level, which can completely characterize the overall topology of the power system. This CIM / XML file is a purely machine-readable format data, which has not undergone natural language text conversion processing and cannot be directly recognized and called by power intelligent agents. It needs to complete the data format and content adaptation processing through subsequent parsing, mapping, and generation steps.

[0025] S02: Based on the equipment entities and topology relationships of the power system, extract the equipment entity class names, equipment attribute names and topology relationship information from the CIM / XML file, and perform standardized mapping processing on the equipment entity class names and equipment attribute names based on a preset Chinese-English mapping table; In a preferred embodiment of this example, the process of extracting the device entity class names, device attribute names, and topology relationship information from the CIM / XML file based on the device entity and topology relationship of the power system, and then performing standardized mapping processing on the device entity class names and device attribute names based on a preset Chinese-English mapping table, specifically: After obtaining the CIM / XML files of the power system, based on the two core data dimensions inherent to the power system—equipment entities and topology relationships—a node traversal and text type matching algorithm based on the IEC 61970 / CIM standard is used to perform a binary classification parsing operation on the CIM / XML files. A depth-first search (DFS) approach is used to scan the CIM / XML files node by node, accurately locating core nodes such as cim:Equipment, cim:ConnectivityNode, and cim:Terminal according to the power standard tag path, completing the binary classification of equipment entity nodes and topology connection nodes. For the located equipment entity nodes, regular expression matching is used to identify CIM standard equipment type tags such as PowerTransformer, Breaker, Switch, and Line. Equipment identification information, equipment name information, and cim:P from the cim:Naming.mRID field are extracted from the equipment entity class tags. The rated parameter information in the `ownerSystemResource.BaseVoltage` field is used to determine the corresponding device entity class name based on the device name information, and the corresponding device attribute name based on the rated parameter information. For topology connection nodes, dedicated topology nodes of type `cim:Terminal.ConnectivityNode` are identified based on the topology relationship data in the CIM / XML file. The unique identifier of the topology node is recorded, and then all device identifiers associated with it are retrieved in reverse using the unique identifier of the topology node as the retrieval basis. Each topology node is associated with no less than two devices, and the device pairs associated with the topology node are determined. The device identifiers in the device pairs and the topology node identifiers are constructed into a triplet of starting device ID - connection node ID - ending device ID, forming the CONNECTED_TO standard topology relationship information, thus completing the full extraction of device entity class names, device attribute names, and topology relationship information. After extracting the above information, duplicate nodes and redundant attributes obtained from the parsing are deduplicated and filtered, retaining only the fields necessary for textual description, forming a regular entity set and relationship set. Subsequently, a preset Chinese-English mapping table is called to perform standardized mapping processing. The Chinese-English mapping table has a built-in one-to-one correspondence between English and Chinese device class names and between English and Chinese attribute names. It can convert PowerTransformer to transformer and Voltage to voltage, and automatically convert the extracted English device entity class names and English device attribute names into Chinese expressions, obtaining Chinese-language device entity information. This completes the standardized mapping between device entity class names and device attribute names, eliminates the recognition obstacles caused by professional English terms, and improves the readability and standardization of subsequent data processing and text generation.

[0026] S03: Based on the standardized mapping process of the device entity class name and device attribute name, and combined with the topology relationship information, generate a device entity table and a topology relationship table; In a preferred embodiment of this invention, the step of generating a device entity table and a topology relationship table based on the standardized mapping processed device entity class names and device attribute names, combined with the topology relationship information, specifically involves: After standardizing the mapping of device entity class names and device attribute names, based on the Chinese-language device entity information and the extracted topology relationship information, the two types of information are organized in a standardized and structured manner according to the preset CSV field definitions, generating text-adapted standardized CSV data. During the data organization process, device entity-related information and topology relationship-related information are strictly separated, without overlap or nesting, ensuring the standardization of subsequent data processing. For the device entity dimension, the device identifier, the standardized mapped Chinese device type, and the Chinese attribute parameters are organized and integrated to generate a device entity table containing device ID, Chinese device type, and Chinese attribute parameters. This device entity table can clearly record the unique identifier, type attribute, and core parameter information of each power device. For the topology relationship dimension, based on the triple data in the topology relationship information, the corresponding associations of the starting device identifier, ending device identifier, Chinese connection relationship, and connection node identifier are sorted out. The above association information is organized and integrated to generate a topology relationship table containing the starting device ID, ending device ID, Chinese connection relationship, and connection node identifier. The generated device entity table and topology relationship table have clear structures and standardized fields, providing an accurate and structured data foundation for subsequent natural language textual description of power topology.

[0027] S04: Based on the device entity table and topology relationship table, and combined with the preset text generation template, generate a single topology connection description, and integrate the single topology connection description according to the power feeder level to obtain a natural language textual description of the power topology. In a preferred embodiment of this example, based on the device entity table and the topology relationship table, and combined with a preset text generation template, a single topology connection description is generated. This single topology connection description is then integrated according to the power feeder level to obtain a natural language textual description of the power topology. Specifically: After generating the device entity table and topology relationship table, text generation and integration are performed based on the standardized device entity table and topology relationship table. The text generation adopts a standardized format of fixed sentence templates plus field filling, and is achieved through lightweight rule matching and template rendering, rather than simple string concatenation. First, based on the starting device identifier, ending device identifier, and connection node identifier recorded in the topology relationship table, a matching query is performed in the device entity table to accurately obtain the corresponding Chinese names of the starting device, ending device, and connection node. Then, a preset text generation template is called. The template adopts a fixed sentence pattern of connecting {Device A Chinese Name} with {Device B Chinese Name} through {Connection Node Chinese Name}. The obtained Chinese names of the starting device, connection node, and ending device are sequentially filled into the corresponding placeholders in the template. The template is then rendered to generate a single topology connection description. This description uses a standardized natural language sentence to clearly describe the topology connection relationship between the two devices formed through the connection node. Next, based on the equipment and power feeder affiliation relationships recorded in the equipment entity table, using the power feeder identifier / feeder name as the grouping key, all generated single topology connection descriptions are assigned to the corresponding feeder groups, resulting in a complete set of single topology connection descriptions for each power feeder. Then, based on the equipment identifiers in this description set, the equipment entity table is queried in reverse, and all retrieved equipment information is deduplicated and sorted in order by voltage level and equipment type to generate a standardized equipment list for that feeder. Following the upstream-to-downstream connectivity order of the power topology, all single topology connection descriptions within the same feeder group are sequentially concatenated to form a chain structure. For loop and branch point structures in the topology, duplicate connections are merged to avoid text redundancy, forming a coherent and complete feeder topology description. Finally, the generated equipment list and the complete feeder topology description are integrated into a unified format: XX feeder contains [equipment list], where [connection relationship 1], [connection relationship 2]... This outputs a standardized, semantically clear, and information-complete power topology natural language text description, such as 10kV Tangyong F10. The #1 power room includes the #1 incoming circuit breaker, the #2 outgoing switch, the #3 outgoing cable, and the #1 main transformer. The #1 incoming circuit breaker is connected to the #2 outgoing switch via the #1 busbar node. The #2 outgoing switch is connected to the #3 outgoing cable via the #2 terminal node. The #3 outgoing cable is connected to the #1 main transformer via the #3 busbar node. This description fully meets the input parsing requirements of the intelligent agent and provides a standardized topology data foundation for subsequent power business Q&A.

[0028] S05: Receive the power service question input by the user, input the power service question and the natural language text description together into the preset power operation and maintenance intelligent agent, so that the power operation and maintenance intelligent agent can identify the power topology based on the natural language text description, reason about the power service question based on the power topology, and output the power service question and answer result.

[0029] In a preferred embodiment of this example, the step of receiving the user's input power service question involves inputting the power service question and the natural language textual description together into a preset power operation and maintenance intelligent agent. This allows the power operation and maintenance intelligent agent to identify the power topology based on the natural language textual description, reason about the power service question based on the power topology, and output a power service question-and-answer result. Specifically: After completing the natural language text description of the power topology, the system receives the power business question input by the user and parses it to determine its corresponding query granularity. Query granularity is specifically divided into three categories: single-device granularity, single-relationship granularity, and feeder granularity. When the query granularity is determined to be single-device or single-relationship granularity, a single topology connection description precisely corresponding to the power business question is selected from the generated natural language text description as the input text to be used. When the query granularity is determined to be feeder granularity, the entire feeder topology description corresponding to the power business question is selected from the natural language text description as the input text to be used. Subsequently, the determined input text and the power business question are concatenated according to a preset prompt instruction format to generate an input instruction conforming to the preset power operation and maintenance intelligent agent input interface specification, and this input instruction is sent to a preset power operation and maintenance intelligent agent with power business reasoning capabilities.

[0030] Upon receiving the natural language text description from the input command, the power operation and maintenance intelligent agent performs semantic parsing. From the parsing results, it extracts device names, connection node names, and connection relationship terms between devices. Based on these extracted names, it then constructs a semantic topology graph with devices as nodes and connections as edges. This semantic topology graph serves as the identified power topology structure. Simultaneously, the intelligent agent parses the power business problem in the input command, extracting the target device identifier or target operation type. Based on the target device identifier, it locates the target device node in the constructed semantic topology graph. Then, it searches for propagation paths along the upstream and downstream connections of the target device node in the semantic topology graph to determine the set of affected devices associated with the target device node. Finally, based on the target operation type and the identified set of affected devices, corresponding question-and-answer results are generated according to preset power operation and maintenance business rules. Specifically, four types of intelligent applications can be realized: For power outage operation questions, a standardized power outage operation process is generated, which includes shutting down the target switch, disconnecting the connecting cable, confirming the power outage, and setting warning signs; for fault diagnosis questions, analysis suggestions are generated for diagnosing and isolating fault points in upstream and downstream related devices of the faulty device; for equipment maintenance and load transfer questions, corresponding operation and maintenance decision support suggestions are generated; and for equipment connection query questions, the answers of upstream and downstream related devices of the target device are directly output. The above operation step sequence, analysis suggestion statements, decision suggestions or query answers are used as the final power business question-and-answer results, completing the entire process of intelligent agent question-and-answer based on power business.

[0031] In summary, this application obtains CIM / XML files and performs binary classification parsing for textual descriptions of power topology. Combined with standardized Chinese-English mapping, it generates structured equipment entity tables and topology relationship tables, transforming machine-readable raw data into standardized tabular data containing Chinese equipment attributes and precise connection relationships. This solves the problems of chaotic data structure and poor readability in existing technologies. Furthermore, based on preset text generation templates and feeder-level integration processing, it automatically generates natural language topology descriptions following a unified semantic format of "equipment-connection node-equipment," replacing manual writing and significantly improving textualization efficiency and format standardization. Then, power business questions are input together with this standardized topology text into a power operation and maintenance intelligent agent, enabling the agent to accurately identify the power topology structure and reason based on upstream and downstream connection relationships, ultimately outputting accurate question-and-answer results. This achieves end-to-end automation from unstructured power data to highly reliable intelligent question-and-answer, effectively solving the problem that existing technologies cannot accurately and efficiently answer power business questions based on intelligent agents.

[0032] Example 2 Please refer to Figure 2This is an intelligent agent question-and-answer system based on power business provided in the embodiments of this application.

[0033] In this embodiment, the intelligent agent question-answering system based on power business includes an acquisition module 10, an extraction module 20, a first generation module 30, a second generation module 40, and an output module 50.

[0034] The acquisition module 10 is used to acquire the CIM / XML file of the power system, wherein the CIM / XML file includes power equipment entities, attribute parameters and topology connection relationships; Extraction module 20 is used to extract the equipment entity class name, equipment attribute name and topology relationship information from the CIM / XML file based on the equipment entity and topology relationship of the power system, and to perform standardized mapping processing on the equipment entity class name and equipment attribute name based on a preset Chinese-English mapping table. The first generation module 30 is used to generate a device entity table and a topology relationship table based on the standardized mapping processed device entity class name and device attribute name, combined with the topology relationship information. The second generation module 40 is used to generate a single topology connection description based on the device entity table and the topology relationship table, combined with a preset text generation template, and to integrate the single topology connection description according to the power feeder level to obtain a natural language textual description of the power topology. The output module 50 is used to receive power service questions input by the user, input the power service questions and the natural language text description together into a preset power operation and maintenance intelligent agent, so that the power operation and maintenance intelligent agent can identify the power topology based on the natural language text description, reason about the power service questions based on the power topology, and output power service question and answer results.

[0035] For ease of description and brevity, the system embodiments of the present invention include all the implementation methods described in the above embodiments of the intelligent agent question-answering method based on power business, and will not be repeated here.

[0036] The specific embodiments described above further illustrate the purpose, technical solution, and beneficial effects of the present invention. It should be understood that the above descriptions are merely specific embodiments of the present invention and are not intended to limit the scope of protection of the present invention. In particular, it should be noted that any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention for those skilled in the art.

Claims

1. A smart agent question-answering method based on power business, characterized in that, include: Obtain the CIM / XML file of the power system, wherein the CIM / XML file includes power equipment entities, attribute parameters, and topology connection relationships; Based on the equipment entities and topology relationships of the power system, the equipment entity class names, equipment attribute names and topology relationship information in the CIM / XML file are extracted, and the equipment entity class names and equipment attribute names are standardized and mapped based on a preset Chinese-English mapping table. Based on the standardized mapping of device entity class names and device attribute names, combined with the topology relationship information, a device entity table and a topology relationship table are generated. Based on the device entity table and topology relationship table, and combined with the preset text generation template, a single topology connection description is generated, and the single topology connection description is integrated according to the power feeder level to obtain a natural language textual description of the power topology. The system receives power service questions input by the user, and inputs the power service questions and the natural language text description together into a preset power operation and maintenance intelligent agent. The power operation and maintenance intelligent agent identifies the power topology based on the natural language text description, infers the power service questions based on the power topology, and outputs power service question-and-answer results.

2. The intelligent agent question-answering method based on power business according to claim 1, characterized in that, The process of extracting the equipment entity class name, equipment attribute name, and topology relationship information from the CIM / XML file based on the equipment entity and topology relationships of the power system is as follows: Scan the CIM / XML file node by node to locate the device entity nodes and topology connection nodes; Based on the device entity node, the device entity class tag is located by regular expression matching, and the device identification information, device name information and rated parameter information in the device entity class tag are extracted. The device entity class name is determined based on the device name information, and the device attribute name is determined based on the rated parameter information; Based on the topology data in the CIM / XML file, the connection node type is identified and the connection node identifier is recorded. Based on the connection node identifier, the associated device identifier is retrieved, the device pair associated with the connection node is determined, and the device identifier in the device pair and the connection node identifier are constructed into a triple to form the topology information.

3. The intelligent agent question-answering method based on power business according to claim 1, characterized in that, The standardization mapping process for the device entity class name and device attribute name based on the preset Chinese-English mapping table is as follows: Based on a preset Chinese-English mapping table, the device entity class name and device attribute name are converted from English to Chinese to obtain Chinese-language device entity information; the Chinese-English mapping table includes the correspondence between English device class names and Chinese device class names, as well as the correspondence between English attribute names and Chinese attribute names; Based on the Chinese-language device entity information and the topology relationship information, the data is structured according to the preset CSV field definitions to generate a device entity table and a topology relationship table. The device entity table includes device identifier, Chinese device type, and Chinese attribute parameters. The topology relationship table includes starting device identifier, ending device identifier, Chinese connection relationship, and connection node identifier.

4. The intelligent agent question-answering method based on power business according to claim 3, characterized in that, Based on the device entity table and topology relationship table, and combined with a preset text generation template, a single topology connection description is generated. This single topology connection description is then integrated and processed according to the power feeder level to obtain a natural language textual description of the power topology, specifically: Based on the starting device identifier, ending device identifier, and connection node identifier in the topology table, query the device entity table to obtain the Chinese names of the starting device, ending device, and connection node. Based on a preset text generation template, the Chinese names of the starting device, the connecting node, and the terminating device are filled into the template to generate a single topology connection description. Based on the relationship between the equipment and the power feeder in the equipment entity table, the single topology connection description is divided into the corresponding group using the power feeder identifier as the grouping key, thus obtaining a set of single topology connection descriptions under each power feeder. Based on the device identifiers in the single topology connection description set, the device entity table is queried, the queried devices are deduplicated and sorted by voltage level and device type to generate a device list; Following the topological connectivity order from upstream to downstream, each individual topological connection description in the set of individual topological connection descriptions is sequentially assembled. Duplicate connection relationships in the loop structure and branch point structure are deduplicated to form the whole feeder topological description. Integrate the equipment list and the feeder topology description to output a natural language textual description of the power topology.

5. The intelligent agent question-answering method based on power business according to claim 1, characterized in that, The process of receiving power service questions input by users and inputting the power service questions along with the natural language text descriptions into a preset power operation and maintenance intelligent agent involves: The system receives power service questions input by users and parses the query granularity of the power service questions; the query granularity includes single device granularity, single relationship granularity, and feeder granularity. When the query granularity is single device granularity or single relation granularity, a single topology connection description corresponding to the power business problem is selected from the natural language text description as the input text; When the query granularity is the feeder granularity, the whole feeder topology description corresponding to the power business problem is selected from the natural language text description as the input text. The text to be input is concatenated with the power business question according to a preset prompt instruction format to generate an input instruction that conforms to the input interface specification of the power operation and maintenance intelligent agent, and the input instruction is sent to the power operation and maintenance intelligent agent.

6. The intelligent agent question-answering method based on power business according to claim 1, characterized in that, The process of enabling the power operation and maintenance intelligent agent to identify the power topology based on the natural language textual description specifically involves: The power operation and maintenance intelligent agent receives the natural language textual description and performs semantic parsing on the natural language textual description; Extract device names, connection node names, and connection relationship terms between devices from the parsing results; Based on the device name, connection node name, and connection relation terms, a semantic topology graph is constructed with devices as nodes and connection relations as edges, which serves as the power topology structure identified by the power operation and maintenance intelligent agent.

7. The intelligent agent question-answering method based on power business according to claim 1, characterized in that, The process of reasoning about the power business problem based on the power topology and outputting the power business question-and-answer result is as follows: The power operation and maintenance intelligent agent analyzes the power business problem and extracts the target device identifier or target operation type from the power business problem; Based on the target device identifier, locate the target device node in the power topology; A propagation path search is performed along the upstream and downstream connections of the target device node in the power topology to determine the set of influencing devices associated with the target device node. Based on the target operation type and the set of affected devices, an operation step sequence or analysis suggestion statement is generated according to the preset power operation and maintenance business rules, and output as the power business Q&A result.

8. A smart agent question-answering system based on power business, characterized in that, include: The acquisition module is used to acquire the CIM / XML file of the power system, wherein the CIM / XML file includes power equipment entities, attribute parameters, and topology connection relationships; The extraction module is used to extract the equipment entity class name, equipment attribute name and topology relationship information from the CIM / XML file based on the equipment entity and topology relationship of the power system, and to perform standardized mapping processing on the equipment entity class name and equipment attribute name based on a preset Chinese-English mapping table. The first generation module is used to generate a device entity table and a topology relationship table based on the standardized mapping process of the device entity class name and device attribute name, combined with the topology relationship information. The second generation module is used to generate a single topology connection description based on the device entity table and the topology relationship table, combined with a preset text generation template, and to integrate the single topology connection description according to the power feeder level to obtain a natural language textual description of the power topology. The output module is used to receive power service questions input by the user, input the power service questions and the natural language text description together into a preset power operation and maintenance intelligent agent, so that the power operation and maintenance intelligent agent can identify the power topology based on the natural language text description, reason about the power service questions based on the power topology, and output power service question and answer results.

9. The intelligent agent question-answering system based on power business according to claim 8, characterized in that, The acquisition module includes: The positioning unit is used to scan the CIM / XML file node by node to locate the device entity nodes and topology connection nodes; The extraction unit is used to locate the device entity class label based on the device entity node using regular expression matching, and extract the device identification information, device name information and rated parameter information within the device entity class label. The determining unit is used to determine the device entity class name based on the device name information and to determine the device attribute name based on the rated parameter information. The identification unit is used to identify the type of connection node based on the topology relationship data in the CIM / XML file, record the connection node identifier, retrieve the associated device identifier based on the connection node identifier, determine the device pair associated with the connection node, and construct a triplet by combining the device identifier in the device pair with the connection node identifier to form topology relationship information.

10. The intelligent agent question-answering system based on power business according to claim 8, characterized in that, The output module includes: The receiving unit is used to receive power service questions input by users and parse the query granularity of the power service questions; the query granularity includes single device granularity, single relationship granularity, and feeder granularity; The first selection unit is used to select a single topology connection description corresponding to the power business problem from the natural language text description when the query granularity is single device granularity or single relation granularity, as the input text; The second selection unit is used to select, when the query granularity is feeder granularity, the whole feeder topology description corresponding to the power business problem from the natural language textual description as the input text; The splicing unit is used to splice the text to be input with the power business question according to a preset prompt instruction format, generate an input instruction that conforms to the input interface specification of the power operation and maintenance intelligent agent, and send the input instruction to the power operation and maintenance intelligent agent.