Model training method for energy service robot

By building a metadata knowledge base and a business problem knowledge base, generating a semantic graph model, and conducting multi-model collaborative training, the problems of poor adaptability of professional terminology and insufficient dynamic business adaptability of existing service robots in the power industry are solved, and efficient intent recognition and information query are achieved.

CN120611022APending Publication Date: 2025-09-09STATE GRID SHANGHAI MUNICIPAL ELECTRIC POWER CO +1

Patent Information

Application Number
CN202510705663.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-29
Publication Date
2025-09-09

AI Technical Summary

Technical Problem

Existing service robots in the power industry have problems such as poor adaptability to professional terminology, insufficient accuracy in intent recognition, performance degradation due to model migration, and inability to adapt to dynamic business scenarios.

Method used

By building a metadata knowledge base to annotate business logic, establish a business problem knowledge base, generate a semantic graph model, combine intent recognition, intelligent dialogue and intelligent spelling models, conduct multi-model collaborative training, and perform model migration through distributed incremental training and containerization.

Benefits of technology

It improves the robot's ability to recognize user intentions, ensures the accuracy of answers, improves information query efficiency and model compatibility, and realizes the robot's efficient adaptability and continuous performance optimization in the power industry.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120611022A_ABST
    Figure CN120611022A_ABST
Patent Text Reader

Abstract

The invention discloses an energy robot-oriented model training method, and relates to the technical field of energy digitization, and the method comprises the steps: synchronizing a business database to a local metadata knowledge base, and carrying out the business feature labeling of a metadata table in the metadata knowledge base according to the business logic; establishing a business problem knowledge base based on the business requirements; constructing a semantic map model of the robot based on the metadata knowledge base; generating mixed data features based on the labeled metadata knowledge base and the business problem knowledge base, and performing multi-model cooperative training of robot intention recognition, intelligent dialogue and intelligent table splicing according to the mixed data features in combination with a semantic map model; performing distributed incremental training on each model of the robot in response to the user session log, and performing model migration according to containerization to complete deployment of the robot; the intention recognition ability and data retrieval and query efficiency of the robot on the text input by the user are improved, then the question-answer response efficiency of the robot is improved, and efficient business question-answer is achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of energy digitalization technology, and specifically to a model training method for energy service robots. Background Art

[0002] With the large-scale application of artificial intelligence in key scenarios, in the process of digital transformation of the energy industry, intelligent service robots are used to handle complex business scenarios, such as material demand management, contract performance tracking, inventory inquiries, etc. In the application of service robots, in order to further liberate business personnel from rigid and repetitive simple operations, with the goal of practicality and effectiveness and reducing the burden on the grassroots, and to effectively serve the daily operations of the front-line teams, it is necessary to build a new model of voice and semantic intelligent interaction. Apply intelligent voice and semantic recognition technology to deeply integrate professional business scenarios, promote the digital transformation of application scenarios, and realize cross-system intelligent data query and cross-platform quick operation through natural language, so that business professionals can "read and understand" business data, effectively improve user experience, and support the expansion of new intelligent business scenarios. However, the application of existing robot natural language technology has the following problems: (1) It has poor adaptability to the professional terminology and business scenarios of the power industry, and its intention recognition accuracy is insufficient, which may lead to misjudgment of user query intentions; (2) Traditional models are difficult to accurately generate database query statements that conform to business logic; (3) When migrating models from a development environment to a production environment, retraining is often required due to differences in data sources or resource incompatibility, resulting in performance degradation or business interruption. (4) Since the model is not updated according to user feedback, the robot cannot adapt to dynamically changing business scenarios in a timely manner.

[0003] The patent, "A Data Processing Method and System for an Intelligent Customer Service Robot," published with publication number CN 115358774A, discloses: basic data statistics and indicator testing for the robot; calculation of custom indicator information related to the robot's voice recognition order accuracy, semantic recognition accuracy, overall business accuracy, problem-solving rate, and the robot's independent reception ratio; the establishment of overall service quality indicator values ​​to evaluate the robot's performance; and the generation of optimization strategies when the evaluation level falls below a set level to optimize the robot's overall indicators and enhance its service capabilities. However, this solution improves semantic recognition accuracy by creating a customer service keyword database and optimizing the knowledge base, but does not disclose how to handle complex natural language processing models to improve the robot's intent recognition accuracy. Furthermore, the solution lacks a dynamic query mechanism for semantic parsing and cannot adapt to diverse business logic, resulting in poor adaptability of the service robot's business performance. Furthermore, the calculation of various indicators involves the influence of correlation data and is limited to historical data, making it impossible to objectively and accurately quantify these indicators in real time as a reflection of the robot's performance, resulting in unreliable performance evaluation results. Summary of the Invention

[0004] The purpose of this application is to address the problem that the existing service robot training technology is unable to effectively process complex natural language and has the limitation of dynamic business logic synchronization, resulting in low service robot business performance; a model training method for energy service robot is proposed, which labels business features by constructing a metadata knowledge base, establishes a business problem knowledge base according to business needs, and constructs the robot's semantic graph model, intent recognition model, intelligent dialogue model and intelligent spelling table based on the metadata knowledge base and the business problem knowledge base, thereby improving the service robot's ability to recognize the intention of user input text, realize business questions and answers, and ensure the accuracy of answers. The intelligent spelling table model improves the robot's data retrieval and query efficiency, thereby improving the robot's question and answer response efficiency; distributed incremental training is performed on the robot's various models in response to user session logs, and model migration is performed based on containerization to continuously improve model performance and ensure model compatibility and resource reuse rate; it solves the problem that the existing service robot training technology is unable to effectively process complex natural language and has the limitation of dynamic business logic synchronization, resulting in low service robot business performance.

