Dialogue processing method, device and electronic device

By analyzing the node execution behavior data of historical human-computer dialogues and identifying and optimizing abnormal branches, the problem of insufficient efficiency and accuracy of robot dialogue process optimization in the existing technology is solved, and more efficient and accurate dialogue process optimization and user response response are achieved.

CN116127036BActive Publication Date: 2025-07-29MASHANG CONSUMER FINANCE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310006006.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-01-04
Publication Date
2025-07-29
Estimated Expiration
2043-01-04

AI Technical Summary

Technical Problem

When the existing technology optimizes the robot dialogue process, the result data statistics cannot intuitively and accurately reflect abnormal problems, resulting in the robot being unable to respond accurately to user responses. Manual analysis is limited by experience and the data is complex, and the optimization effect and efficiency are not good.

Method used

By obtaining the node execution behavior data of historical human-computer dialogue, analyzing the hit data of the robot in the preset dialogue process, identifying exception branches, and optimizing the dialogue process based on exception branches, improving the optimization efficiency and accuracy of the dialogue process.

Benefits of technology

The efficient and accurate optimization of the dialogue process is achieved, and the robot can better respond to user responses and improve the accurate reach of dialogue tasks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116127036B_ABST
    Figure CN116127036B_ABST
Patent Text Reader

Abstract

The present application discloses a dialogue processing method, apparatus and electronic device, which are used to improve the optimization effect and efficiency of the dialogue process so as to improve the accuracy of the robot's response to the user's response. The method includes: obtaining node execution behavior data corresponding to the historical human-machine dialogue, where the node execution behavior data includes process node data executed by the robot in the preset dialogue process and branch data related to the process node data; analyzing and processing the node execution behavior data to obtain hit data of the target object within a specified historical time period, where the target object includes the dialogue path, branch flow direction and branch hit by the robot in the preset dialogue process; determining an abnormal branch in the preset dialogue process based on the hit data of the target object; and optimizing the preset dialogue process based on the branch type of the abnormal branch and the dialogue action represented by the process node connected to the abnormal branch.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the technical field of natural language processing, and in particular, to a dialogue processing method, apparatus, and electronic device. Background Art

[0002] With the rapid development of artificial intelligence technology, more and more services and jobs are being replaced by robots. For example, home appliance repair reporting, ticket reservation, telephone flight booking, product promotion, and business consultation. It is possible that the user is interacting with an artificial intelligence robot for these services, and it has been applied and influenced various industries.

[0003] Task-based intelligent dialogue robots are one of the most widely used robots. With the help of a call center, it can communicate with users by phone; with the help of instant messaging (IM) tools, it can communicate with users via voice and text. The robot analyzes the user's speech through natural language understanding (NLU), such as intention analysis, keyword analysis, semantic processing, etc., and then according to the pre-configured dialogue process, feedbacks the preset words or executes the preset actions to complete the artificial intelligence (AI) communication with the user. During the dialogue between the robot and the user, the user's response is difficult to predict, resulting in situations where the rules stored in the dialogue process configuration cannot be matched, the robot has no preset words to respond to the user, the robot cannot accurately respond to the user, etc., ultimately resulting in the dialogue effect not achieving the task purpose. Therefore, it is particularly important to quantitatively analyze the dialogue effect and optimize the dialogue process.

[0004] Currently, when optimizing the dialogue process of the robot, either focus on the statistical analysis of result data, such as communication results, user tags, communication rounds, etc., or only collect the raw data of program execution at the process nodes and let the operation staff analyze it by themselves. However, the statistical analysis of result data cannot intuitively and accurately reflect the actual abnormal problems in the dialogue process, affecting the optimization effect of the dialogue process, and further resulting in the robot still unable to accurately respond to the user's response; the manual analysis method is limited by human experience, and the configuration information of the dialogue process is relatively scattered and the data is complex, so the optimization effect and efficiency cannot be guaranteed, and it will also result in the robot still unable to accurately respond to the user's response. Summary of the Invention

[0005] The purpose of the embodiments of this application is to provide a dialogue processing method, apparatus, and electronic device, which are used to improve the optimization effect and efficiency of the dialogue process, so as to improve the accuracy of the robot's response to the user's response.

[0006] To achieve the above purpose, the embodiments of this application adopt the following technical solutions:

[0007] In a first aspect, an embodiment of the present application provides a dialogue processing method, including:

[0008] Obtain node execution behavior data corresponding to a historical human-machine dialogue, where the historical human-machine dialogue includes a dialogue between a robot and a user according to a preset dialogue process within a specified historical time period, the node execution behavior data includes process node data executed by the robot in the preset dialogue process and branch data related to the process node data, the process node data represents the dialogue actions executed by the robot during the dialogue, and the branch data represents the conditions that need to be met for the robot to execute another dialogue action after executing one dialogue action;

[0009] Analyze and process the node execution behavior data to obtain hit data of a target object within the specified historical time period, where the target object includes the dialogue path, branch flow direction, and branch hit by the robot in the preset dialogue process, the dialogue path represents the execution order between the process nodes executed by the robot, and the branch flow direction represents the execution order between the dialogue actions corresponding to two adjacent process nodes in the dialogue path;

[0010] Based on the hit data of the target object, determine the abnormal branches in the preset dialogue process;

[0011] Optimize the preset dialogue process based on the branch type of the abnormal branch and the dialogue actions represented by the process nodes connected by the abnormal branch.

[0012] In a second aspect, an embodiment of the present application provides a dialogue processing device, including:

[0013] An acquisition unit, configured to obtain node execution behavior data corresponding to a historical human-machine dialogue, where the historical human-machine dialogue includes a dialogue between a robot and a user according to a preset dialogue process within a specified historical time period, the node execution behavior data includes process node data executed by the robot in the preset dialogue process and branch data related to the process node data, the process node data represents the dialogue actions executed by the robot during the dialogue, and the branch data represents the conditions that need to be met for the robot to execute another dialogue action after executing one dialogue action;

[0014] An analysis unit, configured to analyze and process the node execution behavior data to obtain hit data of a target object within the specified historical time period, where the target object includes the dialogue path, branch flow direction, and branch hit by the robot in the preset dialogue process, the dialogue path represents the execution order between the process nodes executed by the robot, and the branch flow direction represents the execution order between the dialogue actions corresponding to two adjacent process nodes in the dialogue path;

[0015] A determining unit, configured to determine an abnormal branch in the preset dialogue process based on the hit data of the target object;

[0016] An optimizing unit, configured to optimize the preset dialogue process based on the branch type of the abnormal branch and the dialogue actions represented by the process nodes connected by the abnormal branch.

[0017] In a third aspect, an embodiment of the present application provides an electronic device, including: a processor; a memory for storing executable instructions of the processor; wherein, the processor is configured to execute the instructions to implement the method as described in the first aspect.

[0018] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, when the instructions in the storage medium are executed by a processor of an electronic device, enabling the electronic device to execute the method as described in the first aspect.

[0019] The above at least one technical solution adopted in the embodiments of the present application can achieve the following beneficial effects: During the process of the robot having a dialogue with the user according to the preset dialogue process to complete the corresponding dialogue task, the process node data executed by the robot in the preset dialogue process and the branch data related to these process node data, etc., that is, the node execution behavior data, are recorded; by analyzing the node execution behavior data corresponding to the historical human-machine dialogue between the robot and the user, the hit data of the dialogue path hit by the robot within a specified historical time period, the hit data of the branch flow direction, and the hit data of the branch are obtained; the dialogue path hit by the robot represents the execution order between the process nodes executed by the robot, and the hit data of the dialogue path can intuitively and objectively reflect the human-machine dialogue effect corresponding to the preset dialogue process as a whole. The branch flow direction represents the execution order between the dialogue actions represented by two adjacent process nodes in the dialogue path hit by the robot, and the hit data of the branch flow direction can intuitively and objectively reflect the human-machine dialogue effect corresponding to the two connected process nodes in the preset dialogue process from a local perspective. The hit data of the branch can intuitively and objectively reflect the human-machine dialogue effect corresponding to the branch in the preset dialogue process from a finer-grained perspective. Based on this, by analyzing the hit data of the dialogue path, the hit data of the branch flow direction, and the hit data of the branch, abnormal branches that may affect the human-machine dialogue effect in the preset dialogue process can be efficiently and accurately located from multiple perspectives of the whole and details, which is beneficial to improving the optimization efficiency and accuracy of the preset dialogue process; finally, based on the branch type of the abnormal branch and the dialogue actions represented by the process nodes connected by the abnormal branch, the preset dialogue process is optimized, making the optimization process of the preset dialogue process more targeted, further improving the optimization effect of the preset dialogue process, and further enabling the robot to accurately respond to the user's response according to the optimized preset dialogue process, and improving the accurate reach of the dialogue task. Description of the Drawings

