Dialogue data processing method, system and equipment and medium

By identifying intentions and constructing intention flow data on multiple rounds of historical call data, the problem that RAG solution failed to effectively utilize multiple rounds of dialogue historical information in human-computer dialogue is solved, and more accurate, logical and smooth reply is achieved, improving the quality and efficiency of reply.

CN119884312APending Publication Date: 2025-04-25SHENZHEN YISHIHUOLALA TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411950700.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-27
Publication Date
2025-04-25

AI Technical Summary

Technical Problem

The existing RAG scheme fails to effectively utilize the historical information of multiple rounds of dialogue in human-computer dialogue, resulting in the generated answers such as accuracy, logic and fluency, which affects the quality and efficiency of the responses.

Method used

By identifying the intent of multiple rounds of historical call data, constructing intent flow data, and retrieving the corresponding customer intent nodes in the preset invitation graph database, generating replies to reply to the customer.

Benefits of technology

Effectively utilize the historical information of multiple rounds of conversations, improving the accuracy, logic and fluency of generated answers, and improving the quality and efficiency of the responses.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119884312A_ABST
    Figure CN119884312A_ABST
Patent Text Reader

Abstract

The invention provides a dialogue data processing method, system and device and a medium, and relates to the technical field of artificial intelligence, and the processing method comprises the steps: obtaining a current inquiry voice of a client, and translating the current inquiry voice to generate current inquiry data; performing intention recognition processing on the current inquiry data to generate a current inquiry intention; searching whether a client intention node corresponding to the current inquiry intention exists in a preset invitation diagram database or not; if the current inquiry intention exists, acquiring a plurality of inviter intention nodes connected with the client intention node corresponding to the current inquiry intention, and generating a reply verbal skill according to the inviter intentions corresponding to the plurality of inviter intention nodes so as to reply the client; otherwise, replying the customer according to the preset general reply verbal skill. The invention provides a new data organization mode in a multi-round dialogue business scene, the historical information of multi-round dialogues is effectively utilized, and the accuracy, logicality and fluency of the generated answers are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology, and in particular to a method, system, device and medium for processing dialogue data. Background Art

[0002] Human-computer dialogue is an important part of the field of artificial intelligence technology. It allows users to exchange information with systems or machines through natural language, thereby obtaining corresponding dialogue services. However, due to the continuity, diversity and flexibility of natural language itself, single-round dialogue systems often find it difficult to accurately understand users' questions.

[0003] One of the technical solutions currently used is the RAG (Retrieval-Augmented Generation) method. Although this method is effective in some scenarios, it has an important flaw: when performing retrieval operations, it fails to fully consider the information of previous rounds of conversations. Specifically, RAG usually only stores and retrieves the content of conversations within a single round, which results in the question-answer pairs found may not fully fit the specific context of the current conversation. Therefore, the answers generated based on these retrieval results may have problems with inaccuracy, including logical incoherence, poor information consistency, and insufficient expression. In order to compensate for these problems, it is necessary to rely on more powerful models for additional verification and adjustment, but this not only increases the complexity of the processing flow, but also affects the speed and reliability of the response. Therefore, there is room for improvement. Summary of the invention

[0004] In view of the shortcomings of the prior art mentioned above, the purpose of the present invention is to provide a method, system, device and medium for processing conversation data, which is used to solve the technical problem that the RAG scheme in the prior art fails to effectively utilize the historical information of multiple rounds of conversations in human-computer conversations, resulting in the generated answers may have problems with accuracy, logic and fluency, thereby affecting the quality and efficiency of the response.

[0005] To achieve the above-mentioned purpose and other related purposes, the present invention provides a method for processing conversation data, comprising:

[0006] Acquire the customer's current inquiry voice, and translate the current inquiry voice to generate current inquiry data;

[0007] Performing intent recognition processing on the current inquiry data to generate a current inquiry intent;

[0008] Searching in a preset invitation graph database whether there is a customer intention node corresponding to the current inquiry intention, wherein the invitation graph database stores a plurality of intention flow data, and the inviter intention, customer intention and the association relationship between intentions in the intention flow data are respectively represented by the inviter intention node, the customer intention node and the connection between the nodes;

[0009] If so, obtain multiple inviter intention nodes connected to the customer intention node corresponding to the current inquiry intention, and generate a reply script according to the inviter intentions corresponding to the multiple inviter intention nodes to reply to the customer;

[0010] Otherwise, respond to the customer according to the preset general response script.

[0011] In one embodiment of the present invention, the step of generating a reply script based on the multiple inviter intentions to reply to the customer includes:

[0012] Acquire multiple inviter intention nodes connected to the customer intention node corresponding to the current inquiry intention, and extract the inviter intentions corresponding to the multiple inviter intention nodes;

[0013] Selecting an inviter intent as a candidate intent from multiple inviter intents according to a preset rule;

[0014] The customer's historical response data is obtained, and a response script is generated based on the historical response data and the candidate intent to respond to the customer.

[0015] In one embodiment of the present invention, the invitation graph database is generated by the following steps:

[0016] Obtaining historical conversation recordings, and translating the historical conversation recordings to generate corresponding historical conversation data;

[0017] Performing intent recognition processing on the historical conversation data to generate corresponding intent flow data;