[0005] To solve the above technical problems, the technical solution adopted in this application is: a model training method for energy service robots, comprising the following steps: Synchronize the business database to the local metadata knowledge base, and annotate the metadata tables in the metadata knowledge base with business features according to the business logic; Establish a business problem knowledge base based on business needs; Constructing a semantic graph model of the robot based on the metadata knowledge base; Based on the annotated metadata knowledge base and the business problem knowledge base, hybrid data features are generated, and multi-model collaborative training of robot intent recognition, intelligent dialogue and intelligent spelling is performed based on the hybrid data features and combined with the semantic graph model; distributed incremental training is performed on each model of the robot in response to user session logs, and model migration is performed based on containerization to complete the deployment of the robot.

[0006] In this solution, by annotating the metadata knowledge base with business logic, a mapping bridge between the database and natural language is established, so that the robot can accurately understand the relationship between "field name → business meaning → standard terminology"; by building a business problem knowledge base, professional field-related training samples are provided to the intent recognition model, so that the model can efficiently learn the relevant intentions of each problem scenario and improve the accuracy of the model. By associating the metadata knowledge base, the ambiguity problem of semantically similar but different business intentions is solved, so that the robot can quickly adapt to new business scenarios; by training the semantic graph model through the problem knowledge base and the metadata knowledge base, the model can learn the keywords of each problem scenario, so as to convert user slang into standard terminology in real time and reduce the misjudgment of intention due to expression differences; by building an intelligent dialogue model, the robot can be forced to output an answer structure that meets the standards of the power industry, and with the support of the semantic graph model In this way, the robot can maintain context consistency in multiple rounds of conversations, improve user experience, and increase the efficiency and continuity of robot services. By integrating the question knowledge base and the metadata knowledge base to train the intelligent spelling table model, the robot can obtain the intent type based on the question text, quickly match the targeted SQL template, and extract the business keywords in the real-time question text and fill the slots with the SQL template to query the data of the tables and fields in the metadata knowledge base. There is no need to query the database in full. The targeted SQL statement narrows the query scope, improves the robot's information search rate and accuracy, and further improves the speed of the intelligent dialogue model to generate the answer structure. According to the real-time user conversation log, the abnormal status of the robot service process is obtained, and incremental training data can be generated based on the abnormal status to achieve continuous performance optimization of the robot. Finally, the overall service quality of the robot is improved through the collaborative operation of various models.

[0007] Preferably, the step of synchronizing the business database to the local metadata repository and performing business annotation on the metadata tables in the metadata repository according to the business logic includes: Based on the business database containing key fields of energy business, ETL is used to periodically synchronize the data table structure in the business database to the local metadata knowledge base used to store robot operation data; According to the business logic characteristics represented by the metadata table and its fields, business term labels are respectively annotated on the metadata table and each field in the metadata table to complete the annotation of the metadata knowledge base used for robot model input feature mapping.

[0008] Preferably, establishing a business problem knowledge base based on business needs includes: Conduct business demand analysis based on power business scenarios and historical task work orders to determine target problem scenarios; Classify the target problem scenarios and collect a number of problem samples according to each scenario; Classify the question samples into triples based on role-intention-question to generate a structured question list; The structured question list is associated with the metadata knowledge base based on the SQL query template to build a business question knowledge base.

[0009] Preferably, the constructing of a robot's semantic graph model based on the metadata knowledge base includes: Based on the extraction of standardized terms and their synonyms from power documents, a graph neural network is used to construct an industry terminology graph with standardized terms as nodes and synonyms as edges. A semantic graph model is established based on the industry terminology graph for converting real-time user input into standardized terms.

[0010] Preferably, the generation of hybrid data features from the metadata knowledge base and the business problem knowledge base based on annotations includes: Determine an intent label based on the problem scenario, establish a mapping relationship between the intent label and the metadata knowledge base, and associate the intent label with the metadata feature; Based on the business terms contained in the question text that match the metadata field, labeling the question text with the corresponding intent tag; The metadata features are converted into one-hot vectors and embedded and concatenated with the key fields of the question text and the intent label to obtain mixed data features.

[0011] Preferably, the multi-model collaborative training of robot intention recognition, intelligent dialogue and intelligent table spelling based on the hybrid data features in combination with the semantic graph model includes: Based on the pre-trained language model and model fine-tuning, the mixed data features are used as input parameters for model training, the user intent category is output, and an intent recognition model is established; Based on the intent type output by the intent recognition model, a sequence-to-sequence model is used to train the mixed data features and the power document to establish an intelligent dialogue model; Synchronously, during the training process of the intent recognition model and the intelligent dialogue model, a question-SQL pair is established based on the business keywords and metadata table fields of the question text, and the question-SQL pair is used as the input parameter of the sequence-to-sequence model to train the intelligent spelling model.

[0012] Preferably, the method of using the mixed data features as input parameters to perform model training based on the pre-trained language model and model fine-tuning, outputting the user intent category, and establishing the intent recognition model includes: Using the pre-trained language model as the base model, the Transformers fine-tuning component is coupled to extract the semantic features of the mixed data features; Based on the semantic features, intent classification is performed using an activation function through a fully connected layer; The model training parameters are updated according to the minimum loss function, the intent type is output, and the training of the intent recognition model is completed.

[0013] Preferably, the intention type output by the intention recognition model is used to train the mixed data features and the power document using a sequence-to-sequence model to establish an intelligent dialogue model, including: determining a response structure type based on the intent tag; Extracting structured content associated with intent from power system documents and equipment operation manuals, labeling the structured content with corresponding intent tags, and obtaining structured rule data; After the intent label is used as a prefix and fused with the mixed data features and the structured rule data, the natural language in the question text is replaced with standard business terms through a semantic graph model to obtain training data; Based on the training data, a sequence-to-sequence model is used to perform iterative training on dual-branch data containing text and structured data, output a structured answer to the question text, and complete the training of the intelligent dialogue model.

[0014] Preferably, the step of establishing a question-SQL pair based on the business keywords of the question text and the metadata table fields, using the question-SQL pair as an input parameter of a sequence-to-sequence model, and training an intelligent table-building model comprises: Extracting business keywords from the question text and marking target slots corresponding to the business keywords; Determine an SQL template based on the intent type output by the intent recognition model and the metadata table structure associated with each intent tag; fill the target slot into the SQL template to generate a target SQL statement; A question-SQL pair is established according to the target SQL statement and the question text, and is used as an input parameter of a sequence-to-sequence model for model training to obtain an intelligent spelling table model.