[0020] The accompanying drawings described herein are used to provide a further understanding of the present application and form a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation of the present application. In the drawings:

[0021] Figure 1 Schematic diagram of a dialogue flow without subtasks and sub - processes provided for an embodiment of the present application;

[0022] Figure 2 Schematic diagram of a dialogue flow with subtasks and sub - processes provided for an embodiment of the present application;

[0023] Figure 3 Schematic diagram of an application scenario of a dialogue processing method provided for an embodiment of the present application;

[0024] Figure 4 Schematic flowchart of a dialogue processing method provided for an embodiment of the present application;

[0025] Figure 5 Schematic flowchart of a dialogue processing method provided for another embodiment of the present application;

[0026] Figure 6 Schematic flowchart of a dialogue processing method provided for yet another embodiment of the present application;

[0027] Figure 7 Schematic diagram of hit data of a dialogue path provided for an embodiment of the present application;

[0028] Figure 8 Schematic diagram of hit data of a branch flow direction provided for an embodiment of the present application;

[0029] Figure 9 Schematic diagram of hit data of a branch provided for an embodiment of the present application;

[0030] Figure 10 Schematic diagram of the structure of a dialogue processing device provided for an embodiment of the present application;

[0031] Figure 11 Schematic diagram of the structure of an electronic device provided for an embodiment of the present application. Detailed implementation manners

[0032] To make the objectives, technical solutions and advantages of this application more clear, the following will clearly and completely describe the technical solutions of this application in combination with the specific embodiments and corresponding drawings of this application. Obviously, the described embodiments are only a part rather than all of the embodiments of this application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in this application without creative efforts shall fall within the scope of protection of this application.

[0033] The terms "first", "second", etc. in this specification and claims are used to distinguish similar objects, rather than to describe a specific order or sequence. It should be understood that such data can be interchanged under appropriate circumstances so that the embodiments of this application can be implemented in an order other than those illustrated or described herein. In addition, the "and / or" in this specification and claims means at least one of the connected objects, and the character " / " generally indicates that the objects associated before and after are in an "or" relationship.

[0034] Explanation of some concepts:

[0035] Task-based intelligent dialogue robot: It refers to a robot that conducts multi-round interactions with users and ends the dialogue by finally completing a certain task. Each round of interaction is related to the context, and the entire dialogue process is similar to a software process, and is also often referred to as a multi-round dialogue system. The core of a task-based intelligent dialogue robot includes a natural language understanding module, a dialogue management (Dialogue Management, DM) module, and a natural language generation (Natural Language Generation, NLG) module, and can conduct dialogues with users through two interaction methods: text and voice. During voice interaction, it also requires the support of automatic speech recognition (ASR) and text-to-speech (TTS). Task-based intelligent dialogue robots are widely used in various scenarios such as enterprise marketing, customer service, sales, after-sales, and customer return visits.

[0036] Dialogue process configuration: A task-based intelligent dialogue robot needs to perform script configuration in advance, that is, dialogue process configuration. That is, around the completion of a certain task, the operator fully considers possible situations, splits them into multiple process nodes, branches, and sets rules, so that the robot can conduct dialogues according to the rules when communicating with users. A complete dialogue process can include subtasks, subprocesses, process nodes, and branches, etc.

[0037] Sub - tasks and sub - processes: Since a complete dialogue process is very large and may be relatively long, in order to facilitate management and increase reusability, the dialogue process configuration module of some task - based intelligent dialogue robots usually splits tasks into sub - tasks at a smaller dimension. Each sub - task can contain at least one sub - process, and then the entire dialogue process is split into multiple sub - processes. Sub - processes and sub - tasks are non - essential modules, which are only for more convenient operation management and increased reusability. Most task - based intelligent dialogue robots adopt the design of sub - tasks + sub - processes, or only the design of sub - tasks, or only the design of sub - processes. For example, Figure 1 shows a schematic diagram of a dialogue process without sub - tasks and sub - processes. This dialogue process includes various process nodes (such as speech nodes, end nodes) and branches connecting different process nodes, such as branches connecting the speech node at the first level and the speech node on the left side of the second level, etc.; Figure 2 shows a schematic diagram of a dialogue process with sub - tasks and sub - processes. The task corresponding to this dialogue process is split into 6 sub - tasks, namely sub - task 1 to sub - task 6. Each sub - task contains at least one sub - process. For example, sub - task 1 contains 5 sub - processes, namely sub - process 1 to process 5. The schematic diagram of sub - process 2 is as shown Figure 2 on the far right, which includes speech node 1, speech node 2, jump node 1, jump node 2, branch 1, branch 2, and branch 3. Among them, branch 1 connects speech node 1 and speech node 2, branch 2 connects speech node 1 and jump node 1, and branch 3 connects speech node 2 and jump node 3.

[0038] Process nodes: Process nodes are the smallest - granularity dialogue configurations, which often represent a dialogue action, such as a piece of speech, an action, an instruction, etc., and are a completely independent module. According to the matters to be completed by the process nodes, process nodes are generally divided into speech nodes, judgment nodes, function nodes, collection nodes, jump nodes, etc. Of course, other naming or definition - based division methods can also be used to divide process nodes, but their core idea is to split tasks at the smallest - granularity during the dialogue process between the robot and the user, and the paths between nodes all represent the logical sequence of the robot's dialogue.

[0039] Speech nodes: Used to configure a round of dialogue between the robot and the user. Generally, a robot's speech is configured, and then the user's response content is collected. According to the user's response content and previous context content, different branches are set. One branch represents one condition, that is, an independent and different situation. For example, taking Figure 2 the sub - process 2 shown as an example, after the robot executes the speech corresponding to speech node 1, it collects the user's response content. If the user's response content meets the condition represented by branch 1, it continues to execute the speech corresponding to speech node 2.

[0040] Collection nodes: These are where the bot is configured to have a conversation with the user. Typically, a single line of dialogue is configured, and the bot then collects key information (also known as "slot information") from the user's response. Because it may not be possible to collect all the required key information from a single user response, multiple questions can be configured for different key information. These questions are not prioritized, and ultimately, all key information must be collected at a single collection node. Of course, collection may fail. Multiple branches can also be set based on the key information collected and previous context.

[0041] Decision nodes: In some cases, due to the needs of the dialogue logic, it is necessary to set up special branches to meet the dialogue flow of various situations, without requiring the robot to engage in dialogue with the user. This often requires the use of a decision node. Decision nodes generally use context to set up multiple different branches.

[0042] Function nodes are primarily used to facilitate interaction with third-party systems. For example, by setting up a function node, the robot can call a third-party interface to query information or save information during a conversation with the user. Function nodes can be configured with or without robot scripts. Typically, the robot script serves as a guide, such as "Let me check your current balance," followed by a third-party query. Multiple branches can be set based on the query results and context.

[0043] Jump Node: When a conversation or sub-process ends, the next step may be to automatically hang up or enter another sub-process. Therefore, a jump node can be set, and the sub-process ends at the jump node. In addition, the jump node has a unique jump target, such as hanging up, transferring to a human operator, entering another sub-process within the subtask, entering a sub-process within another subtask, and so on.

[0044] Branch: As you can see from the node description above, a branch often represents a logical situation or condition. If this situation or condition is met, the task-based intelligent conversational robot will execute the corresponding conversation action at the downstream process node connected to the branch. Generally speaking, branches in a conversation can be divided into normal branches and abnormal branches.

[0045] Normal branch: When a pre-configured branch rule is hit, it is generally a normal branch. Normal branch rules can be configured based on multiple data sources such as keywords, current round intent, contextual intent, variables, etc. Therefore, generally speaking, countless branches can be configured on a node, which mainly depends on the operator's judgment and experience of possible situations in the conversation process.

[0046] Abnormal branch: It fails to hit the pre-configured branch rules, such as the user not responding in time, the user's intention being unknown, hitting the knowledge in the knowledge base, the user ending the call, etc.

[0047] User not responding in time: After the robot plays the script, it waits for the user to respond, but does not receive a response from the user within the preset time period. Usually, corresponding downstream process nodes also need to be configured for this branch.

[0048] User's intention being unknown: Although the user responds, it does not hit the normal branch, which means that the content of the user's response is a situation that the operator did not expect and the user's intention cannot be recognized. Usually, corresponding downstream process nodes will be configured for this branch.