[0018] The intention flow data is imported into the initial graph database to form the invitation graph database.

[0019] In one embodiment of the present invention, the step of performing intent recognition processing on the historical conversation data to generate corresponding intent flow data includes:

[0020] Performing identification processing on the historical conversation data to obtain multiple original intentions of the inviter and multiple original intentions of the client;

[0021] According to the preset tags, multiple original intentions of the inviter are merged to obtain multiple secondary intentions of the inviter, and multiple original intentions of the customer are merged to obtain multiple secondary intentions of the customer;

[0022] Clustering multiple secondary intentions of the inviter to obtain multiple primary intentions of the inviter, and clustering multiple secondary intentions of the customer to obtain multiple primary intentions of the customer;

[0023] Associate the original intentions of all customers with the original intentions of the corresponding inviters to generate original associated data; associate the secondary intentions of all customers with the secondary intentions of the corresponding inviters to generate secondary associated data; associate the primary intentions of all customers with the primary intentions of the corresponding inviters to generate primary associated data; generate intention flow data based on the original associated data, the secondary associated data and one of the primary associated data.

[0024] In one embodiment of the present invention, the step of importing the intention flow data into the initial graph database to form the invitation graph database includes:

[0025] Creating or updating an inviter intention node in an initial database according to the inviter's secondary intention in the intention flow data;

[0026] Creating or updating a customer intention node in an initial database according to the customer's secondary intention in the intention flow data;

[0027] According to the association relationship between the secondary intention of the customer and the secondary intention of the inviter in the intention flow data, the connection relationship between the customer intention node and the inviter intention node is created or updated to form the invitation graph database.

[0028] In one embodiment of the present invention, the step of creating or updating the inviter intention node in the initial database according to the inviter's secondary intention in the intention flow data includes:

[0029] Determine whether there is an inviter intent node corresponding to the inviter's secondary intent in the intent flow data in the initial graph database:

[0030] If it exists, update the attributes of the corresponding inviter intention node according to the original intention and the first-level intention of the inviter in the intention flow data;

[0031] Otherwise, a new inviter intention node is created according to the secondary intention of the inviter in the intention flow data, and the attributes of the corresponding inviter intention node are set according to the original intention and the primary intention of the inviter.

[0032] In one embodiment of the present invention, the step of creating or updating the connection relationship between the customer intention node and the inviter intention node according to the association relationship between the customer's secondary intention and the inviter's secondary intention in the intention flow data includes:

[0033] According to the association relationship between the secondary intention of the customer and the secondary intention of the inviter in each of the intention flow data, it is determined whether there is a connection relationship between the corresponding customer intention node and the corresponding inviter intention node in the initial graph database;

[0034] If so, update the attribute of the connection relationship between the customer intention node and the inviter intention node;

[0035] Otherwise, a connection relationship between the customer intention node and the inviter intention node is established, and the attributes of the connection relationship are set.

[0036] The present invention also provides a system for processing conversation data, comprising:

[0037] The voice translation module is used to obtain the customer's current inquiry voice, and translate the current inquiry voice to generate current inquiry data;

[0038] An intention recognition module, used to perform intention recognition processing on the current inquiry data to generate a current inquiry intention;

[0039] A retrieval reply module is used to search in a preset invitation graph database whether there is a customer intention node corresponding to the current inquiry intention, wherein the invitation graph database stores multiple intention flow data, and the inviter intention, customer intention and the relationship between intentions in the intention flow data are respectively represented by the inviter intention node, the customer intention node and the connection between the nodes; if it exists, obtain multiple inviter intention nodes connected to the customer intention node corresponding to the current inquiry intention, generate a reply script according to the inviter intentions corresponding to the multiple inviter intention nodes, so as to reply to the customer; otherwise, reply to the customer according to the preset general reply script.

[0040] The present invention also provides an electronic device, comprising:

[0041] one or more processors;

[0042] The storage device is used to store one or more programs. When the one or more programs are executed by the one or more processors, the electronic device implements the method for processing conversation data as described in any one of the above.

[0043] The present invention also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor of a computer, the computer executes any one of the above-mentioned methods for processing conversation data.

[0044] As described above, the method, system, device and medium for processing conversation data of the present invention have the following beneficial effects: the present invention innovatively performs intent recognition on multi-round historical call data, constructs intent flow data, and opens up a new data organization method in multi-round conversation business scenarios. The present invention effectively utilizes the historical information of multi-round conversations and improves the accuracy, logic and fluency of the generated answers. BRIEF DESCRIPTION OF THE DRAWINGS

[0045] Figure 1 A flowchart of a method for processing conversation data provided by an embodiment of the present invention;

[0046] Figure 2 Shown is a schematic diagram of an invitation graph database in one embodiment of the present invention;

[0047] Figure 3 Shown is a structural block diagram of a system for processing conversation data provided by an embodiment of the present invention;

[0048] Figure 4 Shown is a structural schematic diagram of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0049] The following describes the embodiments of the present invention by specific examples, and those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the following embodiments and features in the embodiments can be combined with each other without conflict.

[0050] It should be noted that the illustrations provided in the following embodiments are only schematic illustrations of the basic concept of the present invention, and thus the drawings only show components related to the present invention rather than being drawn according to the number, shape and size of components in actual implementation. In actual implementation, the type, quantity and proportion of each component may be changed arbitrarily, and the component layout may also be more complicated.