[0015] Preferably, the step of performing distributed incremental training on the robot after multi-model collaborative training in response to user session logs, performing model migration according to containerization, and completing robot deployment includes: Extracting exception information based on the exception logs of the intent recognition model, the intelligent dialogue model, the intelligent table puzzle model, and the semantic graph model, including at least exception recognition intent and erroneous SQL statements; Track the cause based on the abnormal information and obtain the target object to be optimized; Based on the target object to be optimized, the abnormal data in the abnormal log is used as incremental training data for each model, and distributed incremental training of each model is performed according to the GPU cluster; Based on containerization technology, each trained model is migrated across the operating environment to complete the deployment of the robot.

[0016] Beneficial effects of this application: 1. Through business logic annotation in the metadata knowledge base, a mapping relationship between technical fields and business terms is established, providing a unified semantic foundation for subsequent intent recognition and SQL generation; 2. Through the collaborative training of multiple models, complex tasks are decomposed into multiple subtasks, each of which is processed by a different model, and the results are finally integrated. Through the intention recognition model, natural language is processed to provide the model with the ability to recognize the intention of user input text, accurately determine the operation the user wants to perform or the information the user wants to obtain; through the intelligent dialogue model to learn industry rules and regulations, the model training can obtain knowledge base question and answer, multi-round question and answer, and context understanding capabilities, and realize flexible business functions such as business question and answer, system document query, etc.; through the intelligent table spelling model, based on table input and standard data table annotation data, intelligent table spelling is realized, and then robot intelligent query is realized, which improves the efficiency of information query; through the modeling of colloquialisms and standard terms to obtain semantic graph models, colloquialisms in the dialogue process are identified and converted into standard terms, providing key data support for subsequent accurate intent recognition; 3. In the process of intent type recognition by the intent recognition model and the training process of the intelligent dialogue model, the network structure of pre-trained language model + fine-tuning takes advantage of the fact that the pre-trained language model has mastered the grammar, semantics and contextual dependencies of natural language. Directly using it as the basic model can avoid training from scratch, reduce the amount of data annotation in the energy field, and enable the model to quickly adapt to professional language environments such as power terminology and equipment names. The fine-tuning component can embed and splice three types of heterogeneous data: metadata features, intent labels, and question text, and then process them uniformly, so that the model can dynamically focus on the importance of different features and solve the problem that a single text feature cannot fully associate with business logic. At the same time, compared with using only the fixed representation of the pre-trained model, the fine-tuning strategy improves the sensitivity of domain terminology, can quickly filter out irrelevant intents that are not business-related, and improve the efficiency of intent recognition. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] Other features, objects, and advantages of the present application will become more apparent upon reading the detailed description of non-limiting embodiments made with reference to the following drawings. The drawings are provided for illustration purposes only and are not to be construed as limiting the present application. Like reference numerals are used throughout the drawings to denote like parts.

[0018] Figure 1This is a flow chart of a model training method for an energy service robot according to an embodiment of the present application.

[0019] Figure 2 This is a schematic diagram of the intelligent dialogue model training process of an embodiment of the present application.

[0020] Figure 3 This is a schematic diagram of training data fusion in the intelligent dialogue model training of an embodiment of the present application.

[0021] Figure 4 This is a schematic diagram of the intelligent question-answering process of an energy service robot according to an embodiment of the present application. DETAILED DESCRIPTION

[0022] In order to make the purpose, technical solutions and advantages of this application more clear, the application is further described in detail below with reference to the accompanying drawings and examples. It should be understood that the specific implementation method described here is only an optimal embodiment of this application, which is only used to explain this application and does not limit the scope of protection of this application. All other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.

[0023] Example 1: Figure 1 As shown, a model training method for an energy service robot includes the following steps: S1. Synchronize the business database to the local metadata knowledge base, and annotate the metadata tables in the metadata knowledge base with business features according to the business logic. Specifically, it includes: Based on the business database containing key fields of energy business, ETL is used to periodically synchronize the data table structure in the business database to the local metadata knowledge base used to store robot operation data; According to the business logic characteristics represented by the metadata table and its fields, business term labels are respectively annotated on the metadata table and each field in the metadata table to complete the annotation of the metadata knowledge base used for robot model input feature mapping.

[0024] In some optional implementations, business annotation of metadata tables in the metadata knowledge base involves adding business semantic tags to database table structures, such as table names, field names, data types, and constraints, transforming them from "pure technical data" into "business-understandable data assets." For example, the field "voltage_level" in the database table "device_info" could be annotated to associate it with the business term "voltage level" and to add the following: "Unit: kV, value range: [10, 220]."

[0025] In this embodiment, metadata business annotation establishes a mapping relationship between business terms and data fields. This allows the robot to understand which database field corresponds to the business terms in the user's question, ensuring that each entity in the question is accurately matched to the table and / or field in the metadata, avoiding query errors caused by terminology ambiguity. In subsequent model training, metadata annotation provides a unified data source, enabling the robot to understand the business, supporting full-process automation, and improving system robustness. It also clarifies the relationships between tables and business rules, providing a logical basis for subsequent generation of complex SQL statements such as multi-table joins and conditional filtering. This ensures that the robot can correctly assemble table structures and directly match the metadata-annotated fields with the rules to generate structured answers.

[0026] S2. Establish a business problem knowledge base based on business needs.

[0027] Specifically, S2 includes: Conduct business demand analysis based on power business scenarios and historical task work orders to determine target problem scenarios; Classify the target problem scenarios and collect a number of problem samples according to each scenario; Classify the question samples into triples based on role-intention-question to generate a structured question list; The structured question list is associated with the metadata knowledge base based on the SQL query template to build a business question knowledge base.

[0028] In some optional implementations, target problem scenarios can be divided according to energy industry characteristics into power query, device operation, policy consultation, and system management. The power query category includes at least electricity cost calculation, electricity price standards, and electricity consumption statistics; the device operation category includes at least device restart, parameter setting, and fault reporting; the policy consultation category includes at least subsidy policies, compliance standards, and application procedures; and the system management category includes at least account binding, data export, and permission setting.