[0049] Hitting the knowledge in the knowledge base: Although the user responds, it does not hit other branches. For this, a knowledge base of frequently asked questions (FAQ) is provided for the robot, and the system automatically calls the knowledge in the knowledge base to answer the user. Usually, corresponding downstream process nodes will be configured for this branch. The branch of hitting the knowledge in the knowledge base is not necessary.

[0050] User ending the call: That is, after the robot executes the dialogue action represented by a certain process node, the user directly ends the call. Usually, corresponding downstream process nodes will be configured for this branch.

[0051] Dialogue state management: During the process of the robot's dialogue with the user, it controls the human-machine dialogue process and manages its two major modules, including dialogue state tracking (DST) and dialogue policy learning (DPL).

[0052] Dialogue state tracking: Various information required for continuous multi-round conversations, including the dialogue history from time 0 to time t, user goals, intentions, slot value pairs, variables, etc. data, and the new data generated at each moment also updates the dialogue state in real time. The "context" mentioned during branch configuration includes all the information generated by DST.

[0053] Dialogue policy learning (DPL): Like DST, DPL is also part of dialogue management. According to the current dialogue state, it generates the system's next execution action, such as answering, clarifying, jumping to execute, etc. The design of dialogue policies is also strongly related to the task scenario. Supervised learning and reinforcement learning methods can be used, but currently in the industry, rule-based methods are mostly adopted to implement the defined actions corresponding to states, that is, the node and branch rules mentioned above, which mainly control the next execution action according to the branch rules.

[0054] It should be noted that different manufacturers may have different ways of defining process nodes. However, the essence of task-based intelligent dialogue robots is to make logical judgments based on process nodes and branches. During the dialogue process, the user may also hang up actively, resulting in an abnormal end of the dialogue (that is, it ends before reaching the jump node).

[0055] As mentioned above, when optimizing and configuring the dialogue process of the robot currently, either focus on the statistical results of data, such as communication results, user tags, communication rounds, etc., or only collect the original data of program execution at the process nodes and let the operation staff analyze it by themselves. However, the statistical results of data cannot intuitively and accurately reflect the actual abnormal problems existing in the dialogue process, affecting the optimization effect of the dialogue process, and further resulting in the robot still being unable to accurately respond to user responses; the manual analysis method is limited by human experience, and the configuration information of the dialogue process is relatively scattered and the data is complex, so the optimization effect and efficiency cannot be guaranteed, and the robot will still be unable to accurately respond to user responses.

[0056] In view of this, an embodiment of the present application aims to propose a dialogue processing method. During the process of a robot having a dialogue with a user according to a preset dialogue process to complete a corresponding dialogue task, the process node data executed by the robot in the preset dialogue process and the node execution behavior data such as the branch data related to these process node data are recorded; by analyzing the node execution behavior data corresponding to the historical human-machine dialogue between the robot and the user, the hit data of the dialogue path hit by the robot within a specified historical time period, the hit data of the branch flow direction, and the hit data of the branch are obtained; the dialogue path hit by the robot represents the execution order between the process nodes executed by the robot, and the hit data of the dialogue path can intuitively and objectively reflect the human-machine dialogue effect corresponding to the preset dialogue process as a whole. The branch flow direction represents the execution order between the dialogue actions represented by two adjacent process nodes in the dialogue path hit by the robot, and the hit data of the branch flow direction can intuitively and objectively reflect the human-machine dialogue effect corresponding to the two connected process nodes in the preset dialogue process locally. The hit data of the branch can intuitively and objectively reflect the human-machine dialogue effect corresponding to the branch in the preset dialogue process from a finer-grained perspective. Based on this, by analyzing the hit data of the dialogue path, the hit data of the branch flow direction, and the hit data of the branch, abnormal branches that may affect the human-machine dialogue effect in the preset dialogue process can be efficiently and accurately located from multiple perspectives of the whole and the details, which is beneficial to improving the optimization efficiency and accuracy of the preset dialogue process; finally, based on the branch type of the abnormal branch and the dialogue actions represented by the process nodes connected by the abnormal branch, the preset dialogue process is optimized, making the optimization process of the preset dialogue process more targeted, further improving the optimization effect of the preset dialogue process, and thus enabling the robot to accurately respond to the user's response according to the optimized preset dialogue process and improving the accurate reach of the dialogue task.

[0057] It should be understood that the dialogue processing method provided by the embodiment of the present application can be executed by an electronic device or software installed in the electronic device. The so-called electronic device here may include a terminal device, such as a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart voice interaction device, a smart home appliance, a smart watch, a vehicle-mounted terminal, an aircraft, etc.; or, the electronic device may also include a server, such as an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services.

[0058] The following will detail the technical solutions provided by each embodiment of the present application with reference to the accompanying drawings.

[0059] The dialogue processing method provided by the embodiment of the present application can be applied to, for example Figure 3In the scene shown, the scene may include a client 1 and a server 2. Among them, the client 1 refers to a client for human-computer interaction, which is usually installed in a user terminal, such as at least one of a mobile phone, a tablet computer, a personal computer (PC), a smart wearable device, etc. The server 2 refers to a server for human-computer interaction, which deploys a robot for conversing with users, such as a task-based intelligent dialogue robot, etc. In practical applications, multiple robots may be deployed in the server 2, such as Figure 3 the robots 1 to n shown, and each robot can execute different dialogue tasks, such as various dialogue tasks like enterprise marketing, customer service, sales, after-sales, customer return visits, etc. Different dialogue tasks have corresponding preset dialogue processes.

[0060] In the embodiment of the present application, the user can converse with the robots deployed in the server 2 through the client 1. To complete a certain dialogue task, such as a customer return visit task, etc., the robots deployed in the server 2 can converse with the user according to the preset dialogue process corresponding to the dialogue task. During the process of the robot and the user conversing, the server 2 will record the process nodes executed by the robot in the preset dialogue process and the node execution behavior data such as the branches between these process nodes.

[0061] If it is necessary to optimize the preset dialogue process, the server 2 can obtain the node execution behavior data corresponding to the historical human-computer conversations between the robot and the user within a specified historical time period. By processing and analyzing the obtained node execution behavior data, abnormal branches in the preset dialogue process can be located; further, the server 2 can optimize the preset dialogue process based on the relevant configuration information of the abnormal branches, such as the branch type of the abnormal branch and the dialogue actions represented by the process nodes connected to the abnormal branch, etc., so that the robot can accurately respond to the user's response according to the optimized preset dialogue process, thereby improving the accurate reach of the dialogue task. The dialogue processing method provided by the embodiment of the present application will describe in detail the process of the server 2 optimizing the preset dialogue process.

[0062] Based on Figure 3 the application scene shown, the embodiment of the present application provides a dialogue processing method. Please refer to Figure 4 , which is a schematic flowchart of a dialogue processing method provided by an embodiment of the present application. The method may include the following steps:

[0063] S402, obtain the node execution behavior data corresponding to the historical human-computer conversations.

[0064] Among them, the historical human-machine dialogue includes the dialogue between the robot and the user according to a preset dialogue process within a specified historical time period. The node execution behavior data includes the process node data executed by the robot in the preset dialogue process and the branch data related to the process node data. Among them, the preset dialogue process includes multiple process nodes and branches connecting different process nodes. Each process node represents a dialogue action, and the branch represents the condition that needs to be satisfied to execute another dialogue action after executing one dialogue action.

[0065] The process node data executed by the robot refers to the process node corresponding to the dialogue action executed by the robot in the preset dialogue process. The branch data related to the process node data represents the condition that the robot satisfies when executing another dialogue action after executing one dialogue action.

[0066] Specifically, before the above S402, the dialogue processing method provided by the embodiment of the present application may further include: during the process of the robot having a dialogue with the user according to the preset dialogue process, recording the node data of the process node currently executed by the robot, and determining, from the branches corresponding to the currently executed process node, the target branch that the response information made by the user for the currently executed process node of the robot satisfies, and recording the branch data of the target branch. Correspondingly, the above S402 may be implemented as: determining the process node data executed by the robot within the specified historical time period from the recorded node data, and determining the branch data related to the process node data executed by the robot within the specified historical time period from the recorded branch data.