[0051] In the following description, numerous details are discussed to provide a more thorough explanation of the embodiments of the present invention. However, it is obvious to those skilled in the art that the embodiments of the present invention can be implemented without these specific details. In other embodiments, well-known structures and devices are shown in the form of block diagrams rather than in detail to avoid making the embodiments of the present invention difficult to understand.

[0052] The present invention provides a method, system, device and medium for processing conversation data, which relates to the field of artificial intelligence technology, and can be specifically used to solve the technical problem that the RAG solution in the prior art fails to effectively utilize the historical information of multiple rounds of conversations in human-computer conversations, resulting in the generated answers may have problems such as accuracy, logic and fluency, affecting the quality and efficiency of the replies. The present invention innovatively identifies the intent of multiple rounds of historical call data, constructs intent flow data, and opens up a new data organization method for multiple rounds of conversation business scenarios. On the basis of traditional RAG, the present invention introduces multiple rounds of conversation information to perform large model retrieval enhancement generation to improve the accuracy of retrieval. The following is a detailed description through specific embodiments.

[0053] See also Figure 1 The present invention provides a method for processing conversation data, which may include the following steps:

[0054] Step S100: obtaining the customer's current inquiry voice, and translating the current inquiry voice to generate current inquiry data;

[0055] Step S200: performing intent recognition processing on the current inquiry data to generate the current inquiry intent;

[0056] Step S300, searching a preset invitation graph database for a customer intention node corresponding to the current inquiry intention, wherein the invitation graph database stores a plurality of intention flow data, and the inviter intention, customer intention, and the association between intentions in the intention flow data are represented by the inviter intention node, the customer intention node, and the connection between the nodes, respectively;

[0057] Step S400: if it exists, obtain multiple inviter intention nodes connected to the customer intention node corresponding to the current inquiry intention, and generate a reply script according to the inviter intentions corresponding to the multiple inviter intention nodes to reply to the customer;

[0058] Step S500: Otherwise, reply to the customer according to the preset general reply script.

[0059] In one embodiment of the present invention, when step S100 is executed, the current inquiry voice of the customer is obtained, and the current inquiry voice is translated and processed to generate current inquiry data. Specifically, first, the current inquiry voice of the customer is obtained. Then, the ASR (Automatic Speech Recognition) technology is used to convert the customer's inquiry voice into text data for subsequent further processing.

[0060] In one embodiment of the present invention, when step S200 is executed, the current inquiry data is processed for intent recognition to generate the current inquiry intent. Specifically, a natural language processing (NLP) model or tool is used to extract the specific intent from the customer's current inquiry data and record it as the customer's current inquiry intent.

[0061] In one embodiment of the present invention, when step S300 is executed, a search is performed in the preset invitation graph database to determine whether there is a customer intention node corresponding to the current inquiry intention, wherein the invitation graph database stores a plurality of intention flow data, and the inviter's intention, customer intention, and the relationship between intentions in the intention flow data are represented by the inviter's intention node, customer intention node, and the connection between nodes, respectively. Specifically, a search is performed in the preset invitation graph database to determine whether there is a customer intention node that matches the current customer intention. The invitation graph database stores intention flow data, and the intention flow data characterizes customer intention, inviter's intention, and the relationship between intentions.

[0062] See also Figure 2 In one embodiment of the present invention, the invitation graph database uses the form of triples (i, d, r) to store intention flow data. Among them, node i represents the intention of the inviter, node d represents the customer intention, and relationship r represents the association between intentions. It can be seen that the nodes in the invitation graph database include two labels: "inviter intention" and "customer intention", and the attributes of each node may include historical conversations, primary intentions, secondary intentions, original intentions, call IDs and other data. The attributes of relationship r may include call IDs, weight values, etc. The weight value of relationship r represents the number of times the connection relationship appears in the historical data.

[0063] In one embodiment of the present invention, the invitation graph database is generated by the following steps:

[0064] Step S310: Obtain historical conversation recordings, and perform translation processing on the historical conversation recordings to generate corresponding historical conversation data;

[0065] Step S320: Perform intent recognition processing on the historical conversation data to generate corresponding intent flow data;

[0066] Step S330: import the intention flow data into the initial graph database to form an invitation graph database.

[0067] In one embodiment of the present invention, when step S310 is executed, historical conversation recordings are obtained, and the historical conversation recordings are translated to generate corresponding historical conversation data. Specifically, the historical conversation recordings of inviters with high conversion rates are first obtained. For example, the historical call recordings of inviters with excellent performance are screened out. These inviters must meet the requirement that the total number of calls in a month is greater than or equal to 50 times, and the outbound call conversion rate is greater than or equal to 0.8. In this step, by ensuring that the recording data used comes from inviters who have been proven to be able to efficiently convert potential customers, and focusing on the first outbound call data, a data set that can better reflect successful communication patterns is constructed. Then, the above historical conversation recordings are ASR translated. In this step, the historical conversation recordings are translated into text data, i.e., historical invitation data, through ASR (Automatic Speech Recognition) technology, to facilitate subsequent further processing.

