Knowledge following type session method and electronic equipment
Through the combination of the recall model and the fine-scheduling model, the problem of low matching between chat content and knowledge points is solved, more accurate knowledge recommendation is achieved, and the service quality of customer service is improved.
Patent Information
- Application Number
- CN202310632207.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-05-30
- Publication Date
- 2024-12-10
AI Technical Summary
In the customer service scenarios, the word matching between chat content and knowledge points is not high, resulting in the recommended knowledge points being inaccurate enough, and it is impossible to effectively assist the agent in quickly locate customer problems and provide solutions.
The recall model is used to recall the candidate reply content, and the priority reply content is filtered in combination with the fine-scheduling model, and the knowledge base is traversed through the card name of the candidate reply content, and the target knowledge card matching the chat content is found, and the target knowledge card is presented to the agent.
It improves the accuracy and reliability of knowledge points, helps the agent better understand customer problems and provides effective reference knowledge, and improves the quality of customer service.
Smart Images

Figure CN119106107A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of natural language processing, and in particular to a knowledge-following conversation method and electronic device. Background Art
[0002] In customer service scenarios, speech association technology can help agents intelligently recommend more appropriate and professional responses to customers based on the real-time chat content and what they are typing. In order to help agents quickly locate customer problems and provide answers that may be needed to solve the problems, related technologies can recommend knowledge points that agents need to refer to based on the chat content.
[0003] The related technology is to use traditional bag-of-words models such as the TFI-DF (term frequency–inverse document frequency) model to process chat content in order to present corresponding knowledge points to the agents. However, the word matching degree between chat content and knowledge points is not high, and the knowledge points matched by the TFI-DF bag-of-words model are not accurate enough. Summary of the invention
[0004] One purpose of the embodiments of the present disclosure is to provide a knowledge-following conversation method and electronic device, aiming to solve the technical problem that the accuracy of knowledge points provided by related technologies is not high.
[0005] In a first aspect, an embodiment of the present disclosure provides a knowledge-following conversation method, including:
[0006] Acquire multiple candidate reply contents recalled by a preset recall model, wherein each candidate reply content includes a card name;
[0007] Determine the score of each candidate response content according to a preset refined ranking model;
[0008] According to the scores of the candidate reply contents, determine the candidate reply contents that meet the score screening conditions among the candidate reply contents as priority reply contents;
[0009] Determine in a preset knowledge base the knowledge card corresponding to the card name of the priority reply content as the target knowledge card;
[0010] Present the target knowledge card.
[0011] Optionally, determining, according to the scores of the candidate reply contents, the candidate reply contents satisfying the score screening condition as the priority reply contents among the candidate reply contents includes:
[0012] Determine whether the score of the candidate reply content is greater than a preset score threshold;
[0013] If it is greater than, it is determined that the candidate reply content meets the score screening condition, and the candidate reply content is used as the priority reply content;
[0014] If it is less than, it is determined that the candidate reply content does not meet the score screening condition.
[0015] Optionally, the obtaining of multiple candidate reply contents recalled by a preset recall model includes:
[0016] Get historical conversation content;
[0017] The historical conversation content is input into a recall model, so that the recall model recalls a plurality of candidate reply contents in a preset inverted index library according to the historical conversation content.
[0018] Optionally, obtaining historical conversation content includes:
[0019] Obtaining a session log, wherein the session log includes the most recent session content of a specified round;
[0020] If the most recent conversation content of the specified round includes a multimedia file, determining multimedia content corresponding to the multimedia file;
[0021] Replacing the multimedia file with the multimedia content to obtain historical session content;
[0022] If the latest conversation content of the specified round does not include a multimedia file, the latest conversation content of the specified round is determined to be a historical conversation content.
[0023] Optionally, determining the multimedia content corresponding to the multimedia file includes:
[0024] determining at least one reference tag corresponding to the multimedia file;
[0025] Multimedia content is determined based on at least one of the reference tags.
[0026] Optionally, determining multimedia content according to at least one of the reference tags includes:
[0027] Determine a score for each of the reference labels according to a preset multi-label classification model;
[0028] Select a specified number of reference labels with the highest scores as target labels;
[0029] The multimedia content is determined according to the tag content of each of the target tags.
[0030] Optionally, the method further comprises:
[0031] Get historical chat logs;
[0032] Detecting whether the historical chat log contains a document in a target file format;
[0033] If included, a knowledge tag is matched for the document, and a knowledge card is generated according to the document and the knowledge tag matching the document. The knowledge card is stored in the knowledge base, and the knowledge tag includes a card name.
[0034] Optionally, matching the document with a knowledge tag includes:
[0035] Taking the document as the center, intercepting partial content of a specified text length in the historical chat log;
[0036] The knowledge tag of the document is determined according to the local content and the card name.
[0037] Optionally, determining the knowledge tag of the document according to the local content and the card name includes:
[0038] Determining whether the local content includes a word that appears in a preset dictionary;
[0039] If included, a knowledge tag is generated according to the word and the card name;
[0040] If not included, a knowledge tag is generated according to the card name.
[0041] In a second aspect, an embodiment of the present disclosure provides a non-volatile readable storage medium storing computer executable instructions, wherein the computer executable instructions are used to enable an electronic device to execute the above-mentioned knowledge-following conversation method.
[0042] In a third aspect, an embodiment of the present disclosure provides an electronic device, including:
[0043] at least one processor; and,
[0044] a memory communicatively connected to the at least one processor; wherein,
[0045] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the above-mentioned knowledge-following conversation method.
[0046] In the knowledge-following conversation method provided in the embodiment of the present disclosure, multiple candidate reply contents recalled by the recall model are obtained, wherein each candidate reply content includes a card name, and the score of each candidate reply content is determined according to the preset precision ranking model. According to the score of each candidate reply content, the candidate reply content that meets the score screening condition is determined as the priority reply content in each candidate reply content, and the knowledge card corresponding to the card name of the priority reply content is determined in the preset knowledge base as the target knowledge card, and the target knowledge card is presented. With the help of the good recall ability of the recall model, this embodiment can obtain candidate reply contents that are relatively matched with the chat content, and then with the help of the good sorting ability of the precision ranking model, it can better screen out more accurate and reliable candidate reply contents, and traverse the knowledge base according to the card names contained in the candidate reply contents, so as to find the target knowledge card that is more accurate with the chat content for presentation, thereby achieving the purpose of knowledge following, effectively providing reference knowledge points for agents, and helping agents to better serve customers. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] One or more embodiments are exemplarily described by pictures in the corresponding drawings, and these exemplified descriptions do not constitute limitations on the embodiments. Elements with the same reference numerals in the drawings represent similar elements, and unless otherwise stated, the figures in the drawings do not constitute proportional limitations.
[0048] Figure 1 A flowchart of a knowledge-following conversation method provided in an embodiment of the present disclosure;
[0049] Figure 2 A schematic diagram of a first conversation scenario provided in an embodiment of the present disclosure;
[0050] Figure 3 A sample diagram of a knowledge card provided in an embodiment of the present disclosure;
[0051] Figure 4 A schematic diagram of a second conversation scenario provided in an embodiment of the present disclosure;
[0052] Figure 5 A schematic diagram of the structure of a knowledge-following conversation device provided in an embodiment of the present disclosure;
[0053] Figure 6 A schematic diagram of a circuit structure of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0054] In order to make the purpose, technical solutions and advantages of the present disclosure more clearly understood, the present disclosure is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present disclosure and are not intended to limit the present disclosure. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of the present disclosure.
[0055] It should be noted that, if there is no conflict, the various features in the embodiments of the present disclosure can be combined with each other, all within the scope of protection of the present disclosure. In addition, although the functional modules are divided in the device schematic diagram and the logical order is shown in the flow chart, in some cases, the steps shown or described can be performed in a different order than the module division in the device or the flow chart. Furthermore, the words "first", "second", "third", etc. used in the present disclosure do not limit the data and execution order, but only distinguish the same items or similar items with basically the same functions and effects.
[0056] Related technologies usually use traditional bag-of-words models such as the TFI-DF bag-of-words model to process chat content. Since the TFI-DF bag-of-words model mainly processes chat content based on the characteristics of word frequency, but the names of some knowledge points do not appear frequently, and the word matching degree between the chat content and the knowledge points is not high, the use of traditional bag-of-words models such as the TFI-DF bag-of-words model is not suitable for unsupervised matching of chat content and knowledge points. During the matching process between chat content and knowledge points, the chat content and knowledge points lack alignment data, and supervised learning cannot be effectively performed. In addition, in the process of realizing the present disclosure, the inventor found that: it is easy for an agent to serve multiple customers at the same time, and the knowledge points provided by the related technology are relatively complex and vague, and the focus is not enough, so the agent cannot quickly and clearly grasp or understand the knowledge points. This embodiment, with the help of the good recall ability of the recall model, can obtain candidate reply content that is relatively matched with the chat content. Then, with the help of the good sorting ability of the refined ranking model, it can better screen out more accurate and reliable candidate reply content, and traverse the knowledge base according to the card names contained in the candidate reply content, so as to find the target knowledge card that is more accurate with the chat content for presentation, thereby achieving the purpose of knowledge following, effectively providing reference knowledge points for agents, and helping agents to better serve customers.
[0057] The present disclosure provides a knowledge-following conversation method. Figure 1 ,The knowledge following conversation method includes the following steps:
[0058] S11: Obtain multiple candidate reply contents recalled by a preset recall model, wherein each candidate reply content includes a card name.
[0059] In this step, the preset recall model is a model constructed in advance by the designer according to the recall algorithm, wherein the recall algorithm includes a single-tower recall algorithm or a dual-tower recall algorithm.
[0060] The candidate reply content is the reply content recalled by the preset recall model. In some embodiments, the preset recall model recalls multiple candidate reply contents based on the historical conversation content, for example, the preset recall model recalls 30 candidate reply contents. In some embodiments, the preset recall model splices the historical conversation content with the target reply content input by the agent to obtain the spliced content, and recalls multiple candidate reply contents based on the spliced content. The target reply content is the content input by the agent. For example, customer A first initiates a conversation, where the conversation is as follows:
[0061] Customer A: Found that students cannot log in.
[0062] Seat B: Are you talking about seewo Cloud Class?
[0063] In the above conversation, the target's reply was "Are you talking about seewo Cloud Class?"
[0064] It is understandable that the target reply content may be a complete reply content, and the complete reply content is the complete content of the agent's reply to the customer's question. For example, in the above conversation, "Are you talking about seewo Cloud Class?" is the complete reply content.
[0065] It is also understandable that the target reply content may also be an incomplete reply content. The incomplete reply content is the existing content that the agent is currently typing but has not yet finished typing when answering a customer's question. For example, in the above conversation, "You mean Xi" is an incomplete reply content.
[0066] In some embodiments, obtaining multiple candidate reply contents recalled by a preset recall model includes the following steps: obtaining historical conversation contents, inputting the historical conversation contents into the recall model, so that the recall model recalls multiple candidate reply contents in a preset inverted index library according to the historical conversation contents.
[0067] The historical conversation content is the most recent conversation content between the agent and the customer in specified rounds. The specified rounds can be customized by the designer according to the business, such as specifying 6 rounds or 8 rounds.
[0068] The inverted index library is a database constructed in advance by the designer, wherein this embodiment constructs an inverted index library based on the open source tool ElasticSearch. Specifically, this embodiment cuts a conversation log of a complete conversation into multiple historical chat contents and historical reply contents, wherein the maximum length of the historical chat content is the content of the most recent 6 rounds of conversations, and the historical reply content is the real reply of the agent. Next, this embodiment processes the historical reply content, filters out the fragments containing the document, and removes the fragments that do not contain the document, so as to obtain the cleaned historical reply content. Finally, this embodiment uses the open source tool ElasticSearch to construct an inverted index library for the historical chat content and the cleaned historical reply content respectively.
[0069] In some embodiments, obtaining historical conversation content includes the following steps: obtaining a conversation log, the conversation log including the most recent conversation content of a specified round; if the most recent conversation content of the specified round includes a multimedia file, determining the multimedia content corresponding to the multimedia file, replacing the multimedia file with the multimedia content, and obtaining the historical conversation content; if the most recent conversation content of the specified round does not include a multimedia file, determining the most recent conversation content of the specified round as the historical conversation content.
[0070] Multimedia files include voice files, video files, image files, etc. Multimedia content is used to represent the content of multimedia files, and the latest conversation content of a specified round is the conversation of the specified round most recent to the current time. Each reply or question is a round of reply or question.
[0071] For example, see Figure 2 , the conversation scenario provided in this embodiment is as follows:
[0072] Agent A: What’s the problem?
[0073] Customer B: Unable to identify
[0074] Customer B: "Provide Figure 2 The barcode image shown"
[0075] Customer B: I changed the cable but it’s still the same.
[0076] Seat A: OK
[0077] Agent A: Could you please provide the contact name, phone number and detailed contact address so that we can help you with the warranty processing?
[0078] In the above conversation scenario, this embodiment determines that the multimedia content of the picture provided by the third round of conversation is [content XXXX]. Then, the historical conversation content is: What is the fault? [Content XXXX] cannot be recognized. The line is still the same. OK, please provide the name, phone number and detailed contact address of the contact person, and we will help you report the problem.
[0079] For example, the conversation scenario provided in this embodiment is as follows:
[0080] Agent A: What’s the problem?
[0081] Customer B: Unable to identify
[0082] Customer B: I don’t know what’s going on.
[0083] Customer B: I changed the cable but it’s still the same.
[0084] Seat A: OK
[0085] Agent A: Could you please provide the contact name, phone number and detailed contact address so that we can help you with the warranty processing?
[0086] In the above conversation scenario, the historical conversation content is: What is the fault? I can't identify it. I don't know what happened. I changed the line but it's still the same. OK, please provide the contact person's name, phone number and detailed contact address, and we will help you report the problem.
[0087] Determining multimedia content corresponding to a multimedia file includes the following steps: determining at least one reference tag corresponding to the multimedia file, and determining the multimedia content according to a score of the at least one reference tag. The reference tag is a tag corresponding to the multimedia file.
[0088] Determining at least one reference tag corresponding to the multimedia file includes: determining at least one reference tag corresponding to the multimedia file according to a preset multi-tag classification model.
[0089] It is understandable that the preset multi-label classification model can be a deep learning model, wherein the deep learning model can be any form of neural network model. For example, during the training process, this embodiment constructs a CNN neural network model, and the loss function adopts the BCE loss function. 2000 training samples and image labels are selected to train the multi-label classification model, wherein the labels include black screen, blue screen, no signal, unable to download, etc. In some embodiments, this embodiment can also match synonymous labels to the labels of the images, which is conducive to improving the accuracy of recall and fine sorting, such as the synonymous label of the label "unable to download" is "cannot download".
[0090] During the training process, this embodiment obtains the text that is a preset number of rounds away from the round where the picture is located, and detects whether the specified word appears in the text. If the specified word appears, the specified word is used as the label of the picture. If not, the designer customizes the label of the picture. The preset number of rounds is 2 rounds. This embodiment can select the previous text that is 2 rounds away from the round where the picture is located and the following text that is 2 rounds away from the round where the picture is located to combine into text. This embodiment adopts this training method to meet the requirement of filtering and obtaining effective training data even when the training data is noisy.
[0091] In some embodiments, according to a preset multi-label classification model, determining at least one reference tag corresponding to a multimedia file includes: determining whether the multimedia file is a voice file; if it is a voice file, converting the multimedia file into text content according to a voice recognition algorithm, and the text content is multimedia content; if it is not a voice file, determining whether the multimedia file is a video file; if it is a video file, extracting key frame images from the video file according to a key frame extraction algorithm, taking the key frame images as target images, and determining at least one reference tag corresponding to the target image according to the preset multi-label classification model; if it is not a video file, that is, the multimedia file is the target image, determining at least one reference tag corresponding to the target image according to the preset multi-label classification model.
[0092] Determining multimedia content based on at least one reference tag includes the following steps: determining a score for each reference tag based on a preset multi-tag classification model, selecting a specified number of reference tags with the highest scores as target tags, and determining multimedia content based on the tag content of each target tag.
[0093] For example, please combine Figure 2 , the multimedia file is input into the multi-label classification type, and the multi-label classification type gives the scores of multiple reference labels that match the multimedia file. Next, this embodiment selects the five reference labels with the highest scores from the multiple reference labels as the target labels. For example, the arrangement order of the five reference labels with the highest scores is "serial number" label 1, "fault" label 2, "unrecognizable" label 3, "PC no signal" label 4 and "warranty processing" label 5, wherein the label content of label 1 is the serial number, the label content of label 2 is fault, the label content of label 3 is unrecognizable, the label content of label 4 is PC no signal, and the label content of label 5 is warranty processing. Finally, this embodiment combines the label contents of labels 1 to 5 to obtain the multimedia content of "serial number, fault, unrecognizable, PC no signal, repair processing".
[0094] In some embodiments, determining multimedia content according to the tag content of each target tag includes: extracting picture content from the multimedia file according to an image analysis algorithm, and combining the picture content with the tag content of each target tag to obtain the multimedia content.
[0095] For example, this embodiment uses an image analysis algorithm to analyze Figure 2 The picture shown in the figure obtains the picture content of the barcode "SN41***0", and then "SN41***0" is combined with "serial number, fault, cannot be identified, pc has no signal, and needs repair processing" to obtain the multimedia content "SN41***0, serial number, fault, cannot be identified, pc has no signal, and needs repair processing".
[0096] Therefore, based on the multimedia content determined in the above embodiment, the historical conversation content may be: What is the fault? Unable to identify [serial number, fault, unable to identify, pc no signal, repair processing], and the multimedia content obtained is "SN41***0, serial number, fault, unable to identify, pc no signal, repair processing], and the line is still the same. OK, please provide the contact person's name, phone number and detailed contact address, and we will help you report the repair.
[0097] In general, when the historical conversation content contains multimedia files, that is, the historical conversation content contains multimedia files as noise, the present embodiment can label the multimedia files, match the multimedia files with corresponding multimedia content, and combine the multimedia content with the remaining conversation content to obtain complete, accurate and comprehensive historical conversation content. Therefore, the present embodiment can be compatible with historical conversation content of multiple modalities, and can express historical conversation content of multiple modalities in a complete, accurate and comprehensive manner in text, which is conducive to improving the accuracy and reliability of matching knowledge cards.
[0098] The card name is used to identify the knowledge card, where the knowledge card is: the knowledge point recommended to the agent for reference in real time during the chat between the agent and the customer. The knowledge card includes knowledge tags and knowledge content. The knowledge tags are used to help the agent quickly identify the knowledge content. The knowledge content contains the content that can be referenced by the agent. The knowledge tags include the card name. It can be understood that the knowledge tags can be presented to the agent in a clear, concise and highly focused manner to facilitate the agent to quickly identify the knowledge content.
[0099] See also Figure 3The knowledge card 30 includes a label area 31 and a content area 32. The label area 31 is used to carry one or more knowledge labels. For example, the label area 31 is provided with a knowledge label, wherein the knowledge label is composed of "system restore.pdf" + "seewo education tablet" + "FXXEB", wherein the card name is "system restore.pdf". The content area 32 is used to display the knowledge content corresponding to the knowledge label. Since there are various types of devices for system restore, some seewo education tablets support system restore, and some other devices support system restore. The seewo education tablet also includes a variety of machine models, and the system restore operations of different machine models are also different. Therefore, in this embodiment, "seewo education tablet" and "FXXEB" are both associated with the card name "system restore.pdf" as part of the label, so that the agent can quickly identify which model and type of device requires system restore.
[0100] It can be understood that the candidate reply contents screened out in this embodiment include card names, and different candidate reply contents may include the same card name or different card names.
[0101] S12: Determine the score of each candidate reply content according to a preset refined ranking model.
[0102] In this step, the preset fine ranking model is a pre-trained fine ranking model, wherein the fine ranking model is a model constructed by a preset fine ranking algorithm, wherein the preset fine ranking algorithm includes LR algorithm, FTRL algorithm, FM algorithm, Wide&Deep algorithm, DeepFM algorithm, etc. When training the fine ranking model, this embodiment can use a positive sample combined with a negative sample, or a positive sample combined with multiple negative samples, or multiple positive samples combined with multiple negative samples to train the fine ranking model, the positive sample is a sample that meets the agent's reply requirements, and the negative sample is a sample selected from multiple candidate reply contents recalled by the recall model according to a random sampling method.
[0103] In the process of training the preset refined ranking model, this embodiment constructs training samples, wherein the real reply content of the agent is used as the positive sample, and the reply content whose Jaccard distance with the positive sample is less than a preset threshold is randomly selected from all the reply contents of the agent as the negative sample. The preset threshold can be customized by the designer according to business needs. For example, the preset threshold is 0.6. The positive samples and negative samples are input into the preset refined ranking model for training to obtain the preset refined ranking model.
[0104] In some embodiments, this embodiment uses the BCE loss function in the training phase and the sigmoid function in the reasoning phase, wherein the result output by the sigmoid function is the score of the corresponding candidate reply content.
[0105] In some embodiments, determining the score of each candidate reply content according to a preset refined ranking model includes: splicing the historical conversation content with each candidate reply content to obtain spliced content, inputting the spliced content into the preset refined ranking model, so that the refined ranking model outputs the score of the candidate reply content.
[0106] Inputting the concatenated content into a preset refined ranking model so that the refined ranking model outputs the scores of each candidate reply content includes the following steps: generating text vector features according to the concatenated content, and inputting the text vector features into a preset refined ranking model so that the refined ranking model outputs the scores of the candidate reply content.
[0107] Generating text vector features according to the concatenated content includes: performing vector representation on each conversation sample according to a pre-trained BERT model to obtain text vector features, wherein the full name of the BERT model is Bidirectional Encoder Representations from Transformers. In this embodiment, each conversation sample is represented by a vector through the BERT model, and the obtained text vector features can participate in the scoring calculation, which is conducive to recommending more reliable candidate reply content.
[0108] For example, please combine Figure 2 , one of the 30 candidate replies is: OK, please provide the name, phone number and detailed contact address of the contact person, and we will help you report the problem. Therefore, the conversation sample is: [CLS][worker] What is the fault? [EOS][user] Cannot be recognized, [SN41***0, serial number, fault, cannot be recognized, pc has no signal, report the problem], the line is changed and it is still the same. [EOS][SEP] OK, please provide the name, phone number and detailed contact address of the contact person, and we will help you report the problem [EOS][SEP]. Among them, "[CLS]", "[SEP]" and "[EOS]" are symbols that come with the pre-trained BERT model, representing "the beginning of the overall input", "the segmentation of the front and back two paragraphs" and "the end of the sentence in the paragraph" respectively. "[worker]" and "[user]" represent the two roles of "agent" and "customer" respectively. Next, this embodiment uses the BERT model to vectorize the above conversation samples and obtains a 768-dimensional text vector feature.
[0109] S13: According to the scores of the candidate reply contents, the candidate reply contents satisfying the score screening conditions are determined as priority reply contents among the candidate reply contents.
[0110] In this step, the score screening condition is a condition for screening out priority reply content, and the priority reply content is the candidate reply content that meets the score screening condition. It is understandable that those skilled in the art can reasonably set the score screening condition according to business needs.
[0111] In some embodiments, based on the score of each candidate reply content, determining the candidate reply content that meets the score screening conditions among the candidate reply contents as the priority reply content includes: selecting a specified number of candidate reply contents with the highest scores as the priority reply contents, for example, in this embodiment, the top three candidate reply contents are selected as the priority reply contents.
[0112] In some embodiments, based on the score of each candidate reply content, determining the candidate reply content that meets the score screening condition as the priority reply content among the candidate reply contents includes: judging whether the score of the candidate reply content is greater than a preset score threshold, if it is greater, determining that the candidate reply content meets the score screening condition, and taking the candidate reply content as the priority reply content, if it is less than, determining that the candidate reply content does not meet the score screening condition. Among them, the preset score threshold is customized by the designer according to business needs. For example, if the preset score threshold is 0.95, the candidate reply content with a score greater than 0.95 will be selected as the priority reply content. This embodiment screens out the candidate reply content with higher scores as the priority reply content, which can lay the foundation for matching more accurate knowledge cards.
[0113] S14: Determine in a preset knowledge base the knowledge card corresponding to the card name of the priority reply content as the target knowledge card.
[0114] In this step, the knowledge base is used to store various knowledge cards, wherein the knowledge base can be constructed in advance by the designer. In this embodiment, the knowledge base is traversed to obtain the target knowledge card according to the card name with the priority reply content.
[0115] S15: Present the target knowledge card.
[0116] In this step, this embodiment can set the target knowledge card on the chat page, which is the page where the agent chats with the customer. Therefore, the agent can chat with the customer on the chat page while enhancing the understanding of the customer's problem through the target knowledge card, which is conducive to quickly providing solutions.
[0117] It is understandable that when the names of the cards of the multiple priority reply contents are different, the number of target knowledge cards can be multiple. In this embodiment, more than two target knowledge cards can be set on the chat page. Figure 4The chat page 40 includes a chat area 41 and a knowledge area 42, wherein the chat area 41 is used to display the chat content between the agent and the user, and the knowledge area 42 is used to display the target knowledge card. The knowledge area 42 is provided with a target knowledge card, and the knowledge label of the target knowledge card is composed of "system restore.pdf", "seewo education tablet" and "FXXEB", wherein "system restore.pdf" is the card name.
[0118] This embodiment cleverly uses the good recall ability of the recall model to obtain candidate reply content that is relatively matched with the chat content. Then, with the good sorting ability of the refined ranking model, it can better screen out more accurate and reliable candidate reply content, and traverse the knowledge base according to the card names contained in the candidate reply content, so as to find the target knowledge cards that are more accurate with the chat content for presentation, thereby achieving the purpose of knowledge following, effectively providing reference knowledge points for agents, and helping agents to better serve customers.
[0119] In some embodiments, this embodiment can organize knowledge according to historical chat logs to obtain knowledge cards. The knowledge following conversation method also includes the following steps:
[0120] S16: Get historical chat logs.
[0121] S17: Detect whether the historical chat log contains a document in the target file format.
[0122] S18: If included, the document is matched with a knowledge tag, and a knowledge card is generated according to the document and the knowledge tag matching the document. The knowledge card is stored in the knowledge base, and the knowledge tag includes the card name.
[0123] S19: If not included, select another historical chat log.
[0124] In S16, the historical chat log is a log of chats between agents and customers. The historical chat log records various chat contents. This embodiment can use such historical chat logs to organize knowledge to obtain various knowledge cards.
[0125] In S17, the target file format can be customized by the designer, for example, the target file format is pdf format, word format, ppt format, excel format, txt format, etc. It can be understood that the documents in the target file format are all knowledge contents carefully organized by the user.
[0126] In S18, matching knowledge tags for documents includes: capturing local content of a specified text length in the historical chat log with the document as the center, and determining the knowledge tag of the document according to the local content and the card name.
[0127] Determining the knowledge tag of a document based on local content and card name includes: judging whether the local content contains words appearing in a preset dictionary, if so, generating a knowledge tag based on the words and card name, if not, generating a knowledge tag based on the card name.
[0128] The preset dictionary includes a brand dictionary and / or a machine model dictionary, and determining whether the local content includes words that appear in the preset dictionary includes: determining whether the local content includes words that appear in the brand dictionary and / or the machine model dictionary.
[0129] For example, this embodiment first uses the document name "system restore.pdf" of the document as the card name, where the card name is part of the knowledge tag. Then, this embodiment takes the document as the center and intercepts the previous context 2 rounds away from the round where the document is located and the following context 2 rounds away from the round in the historical chat log to combine them into local content, that is, the specified text length is 2 rounds. Next, this embodiment determines whether the local content contains words that appear in the brand dictionary and / or machine model dictionary. For example, the local content word "seewo educational tablet" appears in the brand dictionary, and the local content word "FXXEB" appears in the machine model dictionary. Therefore, this embodiment combines "system restore.pdf", "seewo educational tablet" and "FXXEB" into knowledge tags.
[0130] This embodiment obtains knowledge cards and generates a knowledge base through knowledge organization, wherein knowledge organization clarifies the specific form of knowledge following, and uses the retrieval dialogue model formed by the recall model and the refined ranking model to ensure the accuracy of following. Therefore, this embodiment cleverly uses the good recall ability of the recall model to obtain candidate reply content that is relatively matched with the chat content, and then uses the good sorting ability of the refined ranking model to better screen out more accurate and reliable candidate reply content, and traverses the knowledge base according to the card names contained in the candidate reply content, so as to find the target knowledge card that is more accurate with the chat content for presentation, thereby achieving the purpose of knowledge following, effectively providing reference knowledge points for agents, and helping agents to better serve customers.
[0131] It should be noted that, in each of the above-mentioned embodiments, there is not necessarily a certain order between the above-mentioned steps. A person skilled in the art can understand, based on the description of the embodiments of the present disclosure, that in different embodiments, the above-mentioned steps may have different execution orders, that is, they may be executed in parallel, may be executed interchangeably, and so on.
[0132] As another aspect of the embodiments of the present disclosure, the embodiments of the present disclosure provide a knowledge-following conversation device, wherein the knowledge-following conversation device may be a software module, wherein the software module includes a plurality of instructions stored in a memory, and a processor may access the memory, call the instructions for execution, so as to complete the knowledge-following conversation method described in each of the above embodiments.
[0133] In some embodiments, the knowledge-following conversation device can also be constructed by hardware devices. For example, the knowledge-following conversation device can be constructed by one or more chips, and each chip can work in coordination with each other to complete the knowledge-following conversation method described in each of the above embodiments. For another example, the knowledge-following conversation device can also be constructed by various logic devices, such as a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA), a single-chip microcomputer, an ARM (Acorn RISC Machine) or other programmable logic device, discrete gate or transistor logic, discrete hardware components, or any combination of these components.
[0134] See also Figure 5 The knowledge-following conversation device 500 includes a content reply module 51, a score determination module 52, a content determination module 53, a card determination module 54 and a card presentation module 55.
[0135] The content reply module 51 is used to obtain multiple candidate reply contents recalled by a preset recall model, wherein each candidate reply content includes a card name. The score determination module 52 is used to determine the score of each candidate reply content according to the preset fine ranking model. The content determination module 53 is used to determine, according to the score of each candidate reply content, the candidate reply content that meets the score screening condition among the candidate reply contents as the priority reply content. The card determination module 54 is used to determine the knowledge card corresponding to the card name of the priority reply content in the preset knowledge base as the target knowledge card. The card presentation module 55 is used to present the target knowledge card.
[0136] This embodiment cleverly uses the good recall ability of the recall model to obtain candidate reply content that is relatively matched with the chat content. Then, with the good sorting ability of the refined ranking model, it can better screen out more accurate and reliable candidate reply content, and traverse the knowledge base according to the card names contained in the candidate reply content, so as to find the target knowledge cards that are more accurate with the chat content for presentation, thereby achieving the purpose of knowledge following, effectively providing reference knowledge points for agents, and helping agents to better serve customers.
[0137] In some embodiments, the card determination module 54 is specifically used to determine whether the score of the candidate reply content is greater than a preset score threshold. If so, it is determined that the candidate reply content meets the score screening conditions and the candidate reply content is used as the priority reply content. If so, it is determined that the candidate reply content does not meet the score screening conditions.
[0138] In some embodiments, the content reply module 51 is specifically used to: obtain historical conversation content, input the historical conversation content into a recall model, so that the recall model recalls multiple candidate reply contents in a preset inverted index library according to the historical conversation content.
[0139] In some embodiments, the content reply module 51 is specifically used to: obtain a conversation log, the conversation log includes the most recent conversation content of a specified round; if the most recent conversation content of the specified round includes a multimedia file, then determine the multimedia content corresponding to the multimedia file, replace the multimedia file with the multimedia content, and obtain the historical conversation content; if the most recent conversation content of the specified round does not include a multimedia file, then determine that the most recent conversation content of the specified round is the historical conversation content.
[0140] In some embodiments, the content reply module 51 is specifically used to: determine at least one reference tag corresponding to the multimedia file, and determine the multimedia content according to the at least one reference tag.
[0141] In some embodiments, the content reply module 51 is specifically used to: determine the score of each reference tag according to a preset multi-tag classification model, select a specified number of reference tags with the highest scores as target tags, and determine the multimedia content according to the tag content of each target tag.
[0142] Please continue reading Figure 5 The knowledge-following conversation device 500 also includes a label generation module 56, which is used to: obtain historical chat logs, detect whether the historical chat logs contain documents in the target file format, and if so, match the knowledge label to the document, generate a knowledge card based on the document and the knowledge label matching the document, and store the knowledge card in the knowledge base. The knowledge label includes the card name.
[0143] Please continue reading Figure 5 The tag generation module 56 is specifically used to: intercept local content of a specified text length in the historical chat log with the document as the center, and determine the knowledge tag of the document according to the local content and the card name.
[0144] Please continue reading Figure 5 The label generation module 56 is specifically used to determine whether the local content contains words that appear in the preset dictionary. If so, a knowledge label is generated based on the words and the card name. If not, a knowledge label is generated based on the card name.
[0145] It should be noted that the above-mentioned knowledge-following conversation device can execute the knowledge-following conversation method provided in the embodiment of the present disclosure, and has the functional modules and beneficial effects corresponding to the execution method. For technical details not fully described in the embodiment of the knowledge-following conversation device, please refer to the knowledge-following conversation method provided in the embodiment of the present disclosure.
[0146] See also Figure 6 , Figure 6 The following is a schematic diagram of a circuit structure of an electronic device provided by an embodiment of the present disclosure. Figure 6 As shown, the electronic device 600 includes one or more processors 61 and a memory 62. Figure 6 A processor 61 is taken as an example.
[0147] The processor 61 and the memory 62 may be connected via a bus or other means. Figure 6 The example of connecting through bus is taken in the following.
[0148] The memory 62 is a non-volatile computer-readable storage medium that can be used to store non-volatile software programs, non-volatile computer executable programs and modules, such as program instructions / modules corresponding to the knowledge-following conversation method in the embodiment of the present disclosure. The processor 61 executes various functional applications and data processing of the knowledge-following conversation device by running the non-volatile software programs, instructions and modules stored in the memory 62, that is, realizes the knowledge-following conversation method provided by the above method embodiment and the functions of each module or unit of the above device embodiment.
[0149] The memory 62 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage devices. In some embodiments, the memory 62 may optionally include a memory remotely arranged relative to the processor 61, and these remote memories may be connected to the processor 61 via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0150] The program instructions / modules are stored in the memory 62, and when executed by the one or more processors 61, the knowledge-following conversation method in any of the above method embodiments is executed.
[0151] The present disclosure also provides a non-volatile computer storage medium, wherein the computer storage medium stores computer executable instructions, and the computer executable instructions are executed by one or more processors, such as Figure 6 A processor 61 in the embodiment may enable the one or more processors to execute the knowledge-following conversation method in any of the above method embodiments.
[0152] The embodiment of the present disclosure also provides a computer program product, which includes a computer program stored on a non-volatile computer-readable storage medium, and the computer program includes program instructions. When the program instructions are executed by an electronic device, the electronic device executes any one of the knowledge-following conversation methods described.
[0153] The above described device or equipment embodiments are merely illustrative, wherein the unit modules described as separate components may or may not be physically separated, and the components displayed as module units may or may not be physical units, that is, they may be located in one place, or may be distributed on multiple network module units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the present embodiment.
[0154] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a general hardware platform, and of course, by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the relevant technology can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0155] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present disclosure, rather than to limit them. Under the concept of the present disclosure, the technical features in the above embodiments or different embodiments may also be combined, the steps may be implemented in any order, and there are many other changes in different aspects of the present disclosure as described above, which are not provided in detail for the sake of simplicity. Although the present disclosure has been described in detail with reference to the aforementioned embodiments, a person of ordinary skill in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present disclosure.
Claims
1. A knowledge-following conversation method, characterized in that: include: Acquire multiple candidate reply contents recalled by a preset recall model, wherein each candidate reply content includes a card name; Determine the score of each candidate response content according to a preset refined ranking model; According to the scores of the candidate reply contents, determine the candidate reply contents that meet the score screening conditions as the priority reply contents among the candidate reply contents; Determine in a preset knowledge base the knowledge card corresponding to the card name of the priority reply content as the target knowledge card; Present the target knowledge card.
2. The method according to claim 1, characterized in that The step of determining, according to the scores of the candidate reply contents, the candidate reply contents that meet the score screening condition as the priority reply contents from among the candidate reply contents includes: Determine whether the score of the candidate reply content is greater than a preset score threshold; If it is greater than, it is determined that the candidate reply content meets the score screening condition, and the candidate reply content is used as the priority reply content; If it is less than, it is determined that the candidate reply content does not meet the score screening condition.
3. The method according to claim 1, characterized in that The obtaining of multiple candidate response contents recalled by the preset recall model includes: Get historical conversation content; The historical conversation content is input into a recall model, so that the recall model recalls a plurality of candidate reply contents in a preset inverted index library according to the historical conversation content.
4. The method according to claim 3, characterized in that The acquisition of historical session content includes: Obtaining a session log, wherein the session log includes the most recent session content of a specified round; If the most recent conversation content of the specified round includes a multimedia file, determining multimedia content corresponding to the multimedia file; Replacing the multimedia file with the multimedia content to obtain historical session content; If the latest conversation content of the specified round does not include a multimedia file, the latest conversation content of the specified round is determined to be a historical conversation content.
5. The method according to claim 4, characterized in that The determining of the multimedia content corresponding to the multimedia file comprises: determining at least one reference tag corresponding to the multimedia file; Multimedia content is determined based on at least one of the reference tags.
6. The method according to claim 5, characterized in that Determining multimedia content according to at least one of the reference tags comprises: Determine a score for each of the reference labels according to a preset multi-label classification model; Select a specified number of reference labels with the highest scores as target labels; The multimedia content is determined according to the tag content of each of the target tags.
7. The method according to any one of claims 1 to 6, characterized in that: Also includes: Get historical chat logs; Detecting whether the historical chat log contains a document in a target file format; If included, a knowledge tag is matched for the document, and a knowledge card is generated according to the document and the knowledge tag matching the document. The knowledge card is stored in the knowledge base, and the knowledge tag includes a card name.
8. The method according to claim 7, characterized in that The matching of knowledge tags for the document comprises: Taking the document as the center, intercepting partial content of a specified text length in the historical chat log; The knowledge tag of the document is determined according to the local content and the card name.
9. The method according to claim 8, characterized in that Determining the knowledge tag of the document according to the local content and the card name includes: Determining whether the local content includes a word that appears in a preset dictionary; If included, a knowledge tag is generated according to the word and the card name; If not included, a knowledge tag is generated according to the card name.
10. A non-volatile readable storage medium, characterized in that: Computer executable instructions are stored, and the computer executable instructions are used to enable an electronic device to execute the knowledge-following conversation method as described in any one of claims 1 to 9.
11. An electronic device, characterized in that: include: at least one processor; as well as, a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the knowledge-following conversation method as described in any one of claims 1 to 9.
Citation Information
Patent Citations
Entity label determining method and device
CN111967262A
Dialogue processing method and system
CN113656572A
Maintenance knowledge recommendation method and device, electronic equipment, medium and product
CN113946651A
Conversation reply generation method and device, storage medium and computer equipment
CN115129830A