[0067] More specifically, as Figure 5 shown, it is possible to pre-set data collection points at each process node and branch of the preset process respectively. The data collection point corresponding to the process node is used to monitor the event attributes of the execution event of this process node, such as including but not limited to the dialogue identifier of the dialogue to which the execution event belongs, the occurrence time and reporting time of the execution event, and the node data of this process node (including node identifier, node name, etc.); the data collection point corresponding to the branch is used to monitor the event attributes of the execution event of this branch, such as including but not limited to the dialogue identifier of the dialogue to which the execution event belongs, the occurrence time and reporting time of the execution event, and the branch data of this branch (including branch type, condition represented by the branch, downstream process node connected by the branch, etc.). In this way, during the human-machine dialogue process, every time the robot executes a process node or the user's response content hits a branch, a corresponding execution event will be generated, triggering the node corresponding to the process node or branch to collect and report the event attributes of the execution event.

[0068] Exemplarily, a dialogue between the robot and the user is as follows:

[0069]

[0070]

[0071] Based on the above conversation, the node execution behavior data as shown in Table 1 below can be obtained. Among them, the source node represents the process node currently being executed by the robot, and the target node represents the next process node pointed to by the source node under a certain branch configured by it. That is, for each branch, the source node is the upstream process node connected to this branch, and the target node is the downstream process node connected to this branch.

[0072] Table 1

[0073]

[0074] Furthermore, in S402, the node execution behavior data whose occurrence time is within the specified historical time period can be obtained from the recorded node execution behavior data, that is, the node execution behavior data corresponding to the historical human-machine conversation is obtained.

[0075] Of course, it should be understood that logging is only one method of collecting and reporting data, but not the only method. In some other alternative solutions, the data collection and reporting program can also be coupled in the business, and relevant data can be submitted as the business runs. In addition, the logging positions of the logs corresponding to different process nodes and different branches can be different. For example, the logs corresponding to the speech nodes, judgment nodes, and collection nodes are set when judging normal and abnormal branches, and the logs corresponding to the function nodes are set after the synchronous execution request is completed and after the asynchronous request is sent; the logs corresponding to the jump nodes are set when the jump rule is executed.

[0076] S404. Analyze and process the node execution behavior data to obtain the hit data of the target object within the specified historical time period.

[0077] Among them, the target object includes the conversation path, branch flow direction, and branches hit by the robot in the preset conversation process.

[0078] In the embodiments of the present application, the conversation path represents the execution order between the process nodes executed by the robot. For example, when the robot is having a conversation with a certain user and sequentially executes four process nodes: process node 1, process node 2, process node 3, and process node 4, then the conversation path of this conversation segment is: process node 1 -> process node 2 -> process node 3 -> process node 4. The hit data of the conversation path is used to reflect the traffic situation of this conversation path within the specified historical time period, and specifically may include the number of historical human-machine conversations with this conversation path within the specified historical time period. Thus, the hit data of the conversation path can intuitively and objectively reflect the human-machine conversation effect corresponding to the preset conversation process as a whole.

[0079] In the above S404, such as Figure 5 andFigure 6 As shown in the figure, through a pre-set node execution - dialogue path statistics method, data extraction, transformation, and loading (ETL) processing can be performed on the node execution behavior data to obtain the hit data of the dialogue path within a specified historical time period.

[0080] More specifically, the node execution behavior data within a specified historical time period can be grouped according to the historical human - machine dialogues to which they belong, so as to divide the node execution behavior data belonging to the same historical human - machine dialogue into a group; then, for each type of node execution behavior data, according to the chronological order of occurrence, the source node and the target node are spliced to obtain the corresponding dialogue path; further, after obtaining the dialogue paths corresponding to each group of node execution behavior data, the number of historical human - machine dialogues to which each dialogue path belongs is counted, and this number is the hit count of the dialogue path, which can thus be used as the hit data of the dialogue path.

[0081] Exemplarily, by performing ETL processing on the node execution behavior data shown in Table 1 above, the hit data of the dialogue paths hit by the robot within the specified historical time period as shown in Table 2 below can be obtained. In practical applications, Table 2 below can be an incremental table or a full - scale table, which can be specifically set according to actual needs, and the embodiments of the present application do not limit this.

[0082] Table 2

[0083] Dialogue path Quantity Occurrence time Verify identity -> DPD1-7 -> Overdue broadcast -> Next PTP -> End 1 2022-10-18 Verify identity -> Collect RPC -> Request to relay -> Next reminder -> End 1 2022-10-18 … … …

[0084] In the embodiments of the present application, the branch flow direction represents the execution order between the dialogue actions corresponding to two adjacent process nodes in the dialogue path hit by the robot. For example, during the process of the robot having a dialogue with a certain user, after executing the dialogue action represented by dialogue node 1, it is detected that the response content of the user to this dialogue action meets the conditions represented by branch 1, and then the dialogue action represented by dialogue node 2 pointed to by dialogue node 1 under this branch 1 is executed. Then, dialogue node 1 -> dialogue node 2 is a branch flow direction. The hit data of the branch flow direction is used to reflect the traffic situation of this branch flow direction within a specified historical time period, and specifically may include the number of historical human - machine dialogues with this branch flow direction within the specified historical time period. Thus, the hit data of the branch flow direction can intuitively and objectively reflect the human - machine dialogue effect corresponding to two connected process nodes in the preset dialogue process from a local perspective.

[0085] In S404 above, as Figure 5 and Figure 6 shown, through a pre - selected node execution - branch flow direction statistics method, ETL processing can be performed on the node execution behavior data to obtain the hit data of the branch flow direction within a specified time period.

[0086] More specifically, the node execution behavior data for a specified historical time period can be grouped and statistically analyzed according to the source node - target node to obtain the number of historical human - machine conversations belonging to different branch flows. This number is the hit count of the branch flow. Further, by traversing each obtained branch flow in sequence and querying the subprocess to which the branch flow belongs, if a certain branch flow does not have a corresponding subprocess, it can be determined that this branch flow is generally a jump between different subprocesses, and then this branch flow can be deleted. Thus, the number of historical human - machine conversations belonging to each branch flow and the subprocess to which each branch flow belongs can be used as the hit data of the branch flow within the specified historical time period.

[0087] Exemplarily, by performing ETL processing on the node execution behavior data shown in Table 1 above, the hit data of the branch flow within the specified historical time period as shown in Table 3 below can be obtained. In practical applications, Table 3 below can be an incremental table or a full - scale table, which can be specifically set according to actual needs, and the embodiments of the present application do not limit this.

[0088] Table 3

[0089] Sub-process to which it belongs Source node Target node Quantity Occurrence time 1 1 2 291 2022-10-18 1 2 4 121 2022-10-18 2 4 5 232 2022-10-18 2 5 6 124 2022-10-18 1 1 3 4325 2022-10-18 1 3 7 223 2022-10-18 1 7 8 21 2022-10-18 1 8 9 332 2022-10-18 … … … … …

[0090] In the embodiments of the present application, the hit data of the branch is used to reflect the traffic situation of this branch within the specified historical time period, and specifically may include the number of historical human - machine conversations that hit this branch within the specified historical time period. Thus, the hit data of the branch can intuitively and objectively reflect the human - machine conversation effect corresponding to the branch in the preset conversation process from a finer - grained perspective.

[0091] In S404 above, as Figure 5 and Figure 6 shown, the node execution - branch data statistical method can be used to perform ETL processing on the node execution behavior data to obtain the hit data of the branch within the specified historical time period.

[0092] More specifically, the node execution behavior data for a specified historical time period can be grouped and statistically analyzed according to the branch type to obtain the number of historical human - machine conversations that hit each type of branch. This number is the hit count of the branch. Further, for the branches of the type that hit the knowledge in the knowledge base, the number of historical human - machine conversations that hit the knowledge corresponding to these branches is also statistically analyzed to obtain the hit count of the knowledge in the knowledge base. Thus, the number of historical human - machine conversations of each type of branch and the hit count of the knowledge in the knowledge base can be used as the hit data of the branch within the specified historical time period.

[0093] Exemplarily, by performing ETL processing on the node execution behavior data shown in Table 1 above, the hit data of the branches within the specified historical time period shown in Table 4 below can be obtained. In practical applications, Table 4 below can be an incremental table or a full-scale table, which can be specifically set according to actual needs, and the embodiments of the present application do not limit this.

[0094] Table 4

[0095] Type Branch type & Knowledge Quantity Occurrence time Branch a is the person himself 23 2022-10-18 Branch x promises to repay the loan 121 2022-10-18 Branch b is a relative 22 2022-10-18 Branch c has collected the father 34 2022-10-18 Branch d promises to relay 154 2022-10-18 Knowledge Knowledge 1 13 2022-10-18 Branch m has been unrecognized 3 times 12 2022-10-18 Branch z has been unrecognized 1 time 124 2022-10-18 … … … …