[0068] Furthermore, the historical invitation data after ASR translation still has a certain error rate, especially when faced with dialects, accents or non-standard pronunciations. In addition, some conversations may be unclear due to background noise, the speaker's fast speaking speed or other reasons. In this embodiment, NPL (Natural Language Processing) tools can be further used to identify and eliminate those parts of the translated historical invitation data that are obviously wrong and semantically unclear. For example, rule-based methods or machine learning models can be used to detect and correct common spelling errors, misuse of homophones and other phenomena. This step can be used to ensure the quality of the data used in subsequent intent recognition and graph database construction stages.

[0069] In one embodiment of the present invention, when executing step S320, the historical conversation data is processed for intention recognition to generate corresponding intention flow data. Specifically, the following steps may be included:

[0070] Step S321, identifying and processing the historical conversation data to obtain multiple original intentions of the inviter and multiple original intentions of the client;

[0071] Step S322: According to the preset tags, multiple original intentions of the inviter are merged to obtain multiple secondary intentions of the inviter, and multiple original intentions of the client are merged to obtain multiple secondary intentions of the client;

[0072] Step S323: clustering the multiple secondary intentions of the inviter to obtain multiple primary intentions of the inviter, and clustering the multiple secondary intentions of the customer to obtain multiple primary intentions of the customer;

[0073] Step S324, associate the original intentions of all customers with the original intentions of the corresponding inviters to generate original associated data; associate the secondary intentions of all customers with the secondary intentions of the corresponding inviters to generate secondary associated data; associate the primary intentions of all customers with the primary intentions of the corresponding inviters to generate primary associated data; generate intention flow data based on one of the original associated data, the secondary associated data and the primary associated data.

[0074] In one embodiment of the present invention, when step S321 is executed, the historical conversation data is identified and processed to obtain multiple original intentions of the inviter and multiple original intentions of the customer. Specifically, first, the entire conversation is divided into multiple rounds, each round including an exchange between the customer and the inviter. NPL technology (such as syntactic analysis) can be used to determine the boundaries of each speech, or it can be divided based on information such as timestamps and speaker identities. Then, LLM (Large Language Model) technology is used to identify and process each round of conversation in the translated invitation call data, extract the core intentions of the inviter and the customer, and generate the original intentions of the inviter and the customer. These intentions may be discussion points about product introductions, service recommendations, after-sales Q&A, etc. In this embodiment, a pre-trained intent recognition model or a custom rule library can be applied to mark the intent behind each sentence. For example, it can be implemented by using features such as word vectors, TF-IDF (term frequency-inverse document frequency) combined with machine learning algorithms (such as support vector machines, random forests) or deep learning models (such as BERT, LSTM).

[0075] An example of an invitation dialogue is as follows:

[0076] Inviter: "Hello, are you interested in our company's new products?"

[0077] Client: “Well, I do want to know.”

[0078] Inviter: "That's great! The features of this product are..."

[0079] Client: “That sounds good, but I need to think about it a little more.”

[0080] Inviter: "Okay, if you have any questions, feel free to contact me."

[0081] By identifying and processing the above invitation dialogue examples, we can summarize the core intentions of the inviter and the customer. For example, the original intention of the inviter is to inquire about interests, introduce product features, and confirm intentions; the original intention of the customer is to express interest, request more information, and reserve the right to decide.

[0082] In one embodiment of the present invention, when step S322 is executed, that is, according to the preset labels, multiple original intentions of the inviter are merged to obtain multiple secondary intentions of the inviter, and multiple original intentions of the customer are merged to obtain multiple secondary intentions of the customer. Specifically, continue to use the capabilities of the large model, according to the preset labels, try to merge similar or related original intentions together to form higher-level secondary intentions. The preset labels can be promoting products, customer needs, understanding product details, etc. Doing so can better understand the entire conversation context and lay the foundation for further analysis. The above invitation conversation examples are integrated to obtain preliminary secondary intentions. For example, the secondary intentions of the inviter are: promoting products and following up on customer needs; the secondary intentions of the customer are: understanding product details and keeping an open attitude.

[0083] Furthermore, some secondary intents can be merged, corrected and adjusted manually. Although the large model has greatly improved the automation of intent recognition, in some cases manual intervention is still needed to improve the results. For example, when two seemingly different secondary intents actually point to the same core topic, they need to be merged manually; or if a secondary intent is found to be not described accurately enough, it needs to be modified, etc. In this way, it can be ensured that the final intent list is both comprehensive and accurate.

[0084] In one embodiment of the present invention, when step S323 is executed, the multiple secondary intentions of the inviter are clustered to obtain multiple primary intentions of the inviter, and the multiple secondary intentions of the customer are clustered to obtain multiple primary intentions of the customer. Specifically, continue to use the large model to cluster the secondary intentions into primary intentions. Regroup all sorted secondary intentions according to the subject areas to which they belong to form a more macroscopic primary intention framework. It is possible to grasp the overall structure and development trend of the entire conversation at a high level, which is very beneficial for the subsequent formulation of highly targeted service strategies. The above invitation conversation example is clustered to obtain the primary intention. For example, the first-level intention of the inviter is: sales promotion; the first-level intention of the customer is: demand exploration.