[0029] As an optional implementation method, a number of business questions are collected as question samples according to various types of scenarios, and each question sample is classified into triples according to role-intention-question to generate a structured question list including but not limited to CSV format. Business keywords are extracted based on the structured question list, and the business keywords are queried and matched in the metadata knowledge base according to the SQL query template to associate the structured question list with the metadata table and metadata table fields, thereby establishing a business question knowledge base. Ensure that each entity in the question, such as "transformer" and "voltage", can be accurately matched to the table and / or field in the metadata knowledge base.

[0030] In this embodiment, by collecting high-frequency questions, historical conversation records, and real user questions in business scenarios, a sample set of questions that are strongly related to vertical fields such as electricity and energy is formed, which helps to unify the diverse expressions of the same needs of different users, thereby forming a standardized question template and obtaining a business problem knowledge base, and further providing input-output pairs for intent recognition models, intelligent spelling models, etc., to achieve end-to-end training and improve the accuracy of each model.

[0031] S3, constructing a semantic graph model of the robot based on the metadata knowledge base, including: Based on the extraction of standardized terms and their synonyms from power documents, a graph neural network is used to construct an industry terminology graph with standardized terms as nodes and synonyms as edges. A semantic graph model is established based on the industry terminology graph for converting real-time user input into standardized terms.

[0032] S4. Generate hybrid data features based on the annotated metadata knowledge base and the business problem knowledge base, and perform multi-model collaborative training of robot intent recognition, intelligent dialogue and intelligent spelling based on the hybrid data features and the semantic graph model.

[0033] Specifically, the generation of hybrid data features based on the metadata knowledge base and the business problem knowledge base based on annotations includes: Determine an intent label based on the problem scenario, establish a mapping relationship between the intent label and the metadata knowledge base, and associate the intent label with the metadata feature; Based on the business terms contained in the question text that match the metadata field, labeling the question text with the corresponding intent tag; The metadata features are converted into one-hot vectors and embedded and concatenated with the key fields of the question text and the intent label to obtain mixed data features.

[0034] As an optional implementation method, when determining intent labels based on problem scenarios, different levels of intent labels can be defined according to the type of target problem scenarios in the above step S1. For example, device operation, data query, and policy interpretation can be set as first-level intent labels; a mapping relationship is established between the intent label and the metadata knowledge base, and the intent label is further bound and associated with the metadata features. The metadata features can be the field type, table relationship, business label, etc. of the metadata table after business annotation.

[0035] Among them, the intent label can adopt the format of business domain_target problem scenario_object, where business domain_target problem scenario is the coarse-grained label for fast routing, and business domain_target problem scenario_object is the fine-grained label for accurate matching of metadata features.

[0036] As an optional implementation method, the question text is cleaned, including removing noise characters and stop words and unifying the text format; the intent tags related to the question text are determined based on the metadata business terms contained in the question, and then the question text is annotated with three levels of intent tags, including: basic annotation by annotators; automatic review of the basic annotation results based on the matching results between the question text and the intent tags, and correction of incorrect matches caused by deviations in metadata understanding; and resolution of annotation conflicts based on the review results.

[0037] As an optional implementation, metadata features mentioned in the question text are extracted, including: field types, such as time fields and numeric fields, and the number of tables involved in the question text. If single-table query or multi-table query is required, the complexity of table relationships, such as the number of table foreign keys, is further obtained; the semantic representation of tables and / or fields is learned through Node2Vec, and the metadata features are converted into one-hot vectors or graph embedding vectors, which are then concatenated with the question text and intent label embeddings and used as input parameters of the model.

[0038] In this embodiment, by mapping the question text with the intent label and metadata table structure, the metadata features annotated with the business label provide an entity anchor for intent recognition; the unstructured question text, semi-structured intent label and structured metadata are embedded and spliced ​​to form a heterogeneous feature vector, which solves the limitations of single-modal data and supplements the implicit business attributes in the question text based on the structured metadata, thereby ensuring the accuracy of subsequent intent recognition. Since the metadata features contain standardized business term mapping relationships, such as "transformer" → "equipment type = transformer", and the intent label annotates the business scenario, such as "data query", the fusion feature can align the two with the context vector of the question text, thereby eliminating the ambiguity of common language in vertical fields, narrowing the semantic gap, and further providing reliable data support for intent recognition. At the same time, it helps to enhance the adaptability of the robot service field.

[0039] It is understandable that in the hybrid data features, the intent label indicates the business type of the question and the metadata features mark the field-level semantics, which helps to accurately locate the slots during the training of the intelligent table-matching model and provide more accurate slot filling for the subsequent intelligent table-matching model to generate SQL.

[0040] Specifically, the multi-model collaborative training of robot intention recognition, intelligent dialogue and intelligent table spelling based on the mixed data features and the semantic graph model includes: Based on the pre-trained language model and model fine-tuning, the mixed data features are used as input parameters for model training, the user intent category is output, and an intent recognition model is established; Based on the intent type output by the intent recognition model, a sequence-to-sequence model is used to train the mixed data features and the power document to establish an intelligent dialogue model; Synchronously, during the training process of the intent recognition model and the intelligent dialogue model, a question-SQL pair is established based on the business keywords and metadata table fields of the question text, and the question-SQL pair is used as the input parameter of the sequence-to-sequence model to train the intelligent spelling model.

[0041] Specifically, based on the pre-trained language model and model fine-tuning, the mixed data features are used as input parameters for model training, user intent categories are output, and an intent recognition model is established, including: Using the pre-trained language model as the base model, the Transformers fine-tuning component is coupled to extract the semantic features of the mixed data features; Based on the semantic features, intent classification is performed using an activation function through a fully connected layer; The model training parameters are updated according to the minimum loss function, the intent type is output, and the training of the intent recognition model is completed.