[0096] In practical applications, the ETL trigger condition for performing ETL processing on the node execution behavior data can be set in advance. For example, it can be triggered when a set time point is reached, triggered periodically, etc. Correspondingly, as Figure 5 shown, when the ETL trigger condition is reached, the ETL processing of the node execution behavior data can be triggered to obtain the hit data of the conversation paths, the hit data of the branch flow directions, and the hit data of the branches within the specified time period.

[0097] Optionally, in order to enable the operation personnel to quickly understand the hit data of the conversation paths within the specified historical time period and provide data support for operation analysis for the operation personnel, after the above S404, the conversation processing method provided by the embodiments of the present application may further include: displaying the hit times of the conversation paths hit by the robot within the specified historical time period through a first type of chart; in response to a selection operation on the graph representing the hit times on the first type of chart, in an area different from the first type of chart, displaying the conversation paths corresponding to the hit times represented by the selected graph through a second type of chart.

[0098] More specifically, the server may send a first display request to the client, and the first display request carries the hit times of the conversation paths hit by the robot within the specified historical time period and the type identifier representing the first type of chart, so as to request the client to display the hit times of the conversation paths within the specified historical time period through the first type of chart; further, the client may, according to the selection operation of the user on the graph representing the hit times on the first type of chart, display the conversation paths corresponding to the hit times represented by the selected graph through the second type of chart.

[0099] In practical applications, the first type of chart and the second type of chart can be selected according to actual needs, and the embodiments of the present application do not limit this. Exemplarily, the first type of chart can be a bar chart, and the second type of chart can be a flowchart. Figure 7An example is shown of a bar chart presenting the hit counts of conversation paths within a specified historical time period. Each rectangle in the bar chart corresponds to a conversation path, and the height of the rectangle represents the hit count of the corresponding conversation path. In response to the user's selection operation on the leftmost rectangle in the bar chart, the conversation path corresponding to this rectangle can be presented in the form of a flowchart below the bar chart: Process Node 1 -> (Branch 1) -> Process Node 2 -> (Branch 2) -> Process Node 3 -> (Branch 3) -> Process Node 4 -> (Branch 4) -> Process Node 5 -> (Branch 5) -> Process Node 6 -> (Branch 6) -> Process Node 7 -> (Branch 7) -> Process Node 8, where Process Node 1 -> (Branch 1) -> Process Node 2 belongs to Sub-process 1, Process Node 3 -> (Branch 3) -> Process Node 4 belongs to Sub-process 2, Process Node 5 -> (Branch 5) -> Process Node 6 belongs to Sub-process 3, and Process Node 7 -> (Branch 7) -> Process Node 8 belongs to Sub-process 4.

[0100] It can be understood that presenting the hit counts of conversation paths and the selected conversation path in the form of a chart enables the hit data of conversation paths within a specified historical time period to be visually presented to the operation staff, so that the operation staff can quickly understand the hit data of conversation paths within the specified historical time period, providing data support for operation analysis by the operation staff.

[0101] Optionally, in order to enable the operation staff to quickly understand the hit data of branch flows within a specified historical time period and provide data support for operation analysis by the operation staff, after the above S404, the conversation processing method provided by the embodiments of the present application may further include: grouping the branch flows hit by the robot within the specified historical time period according to the sub-processes to which they belong, obtaining multiple groups of branch flows, with each group of branch flows corresponding to a sub-process; presenting the hit counts of each group of branch flows through a third-type chart.

[0102] More specifically, the server may send a second presentation request to the client, which carries the hit counts of branch flows within the specified historical time period and a type identifier indicating the third-type chart, to request the client to present the hit counts of branch flows within the specified historical time period through the third-type chart.

[0103] In practical applications, the third-type chart can be selected according to actual needs, and the embodiments of the present application do not limit this. By way of example, the third-type chart can be a Sankey diagram, also known as a Sankey energy diversion diagram or a Sankey energy balance diagram, which is a relationship diagram of a specific process type, including two elements: nodes and edges. Each edge links two nodes, and the node-node represents the data flow direction, and the edge width represents the magnitude of the data flow between nodes. It is usually used for visual analysis of data such as energy, material division, and finance.

[0104] Figure 8 Shows an example of the hit count of the branch flow in a specified historical period presented in a sankey diagram, which includes multiple sankey diagrams corresponding to the subprocesses included in Subtask 1 to Subtask 3 respectively. Further, in response to the user's selection operation on the sankey diagram corresponding to the second subprocess in Subtask 2, the sankey diagram is enlarged and presented in the right area.

[0105] It can be understood that presenting the hit count of the branch flow in the form of a chart enables the hit data of the branch flow in the specified historical period to be visually presented to the operation personnel, so that the operation personnel can quickly understand the hit data of the branch flow in the specified historical period and provides data support for the operation analysis of the operation personnel.

[0106] Optionally, in order to enable the operation personnel to quickly understand the hit data and configuration data of a certain branch and provide data support for the operation analysis of the operation personnel, after presenting the hit count of each group of branch flows through the third type of chart, the dialogue processing method provided by the embodiment of the present application may further include: in response to the selection operation on the graph representing the branch in the third type of chart, presenting the hit count of the selected branch and the process nodes connected to the branch through the fourth type of chart.

[0107] In practical applications, the fourth type of chart can be selected according to actual needs, and the embodiment of the present application does not limit this. Exemplarily, the third type of chart can be a flowchart. Figure 9 Shows an example of presenting the hit count of a branch in a specified historical period and the process nodes connected to the branch in a flowchart. This figure includes the hit count of the selected Branch 1, the hit count, dialogue actions of the upstream process node 1 (i.e., the source node) connected to Branch 1, and all branches (Branch 1 to Branch 3), and the hit count and dialogue actions of the downstream process node 2 (i.e., the target node).

[0108] It can be understood that presenting the hit count of the selected branch and the process nodes connected to the branch in the form of a chart enables the branch and its related configuration data in the specified historical period to be visually presented to the operation personnel and provides data support for the operation analysis of the operation personnel.

[0109] S406. Determine the abnormal branches in the preset dialogue process based on the hit data of the target object.

[0110] Since the hit data of the dialogue path can intuitively and objectively reflect the human-machine dialogue effect corresponding to the preset dialogue process as a whole, the hit data of the branch flow direction can intuitively and objectively reflect the human-machine dialogue effect corresponding to two connected process nodes in the preset dialogue process locally, and the hit data of the branch can intuitively and objectively reflect the human-machine dialogue effect corresponding to the branch in the preset dialogue process from a finer-grained perspective. Based on this, by analyzing the hit data of the dialogue path, the hit data of the branch flow direction, and the hit data of the branch, abnormal branches that may affect the human-machine dialogue effect in the preset dialogue process can be efficiently and accurately located from multiple perspectives of the whole and details, which is beneficial to improving the optimization efficiency and accuracy of the preset dialogue process.

[0111] In an alternative implementation, in order to quickly and accurately locate the abnormal branches in the preset dialogue process, the dialogue path analysis - branch flow direction analysis - branch and knowledge hit analysis can be performed in sequence from the whole to the details. Specifically, the above S406 may include the following steps:

[0112] S461, Select the dialogue paths with the hit times greater than or equal to the first preset times threshold from the dialogue paths hit by the robot within the specified historical time period as the abnormal dialogue paths.

[0113] From an overall perspective, if a certain dialogue path in the preset dialogue process is unreasonably configured, then this dialogue path usually has traffic accumulation within a certain time period. Based on this, if the hit times of a certain dialogue path are greater than the first preset times threshold, it can be determined that the abnormal probability of this dialogue path is relatively large, and then this dialogue path can be used as an abnormal dialogue path.

[0114] In practical applications, the first preset times threshold can be set according to actual needs, and the embodiments of the present application do not limit this.

[0115] S462, Based on the hit times of each branch flow direction in the sub-process involved in the abnormal dialogue path, select the branch flow directions with the hit times greater than or equal to the second preset times threshold from the abnormal dialogue path as the abnormal branch flow directions.

[0116] From a local perspective, if a certain branch flow direction in the preset dialogue process is unreasonably configured, then this branch flow direction usually also has traffic accumulation within a certain time period. Based on this, if the hit times of a certain branch flow direction in the above abnormal dialogue path are greater than or equal to the second preset times threshold, it can be determined that the abnormal probability of this branch flow direction is relatively large, and then this branch flow direction can be used as an abnormal branch flow direction.

[0117] Further, considering that for the convenience of management and increased reuse, tasks are usually split into subtasks of smaller dimensions, and a complete dialogue process is also split into multiple sub-processes according to different subtasks. Based on this, in order to intuitively reflect the human-machine dialogue effect of each sub-process, taking the sub-process as a unit, for each sub-process involved in the abnormal dialogue path, according to the hit times of each branch flow direction in this sub-process, select the branch flow direction with the hit times greater than or equal to the second preset number threshold from this sub-process as the abnormal branch flow direction.