[0085] In one embodiment of the present invention, when step S324 is executed, the original intentions of all customers are associated with the original intentions of the corresponding inviters to generate original associated data; the secondary intentions of all customers are associated with the secondary intentions of the corresponding inviters to generate secondary associated data; the primary intentions of all customers are associated with the primary intentions of the corresponding inviters to generate primary associated data; the intention flow data is generated according to the original associated data, the secondary associated data and one of the primary associated data. Specifically, a structured intention flow record is constructed, and the original intentions, secondary intentions and final primary intentions of the customers and inviters in each round of dialogue are associated respectively to generate original associated data, secondary associated data and primary associated data. Then, one of the above original associated data, secondary associated data and primary associated data is stored in a certain format, such as a JSON file, a CSV file or a database table, so as to generate intention flow data. The intention flow data should also contain other relevant information, such as the conversation time, the ID of the participants, etc., to facilitate subsequent analysis.

[0086] In one embodiment of the present invention, when step S330 is executed, the intent flow data is imported into the initial graph database to form an invitation graph database. Specifically, the initial graph database adopts the Neo4j graph database. The Neo4j graph database allows the storage, query and operation of highly connected data. Unlike traditional relational databases, Neo4j is specially optimized for graph data models, which makes the processing of complex and interrelated data more efficient. In the initial database, the intent flow data is organized in the form of triples (i, r, d), where the i and d nodes represent the "inviter's intention" and "driver's intention" respectively, and r is the connection relationship between the intentions. In this embodiment, py2neo is used to create and update nodes and relationships to construct a graph database. Step S330 may include the following steps:

[0087] Step S331: Create or update the inviter intention node in the initial database according to the inviter's secondary intention in the intention flow data;

[0088] Step S332: Create or update a customer intention node in the initial database according to the customer's secondary intention in the intention flow data;

[0089] Step S333: Create or update the connection relationship between the customer's intention node and the inviter's intention node according to the association relationship between the customer's secondary intention and the inviter's secondary intention in the intention flow data to form the invitation graph database.

[0090] In one embodiment of the present invention, when executing step S331, that is, according to the secondary intention of the inviter in the intention flow data, the inviter intention node is created or updated in the initial database. Specifically, the following steps may be included:

[0091] Step S3311, determining whether there is an inviter intention node corresponding to the inviter's secondary intention in the intention flow data in the initial graph database;

[0092] Step S3312: If it exists, update the attributes of the corresponding inviter intention node according to the original intention and the first-level intention of the inviter in the intention flow data;

[0093] Step S3313: Otherwise, create a new inviter intention node according to the inviter's secondary intention in the intention flow data, and set the attributes of the corresponding inviter intention node according to the inviter's original intention and primary intention.

[0094] In one embodiment of the present invention, when executing steps S3311 to S3313, specifically, in this embodiment, first, query whether there is already an inviter intention node with the same secondary intent in the initial graph database. If there is an inviter intention node with the same secondary intent, update the attributes of the node according to the original intent and primary intent of the inviter. If there is no inviter intention node with the same secondary intent, first create a new inviter intention node according to the secondary intent of the inviter in the intention flow data; then set the attributes of this new inviter intention node according to the original intent and primary intent of the inviter. Furthermore, the inviter's ID and words can also be added to the attributes of the inviter intention node.

[0095] In one embodiment of the present invention, when executing step S332, that is, according to the secondary intention of the customer in the intention flow data, a customer intention node is created or updated in the initial database. Specifically, the following steps may be included:

[0096] Step S3321, determining whether there is a customer intent node corresponding to the secondary intent of the customer in the intent flow data in the initial graph database;

[0097] Step S3322: If it exists, update the attributes of the corresponding customer intention node according to the original intention and primary intention of the customer in the intention flow data;

[0098] Step S3323: Otherwise, create a new customer intent node according to the customer's secondary intent in the intent flow data, and set the attributes of the corresponding customer intent node according to the customer's original intent and primary intent.

[0099] In one embodiment of the present invention, when executing steps S3321 to S3323, specifically, first, query whether a customer intent node with the same secondary intent already exists in the initial graph database. If a customer intent node with the same secondary intent exists, update the attributes of the node according to the customer's original intent and primary intent. If a customer intent node with the same secondary intent does not exist, first create a new customer intent node based on the customer's secondary intent in the intent flow data; then set the attributes of the new customer intent node based on the customer's original intent and primary intent. Furthermore, the customer's ID and speech can also be added to the attributes of the customer intent node.

[0100] In one embodiment of the present invention, when executing step S333, that is, according to the association relationship between the secondary intention of the customer and the secondary intention of the inviter in the intention flow data, the connection relationship between the customer intention node and the inviter intention node is created or updated to form an invitation graph database. Specifically, the following steps may be included:

[0101] Step S3331: According to the association relationship between the secondary intention of the customer and the secondary intention of the inviter in each intention flow data, determine whether there is a connection relationship between the corresponding customer intention node and the corresponding inviter intention node in the initial graph database;

[0102] Step S3332: if it exists, update the attribute of the connection relationship between the customer intention node and the inviter intention node;

[0103] Step S3333: Otherwise, establish a connection relationship between the customer intention node and the inviter intention node, and set the attributes of the connection relationship.