[0042] As an optional implementation method, the pre-trained language model is used as the base model, and the Transformers fine-tuning component is coupled to the base model. The training parameters epochs and batch_size are set, and the mixed data features are input into the model according to the batch_size. The structured semantic features in the data features are extracted, and the structured features such as field types and table relationships are mapped to the same dimension using a fully connected network. The input mixed data features are classified according to the intent label through the activation function, and the cross-entropy loss function is used to measure the difference between the model prediction results and the true intent label to update the training parameters. After each epoch, the model is verified using the mixed data feature validation set, and the output intent type is compared with the true intent label. The performance of the model on different intent labels is checked to find the weak links of the model, and the model training parameters are dynamically adjusted and the model structure is optimized until the model outputs the intent type with the highest accuracy corresponding to the smallest loss function, thereby completing the training of the intent recognition model.

[0043] Furthermore, during model training, the loss and evaluation indicators on the validation set, such as accuracy and F1-score, can be monitored to prevent model overfitting and improve model generalization robustness.

[0044] In this embodiment, by training the intent recognition model, the model's intent recognition capability in complex dialogue scenarios, such as multi-round dialogues and context associations, is enhanced, and the intelligent service robot's intent recognition capability for user input text is improved, so that the user can accurately determine the operations he wants to perform or the information he wants to obtain. Among them, through the annotated intent labels, the model learns the direct mapping between questions and business scenarios, which significantly improves the accuracy of intent recognition.

[0045] Specifically, based on the intent type output by the intent recognition model, a sequence-to-sequence model is used to train the mixed data features and the power document to establish an intelligent dialogue model, including: determining a response structure type based on the intent tag; Extracting structured content associated with intent from power system documents and equipment operation manuals, labeling the structured content with corresponding intent tags, and obtaining structured rule data; After the intent label is used as a prefix and fused with the mixed data features and the structured rule data, the natural language in the question text is replaced with standard business terms through a semantic graph model to obtain training data; Based on the training data, a sequence-to-sequence model is used to perform iterative training on dual-branch data containing text and structured data, output a structured answer to the question text, and complete the training of the intelligent dialogue model.

[0046] As an optional implementation, Figure 2 and Figure 3 As shown, considering that different intent types correspond to different answer structures, for example, query intent may need to return a flowchart and node description, while operation intent requires a list of steps. Therefore, in this embodiment, the answer structure type is determined according to the intent label type. Before model training, training data preparation is required: First, parse the power system documents and equipment operation manuals into structured data. Information extraction technology or PDF parsing technology can be used to associate the parsed structured data with intent tags. The details are as follows: A1. Extract structured clauses related to intent types from power system documents, such as policy types like electricity pricing policies and grid connection regulations, policy effective dates, and applicable scopes. Also extract operational procedures from equipment manuals, including at least structured fields such as equipment model, operational procedures, operational objects, fault codes, maintenance cycles, and operational tools. These structured fields are then transformed into a structured process based on intent, equipment ID, and operational procedures. A2. Associate the obtained structured data, i.e., the structured clause content and operation step content, with the intent tag through data IDs, where the data IDs are the unique number of the structured clause and the process number of the structured process, respectively; A3. Extract features from structured data. The features at least include classification features, numerical features, and text features corresponding to the intention type. Replace the natural language in the question text with standard business terms through the semantic graph model, and then extract business keyword features. Align the data through the structured data ID, splice the features of each question text with its associated structured data, and incorporate the intention label as a prefix into the spliced structured data to obtain training data. For example: "<intention>ELECT_QUERY_PRICE< / intention> What is the electricity price of Hangzhou residents in 2024?", ELECT_QUERY_PRICE is the intention label, and electricity price is the business term annotated in the metadata knowledge base.

[0047] Among them, align the question text with the corresponding regulations or / and operation records through the structured data ID to form one-to-one or one-to-many samples. For example, one question may be associated with multiple regulation clauses. When splicing features, splice the feature vectors of the question text and the structured data along the dimension axis to form training data containing multi-dimensional mixed features.

[0048] As an optional implementation, divide the training data into a training set and a validation set according to a certain proportion to ensure that the same type of question-structured data pairs are scattered in different sets. Based on the training set, train using a sequence-to-sequence model. Extract the question text vector through the first branch, add a fully connected layer as the second branch to process the structured data features; merge through the fusion layer; output from both branches, input to the activation function classification layer for feature classification, and output the answer structure; verify the accuracy of the model output through the validation set, set the weighted cross-entropy loss function, increase the weight for the intention label, optimize the model training parameters, and dynamically adjust the learning rate during training to complete the training of the intelligent dialogue model.

[0049] As an optional implementation, the training data includes synonym replacement of the question text corresponding to the same intention label to obtain incremental training samples. Further, the training of the intelligent dialogue model can be divided into two stages, namely: the first stage, pre-train the model based on the training set to generate a general answer structure for each intention type, such as JSON, list, etc.; the second stage optimizes the intention-structure mapping through power domain data to fine-tune the model output.

[0050] Further, during the training process of the model, verify whether the answer structure output by the model matches the intention, and whether the output answer structure contains the necessary structured data. If the model output result is empty or the answer structure is incorrect, handle the abnormal model training based on the fallback strategy. The fallback strategy can be to call the intelligent table splicing model of the robot to generate new SQL query conditions, and then obtain new query results, convert them into an answer structure, and fill in the relevant structured data to respond to the user's question request.

[0051] As an optional implementation, the intelligent dialogue model can be continuously optimized based on feedback from the intent recognition model. For example, question-answer pairs where the intent type and answer structure do not match can be recorded and anomaly traced to analyze whether the intent recognition model misidentified the intent type. If so, the intent type needs to be re-identified. If not, the structured data is analyzed to see if the answer structure for the intent type is not covered. If not, the training data needs to be updated.