[0118] In practical applications, the second preset number threshold can be set according to actual needs, and the embodiments of the present application do not limit this.

[0119] S463, select the branch with the hit times exceeding the third preset number threshold from the abnormal branch flow directions as the abnormal branch.

[0120] From a finer-grained perspective, if a certain branch in the preset dialogue process is not reasonably configured, then this branch usually shows traffic accumulation within a certain period of time. Based on this, if the hit times of a certain branch in the above abnormal dialogue path are greater than or equal to the third preset number threshold, it can be determined that the abnormal probability of this branch is relatively high, and then this branch can be used as the abnormal branch flow direction.

[0121] In practical applications, the third preset number threshold can be set according to actual needs, and the embodiments of the present application do not limit this.

[0122] The embodiments of the present application show a specific implementation manner of the above S406 here. Of course, it should be understood that the above S406 can also be implemented in other ways, and the embodiments of the present application do not limit this. Exemplarily, the dialogue paths with the hit times greater than or equal to the first preset number threshold can be selected from the dialogue paths within the specified historical time period as the abnormal dialogue paths, and the branches included in the abnormal dialogue paths are determined; the branch flow directions with the hit times greater than or equal to the second preset number threshold are selected from the branch flow directions within the specified historical time period as the abnormal branch flow directions, and the branches included in the abnormal branch flow directions are determined; the branches with the hit times greater than or equal to the third preset number threshold are selected from the branches within the specified historical time period as the candidate branches; then, the intersection among the branches included in the abnormal dialogue paths, the branches included in the abnormal branch flow directions, and the candidate branches is determined as the abnormal branches.

[0123] S408, optimize the preset dialogue process based on the branch type of the abnormal branch and the dialogue actions represented by the process nodes connected by the abnormal branch.

[0124] In an optional implementation manner, the above S408 can be specifically implemented as:

[0125] Case 1: If the branch type of the abnormal branch is that the user ends the call, optimize the corresponding dialogue action represented by the upstream process node connected to the abnormal branch.

[0126] If the branch type of the abnormal branch with a large number of hits is that the user ends the call, it can be determined that the dialogue action configuration represented by the upstream process node connected to the abnormal branch is unreasonable, resulting in a low interest level of the user to continue the conversation. In this case, by optimizing the corresponding dialogue in the upstream process node connected to the abnormal branch, the interest level of the user to continue the conversation can be increased, which is conducive to improving the reach rate of the dialogue task.

[0127] For example, if the dialogue action represented by the upstream process node connected to the above abnormal branch is to play the words "Your XX application has expired", it can be optimized to "Your XX application has expired. To avoid affecting the use of Y service, please resubmit your XX application as soon as possible."

[0128] Case 2: If the branch type of the abnormal branch is that the user's intention is unknown, based on the dialogue action represented by the downstream process node connected to the abnormal branch, add a branch to the upstream process node connected to the abnormal branch and determine the downstream process node connected to the newly added branch.

[0129] If the branch type of the abnormal branch with a large number of hits is that the user's intention is unknown, it can be determined that the dialogue scenario is not fully considered. In this case, by adding a branch to the upstream process node connected to the abnormal branch and determining the downstream process node connected to the newly added branch, the branch flow corresponding to the newly added branch can better cover the requirements of various dialogue scenarios, which is conducive to improving the reach rate of the dialogue task.

[0130] For example, if the current branches of the upstream process node connected to the above abnormal branch include "It's the person himself" and "It's not the person himself", more branches can be added to this upstream process node, such as branches like "Who are you" and "Didn't catch it clearly".

[0131] Case 3: If the branch type of the abnormal branch is a hit in the knowledge base, optimize the knowledge in the knowledge base with the number of hits less than the fourth preset number threshold.

[0132] If the branch type of the abnormal branch with a large number of hits is a hit in the knowledge base, by optimizing the knowledge with a low number of hits in the knowledge base, the satisfaction of the user with the robot's response can be improved, which is conducive to improving the reach rate of the dialogue task.

[0133] Situation 4: If the branch type of the abnormal branch does not belong to the preset branch types, the abnormal branch is decomposed into multiple sub-branches, and the dialogue actions represented by the downstream process nodes connected to each sub-branch are determined. The preset branch types include unknown user intention, user ending the call, hitting knowledge in the knowledge base, and user not responding due to timeout.

[0134] If the branch type of the abnormal branch with a large number of hits does not belong to the preset branch types, it can be determined that the condition represented by the abnormal branch is too general. Therefore, the abnormal branch can be decomposed into multiple sub-branches, and the dialogue actions represented by the downstream process nodes connected to each sub-branch can be determined. This can more accurately identify the user's dialogue intention, thereby facilitating the improvement of the reach rate of the dialogue task.

[0135] Exemplarily, if the above abnormal branch is "unknown", the abnormal branch can be decomposed into multiple sub-branches such as "Who are you" and "Didn't hear clearly", and the downstream process nodes pointed to by each sub-branch and the dialogue actions they represent are determined.

[0136] In the dialogue processing method provided by one or more embodiments of the present application above, during the process of the robot having a dialogue with the user according to the preset dialogue process to complete the corresponding dialogue task, the process node data executed by the robot in the preset dialogue process and the branch data related to these process node data, etc., are recorded as node execution behavior data; by analyzing the node execution behavior data corresponding to the historical human-machine dialogue between the robot and the user, the hit data of the dialogue path hit by the robot within the specified historical time period, the hit data of the branch flow direction, and the hit data of the branch are obtained; the dialogue path hit by the robot represents the execution order between the process nodes executed by the robot, and the hit data of the dialogue path can intuitively and objectively reflect the human-machine dialogue effect corresponding to the preset dialogue process as a whole. The branch flow direction represents the execution order between the dialogue actions represented by two adjacent process nodes in the dialogue path hit by the robot, and the hit data of the branch flow direction can intuitively and objectively reflect the human-machine dialogue effect corresponding to two connected process nodes in the preset dialogue process from a local perspective. The hit data of the branch can intuitively and objectively reflect the human-machine dialogue effect corresponding to the branch in the preset dialogue process from a finer-grained perspective. Based on this, by analyzing the hit data of the dialogue path, the hit data of the branch flow direction, and the hit data of the branch, abnormal branches that may affect the human-machine dialogue effect in the preset dialogue process can be efficiently and accurately located from multiple perspectives of the whole and details, which is beneficial to improving the optimization efficiency and accuracy of the preset dialogue process; finally, based on the branch type of the abnormal branch and the dialogue actions represented by the process nodes connected to the abnormal branch, the preset dialogue process is optimized, making the optimization process of the preset dialogue process more targeted, further improving the optimization effect of the preset dialogue process, and then enabling the robot to accurately respond to the user's response according to the optimized preset dialogue process, and improving the accurate reach of the dialogue task.

[0137] It should be noted that in practical applications, the dialogue actions represented by each process node in the preset dialogue process and the response content made by the user to the dialogue action can be used as the input, and the dialogue action represented by the downstream process node executed under the response content of the process node can be used as the output to train the human-machine dialogue model. Thus, the robot inputs the dialogue action represented by the currently executed process node and the response content made by the user to the dialogue action into the human-machine dialogue model, and can determine the next dialogue action to be executed, realizing an automatic and intelligent dialogue with the user. Further, the abnormal branches in the preset dialogue process can be determined through the above steps S402 to S406; further, in the above S406, based on the branch type of the abnormal branch and the dialogue action represented by the process node connected to the abnormal branch, the human-machine dialogue model is optimized, so as to realize the optimization of the preset dialogue process.

[0138] The specific embodiments of the present specification have been described above. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve the desired result. Additionally, the processes depicted in the figures do not necessarily require the specific order or sequential order shown to achieve the desired result. In certain embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0139] In addition, corresponding to the above Figure 4 shown dialogue processing method, an embodiment of the present application also provides a dialogue processing device. Please refer to Figure 10 FIG. 1000 is a schematic structural diagram of a dialogue processing device 1000 provided in an embodiment of the present application. The device 1000 may include:

[0140] An obtaining unit 1010, configured to obtain node execution behavior data corresponding to a historical human-machine dialogue, where the historical human-machine dialogue includes a dialogue in which a robot conducts a dialogue with a user according to a preset dialogue process within a specified historical time period, the node execution behavior data includes process node data executed by the robot in the preset dialogue process and branch data related to the process node data, the process node data represents a dialogue action executed by the robot during the dialogue, and the branch data represents a condition satisfied for the robot to execute another dialogue action after executing a dialogue action;