[0104] In one embodiment of the present invention, when executing steps S3331 to S3333, specifically, first, query whether there is already a connection relationship between the node corresponding to the secondary intent of the customer and the node corresponding to the secondary intent of the inviter in the graph database, that is, whether there is a connection line between the two nodes. If so, update the attributes of the relationship, for example, increase the weight value of the connection relationship by 1. If not, first create a new connection relationship, and then set the attributes of the connection relationship, for example, set the weight value of the connection relationship to 1. In this embodiment, setting the attributes of the connection relationship may also include adding the ID of the inviter and the ID of the customer who invited the call. Complete the import of all intent flow data into the intent flow data, thereby forming the required invitation graph database.

[0105] In one embodiment of the present invention, when step S400 is executed, if any, multiple inviter intent nodes associated with the customer intent node corresponding to the current inquiry intent are obtained, and a reply script is generated according to the inviter intent corresponding to the multiple inviter intent nodes to reply to the customer. Specifically, the following steps may be included:

[0106] Step S410, obtaining multiple inviter intention nodes connected to the customer intention node corresponding to the current inquiry intention, and extracting the inviter intentions corresponding to the multiple inviter intention nodes;

[0107] Step S420: selecting an inviter intention from multiple inviter intentions as a candidate intention according to a preset rule;

[0108] Step S430: Obtain the customer's historical response data, and generate a response script based on the historical response data and candidate intents to respond to the customer.

[0109] In one embodiment of the present invention, when step S410 is executed, multiple inviter intention nodes connected to the customer intention node corresponding to the current inquiry intention are obtained, and the inviter intentions corresponding to the multiple inviter intention nodes are extracted. Specifically, first locate the customer intention node corresponding to the current inquiry intention in the invitation graph database. Then, find all inviter intention nodes directly connected to the customer intention node. Next, extract their "inviter intentions" from these inviter intention nodes, that is, the intentions or purposes they expressed in past conversations.

[0110] In one embodiment of the present invention, when step S420 is executed, an inviter intention is selected from multiple inviter intentions as a candidate intention according to preset rules. Specifically, one of the many inviter intentions that best suits the current situation is selected as the basis for the reply. In this embodiment, the preset rules may be selection criteria set based on multiple factors. For example, based on the weight value of the node relationship, that is, the frequency of intent flow, the most frequently occurring inviter intention in history is selected. For another example, based on the success rate of the dialogue results, the inviter intention that previously led to a successful transaction or satisfactory feedback is selected. Furthermore, the most recent successful intention may be selected based on time relevance. In addition, this may be based on criteria determined by other business logic or algorithms. The selected inviter intention is used as a candidate intention. The candidate intention will serve as a reference point or template for constructing the reply script in the next step.

[0111] In one embodiment of the present invention, when step S430 is executed, the customer's historical response data is obtained, and a response script is generated based on the historical response data and candidate intents to respond to the customer. Specifically, first collect and analyze the customer's historical response data for this round of conversation to understand their preferences, habits and possible needs. Then, combined with the candidate intents selected in the previous step, consider the main purpose of this response or the expected effect. Utilize natural language processing (NLP) technology, large language model technology (LLM) or other text generation methods, combined with historical response data and candidate intents, to develop a response script that is both in line with company strategy and can meet or guide customer needs. Finally, the generated script is used to actually reply to customers in order to achieve the best communication effect.

[0112] In one embodiment of the present invention, when step S500 is executed, that is, otherwise, the customer is replied to according to the preset general reply words. Specifically, if no customer intent node matching the current inquiry intent is found in the entire invitation graph database, it means that this is a completely new situation or a relatively rare situation. At this time, a set of pre-prepared general reply words can be used to respond. These general words are usually carefully designed to cover as many different scenarios as possible while maintaining a friendly and professional tone. Even in the absence of an exact match, this type of words can effectively guide the conversation to continue until enough information is obtained to provide more specific help.

[0113] As can be seen from the above, the present invention uses a large model to summarize the intentions based on the historical call data of the inviter and the driver, and establishes the intention flow data of the inviter and the driver in the invitation scenario. The Neo4j graph database is used to organize the intention flow data and store information such as intention categories, words, and weights. When the invitation is actually made, the LLM and the driver's multi-round conversation intentions are combined for retrieval, and the candidate intentions are obtained by combining information such as weights. Finally, the large model is used to interact with the candidate intentions and their words, weights, and historical call data.

[0114] See also Figure 2 The present invention also provides a system for processing dialogue data, which corresponds to the processing method in the above embodiment. The processing system may include a speech translation module 11, an intention recognition module 12, and a search and reply module 13. The functional modules are described in detail as follows:

[0115] The voice translation module 11 can be used to obtain the current inquiry voice of the customer, and translate the current inquiry voice to generate current inquiry data. Further, the voice translation module 11 can be specifically used to first obtain the current inquiry voice of the customer. Then, using ASR technology, the customer's voice reply is converted into text data for subsequent further processing.

[0116] The intention recognition module 12 can be used to perform intention recognition processing on the current inquiry data to generate the current inquiry intention. Further, the intention recognition module 12 can be specifically used to use a natural language processing (NLP) model or tool to extract a specific intention from the customer's current inquiry data and record it as the current customer intention.