[0052] In this embodiment, an explicit association between questions and professional power documents is established through structured data IDs, which can avoid the ambiguity of implicit semantic matching and the limitations of pure data-driven models, so as to correctly splice the question text features with the structured data features and ensure the accuracy of the answer structure. Through the dual-branch training model, text semantics and structured data are processed separately, avoiding the feature masking effect of a single network on heterogeneous data, such as the structured data features being overwhelmed by text features. The dual-branch network can retain the pre-trained model's deep understanding of semantics and quickly fit the linear relationship of structured data. The loss weight function is then used to adjust and optimize the model parameters, solving the problem of imbalanced training data samples, avoiding the problem of overfitting power field data, and improving the accuracy of the intelligent dialogue model in the hybrid intention of power policy + equipment.

[0053] It should be noted that during the intent recognition model's intent type identification process and the training of the intelligent dialogue model, a pre-trained language model, such as BERT and RoBERTa, is first used as the base model. This model has been pre-trained on large-scale general corpora and has mastered the grammatical, semantic, and contextual dependencies of natural language. Using it directly as the base model avoids starting from scratch, reduces the amount of data annotation in the energy sector, and enables the model to quickly adapt to professional language environments such as electrical terminology and equipment names. A fine-tuning structure is then designed, such as the Transformers fine-tuning component, which can embed and concatenate three types of heterogeneous data: metadata features, intent labels, and question text, and then process them uniformly. This allows the model to dynamically focus on the importance of different features, resolving the problem that a single text feature cannot fully associate with business logic.

[0054] During fine-tuning, the model's multi-layer Transformer architecture captures long-range dependencies and deep semantics. Compared to traditional convolutional and recurrent neural network models, the pre-trained language model plus fine-tuning architecture is more suitable for abstract classification of complex problem intents, such as distinguishing between "querying equipment status" and "reporting a fault." With this fine-tuning architecture, the model can reversely optimize parameters for intent recognition tasks in the energy sector. Compared to using only the fixed representation of a pre-trained model, the fine-tuning strategy improves sensitivity to domain terminology and can quickly filter out irrelevant non-business-related intents.

[0055] Specifically, the question-SQL pair is established based on the business keywords of the question text and the metadata table fields, and the question-SQL pair is used as the input parameter of the sequence-to-sequence model to train the intelligent table-building model, including: Extracting business keywords from the question text and marking target slots corresponding to the business keywords; Determine an SQL template based on the intent type output by the intent recognition model and the metadata table structure associated with each intent tag; fill the target slot into the SQL template to generate a target SQL statement; A question-SQL pair is established according to the target SQL statement and the question text, and is used as an input parameter of a sequence-to-sequence model for model training to obtain an intelligent spelling table model.

[0056] As an optional implementation, based on the metadata knowledge base annotated with the above-mentioned business terms, including metadata tables and fields, and the above-mentioned business question knowledge base, the business keywords in the question text are bound to the metadata field name and field type. At the same time, the metadata table where the metadata field is located is associated according to the intent tag. The business keywords in the question text are mainly entity objects in the text whose semantics are the same as the business terms annotated in the metadata knowledge base, such as time, region, device type, etc. These entity objects are mapped to metadata fields and annotated with slots, such as {time} and {region}, and then the question text is converted into a standardized question with slots. The specific examples are as follows: Question text: "The load factor of the 35kV transformer in substation A last week"; Extract entity objects from the question text: station = A substation, voltage = 35kV, device_type = transformer, time = last week; Entity mapping, labeled slots: {station_name}, {voltage_level}, {device_type}, {time}; Standardized question conversion: "{voltage_level}{device_type} load rate at {time} at {station_name}".

[0057] The metadata table includes the main table to which metadata fields need to be bound and other possible associated tables, such as the intent tag QUERY_DEVICE_STATUS → main table device, associated table device_status. Associated tables are linked through corresponding foreign keys.

[0058] Among them, the natural language vocabulary in the question text is converted into standardized business terms corresponding to the fields in the metadata knowledge base through the semantic graph model.

[0059] As an optional implementation, SQL templates are generated based on the mapping relationship between intent types, metadata tables, and metadata field types. These include single-table query SQL templates and multi-table join query SQL templates. When defining SQL templates, template constraints must be added, including at least mandatory metadata field types. For example, the time slot {time} can only match DATE or DATETIME type fields.

[0060] As an optional implementation, establishing a question-SQL pair includes: matching the slots in the question with the {slot} in the SQL template one by one, filling in the slots and generating a specific SQL statement. For example: Problem slot: {station_name} = Substation A, {time} = 2024-12; SQL template: SELECT*FROM substation WHERE station_name={station_name}ANDmonth={time}; The slot filling generates the SQL statement: "SELECT * FROM substation WHERE station_name = 'A substation' AND month = '2024-12';".

[0061] Furthermore, by replacing entity objects in the question text with synonyms corresponding to the same metadata field name, the slot value can be adaptively perturbed to enhance training data. For example, replacing "electricity usage" in the question text with "total electricity consumption" corresponds to the same metadata field. The perturbation of the slot value is the dynamic adjustment of the adjustable value in the SQL statement, such as adjusting the time "2024-12" to "2025-01", while the final SQL structure remains unchanged.

[0062] As an optional implementation, during model training, a question-SQL pair is first input. The question text is encoded by the first Transformer branch, and then decoded by the second Transformer branch to generate SQL statements. Next, the model is trained in stages. In the first stage, pre-training is performed based on single-table queries to generate several single-table query SQL templates. In the second stage, the pre-trained model is fine-tuned by adding question-SQL pairs for multi-table joins to generate SQL templates for multi-table join queries, resulting in an intelligent table-joining model.

[0063] Among them, the second Transformer branch can forcibly generate the table name and field name existing in the metadata knowledge base during decoding.

[0064] Furthermore, error analysis is performed based on the erroneous SQL statements output by the model. This includes at least an analysis of the causes of field name errors and omissions in multi-table joins, and corresponding error corrections are made based on the analysis results. For example, if a spelling error in the field name slot annotation is caused by a typo in the metadata annotation, the metadata annotation must be corrected and retrained. For issues with omissions in multi-table joins, a forced join mechanism can be configured in the SQL template. For example, based on the foreign key join relationship between tables, all related tables connected by foreign keys of the main table can be forced to join.