[0141] An analysis unit 1020 is configured to analyze and process the behavior data of the nodes to obtain the hit data of the target object within the specified historical time period. The target object includes the dialogue path, branch flow direction, and branch hit by the robot in the preset dialogue process. The dialogue path represents the execution order between the process nodes executed by the robot, and the branch flow direction represents the execution order between the dialogue actions corresponding to two adjacent process nodes in the dialogue path.

[0142] A determination unit 1030 is configured to determine the abnormal branches in the preset dialogue process based on the hit data of the target object.

[0143] An optimization unit 1040 is configured to optimize the preset dialogue process based on the branch type of the abnormal branch and the dialogue actions represented by the process nodes connected to the abnormal branch.

[0144] Optionally, the hit data of the target object includes the hit times of the target object. The preset dialogue process includes multiple sub-processes, and each sub-process includes at least one branch and the process nodes connected by the at least one branch.

[0145] The determination unit is specifically configured to: select the dialogue paths with hit times greater than or equal to the first preset times threshold from the dialogue paths hit by the robot as the abnormal dialogue paths; based on the hit times of each branch flow direction in the sub-processes involved in the abnormal dialogue paths, select the branch flow directions with hit times greater than or equal to the second preset times threshold from the abnormal dialogue paths as the abnormal branch flow directions; and select the branches with hit times exceeding the third preset times threshold from the abnormal branch flow directions as the abnormal branches.

[0146] Optionally, the optimization unit is specifically configured to:

[0147] If the branch type of the abnormal branch is that the user ends the call, optimize the dialogue action represented by the upstream process node connected to the abnormal branch; or,

[0148] If the branch type of the abnormal branch is that the user's intention is unknown, based on the dialogue action represented by the downstream process node connected to the abnormal branch, add a branch to the upstream process node connected to the abnormal branch and determine the downstream process node connected to the newly added branch; or,

[0149] If the branch type of the abnormal branch is a hit in the knowledge base, optimize the knowledge with hit times less than the fourth preset times threshold in the knowledge base; or,

[0150] If the branch type of the abnormal branch does not belong to the preset branch type, decompose the abnormal branch into multiple sub-branches and determine the dialogue actions represented by the downstream process nodes connected to each sub-branch. The preset branch types include unknown user intention, user ending the call, hitting knowledge in the knowledge base, and user not responding within the timeout.

[0151] Optionally, the device further includes:

[0152] A first display unit, configured to, after the analysis unit analyzes and processes the behavior data of the node to obtain the hit data of the target object within the specified historical period, display the hit times of the dialogue paths hit by the robot through a first-type chart, and in response to a selection operation on the graph representing the hit times on the first-type chart, display, in an area different from the first-type chart, the dialogue paths corresponding to the hit times represented by the selected graph through a second-type chart.

[0153] Optionally, the device further includes:

[0154] A second display unit, configured to, after the analysis unit analyzes and processes the behavior data of the node to obtain the hit data of the target object within the specified historical period, group the branch flows hit by the robot according to the sub-processes to which they belong to obtain multiple groups of branch flows, each group of branch flows corresponding to a sub-process, and display the hit times of each group of branch flows through a third-type chart.

[0155] Optionally, the second display unit is further configured to: in response to a selection operation on the graph representing the sub-process in the third-type chart, display the hit data of the selected branch and the process nodes connected to the selected branch through a fourth-type chart.

[0156] Optionally, the device further includes:

[0157] A recording unit, configured to, before the acquisition unit acquires the node execution behavior data corresponding to the historical human-machine dialogue, record the node data of the process node currently executed by the robot during the process of the robot having a dialogue with the user according to the preset dialogue process, and determine, from the branches corresponding to the currently executed process node, the target branch that the response information made by the user for the currently executed process node of the robot satisfies, and record the branch data of the target branch;

[0158] The acquisition unit is specifically configured to: determine the process node data executed by the robot within the specified historical period from the recorded node data, and determine the branch data related to the process node data executed by the robot within the specified historical period from the recorded branch data.

[0159] Obviously, the dialogue processing device provided by the embodiments of the present application can serve as Figure 4 the execution subject of the dialogue processing method shown in, for example, Figure 4 in the dialogue processing method shown in, step S402 can be executed by the acquisition unit in the Figure 10 dialogue processing device shown in, step S404 can be executed by the analysis unit in the dialogue processing device, step S406 can be executed by the determination unit in the dialogue processing device, and step S408 can be executed by the optimization unit in the dialogue processing device.

[0160] According to another embodiment of the present application, Figure 4 each unit in the dialogue processing device shown in can be separately or entirely combined into one or several other units to form, or some of them can be further split into multiple smaller units in terms of function to form, which can achieve the same operation without affecting the realization of the technical effects of the embodiments of the present application. The above units are divided based on logical functions. In actual applications, the function of one unit can also be realized by multiple units, or the functions of multiple units can be realized by one unit. In other embodiments of the present application, the dialogue processing device can also include other units. In actual applications, these functions can also be assisted by other units and can be realized by the cooperation of multiple units.

[0161] According to another embodiment of the present application, it can be achieved by running a computer program (including program code) capable of executing the steps involved in the corresponding method shown in Figure 4 on a general computing device such as a computer including processing elements and storage elements such as a central processing unit (CPU), a random access memory (RAM), and a read-only memory (ROM), to construct the dialogue processing device shown in Figure 10 and to implement the dialogue processing method of the embodiments of the present application. The computer program can be recorded on, for example, a computer-readable storage medium and transferred to an electronic device through the computer-readable storage medium and run therein.

[0162] Figure 11 is a schematic structural diagram of an electronic device according to an embodiment of the present application. Please refer to Figure 11, at the hardware level, the electronic device includes a processor, and optionally also includes an internal bus, a network interface, and a memory. Among them, the memory may include a memory, such as a high-speed random access memory (RAM), and may also include a non-volatile memory, such as at least one disk memory, etc. Of course, the electronic device may also include other hardware required for other services.

[0163] The processor, network interface, and memory can be interconnected through an internal bus, which can be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For the sake of simplicity of representation, Figure 11 only a two-way arrow is used in the figure, but it does not mean that there is only one bus or one type of bus.

[0164] The memory is used to store programs. Specifically, the program can include program code, and the program code includes computer operation instructions. The memory can include a memory and a non-volatile memory, and provide instructions and data to the processor.

[0165] The processor reads the corresponding computer program from the non-volatile memory into the memory and then runs it, forming a dialogue processing device at the logical level. The processor executes the program stored in the memory and is specifically used to perform the following operations:

[0166] Obtain the node execution behavior data corresponding to the historical human-machine dialogue. Among them, the historical human-machine dialogue includes the dialogue between the robot and the user according to a preset dialogue process within a specified historical time period. The node execution behavior data includes the process node data executed by the robot in the preset dialogue process and the branch data related to the process node data. The process node data represents the dialogue actions executed by the robot during the dialogue, and the branch data represents the conditions satisfied for the robot to execute another dialogue action after executing a dialogue action;

[0167] Analyze and process the execution behavior data of the node to obtain the hit data of the target object within the specified historical time period. The target object includes the dialogue path, branch flow direction, and branch hit by the robot in the preset dialogue process. The dialogue path represents the execution order between the process nodes executed by the robot, and the branch flow direction represents the execution order between the dialogue actions corresponding to two adjacent process nodes in the dialogue path;

[0168] Based on the hit data of the target object, determine the abnormal branches in the preset dialogue process;

[0169] Based on the branch type of the abnormal branch and the dialogue actions represented by the process nodes connected by the abnormal branch, optimize the preset dialogue process.

[0170] The method executed by the dialogue processing device disclosed in the above embodiments of the present application Figure 4 can be applied to a processor or implemented by a processor. The processor may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the integrated logic circuit in the hardware of the processor or by instructions in the form of software. The above processor may be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it may also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components. It can implement or execute the various methods, steps, and logic block diagrams disclosed in the embodiments of the present application. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. The steps of the method disclosed in combination with the embodiments of the present application can be directly embodied as being executed and completed by the hardware decoding processor, or by a combination of the hardware and software modules in the decoding processor. The software module may be located in a mature storage medium in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, etc. This storage medium is located in the memory, and the processor reads the information in the memory and combines its hardware to complete the steps of the above method.

[0171] The electronic device can also execute Figure 4 the method and implement the functions of the dialogue processing device in Figures 4 to 9 the embodiments shown. The embodiments of the present application will not be elaborated here.