[0117] The retrieval reply module 13 can be used to retrieve whether there is a customer intention node corresponding to the current inquiry intention in the preset invitation graph database, wherein the invitation graph database stores multiple intention flow data, and the inviter intention, customer intention and the relationship between intentions in the intention flow data are represented by the inviter intention node, customer intention node and the connection between nodes respectively; if there is, obtain multiple inviter intention nodes connected to the customer intention node corresponding to the current inquiry intention, and generate reply words according to the inviter intentions corresponding to the multiple inviter intention nodes to reply to the customer; otherwise, reply to the customer according to the preset general reply words. Further, the retrieval reply module 13 can be specifically used to obtain multiple inviter intention nodes connected to the customer intention node corresponding to the current inquiry intention, and extract the inviter intentions corresponding to the multiple inviter intention nodes; select an inviter intention from multiple inviter intentions as a candidate intention according to preset rules; obtain the customer's historical reply data, and generate reply words according to the historical reply data and the candidate intentions to reply to the customer.

[0118] The specific definition of the processing system of the conversation data can be found in the definition of the processing method above, which will not be repeated here. Each module in the above training system can be implemented in whole or in part by software, hardware and a combination thereof. Each of the above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to each of the above modules.

[0119] An embodiment of the present invention also provides an electronic device, comprising: one or more processors; a storage device for storing one or more programs, when the one or more programs are executed by one or more processors, the electronic device implements the method for processing conversation data provided in the above-mentioned embodiments.

[0120] See also Figure 3The electronic device 2 may include a memory 22, a processor 23 and a bus, and may also include a computer program stored in the memory 22 and executable on the processor 23, such as a program for processing conversation data.

[0121] The memory 22 includes at least one type of readable storage medium, and the readable storage medium includes a flash memory, a mobile hard disk, a multimedia card, a card-type memory (e.g., SD or DX memory, etc.), a magnetic memory, a disk, an optical disk, etc. In some embodiments, the memory 22 may be an internal storage unit of the electronic device 2, such as a mobile hard disk of the electronic device 2. In other embodiments, the memory 22 may also be an external storage device of the electronic device 2, such as a plug-in mobile hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc. equipped on the electronic device 2. Further, the memory 22 may also include both an internal storage unit of the electronic device 2 and an external storage device. The memory 22 may not only be used to store application software and various types of data installed in the electronic device 2, such as codes for processing conversation data, etc., but may also be used to temporarily store data that has been output or is to be output.

[0122] In some embodiments, the processor 23 may be composed of an integrated circuit, for example, a single packaged integrated circuit, or a plurality of packaged integrated circuits with the same or different functions, including one or more central processing units (CPUs), microprocessors, digital processing chips, graphics processors, and combinations of various control chips. The processor 23 is the control core (Control Unit) of the electronic device 2, and uses various interfaces and lines to connect various components of the entire electronic device 2, and executes or executes programs or modules (such as fatigue prediction model training programs, etc.) stored in the memory 22, and calls data stored in the memory 22 to execute various functions of the electronic device 2 and process data.

[0123] The processor 23 executes the operating system and various installed applications of the electronic device 2. The processor 23 executes the applications to implement the steps in the above-mentioned method for processing conversation data.

[0124] Exemplarily, the computer program may be divided into one or more modules, which are stored in the memory 22 and executed by the processor 23 to complete the present application. The one or more modules may be a series of computer program instruction segments capable of completing specific functions, which are used to describe the execution process of the computer program in the electronic device 2. For example, the computer program may be divided into a speech translation module 11, an intention recognition module 12, and a retrieval reply module 13.

[0125] The above-mentioned integrated unit implemented in the form of a software function module can be stored in a computer-readable storage medium, and the computer-readable storage medium can be non-volatile or volatile. The above-mentioned software function module is stored in a storage medium, including several instructions for enabling a computer device (which can be a personal computer, a computer device, or a network device, etc.) or a processor to perform part of the functions of the method for processing conversation data described in various embodiments of the present application.

[0126] In summary, the present invention discloses a method, system, device and medium for processing dialogue data, which relate to the field of artificial intelligence technology. The present invention obtains the inviter intention node and the driver intention node by performing intent recognition on historical multi-round call data, and uses a graph database to organize the intent flow data, stores historical speech, primary intent, secondary intent and other information, can utilize rich historical data, and has strong scalability, and can automatically expand the data in the graph database through LLM. In addition, in the dialogue interaction application of the present invention, intent recognition is first performed through LLM, and then the corresponding candidate intentions and speech are retrieved from the graph database through multi-round intent data, introducing historical excellent experience, and can be further screened through information such as weights, thereby improving the accuracy of retrieval enhancement generation. Therefore, the present invention effectively overcomes the various shortcomings in the prior art and has a high industrial utilization value.

[0127] The above embodiments are merely illustrative of the principles and effects of the present invention, and are not intended to limit the present invention. Anyone familiar with the art may modify or alter the above embodiments without departing from the spirit and scope of the present invention. Therefore, all equivalent modifications or alterations made by a person of ordinary skill in the art without departing from the spirit and technical concept disclosed by the present invention shall still be covered by the claims of the present invention.

Claims

