Intelligent customer service question answering method and system based on large model and database
By introducing smart customer service Q&A methods with large models and databases into the customer service system, the existing customer service system is solved, and the existing customer service system is inefficient and unable to provide personalized services is achieved, and the accurate understanding and personalized response to customer problems is achieved, which improves customer service efficiency and customer experience.
Patent Information
- Application Number
- CN202510480969.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-17
- Publication Date
- 2025-05-13
AI Technical Summary
The existing customer service system is inefficient and cannot effectively understand customer problems. In particular, the problem is not standardized or contains complex contextual information, and cannot provide personalized and customized services.
Using a smart customer service question-and-answer method based on big models and databases, we extract customer-related data from the customer service database, combine deep learning big models to perform intelligent question-and-answer reasoning, and generate personalized recommended answers.
It achieves accurate understanding and personalized response to customer problems, can adapt to customers' communication style and needs, and improve customer service efficiency and customer experience.
Smart Images

Figure CN119988751A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of customer service question and answer, and specifically to an intelligent customer service question and answer method and system based on a large model and a database. Background Art
[0002] In the past, customer service mainly relied on manual phone calls, email replies or online chats. This method is inefficient. A customer service staff can only handle a limited number of customer inquiries at the same time, and is easily affected by human factors, such as emotional fluctuations and insufficient knowledge reserves, resulting in uneven service quality.
[0003] At the same time, existing automated customer service systems are mostly built on rule engines. By presetting a series of fixed question templates and corresponding answer rules, when a customer enters a question, the system tries to match the template and give an answer. However, this method has poor flexibility. Once the customer's question expression changes slightly and deviates from the preset template, the system will not be able to respond accurately.
[0004] Although the customer service system can record some basic information about customers, it is insufficient in deeply integrating customer portraits to provide personalized services. Different customers have different communication styles, and it does not fully consider factors such as customers’ historical behaviors, preferences, and habits to provide answers that are more in line with customer needs. Summary of the invention
[0005] In view of the shortcomings of the existing technology, the present invention proposes an intelligent customer service question and answer method and system based on a big model and database, which makes full use of customers' historical behavior data, preferences, habits and other factors, combines the big model of deep learning, and performs intelligent question and answer reasoning, thereby providing customers with more personalized and efficient services.
[0006] To achieve the above object, the present invention provides the following technical solutions: Intelligent customer service question-and-answer method based on large models and databases, including: Extract customer-related data from the customer service database and pre-process it; Obtaining questions asked by customers, determining the relevance between the questions asked by customers and customer-related data, setting a relevance threshold, filtering to obtain first relevance data, setting a preset time range, and filtering to obtain second relevance data based on questions asked by customers within the preset time range; Use the big model and the second relevance data to answer questions asked by customers and generate preliminary answers; Generate personalized recommendations based on historical conversations and sentiment analysis, and respond to questions raised by customers.
[0007] Specifically, obtaining the question asked by the customer and determining the relevance between the question asked by the customer and the customer-related data includes: Extracting the first feature, the second feature and the third feature of the preprocessed customer-related data, and constructing a multi-dimensional feature vector; Analyze the questions asked by customers and extract multiple elements of the questions asked by customers, including: part of speech, syntax, entity, semantics and sentiment; Match the extracted multiple elements of the customer's questions with the multi-dimensional feature vector to evaluate the relevance of the customer's questions and the customer's related data; Set a relevance threshold, filter out data whose relevance between the question asked by the customer and the customer-related data is greater than the relevance threshold, and set it as the first relevance data; A preset time range is set, and questions asked by customers within the preset time range are obtained based on the timestamps of questions asked by customers in combination with the preset time range. Secondary screening is performed in the first relevance data based on the time tags of the questions asked by customers within the preset time range and the multiple elements to obtain second relevance data.
[0008] Specifically, the method of using the large model and the second relevance data to answer questions asked by customers and generate preliminary answers includes: Build and train the big model to obtain a trained big model, and input the questions asked by customers into the trained big model; In each word context of the input text, the attention weight matrix is calculated through the multi-head attention mechanism; The trained large model transmits and synthesizes information through a multi-layer network, fuses the attention weight matrix, and obtains a unified semantic vector; Based on the second relevance data, according to the unified semantic vector, it is input into the trained large model, and a sampling strategy is used to generate multiple candidate answers, i.e. preliminary answers.
[0009] Specifically, the sampling strategy includes: Generate a preliminary sentence based on the unified semantic vector of the input; In the process of generating candidate answers, the large model generates each word or subword in turn based on the generated part and the input unified semantic vector context information, and screens each generated word or subword; Input each generated word or subword as context into the big model to predict the next word or subword; The generation process stops when a termination marker is encountered or the length of the generated answer exceeds the maximum limit, and multiple candidate answers, i.e., preliminary answers, are obtained.
[0010] Specifically, the screening of each generated word or subword includes: Each time, the word or subword with the highest probability is selected as the output; Alternatively, select the top k words or subwords with the highest probability as output; Alternatively, the smallest word or subword set whose cumulative threshold exceeds a set threshold is selected as output.
[0011] Specifically, based on historical conversations and sentiment analysis, personalized recommended answers are generated, and responses are given to questions raised by customers, including: Generate a personalized customer portrait based on the multi-dimensional feature vector; Match the generated preliminary answers with the customer portrait, calculate the semantic matching, emotional matching, style matching and preference matching, and perform weighted summation of the matching of all dimensions to obtain the personalized adaptation degree; Through the customer conversation history, understand the relationship between the current question and the historical conversation, and determine whether the current question is continuous and relevant to the previous round of conversation. If not, select the one with the highest personalized adaptability from the preliminary answers as the final answer. If so, in each round of conversation, dynamically adjust the personalized customer portrait according to the customer's emotional changes, update the personalized adaptability, and select the one with the highest personalized adaptability from the preliminary answers as the final answer; Respond to the customer's questions based on the final answer.
[0012] Specifically, the customer service database contains historical data, including: customer questions, common problems, product information, solutions, and user feedback; The preprocessing includes: data standardization, which is used to convert various types of information in the customer service database into a unified format; data denoising, which is used to remove noise data and redundant data; entity extraction and relationship identification, which are used to identify key entities in the customer service database and the relationships between entities.
[0013] An intelligent customer service question-and-answer system based on a large model and a database, used to implement the intelligent customer service question-and-answer method based on a large model and a database, comprising: a data extraction module, a question association module, a preliminary answer module, and a personalized answer module; The data extraction module is used to extract customer-related data from the customer service database and perform preprocessing; The question association module is used to obtain questions asked by customers, determine the relevance between the questions asked by customers and customer-related data, set a relevance threshold, filter out first relevance data, set a preset time range, and filter out second relevance data based on questions asked by customers within the preset time range; The preliminary answer module is used to answer the questions asked by the customer using the large model and the second relevance data to generate a preliminary answer; The personalized answer module is used to generate personalized recommended answers based on historical conversations and sentiment analysis, and respond to questions raised by customers.
[0014] Specifically, the preliminary answer module includes: a large model unit, a semantic vector calculation unit and a preliminary answer generation unit; The large model unit is used to build and train the large model; The semantic vector calculation unit is used to calculate the attention weight matrix through the multi-head attention mechanism, and fuse the attention weight matrix to obtain a unified semantic vector; The preliminary answer generation unit is used to input a unified semantic vector into a trained large model and use a sampling strategy to generate multiple candidate answers, namely preliminary answers.
[0015] Specifically, the personalized answer module includes: a portrait generation unit, a fitness calculation unit and a final answer generation unit; The portrait generation unit is used to generate a personalized customer portrait based on the multi-dimensional feature vector; The fitness calculation unit is used to perform weighted summation of the matching degrees of all dimensions to calculate the personalized fitness; The final answer generating unit is used to generate the final answer to the question raised by the customer.
[0016] Compared with the prior art, the present invention has the following beneficial effects: 1. The present invention proposes an intelligent customer service question-and-answer method based on a large model and a database, which can accurately understand the questions raised by customers and generate appropriate answers even if the questions are not expressed in a standardized manner or contain complex contextual information.
[0017] 2. The present invention proposes an intelligent customer service question-and-answer method based on a large model and a database. By accessing the customer service database, the intelligent customer service can fully understand each customer's historical behavior, preferences, communication style and other information, and provide customized recommended answers based on the customer portrait to adapt to the customer's communication style and needs.
[0018] 3. The present invention proposes an intelligent customer service question-and-answer method based on a large model and a database. In complex or emotional questions, it can identify the customer's emotional state (such as anxiety, pleasure, anger, etc.) in real time and adjust the tone of the answer accordingly, which can reduce the work pressure of customer service personnel and improve customer experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1 A flow chart of the intelligent customer service question-and-answer method based on a large model and a database provided by the present invention; Figure 2 Generate a flow chart for the final answer of the present invention; Figure 3 This is an architecture diagram of the intelligent customer service question and answer system based on a large model and database provided by the present invention. DETAILED DESCRIPTION
[0020] The present application is described in detail below in conjunction with specific embodiments. The following embodiments will help those skilled in the art to further understand the present application, but do not limit the present application in any form. It should be noted that, for those of ordinary skill in the art, several variations and improvements can also be made without departing from the concept of the present application. These all belong to the protection scope of the present application.
[0021] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application 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 application and are not used to limit the present application.
[0022] It should be noted that, if there is no conflict, the various features in the embodiments of the present application can be combined with each other, all within the scope of protection of the present application. In addition, although the functional module division is performed 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 sequence different from the module division in the device or the flow chart. In addition, the words "first", "second", "third" and the like used in the present application do not limit the data and the execution order, but only distinguish the same items or similar items with substantially the same functions and effects.
[0023] Unless otherwise defined, all technical and scientific terms used in this specification have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used in this specification and in the specification of this application are only for the purpose of describing specific embodiments and are not intended to limit this application. The term "and / or" used in this specification includes any and all combinations of one or more of the related listed items.
[0024] Example 1 See also Figure 1 and Figure 2 , an embodiment provided by the present invention: a smart customer service question-answering method based on a large model and a database, comprising the following specific steps: Step S1: extracting customer-related data from the customer service database and preprocessing it; The customer service database contains a large amount of historical data, such as customer questions, common problems, product information, solutions, user feedback, etc. Data extraction: Extract raw data from customer service databases (such as FAQs, chat logs, product documentation, solution databases, etc.) through SQL queries or API interfaces; The preprocessing includes: data standardization, which is used to convert various types of information in the database (such as customer questions, historical conversation records, product descriptions, etc.) into a unified format to ensure data consistency; Data denoising, removing unnecessary noise data and redundant data through natural language processing algorithms (such as stop word removal and grammar correction); Entity extraction and relationship identification: identify key entities in the customer service database (such as product name, problem category, service time limit, etc.) through named entity recognition (NER) technology, and identify the relationship between entities through relationship extraction technology.
[0025] Step S2: obtaining questions asked by customers, determining the relevance between the questions asked by customers and customer-related data, setting a relevance threshold, filtering to obtain first relevance data, setting a preset time range, and filtering to obtain second relevance data based on questions asked by customers within the preset time range; The specific steps of step S2 are: Step S201: extracting the first feature, the second feature and the third feature of the pre-processed customer-related data, and constructing a multi-dimensional feature vector; In this embodiment, the first feature of the customer-related data may be a behavioral feature, which is usually obtained by using a clustering algorithm (such as K-means, DBSCAN, hierarchical clustering, etc.), the purpose of which is to divide customers into different groups according to their purchase frequency, consumption amount, etc., and the implementation method is as follows: 1) Purchase frequency: the number of purchases made by a customer within a period of time; 2) Consumption amount: the total consumption amount or the average single consumption amount of a customer within a period of time; 3) Clustering results: through the clustering algorithm, customers can be divided into different groups such as high-value customers, low-value customers, and potential customers; The second feature of customer-related data can be an interest feature, which is usually obtained through text analysis algorithms (such as TF-IDF, LDA, Word2Vec, etc.). The purpose is to divide customers into different groups according to their interests and hobbies. The implementation method is: perform text preprocessing on customers' historical questions and comments (such as removing stop words and word segmentation), and use text analysis algorithms to extract high-frequency words or topics as customers' interest features; The third feature of customer-related data can be the active time feature, which is obtained through time series analysis methods (such as ARIMA, time window, etc.). The purpose is to analyze the time pattern of customer interaction with the brand and identify the customer's active time period. The implementation method is: analyze the frequency and time period of customer interaction with the brand, find out the specific time points or time periods when the customer is active, such as 7-9 pm every day or the morning rush hour on weekdays. According to these patterns, construct the customer's active time characteristics, such as: active time period, preferred communication time, etc.
[0026] Each dimension in the multi-dimensional feature vector represents a customer attribute, and the value in the vector is the quantitative score or label of the customer attribute. By combining features of different dimensions, a comprehensive customer profile can be obtained. Customer attributes include: value attributes, interest attributes, time attributes and other attributes (such as social, geographic, device, etc.).
[0027] For example, a customer's multi-dimensional feature vector may include the following: value attribute: high-value customer (score 5); interest attribute: smart home (score 3), Internet of Things (score 2); time attribute: active on weekday evenings (score 1); social attribute: active social user (score 4); geographic attribute: first-tier city (score 2). The constructed multi-dimensional feature vector is [5,3,2,1,4,2].
[0028] Step S202: Analyze the question asked by the customer and extract multiple elements of the question asked by the customer, including: part of speech, syntax, entity, semantics and sentiment, etc.; For example, the question a customer asks is: "How is the battery of this mobile phone?" The part-of-speech tagging result is: ["this", "model", "mobile phone", "of", "battery", "how about"], where "mobile phone" is a noun, indicating an entity, "battery" is also a noun, and "how about" is an adjective, indicating an evaluation of the battery. Through syntactic analysis, we can know that "battery" is the core of the question, and "mobile phone" is the modification information of the battery. The entities are "mobile phone" and "battery"; For another example, a customer asks: "Can I buy this product?", the action is "buy", the actor is "I", and the target is "this product". Through semantic role labeling, we can clearly understand that "I" is the initiator of the purchase behavior and "this product" is the object of purchase.
[0029] Step S203: Matching the extracted multiple elements of the customer's question with the multi-dimensional feature vector to evaluate the relevance between the customer's question and the customer-related data; In this embodiment, the relevance between the question asked by the customer and the customer-related data is evaluated and calculated through keyword matching and semantic matching.
[0030] Step S204: setting a relevance threshold, screening out data whose relevance between the question asked by the customer and the customer-related data is greater than the relevance threshold, and setting the data as first relevance data; Step S205: Set a preset time range, obtain the questions asked by the customer within the preset time range based on the timestamp of the question asked by the customer and the preset time range, and perform a secondary screening in the first relevance data based on the time tags of the questions asked by the customer within the preset time range and the multiple elements to obtain second relevance data.
[0031] For example, if a customer asked a question 10 years ago, "recommend a new graphics card", the time tag is "10 years ago", and multiple elements include "new" and "graphics card", the first relevance data can be obtained. If the customer asks the same question within a preset time range, the outdated data from 10 years ago needs to be screened out, and only the first relevance data corresponding to the question time within the preset time range is retained, further narrowing the scope to obtain a smaller and more accurate second relevance data, and the preset time can be 10s, 30s, 60s, etc.; Technological products are changing with each passing day. With the release of new products, old problems are no longer relevant. By filtering at preset times, information that is no longer applicable due to product iterations or market changes can be excluded. Whether it is R&D personnel analyzing feedback to improve products, or customer service personnel answering questions, they can focus on current valid information and improve work efficiency.
[0032] Step S3: using the large model and the second relevance data, answer the questions asked by the customer and generate a preliminary answer; The specific steps of step S3 are: Step S301: construct and train the big model to obtain a trained big model, and input the questions asked by the customer into the trained big model; The large model can be a language model, such as Doubao, ChatGPT, etc. Step S302: In each word context of the input text, an attention weight matrix is calculated through a multi-head attention mechanism; The attention weight matrix calculated by the multi-head attention mechanism is multiple; Step S303: The trained large model is used to transmit and synthesize information through a multi-layer network, and the attention weight matrix is fused to obtain a unified semantic vector; In this embodiment, the step of fusing the attention weight matrix is: Concatenate the outputs of all attention heads by columns to get a new tensor; The concatenated output undergoes a linear transformation (usually a matrix multiplication) to map the concatenated vector space back to the original dimensional space. This linear transformation is to restore the same dimension as the input so that it can be passed to the subsequent layer in the next step. After linear transformation, a unified semantic vector is obtained, which integrates the output information of all attention heads.
[0033] Step S304: Based on the second relevance data and the unified semantic vector, the data is input into the trained large model and a sampling strategy is used to generate multiple candidate answers, i.e., preliminary answers.
[0034] Step S301 and step S304 are input into the large model, and the inputs are different layers in the large model; For example, a customer's question: "How to optimize the camera function of a certain mobile phone?" The initial answer generated is: "Adjust camera parameters, such as increasing exposure compensation, adjusting ISO value, and turning on night mode", or "The photo effect can be improved by optimizing focal length and turning on HDR mode", or "Use a tripod to reduce shaking and ensure image stability, and turn on continuous shooting mode to capture more details". Each candidate answer has a different focus and is answered from multiple dimensions such as parameter adjustment, usage scenarios, and shooting techniques.
[0035] The specific steps of the sampling strategy in step S304 are: Step S3041: firstly generate a preliminary sentence based on the input unified semantic vector; For example, for the question "How to optimize the camera function of a certain mobile phone?", the model first generates an opening: "To optimize the camera function of the mobile phone, you can first..."; Step S3042: In the process of generating candidate answers, the large model generates each word or subword in turn according to the generated part and the input unified semantic vector context information, and screens each generated word or subword; For example, starting from “To optimize the camera function of a mobile phone, you can first…”, the probability distribution of the next word is calculated, such as “adjust”, “improve” or “enable”, and selection is performed based on these probabilities; Step S3043: input each generated word or subword as context into the large model to predict the next word or subword; Step S3044: The generation process stops until a termination mark (such as " ") is encountered or the length of the generated answer exceeds the maximum limit, and multiple candidate answers, i.e., preliminary answers, are obtained.
[0036] Based on multiple screening methods, multiple candidate answers can be obtained.
[0037] The step S3042 screens each generated word or subword, including: selecting the word or subword with the highest probability as output each time; Alternatively, select the top k words or subwords with the highest probability as output; Alternatively, the smallest word or subword set whose cumulative threshold exceeds a set threshold is selected as output.
[0038] Step S4: Generate personalized recommended answers based on historical conversations and sentiment analysis, and respond to questions raised by customers.
[0039] The specific steps of step S4 are: Step S401: Generate a personalized customer portrait based on the multi-dimensional feature vector; In this embodiment, the customer profile is constructed based on information such as the customer's historical behavior, preferences, and communication habits, i.e., a multi-dimensional feature vector; Step S402: Match the generated preliminary answer with the customer portrait, calculate the semantic matching degree, emotional matching degree, style matching degree and preference matching degree, perform weighted summation on the matching degrees of all dimensions, and obtain the personalized adaptation degree; In this embodiment, semantic matching degree: the semantic matching degree between the candidate answer and the customer question is calculated by a semantic matching model (such as BERT or TF-IDF); Emotional match: Calculate the match based on the customer's emotional state and the emotional tendency of the candidate's answer (such as positive, negative); Style match: evaluate whether the candidate answer matches the client’s communication style (e.g., colloquial, formal, etc.); Preference match: Consider the customer's historical questions and preferences and evaluate the match of the answer; The matching degrees of all dimensions are weighted and summed to obtain the personalized adaptation degree.
[0040] Step S403: Understand the relationship between the current question and the historical conversations through the customer conversation history, and determine whether the current question is continuous and relevant to the previous round of conversations. If not, select the one with the highest personalized adaptability from the preliminary answers as the final answer. If yes, dynamically adjust the personalized customer profile according to the customer's emotional changes in each round of conversation, update the personalized adaptability, and select the one with the highest personalized adaptability from the preliminary answers as the final answer. In this embodiment, the generation of personalized answers is not limited to a single round of dialogue, but must also adapt to changes in customer needs in multiple rounds of dialogue. In multiple rounds of dialogue, the answer strategy needs to be dynamically adjusted based on the context of each round of dialogue and customer feedback.
[0041] For example, a single-round conversation example, assuming that the customer's information is as follows: Historical behavior: This customer is a frequent consumer of electronic products and has purchased smartphones, laptops, and headphones. Communication style: Prefer concise and direct answers to questions; Preferences: This customer prefers the latest information and special offers on electronic products; Sentiment Analysis: The emotional state of the customers is neutral (no obvious positive or negative emotions).
[0042] Customer question: "Do you have any new headphone products recently?" Generate multiple candidate answers based on the customer's background information and questions: Candidate answer 1 (neutral tone): “Hello, we have recently launched several new headphones, including X1 and X2. X1 supports active noise cancellation, while X2 is suitable for sports. Please check our official website for details.” Candidate answer 2 (concise): "Recently, there are two new headphones, X1 and X2, which support active noise cancellation. X2 is also suitable for sports use." Candidate answer 3 (slightly more friendly): “Dear users, we recently launched the X1 and X2 headphones. The X1 is very suitable for users who like a quiet environment, while the X2 is designed for sports. You can choose according to your needs.” Since the customer likes concise and clear answers, the system finally selects candidate answer 2 because it is more concise and provides the product information that the user wants. The final answer is: "Recently, there are two new headphones, X1 and X2, which support active noise cancellation. X2 is also suitable for sports use." For example, a multi-round dialogue example, assuming that the customer's information is as follows: Historical behavior: This customer has purchased multiple smart home devices in the past, such as smart light bulbs, smart speakers, and smart sockets.
[0043] Preferences: Prefer the compatibility and ease of use of smart home products, and pay special attention to the linkage between devices.
[0044] Sentiment analysis: Customer sentiment tends to be positive, showing interest in new technologies and products.
[0045] Communication style: Prefers concise and clear answers, but has a high demand for details on new products and is willing to accept slightly longer explanations.
[0046] The first round of conversation in history: Customer question: "Have you launched any new smart speakers recently? I want to see if there are any higher-end options." Candidate answer 1 (professional): “Yes, we recently launched the X-Stream smart speaker, which supports 360-degree surround sound and can be linked with other smart devices, such as smart light bulbs, thermostats, etc. It also has a voice assistant function that can help you control smart home devices.” Candidate answer 2 (concise): “We have launched the X-Stream smart speaker, which supports high-quality sound effects and linkage with other smart devices, and supports voice assistants.” Candidate answer 3 (friendly): “Dear users, our newly launched X-Stream smart speaker not only provides high-quality surround sound, but also can be seamlessly connected with smart devices in your home and easily control other devices. It is very suitable for you who love technology!” Since the customer likes concise and clear answers and pays attention to the high-end performance of the product, the final answer is: Candidate 1 is selected, which provides detailed information and emphasizes the high-end functions and equipment linkage of the audio system; Second round of historical conversation: Customer asked: "Does the X-Stream speaker support simultaneous playback in multiple rooms? If I have multiple speakers, can I play music together? Please be brief so that I don't have to read so many words." Candidate answer 1 (professional): "X-Stream smart speakers support multi-room simultaneous playback. You can connect multiple speakers through our smart home control platform and play the same music in different rooms to ensure a consistent music experience throughout the house." Candidate answer 2 (concise): “Yes, X-Stream supports multi-room simultaneous playback, and you can manage multiple speakers through the control platform.” Candidate answer 3 (friendly): "Yes, X-Stream speakers can be easily connected to multiple speakers through our smart control platform, so you can enjoy a synchronized music experience in different rooms." Since the customer emphasized simplicity and clarity when asking the question, the final answer was candidate 2, which is simple and clear and also summarizes the functions of the speaker; Current conversation (third round of conversation): Customer asks: "If I buy X-Stream speakers now, are there any promotions or discounts?" Candidate answer 1 (professional): "Currently, customers who purchase an X-Stream smart speaker can enjoy a 10% discount and also receive a free subscription to our smart home platform if you choose to join our membership program at the time of purchase." Candidate answer 2 (concise): "There is currently a 10% discount on X-Stream speakers, and if you join the membership program, you can enjoy more discounts." Candidate answer 3 (friendly): “Dear users, if you purchase X-Stream speakers now, we will provide you with a 10% discount and a free smart home platform subscription! If you become a member, you will get more exclusive offers.” Since the client’s personal style tends to be professional, but the previous round of answers required conciseness and clarity, combined with the context, the final answer is candidate answer 2.
[0047] In the single-round and multi-round examples, it can be seen that different tones and levels of detail are provided for each question, thereby maximizing the satisfaction of the customer's individual needs.
[0048] Step S404: Respond to the questions raised by the customer based on the final answer.
[0049] Example 2 See also Figure 3 , another embodiment provided by the present invention: a smart customer service question-answering system based on a large model and a database, comprising: a data extraction module, a question association module, a preliminary answer module and a personalized answer module; The data extraction module is used to extract customer-related data from the customer service database and perform preprocessing; The question association module is used to obtain questions asked by customers, determine the relevance between the questions asked by customers and customer-related data, set a relevance threshold, filter out first relevance data, set a preset time range, and filter out second relevance data based on questions asked by customers within the preset time range; The preliminary answer module is used to answer the questions asked by the customer using the large model and the second relevance data to generate a preliminary answer; The personalized answer module is used to generate personalized recommended answers based on historical conversations and sentiment analysis, and respond to questions raised by customers.
[0050] A preliminary answer module, including: a large model unit, a semantic vector calculation unit and a preliminary answer generation unit; The large model unit is used to build and train the large model; The semantic vector calculation unit is used to calculate the attention weight matrix through the multi-head attention mechanism, and fuse the attention weight matrix to obtain a unified semantic vector; The preliminary answer generation unit is used to input a unified semantic vector into a trained large model and use a sampling strategy to generate multiple candidate answers, namely preliminary answers.
[0051] The personalized answer module includes: a portrait generation unit, a fitness calculation unit and a final answer generation unit; The portrait generation unit is used to generate a personalized customer portrait based on the multi-dimensional feature vector; The fitness calculation unit is used to perform weighted summation of the matching degrees of all dimensions to calculate the personalized fitness; The final answer generating unit is used to generate the final answer to the question raised by the customer.
[0052] In addition, the parts of the above-mentioned technical solutions provided in the embodiments of the present application that are consistent with the implementation principles of the corresponding technical solutions in the prior art are not described in detail to avoid excessive redundancy.
[0053] The specific implementation modes as described above further describe the purpose, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation mode of the present invention and is not intended to limit the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. An intelligent customer service question-answering method based on a large model and database, characterized in that: include: Extract customer-related data from the customer service database and pre-process it; Obtaining questions asked by customers, determining the relevance between the questions asked by customers and customer-related data, setting a relevance threshold, filtering to obtain first relevance data, setting a preset time range, and filtering to obtain second relevance data based on questions asked by customers within the preset time range; Use the big model and the second relevance data to answer the questions asked by customers and generate preliminary answers; Generate personalized recommendations based on historical conversations and sentiment analysis, and respond to questions raised by customers.
2. The intelligent customer service question-answering method based on a large model and a database as claimed in claim 1, characterized in that: The obtaining of the question asked by the customer and determining the relevance of the question asked by the customer and the customer-related data includes: Extracting the first feature, the second feature and the third feature of the preprocessed customer-related data, and constructing a multi-dimensional feature vector; Analyze the questions asked by customers and extract multiple elements of the questions asked by customers, including: part of speech, syntax, entity, semantics and sentiment; Match the extracted multiple elements of the customer's questions with the multi-dimensional feature vector to evaluate the relevance of the customer's questions and the customer's related data; Set a relevance threshold, filter out data whose relevance between the question asked by the customer and the customer-related data is greater than the relevance threshold, and set it as the first relevance data; A preset time range is set, and questions asked by customers within the preset time range are obtained based on the timestamps of questions asked by customers in combination with the preset time range. Secondary screening is performed in the first relevance data based on the time tags of the questions asked by customers within the preset time range and the multiple elements to obtain second relevance data.
3. The intelligent customer service question-answering method based on a large model and a database as claimed in claim 1, characterized in that: The method uses the large model and the second relevance data to answer questions asked by customers and generate preliminary answers, including: Build and train the big model to obtain a trained big model, and input the questions asked by customers into the trained big model; In each word context of the input text, the attention weight matrix is calculated through the multi-head attention mechanism; The trained large model transmits and synthesizes information through a multi-layer network, fuses the attention weight matrix, and obtains a unified semantic vector; Based on the second relevance data, according to the unified semantic vector, it is input into the trained large model, and a sampling strategy is used to generate multiple candidate answers, i.e. preliminary answers.
4. The intelligent customer service question-answering method based on a large model and a database as claimed in claim 3, characterized in that: The sampling strategy includes: Generate a preliminary sentence based on the unified semantic vector of the input; In the process of generating candidate answers, the large model generates each word or subword in turn based on the generated part and the input unified semantic vector context information, and screens each generated word or subword; Input each generated word or subword as context into the big model to predict the next word or subword; The generation process stops when a termination marker is encountered or the length of the generated answer exceeds the maximum limit, and multiple candidate answers, i.e., preliminary answers, are obtained.
5. The intelligent customer service question-answering method based on a large model and a database as claimed in claim 4, characterized in that: The step of screening each generated word or subword includes: Each time, the word or subword with the highest probability is selected as the output; Alternatively, select the top k words or subwords with the highest probability as output; Alternatively, the smallest word or subword set whose cumulative threshold exceeds a set threshold is selected as output.
6. The intelligent customer service question-answering method based on a large model and a database as claimed in claim 1, characterized in that: Based on historical conversations and sentiment analysis, the system generates personalized recommendations and responds to questions raised by customers, including: Generate personalized customer portraits based on multi-dimensional feature vectors; Match the generated preliminary answers with the customer portrait, calculate the semantic matching, emotional matching, style matching and preference matching, and perform weighted summation of the matching of all dimensions to obtain the personalized adaptation degree; Through the customer conversation history, understand the relationship between the current question and the historical conversation, and determine whether the current question is continuous and relevant to the previous round of conversation. If not, select the one with the highest personalized adaptability from the preliminary answers as the final answer. If so, in each round of conversation, dynamically adjust the personalized customer portrait according to the customer's emotional changes, update the personalized adaptability, and select the one with the highest personalized adaptability from the preliminary answers as the final answer; Respond to the customer's questions based on the final answer.
7. The intelligent customer service question-answering method based on a large model and a database as claimed in claim 1, characterized in that: The customer service database contains historical data, including: customer questions, common problems, product information, solutions, and user feedback; The preprocessing includes: data standardization, which is used to convert various types of information in the customer service database into a unified format; data denoising, which is used to remove noise data and redundant data; entity extraction and relationship identification, which are used to identify key entities in the customer service database and the relationships between entities.
8. An intelligent customer service question-and-answer system based on a large model and a database, used to implement the intelligent customer service question-and-answer method based on a large model and a database as described in any one of claims 1 to 7, characterized in that: include: Data extraction module, question association module, preliminary answer module and personalized answer module; The data extraction module is used to extract customer-related data from the customer service database and perform preprocessing; The question association module is used to obtain questions asked by customers, determine the relevance between the questions asked by customers and customer-related data, set a relevance threshold, filter out first relevance data, set a preset time range, and filter out second relevance data based on questions asked by customers within the preset time range; The preliminary answer module is used to answer the questions asked by the customer using the large model and the second relevance data to generate a preliminary answer; The personalized answer module is used to generate personalized recommended answers based on historical conversations and sentiment analysis, and respond to questions raised by customers.
9. The intelligent customer service question-answering system based on a large model and a database as claimed in claim 8, characterized in that: The preliminary answer module includes: a large model unit, a semantic vector calculation unit and a preliminary answer generation unit; The large model unit is used to build and train the large model; The semantic vector calculation unit is used to calculate the attention weight matrix through the multi-head attention mechanism, and fuse the attention weight matrix to obtain a unified semantic vector; The preliminary answer generation unit is used to input a unified semantic vector into a trained large model and use a sampling strategy to generate multiple candidate answers, namely preliminary answers.
10. The intelligent customer service question-answering system based on a large model and a database as claimed in claim 9, characterized in that: The personalized answer module includes: a portrait generation unit, a fitness calculation unit and a final answer generation unit; The portrait generation unit is used to generate a personalized customer portrait based on the multi-dimensional feature vector; The fitness calculation unit is used to perform weighted summation of the matching degrees of all dimensions to calculate the personalized fitness; The final answer generating unit is used to generate the final answer to the question raised by the customer.
Citation Information
Patent Citations
Retrieval type personalized conversation method and system
CN113901188A
Language processing question answering system and method based on AIGC large model
CN118093834A
Method for improving reply accuracy of intelligent customer service
CN119398149A
Intelligent customer service system based on AI large model
CN119474280A
Multi-modal large model dialogue method and system based on context awareness and medium
CN119537521A