[0065] Furthermore, in the actual operation of the robot, based on the intent type output by the intent recognition model in real time, a subset of SQL templates is adaptively selected to generate SQL statements for the question text, and the accuracy of the table names and field names in the SQL statements is verified through the metadata knowledge base.

[0066] In this embodiment, a bridge between business terms and metadata fields is established by annotating business terms in the metadata knowledge base and mapping them with the business problem knowledge base, so as to accurately bind and associate the natural language vocabulary in the question with the data field. Then, the intention label is used to preset that the question may involve the main table and the related table, which reduces the search space for subsequent SQL generation. There is no need to search for tables and fields in the full metadata, which improves the information query performance of the service robot and thus improves the efficiency of the robot's answer. At the same time, a question-SQL pair is established to avoid the same business word corresponding to multiple fields. By increasing sample diversity through methods such as synonym replacement and slot value perturbation, the generalization ability of the model is improved, ensuring that the robot can handle various forms of synonymous and different forms of problems. Through the error analysis results, the metadata can be corrected or template rules can be added to continuously improve the accuracy of the model.

[0067] S5. Perform distributed incremental training on each robot model in response to the user session log, migrate the model based on containerization, and complete the deployment of the robot.

[0068] Specifically, S5 includes: Extracting exception information based on the exception logs of the intent recognition model, the intelligent dialogue model, the intelligent table puzzle model, and the semantic graph model, including at least exception recognition intent and erroneous SQL statements; Track the cause based on the abnormal information and obtain the target object to be optimized; Based on the target object to be optimized, the abnormal data in the abnormal log is used as incremental training data for each model, and distributed incremental training of each model is performed according to the GPU cluster; Based on containerization technology, each trained model is migrated across the operating environment to complete the deployment of the robot.

[0069] As an optional implementation, user session logs are recorded in real time, including exception logs for the intent recognition model, intelligent dialogue model, intelligent spelling model, and semantic graph model. Core business personnel review the feedback data of daily user session logs and mark samples that need optimization. Add the feedback data to the training set of each model to obtain incremental training data, re-correct the problem-SQL mapping relationship, and perform distributed incremental training of each model on the GPU cluster. The learning rate of each model can be set to 10% of the initial training; In a transitional environment, such as a laboratory, model performance is tested based on a copy of production data, and model accuracy is compared through A / B testing. After the test is completed, seamless model migration is achieved through containerization such as Docker+K8S to ensure zero service interruption.

[0070] As you can understand, a GPU cluster, as a high-performance computing architecture, consists of multiple computer nodes equipped with graphics processing units (GPUs). These GPU nodes are connected via a high-speed network and work together to provide powerful parallel computing capabilities, providing computing power for the efficient training of service robot intent recognition models, intelligent dialogue models, intelligent spelling models, and semantic graph models.

[0071] Furthermore, Docker and Kubernetes (k8s), as the two main tools for containerized applications, enable the packaging of service robots' applications such as intent recognition, voice conversations, database queries, and user natural language recognition and conversion into lightweight, portable containers, and then automatically deploy, scale, and manage containerized applications on multiple hosts, thereby improving the adaptability of service robots.

[0072] In this embodiment, based on the incremental training mechanism of user feedback, the robot models are dynamically adjusted and optimized in real time, the functions of the service robot are improved, and the adaptability and flexibility of the service robot to dynamic changes in business scenarios are improved.

[0073] Example 2, as Figure 4 As shown in the figure, the overall process of intelligent question answering of the service robot includes: In response to the question text input by the user, including but not limited to voice, text, and pictures, the natural language vocabulary in the question text is converted into standard business terms based on the semantic graph model; Standard business terms are input into the intent recognition model. The intent labels are used to establish an association with the metadata table structure corresponding to the metadata knowledge base. The question text is annotated with the intent label. The key fields of the question text, the intent label, and the corresponding metadata feature vector are embedded and concatenated to obtain mixed data features. The semantic features of the mixed data features are extracted based on the Transformers fine-tuning component. The activation function is used to classify the intent and output the intent type. Learning the structured rules of power system documents and equipment operation manuals based on intelligent dialogue models; Based on the intent type, the intelligent spelling model automatically selects the SQL template, then marks the corresponding target slots according to the key fields of the question text, fills the target slots into the SQL template, and generates the target SQL statement; Query relevant data in the business database based on the target SQL statement, generate the corresponding answer structure type based on this data through the intelligent dialogue model, obtain the structured answer result, and return it to the user; Monitor the operation logs of each step in real time, obtain abnormal information, further generate incremental training data, locate abnormal nodes based on abnormal information, and perform distributed incremental training on the corresponding model to optimize model performance in real time.

[0074] In this embodiment, the question text input by the user is received through the intelligent dialogue model and converted into standard business terms through the semantic graph model to eliminate expression ambiguity and mine implicit semantics to achieve knowledge reasoning; the text is further spliced ​​in three dimensions with metadata features and intent labels to achieve multimodal feature fusion, so as to accurately identify user intent; based on the identified intent type, the intelligent spelling table model selects an SQL template based on the business keywords in the question text and generates a specific SQL statement to query related data. The intelligent dialogue model generates the corresponding answer structure based on the query data and responds to the user. During the entire question-and-answer process, abnormal information in the user session log is monitored in real time, abnormal links are located based on the abnormal information, and incremental training data is generated for the abnormal content. Each model is incrementally and collaboratively trained in a distributed manner to achieve continuous performance optimization of the service robot, ensure that the robot does not interrupt service, and improve user experience.

[0075] The above specific implementation methods are preferred implementation methods of the present application, and are not intended to limit the specific implementation scope of the present application. The scope of the present application includes but is not limited to the specific implementation methods. Any equivalent changes made in accordance with the shape, structure, and method of the present application are within the scope of protection of the present application.

Claims