1. A method for processing conversation data, characterized in that: include: Acquire the customer's current inquiry voice, and translate the current inquiry voice to generate current inquiry data; Performing intent recognition processing on the current inquiry data to generate a current inquiry intent; Searching in a preset invitation graph database whether there is a customer intention node corresponding to the current inquiry intention, wherein the invitation graph database stores a plurality of intention flow data, and the inviter intention, customer intention and the association relationship between intentions in the intention flow data are respectively represented by the inviter intention node, the customer intention node and the connection between the nodes; If so, obtain multiple inviter intention nodes connected to the customer intention node corresponding to the current inquiry intention, and generate a reply script according to the inviter intentions corresponding to the multiple inviter intention nodes to reply to the customer; Otherwise, respond to the customer according to the preset general response script.

2. The method for processing conversation data according to claim 1, characterized in that: The step of generating a reply script based on the multiple inviter intentions to reply to the customer includes: Acquire multiple inviter intention nodes connected to the customer intention node corresponding to the current inquiry intention, and extract the inviter intentions corresponding to the multiple inviter intention nodes; Selecting an inviter intent as a candidate intent from multiple inviter intents according to a preset rule; The customer's historical response data is obtained, and a response script is generated based on the historical response data and the candidate intent to respond to the customer.

3. The method for processing conversation data according to claim 1, characterized in that: The invitation graph database is generated by the following steps: Obtaining historical conversation recordings, and translating the historical conversation recordings to generate corresponding historical conversation data; Performing intent recognition processing on the historical conversation data to generate corresponding intent flow data; The intention flow data is imported into the initial graph database to form the invitation graph database.

4. The method for processing conversation data according to claim 3, characterized in that: The step of performing intent recognition processing on the historical conversation data to generate corresponding intent flow data includes: Performing identification processing on the historical conversation data to obtain multiple original intentions of the inviter and multiple original intentions of the client; According to the preset tags, multiple original intentions of the inviter are merged to obtain multiple secondary intentions of the inviter, and multiple original intentions of the customer are merged to obtain multiple secondary intentions of the customer; Clustering multiple secondary intentions of the inviter to obtain multiple primary intentions of the inviter, and clustering multiple secondary intentions of the customer to obtain multiple primary intentions of the customer; Associate the original intentions of all customers with the original intentions of the corresponding inviters to generate original associated data; associate the secondary intentions of all customers with the secondary intentions of the corresponding inviters to generate secondary associated data; associate the primary intentions of all customers with the primary intentions of the corresponding inviters to generate primary associated data; generate intention flow data based on the original associated data, the secondary associated data and one of the primary associated data.

5. The method for processing conversation data according to claim 4, characterized in that: The step of importing the intention flow data into the initial graph database to form the invitation graph database includes: Creating or updating an inviter intention node in an initial database according to the inviter's secondary intention in the intention flow data; Creating or updating a customer intention node in an initial database according to the customer's secondary intention in the intention flow data; According to the association relationship between the secondary intention of the customer and the secondary intention of the inviter in the intention flow data, the connection relationship between the customer intention node and the inviter intention node is created or updated to form the invitation graph database.

6. The method for processing conversation data according to claim 5, characterized in that: The step of creating or updating the inviter intention node in the initial database according to the inviter's secondary intention in the intention flow data includes: Determine whether there is an inviter intent node corresponding to the inviter's secondary intent in the intent flow data in the initial graph database: If it exists, update the attributes of the corresponding inviter intention node according to the original intention and the first-level intention of the inviter in the intention flow data; Otherwise, a new inviter intention node is created according to the secondary intention of the inviter in the intention flow data, and the attributes of the corresponding inviter intention node are set according to the original intention and the primary intention of the inviter.

7. The method for processing conversation data according to claim 5, characterized in that: The step of creating or updating the connection relationship between the customer intention node and the inviter intention node according to the association relationship between the customer's secondary intention and the inviter's secondary intention in the intention flow data comprises: According to the association relationship between the secondary intention of the customer and the secondary intention of the inviter in each of the intention flow data, it is determined whether there is a connection relationship between the corresponding customer intention node and the corresponding inviter intention node in the initial graph database; If so, update the attribute of the connection relationship between the customer intention node and the inviter intention node; Otherwise, a connection relationship between the customer intention node and the inviter intention node is established, and the attributes of the connection relationship are set.

8. A system for processing conversation data, characterized in that: include: The voice translation module is used to obtain the customer's current inquiry voice, and translate the current inquiry voice to generate current inquiry data; An intention recognition module, used to perform intention recognition processing on the current inquiry data to generate a current inquiry intention; A retrieval reply module is used to search in a preset invitation graph database whether there is a customer intention node corresponding to the current inquiry intention, wherein the invitation graph database stores multiple intention flow data, and the inviter intention, customer intention and the relationship between intentions in the intention flow data are respectively represented by the inviter intention node, the customer intention node and the connection between the nodes; if it exists, obtain multiple inviter intention nodes connected to the customer intention node corresponding to the current inquiry intention, generate a reply script according to the inviter intentions corresponding to the multiple inviter intention nodes, so as to reply to the customer; otherwise, reply to the customer according to the preset general reply script.

9. An electronic device, characterized in that: include: one or more processors; A storage device for storing one or more programs, which, when executed by the one or more processors, enables the electronic device to implement the method for processing conversation data as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that: A computer program is stored thereon, and when the computer program is executed by a processor of a computer, the computer is caused to execute the method for processing conversation data according to any one of claims 1 to 7.

Citation Information

Cited By

  • Distributed intelligent customer service database updating method

    CN120804125A