[0172] Of course, in addition to the software implementation, the electronic device of the present application does not exclude other implementation manners, such as logic devices or a combination of software and hardware, etc. That is to say, the execution subject of the following processing flow is not limited to each logic unit, and may also be hardware or a logic device.

[0173] The embodiment of the present application also provides a computer-readable storage medium, which stores one or more programs. The one or more programs include instructions that, when executed by a portable electronic device including a plurality of application programs, can cause the portable electronic device to execute Figure 4 the method of the illustrated embodiment, and specifically used to perform the following operations:

[0174] Obtain node execution behavior data corresponding to a historical human-machine dialogue. The historical human-machine dialogue includes a dialogue between a robot and a user according to a preset dialogue process within a specified historical time period. The node execution behavior data includes process node data executed by the robot in the preset dialogue process and branch data related to the process node data. The process node data represents the dialogue actions executed by the robot during the dialogue, and the branch data represents the conditions satisfied for the robot to execute another dialogue action after executing one dialogue action;

[0175] Analyze and process the node execution behavior data to obtain hit data of a target object within the specified historical time period. The target object includes the dialogue path, branch flow direction, and branch hit by the robot in the preset dialogue process. The dialogue path represents the execution order between the process nodes executed by the robot, and the branch flow direction represents the execution order between the dialogue actions corresponding to two adjacent process nodes in the dialogue path;

[0176] Based on the hit data of the target object, determine an abnormal branch in the preset dialogue process;

[0177] Optimize the preset dialogue process based on the branch type of the abnormal branch and the dialogue actions represented by the process nodes connected by the abnormal branch.

[0178] In summary, the above are only the preferred embodiments of the present application and are not used to limit the protection scope of the present application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.

[0179] The systems, devices, modules or units described in the above embodiments can be specifically implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer. Specifically, the computer can be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or any combination of these devices.

[0180] Computer-readable media includes both permanent and non-permanent, removable and non-removable media and can store information by any method or technology. The information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, magnetic tape disk storage or other magnetic storage devices, or any other non-transitory medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transitory media such as modulated data signals and carrier waves.

[0181] It should also be noted that the term "comprising", "including" or any other variant thereof is intended to cover non-exclusive inclusion, such that a process, method, commodity or device comprising a series of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, commodity or device. Without further limitation, an element defined by the statement "comprising an..." does not exclude the presence of additional identical elements in the process, method, commodity or device comprising the element.

[0182] Each embodiment in this specification is described in a progressive manner. The same or similar parts among the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can refer to the description of the method embodiment.

Claims

1. A dialogue processing method, characterized in that, Including: Obtain the node execution behavior data corresponding to the historical human-machine conversation. Among them, the historical human-machine conversation includes the conversation between the robot and the user according to a preset conversation process within a specified historical time period. The node execution behavior data includes the process node data executed by the robot in the preset conversation process and the branch data related to the process node data. The process node data represents the conversation actions executed by the robot during the conversation, and the branch data represents the conditions satisfied for the robot to execute another conversation action after executing one conversation action; Analyze and process the node execution behavior data to obtain the hit data of the target object within the specified historical time period. The target object includes the conversation path, branch flow direction, and branch hit by the robot in the preset conversation process. The conversation path represents the execution order between the process nodes executed by the robot, and the branch flow direction represents the execution order between the conversation actions corresponding to two adjacent process nodes in the conversation path; Based on the hit data of the target object, determine the abnormal branches in the preset conversation process; Optimize the preset conversation process based on the branch type of the abnormal branch and the conversation actions represented by the process nodes connected by the abnormal branch.

2. The method according to claim 1, wherein The hit data of the target object includes the hit times of the target object. The preset conversation process includes multiple sub-processes, and each sub-process includes at least one branch and the process nodes connected by the at least one branch; The determining the abnormal branches in the preset conversation process based on the hit data of the target object includes: Select the conversation paths with hit times greater than or equal to the first preset times threshold from the conversation paths hit by the robot as the abnormal conversation paths; Based on the hit times of each branch flow direction in the sub-processes involved in the abnormal conversation paths, select the branch flow directions with hit times greater than or equal to the second preset times threshold from the abnormal conversation paths as the abnormal branch flow directions; Select the branches with hit times exceeding the third preset times threshold from the abnormal branch flow directions as the abnormal branches.

3. The method according to claim 2, characterized in that, The optimizing the preset conversation process based on the branch type of the abnormal branch and the conversation actions represented by the process nodes connected by the abnormal branch includes: If the branch type of the abnormal branch is that the user ends the call, optimize the conversation action represented by the upstream process node connected by the abnormal branch; or, If the branch type of the abnormal branch is that the user's intention is unknown, based on the conversation action represented by the downstream process node connected by the abnormal branch, add a branch for the upstream process node connected by the abnormal branch and determine the downstream process node connected by the newly added branch; or, If the branch type of the abnormal branch is a hit in the knowledge base, optimize the knowledge with hit times less than the fourth preset times threshold in the knowledge base; or, If the branch type of the abnormal branch does not belong to the preset branch type, decompose the abnormal branch into multiple sub-branches and determine the corresponding dialogue actions of the downstream process nodes connected by each sub-branch. The preset branch types include unknown user intention, user ends the call, hits knowledge in the knowledge base, and user does not respond in time.

4. The method according to claim 2, wherein After analyzing and processing the node execution behavior data to obtain the hit data of the target object within the specified historical period, the method further includes: Displaying the hit times of the dialogue paths hit by the robot through a first type of chart; In response to a selection operation on the graph representing the hit times on the first type of chart, in an area different from the first type of chart, displaying the dialogue paths corresponding to the hit times represented by the selected graph through a second type of chart.

5. The method according to claim 2, wherein After analyzing and processing the node execution behavior data to obtain the hit data of the target object within the specified historical period, the method further includes: Grouping the branch flows hit by the robot according to the sub-processes to which they belong to obtain multiple groups of branch flows, and each group of branch flows corresponds to a sub-process; Displaying the hit times of each of the multiple groups of branch flows through a third type of chart.

6. The method according to claim 5, characterized in that, After displaying the hit times of each of the multiple groups of branch flows through the third type of chart, the method further includes: In response to a selection operation on the graph representing the sub-process in the third type of chart, displaying the hit data of the selected branch and the process nodes connected by the selected branch through a fourth type of chart.

7. The method according to any one of claims 1-6, characterized in that, Before obtaining the node execution behavior data corresponding to the historical human-machine dialogue, the method further includes: During the process of the robot having a dialogue with the user according to the preset dialogue process, recording the node data of the process node currently executed by the robot; From the branches corresponding to the currently executed process node, determining the target branch satisfied by the response information made by the user for the currently executed process node of the robot, and recording the branch data of the target branch; The obtaining of the node execution behavior data corresponding to the historical human-machine dialogue includes: Determining the process node data executed by the robot within the specified historical period from the recorded node data, and determining the branch data related to the process node data executed by the robot within the specified historical period from the recorded branch data.

8. A dialogue processing device, characterized in that, Including: An obtaining unit, configured to obtain the node execution behavior data corresponding to the historical human-machine dialogue, where the historical human-machine dialogue includes the dialogue between the robot and the user within a specified historical period according to a preset dialogue process, the node execution behavior data includes the process node data executed by the robot in the preset dialogue process and the branch data related to the process node data, the process node data represents the dialogue actions executed by the robot during the dialogue, and the branch data represents the conditions satisfied for the robot to execute another dialogue action after executing one dialogue action; An analysis unit for analyzing and processing the execution behavior data of the nodes to obtain the hit data of the target object within the specified historical time period, where the target object includes the dialogue paths, branch flows, and branches hit by the robot in the preset dialogue process, the dialogue path represents the execution order between the process nodes executed by the robot, and the branch flow represents the execution order between the dialogue actions corresponding to two adjacent process nodes in the dialogue path; A determination unit for determining the abnormal branches in the preset dialogue process based on the hit data of the target object; An optimization unit for optimizing the preset dialogue process based on the branch type of the abnormal branch and the dialogue actions corresponding to the process nodes connected by the abnormal branch.

9. An electronic device, characterized in that, Comprising: A processor; A memory for storing the executable instructions of the processor; Wherein, the processor is configured to execute the instructions to implement the method according to any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, When the instructions in the storage medium are executed by the processor of the electronic device, the electronic device is enabled to execute the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Man-machine conversation book generation method, device and equipment and readable storage medium

    CN112328770A

  • Dialogue stream diagnosis method and device

    CN114996537A