1. A model training method for energy robots, characterized by: The steps include: Synchronize the business database to the local metadata knowledge base, and annotate the metadata tables in the metadata knowledge base with business features according to the business logic; Establish a business problem knowledge base based on business needs; Constructing a semantic graph model of the robot based on the metadata knowledge base; Based on the annotated metadata knowledge base and the business problem knowledge base, hybrid data features are generated, and multi-model collaborative training of robot intent recognition, intelligent dialogue and intelligent spelling is performed based on the hybrid data features and combined with the semantic graph model; distributed incremental training is performed on each model of the robot in response to user session logs, and model migration is performed based on containerization to complete the deployment of the robot.

2. The energy-oriented robot model training method according to claim 1, characterized in that: The synchronization of the business database to the local metadata knowledge base and the business annotation of the metadata table in the metadata knowledge base according to the business logic include: based on the business database containing key fields of the energy business, using ETL to periodically synchronize the data table structure in the business database to the local metadata knowledge base for storing robot operation data; According to the business logic characteristics represented by the metadata table and its fields, business term labels are respectively annotated on the metadata table and each field in the metadata table to complete the annotation of the metadata knowledge base used for robot model input feature mapping.

3. The energy-oriented robot model training method according to claim 1, characterized in that: The business problem knowledge base established based on business needs includes: Conduct business demand analysis based on power business scenarios and historical task work orders to determine target problem scenarios; Classify the target problem scenarios and collect a number of problem samples according to each scenario; Classify the question samples into triples based on role-intention-question to generate a structured question list; The structured question list is associated with the metadata knowledge base based on the SQL query template to build a business question knowledge base.

4. The energy-oriented robot model training method according to claim 1, characterized in that: The method of constructing a semantic graph model of a robot based on the metadata knowledge base includes: Based on the metadata knowledge base, standard terms and their synonyms are extracted, and a graph neural network is used to construct an industry term graph with standard terms as nodes and synonyms as edges; A semantic graph model is established based on the industry terminology graph for converting real-time user input into standardized terms.

5. The energy-oriented robot model training method according to claim 3 is characterized in that: The generating of hybrid data features based on the metadata knowledge base and the business problem knowledge base based on annotations includes: Determine an intent label based on the problem scenario, establish a mapping relationship between the intent label and the metadata knowledge base, and associate the intent label with the metadata feature; Based on the business terms contained in the question text that match the metadata field, labeling the question text with the corresponding intent tag; The metadata features are converted into one-hot vectors and embedded and concatenated with the key fields of the question text and the intent label to obtain mixed data features.

6. The energy-oriented robot model training method according to claim 4 or 5, characterized in that: The multi-model collaborative training of robot intention recognition, intelligent dialogue, and intelligent table spelling based on the mixed data features and the semantic graph model includes: Based on the pre-trained language model and model fine-tuning, the mixed data features are used as input parameters for model training, the user intent category is output, and an intent recognition model is established; Based on the intent type output by the intent recognition model, a sequence-to-sequence model is used to train the mixed data features and the power document to establish an intelligent dialogue model; Synchronously, during the training process of the intent recognition model and the intelligent dialogue model, a question-SQL pair is established based on the business keywords and metadata table fields of the question text, and the question-SQL pair is used as the input parameter of the sequence-to-sequence model to train the intelligent spelling model.

7. The energy-oriented robot model training method according to claim 6, characterized in that: The method uses the mixed data features as input parameters to perform model training based on the pre-trained language model and model fine-tuning, outputs the user intent category, and establishes an intent recognition model, including: Using the pre-trained language model as the base model, the Transformers fine-tuning component is coupled to extract the semantic features of the mixed data features; Based on the semantic features, intent classification is performed using an activation function through a fully connected layer; The model training parameters are updated according to the minimum loss function, the intent type is output, and the training of the intent recognition model is completed.

8. The energy-oriented robot model training method according to any one of claim 6, characterized in that: The intention type output by the intention recognition model is based on the mixed data features and the power document using a sequence-to-sequence model to establish an intelligent dialogue model, including: determining a response structure type based on the intent tag; Extracting structured content associated with intent from power system documents and equipment operation manuals, labeling the structured content with corresponding intent tags, and obtaining structured rule data; After the intent label is used as a prefix and fused with the mixed data features and the structured rule data, the natural language in the question text is replaced with standard business terms through a semantic graph model to obtain training data; Based on the training data, a sequence-to-sequence model is used to perform iterative training on dual-branch data containing text and structured data, output a structured answer to the question text, and complete the training of the intelligent dialogue model.

9. The energy-oriented robot model training method according to claim 6, characterized in that: The process of establishing a question-SQL pair based on the business keywords of the question text and the metadata table fields, using the question-SQL pair as an input parameter of a sequence-to-sequence model, and training an intelligent table-building model includes: Extracting business keywords from the question text and marking target slots corresponding to the business keywords; Determine an SQL template based on the intent type output by the intent recognition model and the metadata table structure associated with each intent tag; fill the target slot into the SQL template to generate a target SQL statement; A question-SQL pair is established according to the target SQL statement and the question text, and is used as an input parameter of a sequence-to-sequence model for model training to obtain an intelligent spelling table model.

10. The energy-oriented robot model training method according to any one of claim 6, characterized in that: The method performs distributed incremental training on the robot after multi-model collaborative training in response to user session logs, performs model migration according to containerization, and completes the deployment of the robot, including: Extracting exception information based on the exception logs of the intent recognition model, the intelligent dialogue model, the intelligent table puzzle model, and the semantic graph model, including at least exception recognition intent and erroneous SQL statements; Track the cause based on the abnormal information and obtain the target object to be optimized; Based on the target object to be optimized, the abnormal data in the abnormal log is used as incremental training data for each model, and distributed incremental training of each model is performed according to the GPU cluster; Based on containerization technology, each trained model is migrated across the operating environment to complete the deployment of the robot.

Citation Information

Patent Citations

  • Intelligent customer service robot data processing method and system

    CN115358774A

Cited By

  • Distributed multi-cloud-node remote sensing data synchronous transmission method, system and equipment

    CN120980095A

  • Enterprise knowledge base construction method and device suitable for question and answer large model, equipment and medium

    CN121072699A

  • Intelligent number asking method and related device

    CN121144464A