A consultation text generation method, device, equipment and storage medium
By automating the identification and generation of consultation texts, the problems of large errors and low efficiency in traditional manual recording have been solved, achieving efficient and accurate consultation records and improving service quality.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- 北京新氧万维科技咨询有限公司
- Filing Date
- 2024-12-31
- Publication Date
- 2026-06-30
AI Technical Summary
Traditional consultation record-keeping methods rely on manual processing, which can easily lead to errors or omissions in the records and make it difficult to meet the requirements of efficient and accurate services, thus increasing the operating costs of enterprises.
By acquiring the consultation service dialogue between customers and service personnel, keywords are automatically identified using a keyword dictionary and preset rules to generate standard-format consultation text, including consultation points and details.
It improves the accuracy and efficiency of consultation records, avoids omissions and errors in manual recording, and is suitable for various customer service hotlines and sales consultation scenarios, helping companies better understand customer needs.
Smart Images

Figure CN122309729A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of artificial intelligence technology, and in particular to a method, apparatus, device, and storage medium for generating consultation text. Background Technology
[0002] Customer service has always played a vital role as a key communication channel between customers and businesses. However, traditional consultation record-keeping relies on manual compilation by consultants, a process that is not only tedious and complex but also highly susceptible to human error, potentially leading to errors or omissions in the recorded information. Furthermore, as businesses grow and customer service demands increase, manual compilation of consultation records can no longer meet the requirements for efficient and accurate service. A significant amount of time, manpower, and resources are invested in this repetitive work, greatly increasing the company's operating costs.
[0003] Therefore, how to efficiently extract key information from consultation service dialogues and automatically generate complete and accurate consultation record texts has become a technical problem that urgently needs to be solved by those skilled in the art. Summary of the Invention
[0004] The purpose of this invention is to provide a method, apparatus, device, and storage medium for generating consultation text, which can efficiently extract keywords from consultation service dialogues and automatically generate concise and accurate consultation record text based on the keywords.
[0005] According to one aspect of the present invention, a method for generating consultation text is provided, the method comprising: Obtain the content of consultation service conversations between customers and service personnel; Based on the content of the consultation service dialogue and the keyword dictionary corresponding to the consultation service, the target keywords are obtained; Based on the target keywords and the consultation service dialogue content, a standard format consultation text is generated; wherein, the standard format consultation text includes consultation points and consultation details.
[0006] Optionally, generating a standard-format consultation text based on the target keywords and the consultation service dialogue content specifically includes: Based on the target keywords, obtain the keyword feature tags corresponding to the target keywords; The key points of consultation are obtained based on the keyword feature tags and the target keywords.
[0007] Optionally, the keyword dictionary includes: keywords, and keyword feature tags corresponding to the keywords.
[0008] Optionally, the keyword dictionary includes: primary keywords and secondary keywords, wherein the primary keywords are high-frequency words, and the secondary keywords are synonyms or near-synonyms of the corresponding primary keywords; The step of obtaining target keywords based on the consultation service dialogue content and the corresponding keyword dictionary includes: If the content of the consultation service dialogue matches a first-level keyword in the keyword dictionary, the matched first-level keyword will be used as the target keyword. If the content of the consultation service dialogue matches a secondary keyword in the keyword dictionary, then the primary keyword corresponding to the matched secondary keyword will be used as the target keyword.
[0009] Optionally, generating a standard-format consultation text based on the target keywords and the consultation service dialogue content specifically includes: Obtain preset key point reasoning rules; wherein, the key point reasoning rules are used to form consultation key points, and the key point reasoning rules are divided into trigger word reasoning rules and reverse reasoning rules; Each trigger word reasoning rule is traversed sequentially. It is determined whether the trigger word associated with the currently traversed trigger word reasoning rule is included in the consultation service dialogue content. If so, a consultation point is formed based on the included trigger word and the currently traversed trigger word reasoning rule. Iterate through each reverse reasoning rule in turn, and determine whether the consultation point associated with the currently traversed reverse reasoning rule has been formed. If so, form a new consultation point based on the already formed consultation point and the currently traversed reverse reasoning rule.
[0010] Optionally, generating standard-format consultation text based on the target keywords and the consultation service dialogue content further includes: Obtain a preset product knowledge graph; wherein, the product knowledge graph includes: multiple product categories, with a corresponding category dictionary set for each product category, and an item dictionary for each product item under each product category; Based on all the identified consultation points, the target product category and target product item are determined from the product knowledge graph; A product category introduction is generated based on the category dictionary of the target product category, and a product item introduction is generated based on the item dictionary of the target product item; Add the product category description and the product project description to the standard format consultation text.
[0011] Optionally, if the consultation service is skin management, the consultation points include at least one of the following: skin type, skin tone, and skincare needs.
[0012] To achieve the above objectives, the present invention also provides a consultation text generation apparatus, the apparatus comprising: The acquisition module is used to acquire the content of consultation service dialogues between customers and service personnel; The query module is used to obtain target keywords based on the content of the consultation service dialogue and a keyword dictionary corresponding to the consultation service; The generation module is used to generate a standard format consultation text based on the target keywords and the consultation service dialogue content; wherein, the standard format consultation text includes consultation points and consultation details.
[0013] To achieve the above objectives, the present invention also provides a computer device, which specifically includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the consultation text generation method described above.
[0014] To achieve the above objectives, the present invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the consultation text generation method described above.
[0015] The consultation text generation method, apparatus, device, and storage medium provided by this invention accurately identify key information in the dialogue through keyword dictionary matching. Then, using a preset standard format, it can further extract core consultation points such as the customer's basic information, needs, and precautions. Finally, based on these consultation points, it automatically generates standard format consultation text, which not only significantly improves the accuracy and efficiency of consultation records but also effectively avoids omissions and errors that may occur with manual recording. Furthermore, this method has a wide range of applications, suitable for various customer service hotlines, sales consultations, and other scenarios, helping enterprises better understand customer needs and improve service quality. Attached Figure Description
[0016] Various other advantages and benefits will become apparent to those skilled in the art upon reading the following detailed description of preferred embodiments. The accompanying drawings are for illustrative purposes only and are not intended to limit the invention. Furthermore, the same reference numerals denote the same parts throughout the drawings. In the drawings: Figure 1 A schematic diagram of an optional process for the consultation text generation method provided in Embodiment 1; Figure 2 This is a schematic diagram of another optional process for the consultation text generation method provided in Example 1; Figure 3This is a schematic diagram of an optional component structure of the consultation text generation device provided in Embodiment 2; Figure 4 This is a schematic diagram of an optional hardware structure for the computer device provided in Embodiment 3. Detailed Implementation
[0017] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without inventive effort are within the scope of protection of this invention.
[0018] Example 1 This invention provides a method for generating consultation text, such as... Figure 1 As shown, the method specifically includes the following steps: Step S101: Obtain the consultation service dialogue content between the customer and the service personnel.
[0019] The consultation service dialogue content between customers and service personnel can be obtained by extracting voice calls or on-site consultation dialogues between customers and service personnel; or by obtaining online Q&A between customers and service personnel. This invention allows for the selection of appropriate acquisition methods based on different scenarios for obtaining the consultation service dialogue content between customers and service personnel.
[0020] Step S102: Based on the content of the consultation service dialogue and the keyword dictionary corresponding to the consultation service, obtain the target keywords.
[0021] In this embodiment, a keyword dictionary that conforms to the language characteristics of a specific query service scenario will be generated in advance, and multiple keywords belonging to the specific query service scenario will be stored in the keyword dictionary.
[0022] Step S103: Generate a standard format consultation text based on the target keywords and the consultation service dialogue content; wherein the standard format consultation text includes consultation points and consultation details.
[0023] The consultation key points are the key information extracted from the consultation service dialogue content. The consultation key points are used to represent the customer's basic information, needs and / or precautions. The consultation details are a summary or abstract of the consultation service dialogue content.
[0024] Preferably, the consultation points adopt a key-value pair data structure, and the consultation points include: keyword feature tags and keywords; wherein, the keyword feature tags can be the customer's basic information, such as gender, age, and address, and the keyword feature tags can also be the customer's needs, such as customer product needs, customer budget range, and precautions; in addition, the keywords are the specific values of the keyword feature tags; for example, for the keyword feature tag "gender" and the keyword is "male", the resulting consultation point is "gender: male"; for the keyword feature tag "customer budget range" and the keyword is "100-500", the resulting consultation point is "customer budget range: 100-500".
[0025] In this embodiment, key information in the dialogue is accurately identified through keyword dictionary matching. Then, using a preset standard format, core consultation points such as the customer's basic information, needs, and precautions can be further extracted. Finally, standard format consultation text is automatically generated based on these consultation points. This not only significantly improves the accuracy and efficiency of consultation records but also effectively avoids omissions and errors that may occur with manual recording. Furthermore, this method has wide applications, suitable for various customer service hotlines, sales consultations, and other scenarios, helping businesses better understand customer needs and improve service quality.
[0026] Specifically, obtaining the consultation service dialogue content between the customer and the service personnel in step S101 includes the following steps: Step A1: Determine whether the terminal running the consultation service interface supports recording.
[0027] For example, you can use the navigator.mediaDevices.getUserMedia method in the navigator.mediaDevices object to determine whether the terminal has a recording function.
[0028] Step A2: If so, create a media recording instance by calling MediaRecorder, and set the sample rate, sample bit depth, and number of channels in the media recording instance as needed.
[0029] The MediaRecorder instance provides a series of methods and events, such as starting MediaRecorder.start, stopping MediaRecorder.stop, pausing MediaRecorder.pause, resuming recording MediaRecorder.resume, and recording state MediaRecorder.state.
[0030] The sampling rate determines the frequency range of an audio signal; a higher sampling rate can capture higher frequency sound details, but it also increases the amount of data; common sampling rates include 44.1kHz (CD quality) and 48kHz (professional audio).
[0031] The bit depth determines the dynamic range of an audio signal; a higher bit depth can capture more delicate audio details and a wider dynamic range; common bit depths include 16-bit (CD quality) and 24-bit (professional audio).
[0032] It should also be noted that in speaker recognition and separation tasks, higher sampling rates and bit depths can provide clearer audio signals, thereby improving the accuracy of recognition and separation. Customer service personnel can modify the sampling rate and bit depth as needed to record high-quality, clearer audio content.
[0033] Step A3: Record the consultation service dialogue between the customer and the service personnel using the media recording example to obtain the consultation audio.
[0034] The media recording example involves recording the consultation service dialogue between customer service representatives and service personnel to obtain a stream file. The stream file is then converted into Blob format, then converted into MP3 format consultation audio, and finally stored on the corresponding server.
[0035] In this embodiment, a webpage was developed that allows service personnel to record consultations and automatically generate corresponding text content. The webpage uses a browser interface (MediaStream) to record audio through the microphone on the terminal running the webpage, and the audio of the consultation between the customer and the service personnel is clearly and completely saved.
[0036] Step A4: Divide the consultation audio into multiple dialogue segments by distinguishing different audio lengths.
[0037] For example, by detecting changes in the consultation audio, such as the transition from silence to speech or speech to silence, the consultation audio can be segmented into multiple consecutive dialogue segments based on these changes.
[0038] Step A5: Use the pre-trained acoustic model to identify the role information corresponding to each dialogue segment.
[0039] For example, an acoustic model is obtained by training a deep neural network (e.g., a convolutional neural network CNN or a long short-term memory network LSTM) with a large amount of labeled speech data; each dialogue segment is input into the acoustic model to identify the phonemes and / or syllables in each dialogue segment, and the role of the person to which each dialogue segment belongs is determined based on the identification results.
[0040] Step A6: Use the pre-trained language model to convert each dialogue segment into corresponding text information.
[0041] For example, an N-Gram model or a neural network language model can be trained to obtain a language model. Each dialogue segment is then input into this language model to identify the phoneme and / or syllable sequences within each segment, converting them into corresponding words and sentences to form text information. Furthermore, to further improve recognition accuracy, the language model can be combined with a pre-defined vocabulary containing multiple standard words to more accurately convert each dialogue segment into corresponding text information.
[0042] Step A7: Based on the role information and text information of each dialogue segment, form a structured text format for the consultation service dialogue content.
[0043] It should also be noted that before the consultation service dialogue content is generated into a text format, the generated text information can be standardized; for example, removing noisy words, removing duplicate words, and correcting spelling errors.
[0044] Furthermore, step A7 specifically includes: Step A71: Set a unique role identifier for each role; Step A72: Traverse each dialogue segment in chronological order, generate an object for the currently traversed dialogue segment that includes a text key and a role key, and add the text information corresponding to the currently traversed dialogue segment as the value of the text key to the object, and add the role identifier corresponding to the role information of the currently traversed dialogue segment as the value of the role key, speaker, to the object.
[0045] In this embodiment, the MP3 format consultation audio is analyzed to first segment the audio into different dialogue segments, with each dialogue segment corresponding to a role (speaker). Then, the role of each dialogue segment is identified, followed by the conversion of each dialogue segment into corresponding text information. Finally, based on the role information and text information corresponding to each dialogue segment, a structured text-formatted consultation service dialogue content is formed and stored in the server. Preferably, the text-formatted consultation service dialogue content adopts JSON format.
[0046] This embodiment proposes a method for automatically recording audio, parsing text, and generating consultation details records. Through automated audio data parsing, the dialogue content can be quickly and efficiently converted into audio recordings and text files, providing strong support for various subsequent application scenarios.
[0047] Specifically, step S103, which generates a standard format consultation text based on the target keywords and the consultation service dialogue content, includes the following steps: Step B1: Based on the target keyword, obtain the keyword feature tags corresponding to the target keyword; Step B2: Obtain the consultation points based on the keyword feature tags and the target keywords.
[0048] The keyword feature tags are used to characterize the topic or category of the consultation points, and the target keywords are the specific values of the keyword feature tags.
[0049] In a feasible embodiment, corresponding keyword feature tags can be inferred from the target keywords. For example, multiple key point inference rules for forming consultation key points can be set in advance. One key point inference rule is used to form corresponding consultation key points based on one or more keywords. After the target keywords are determined from the consultation service dialogue content, each key point inference rule will be traversed in turn to determine whether there are target keywords associated with the currently traversed key point inference rule. If so, the corresponding consultation key points will be formed based on the associated target keywords and the currently traversed key point inference rule.
[0050] In another feasible embodiment, the keyword dictionary includes: keywords and keyword feature tags corresponding to the keywords; wherein, one keyword feature tag corresponds to one or more keywords. The above steps of generating standard format consultation text based on the target keywords and the consultation service dialogue content specifically include: matching the target keyword with the keyword dictionary, obtaining the corresponding keyword feature tags based on the matching results, and thus processing the target keyword and its corresponding keyword feature tags to obtain the consultation points.
[0051] Optionally, the keywords in the keyword dictionary are divided into: primary keywords and secondary keywords. The primary keywords are high-frequency words, and the secondary keywords are synonyms or near-synonyms of the corresponding primary keywords. Each primary keyword corresponds to one or more secondary keywords.
[0052] At this point, the step S102, which involves obtaining target keywords based on the consultation service dialogue content and a keyword dictionary corresponding to the consultation service, specifically includes: If the content of the consultation service dialogue matches a first-level keyword in the keyword dictionary, the matched first-level keyword will be used as the target keyword. If the content of the consultation service dialogue matches a secondary keyword in the keyword dictionary, then the primary keyword corresponding to the matched secondary keyword will be used as the target keyword.
[0053] In this embodiment, the keyword dictionary may include primary keywords and secondary keywords. In this case, the keyword feature tags are first deduced based on the target keywords included in the keyword dictionary and the preset key point reasoning rules. Then, the keyword feature tags and the target keywords are used to form a consultation key point in the form of key-value pairs.
[0054] In addition, the keyword dictionary may include: multiple keyword feature tags used to characterize the categories of consultation points, and multiple primary keywords corresponding to each keyword feature tag used to characterize the details of the consultation points. Furthermore, each primary keyword has multiple secondary keywords, and these secondary keywords are synonyms or near-synonyms of the corresponding primary keywords. For example, when the consultation service is skin management, the keyword feature tags in the keyword dictionary are: client skin type, client skin tone, client skincare needs, client contraindications (client precautions); the primary keywords for the keyword feature tag "client skin type" are: dry skin, oily skin, sensitive skin; the primary keywords for the keyword feature tag "client skin tone" are: white, yellow, dull; the primary keywords for the keyword feature tag "client skincare needs" are: hydrating, whitening, anti-aging; the secondary keywords for the primary keyword "dry skin" are: dry skin, dry, dehydrated, peeling; the secondary keywords for the primary keyword "white" are: fair, white skin; and the secondary keywords for the primary keyword "hydrating" are: dehydrated, moisturizing. It should be noted that the above is just an example of a keyword dictionary, and this embodiment does not specifically limit the content of the keyword dictionary.
[0055] In this embodiment, by using a multi-level keyword dictionary, target keywords can be efficiently and accurately identified from the content of the consultation service dialogue.
[0056] Furthermore, step S103 also includes the following steps: Step C1: Obtain preset key point reasoning rules; wherein, the key point reasoning rules are used to form consultation key points, and the key point reasoning rules are divided into trigger word reasoning rules and reverse reasoning rules.
[0057] Step C2: Iterate through each trigger word reasoning rule in turn, and determine whether the trigger word associated with the currently iterated trigger word reasoning rule is included in the consultation service dialogue content. If so, form a consultation point based on the included trigger word and the currently iterated trigger word reasoning rule.
[0058] Due to the limitations of keyword dictionaries, this embodiment also employs trigger word inference rules to supplement the method of forming consultation points through keyword dictionaries. The trigger word associated with the trigger word inference rule can be one or more, and the trigger word can also be a keyword from the keyword dictionary. For example, when the consultation service dialogue mentions "hydration," "dry skin," or "peeling," the formed consultation point is "Client skin type: dry skin"; when the consultation service dialogue mentions "dull skin," "pale," or "sallow," the formed consultation point is "Client skin tone: yellow"; when the consultation service dialogue mentions "winter" and "dry skin," the formed consultation point is "Client skincare needs: hydration"; when the consultation service dialogue mentions "sensitive" and "skin inflammation," the formed consultation points are "Skincare contraindications: irritating care" and "Skincare contraindications: strong light therapy."
[0059] Step C3: Iterate through each reverse reasoning rule in turn, and determine whether the consultation points associated with the currently iterated reverse reasoning rule have been formed. If so, form new consultation points based on the already formed consultation points and the currently iterated reverse reasoning rule.
[0060] In this embodiment, reverse reasoning rules can be used to form new consultation points based on the already determined consultation points. For example, when the already formed consultation point is "customer skincare need: hydration", a new consultation point "customer skin type: dry skin" can be formed; when the already formed consultation point is "customer skincare need: whitening", a new consultation point "customer skin tone: dull" can be formed; when the already formed consultation points are "customer skin type: dry skin" and "customer skin tone: yellow", a new consultation point "customer skincare need: whitening and hydration" can be formed; when the already formed consultation points are "customer skin type: sensitive" and "customer skincare need: hydration", a new consultation point "product type: gentle hydration" can be formed.
[0061] In this embodiment, key consultation points can be formed based on keywords appearing in the consultation service dialogue, and new key consultation points can be formed based on existing key consultation points; thus, key information can be extracted more comprehensively from the consultation service dialogue content, avoiding omissions and errors in information.
[0062] Furthermore, step S103 also includes the following steps: Step D1: Based on all the identified target keywords, all consultation points, and the content of the consultation service dialogue, generate consultation details; Step D2: Combine all identified consultation points and consultation details into the standard format consultation text.
[0063] In this embodiment, the identified target keywords, extracted consultation points, and consultation service dialogue content are summarized and organized according to different dimensions to form a structured summary that is easy for customer service personnel to quickly understand. This summary is then filled into the consultation record page according to a fixed format, thereby improving the work efficiency of customer service personnel. For example, when the consultation service is for skin management, the target keywords related to skin management are first obtained from the consultation service dialogue content based on the keyword dictionary corresponding to skin management: such as dry skin, dullness, and moisturizing. Then, by matching the obtained target keywords with the keyword dictionary, keyword feature tags for skin type, skin tone, and skin care needs are obtained. Finally, the following consultation points are obtained: skin type - dry skin, skin tone - yellow, skin care needs - hydration. Afterwards, based on the target keywords and consultation points, the consultation service dialogue content is summarized to form consultation details: such as, the user's skin has recently become dry and dull, and they want to know about skin care information on hydration and moisturizing.
[0064] Furthermore, step S103 also includes the following steps: Step E1: Obtain a preset product knowledge graph; wherein, the product knowledge graph includes: multiple product categories, and each product category has a corresponding category dictionary, the category fields of which include at least one of the following: product item, usage scenario, precautions; the product knowledge graph also includes: project dictionary for each product item under each product category, the project dictionary including at least one of the following: project scope of application, project efficacy, project contraindications, project cycle, project cost.
[0065] For example, when the consultation service is skin management, the product categories in the product knowledge graph are: laser, intense pulsed light, chemical peel, radiofrequency, injection & filler; the category dictionary for "radiofrequency" includes: (1) Product items: Thermage, microneedle radiofrequency, (2) Usage scenarios: skin tightening and wrinkle removal, acne pit and scar repair, fat reduction and body shaping and rejuvenation, (3) Precautions: not suitable for heart disease patients, pregnant women, and those with metal implants. Before the procedure, the skin needs to be kept clean and avoid irritating skin care products. After the procedure, the skin needs to be kept moisturized and avoid high temperature environments. In addition, the project dictionary for the product item "CC light" includes: (1) Project application scope: brightening skin, removing pigmentation, shrinking pores, (2) Maintenance effect: 3-6 months, (3) Recovery period: 2-5 days, (4) Contraindications: sun exposure, sauna, use of exfoliating products. In the medical aesthetics field, product knowledge graphs mainly involve deep learning of medical aesthetics content such as commonly used medical aesthetics terms, the therapeutic effects of medical aesthetics products, the contraindications of medical aesthetics products, and the applicable scenarios of medical aesthetics products, to form a complete knowledge graph.
[0066] Step E2: Based on all the identified consultation points, determine the target product category and target product item from the product knowledge graph.
[0067] Step E3: Generate product category descriptions based on the category dictionary of the target product category, and generate product item descriptions based on the item dictionary of the target product item.
[0068] In this embodiment, product solutions are suggested and reminded through a trained large model and product knowledge graph. For example, if a customer mentions the keyword "CC light" in the consultation service dialogue, or if the customer service staff introduces CC light as a medical aesthetic treatment, then the customer needs to be reminded of the following product project introduction, which is then displayed on the consultation record page in real time: The product project introduction is as follows: Laser-classified project, commonly used to brighten skin, remove pigmentation, and shrink pores. The project name includes CC light, etc. The effect lasts for 3-6 months, and the recovery period is 2-5 days. After the procedure, it is not suitable to sunbathe, take saunas, or use exfoliating products. If the skin has trauma or inflammation, or if the patient is pregnant or breastfeeding, CC light is not suitable.
[0069] Step E4: Add the product category description and the product project description to the standard format consultation text.
[0070] In this embodiment, a targeted product recommendation plan can be formed based on the content of the consultation service dialogue and the identified consultation points, thereby improving the professionalism of customer service personnel and simplifying their work.
[0071] In this embodiment, as Figure 2As shown, the consultation service dialogue is first recorded through the browser, and the audio is clearly and completely saved; then the dialogue content in the audio is analyzed, the dialogue content is extracted, the dialogue roles are distinguished, the dialogue outline and other element data are extracted, and the extracted data is converted into a common JSON format; finally, the JSON format data is pushed to the corresponding consultation record page for display; this embodiment has the following beneficial effects: (1) high degree of automation, no manual intervention is required to complete the conversion; (2) fast conversion speed, which can greatly improve efficiency; (3) accurate conversion results, complete audio element data; (4) output of a common data format, with a wide range of applications.
[0072] Example 2 This invention provides a consultation text generation device, such as... Figure 3 As shown, the device specifically includes the following components: The acquisition module 301 is used to acquire the consultation service dialogue content between customers and service personnel; The query module 302 is used to obtain target keywords based on the content of the consultation service dialogue and the keyword dictionary corresponding to the consultation service; The generation module 303 is used to generate a standard format consultation text based on the target keywords and the consultation service dialogue content; wherein the standard format consultation text includes consultation points and consultation details.
[0073] Specifically, the generation module 303 is used for: Based on the target keywords, obtain the keyword feature tags corresponding to the target keywords; The key points of consultation are obtained based on the keyword feature tags and the target keywords.
[0074] Furthermore, the keyword dictionary includes: keywords, and keyword feature tags corresponding to the keywords.
[0075] Furthermore, the keyword dictionary includes: primary keywords and secondary keywords, wherein the primary keywords are high-frequency words, and the secondary keywords are synonyms or near-synonyms of the corresponding primary keywords.
[0076] At this time, the query module 302 is specifically used for: If the content of the consultation service dialogue matches a first-level keyword in the keyword dictionary, the matched first-level keyword will be used as the target keyword. If the content of the consultation service dialogue matches a secondary keyword in the keyword dictionary, then the primary keyword corresponding to the matched secondary keyword will be used as the target keyword.
[0077] In addition, the generation module 303 is also specifically used for: Obtain preset key point reasoning rules; wherein, the key point reasoning rules are used to form consultation key points, and the key point reasoning rules are divided into trigger word reasoning rules and reverse reasoning rules; Each trigger word reasoning rule is traversed sequentially. It is determined whether the trigger word associated with the currently traversed trigger word reasoning rule is included in the consultation service dialogue content. If so, a consultation point is formed based on the included trigger word and the currently traversed trigger word reasoning rule. Iterate through each reverse reasoning rule in turn, and determine whether the consultation point associated with the currently traversed reverse reasoning rule has been formed. If so, form a new consultation point based on the already formed consultation point and the currently traversed reverse reasoning rule.
[0078] Furthermore, the generation module 303 is also specifically used for: Consultation details are generated based on all identified target keywords, all key consultation points, and the content of the consultation service dialogue. All identified consultation points and consultation details are compiled into the standard consultation text.
[0079] Furthermore, the generation module 303 is also specifically used for: Obtain a preset product knowledge graph; wherein, the product knowledge graph includes: multiple product categories, with a corresponding category dictionary set for each product category, and an item dictionary for each product item under each product category; Based on all the identified consultation points, the target product category and target product item are determined from the product knowledge graph; A product category introduction is generated based on the category dictionary of the target product category, and a product item introduction is generated based on the item dictionary of the target product item; Add the product category description and the product project description to the standard format consultation text.
[0080] Preferably, if the consultation service is skin management, the consultation points include at least one of the following: skin type, skin tone, and skin care needs.
[0081] In this embodiment, key information in the dialogue is accurately identified through keyword dictionary matching. Then, using a preset standard format, core consultation points such as the customer's basic information, needs, and precautions can be further extracted. Finally, standard format consultation text is automatically generated based on these consultation points. This not only significantly improves the accuracy and efficiency of consultation records but also effectively avoids omissions and errors that may occur with manual recording. Furthermore, this method has wide applications, suitable for various customer service hotlines, sales consultations, and other scenarios, helping businesses better understand customer needs and improve service quality.
[0082] Example 3 This embodiment also provides a computer device, such as a smartphone, tablet computer, laptop computer, desktop computer, rack server, blade server, tower server, or cabinet server (including a standalone server or a server cluster composed of multiple servers), etc., capable of executing programs. Figure 4 As shown, the computer device 40 in this embodiment includes, but is not limited to, a memory 401 and a processor 402 that are communicatively connected to each other via a system bus. It should be noted that... Figure 4 Only a computer device 40 with components 401-402 is shown; however, it should be understood that it is not required to implement all of the components shown, and more or fewer components may be implemented instead.
[0083] In this embodiment, the memory 401 (i.e., the readable storage medium) includes flash memory, hard disk, multimedia card, card-type memory (e.g., SD or DX memory), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, the memory 401 may be an internal storage unit of the computer device 40, such as the hard disk or memory of the computer device 40. In other embodiments, the memory 401 may also be an external storage device of the computer device 40, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc., equipped on the computer device 40. Of course, the memory 401 may include both the internal storage unit and its external storage device of the computer device 40. In this embodiment, the memory 401 is typically used to store the operating system and various application software installed on the computer device 40. In addition, the memory 401 may also be used to temporarily store various types of data that have been output or will be output.
[0084] In some embodiments, processor 402 may be a central processing unit (CPU), controller, microcontroller, microprocessor, or other data processing chip. This processor 402 is typically used to control the overall operation of computer device 40.
[0085] Specifically, in this embodiment, the processor 402 is used to execute the program for the consultation text generation method stored in the memory 401. When the program for the consultation text generation method is executed, it performs the following steps: Obtain the content of consultation service conversations between customers and service personnel; Based on the content of the consultation service dialogue and the keyword dictionary corresponding to the consultation service, the target keywords are obtained; Based on the target keywords and the consultation service dialogue content, a standard format consultation text is generated; wherein, the standard format consultation text includes consultation points and consultation details.
[0086] For a detailed description of the above method steps, please refer to Example 1. This example will not be repeated here.
[0087] Example 4 This embodiment also provides a computer-readable storage medium, such as flash memory, hard disk, multimedia card, card-type memory (e.g., SD or DX memory), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, disk, optical disk, server, app store, etc., which stores a computer program. When the computer program is executed by a processor, it implements the following method steps: Obtain the content of consultation service conversations between customers and service personnel; Based on the content of the consultation service dialogue and the keyword dictionary corresponding to the consultation service, the target keywords are obtained; Based on the target keywords and the consultation service dialogue content, a standard format consultation text is generated; wherein, the standard format consultation text includes consultation points and consultation details.
[0088] For a detailed description of the above method steps, please refer to the first embodiment. This embodiment will not repeat the details here.
[0089] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.
[0090] The sequence numbers of the above embodiments of the present invention are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0091] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method.
[0092] The above are merely preferred embodiments of the present invention and do not limit the patent scope of the present invention. Any equivalent structural or procedural transformations made based on the content of the present invention's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of the present invention.
Claims
1. A method for generating consultation text, characterized in that, The method includes: Obtain the content of consultation service conversations between customers and service personnel; Based on the content of the consultation service dialogue and the keyword dictionary corresponding to the consultation service, the target keywords are obtained; Based on the target keywords and the consultation service dialogue content, a standard format consultation text is generated; wherein, the standard format consultation text includes consultation points and consultation details.
2. The consultation text generation method according to claim 1, characterized in that, The step of generating a standard-format consultation text based on the target keywords and the consultation service dialogue content specifically includes: Based on the target keywords, obtain the keyword feature tags corresponding to the target keywords; The key points of consultation are obtained based on the keyword feature tags and the target keywords.
3. The consultation text generation method according to claim 2, characterized in that, The keyword dictionary includes keywords and keyword feature tags corresponding to the keywords.
4. The consultation text generation method according to claim 2 or 3, characterized in that, The keyword dictionary includes: primary keywords and secondary keywords, wherein the primary keywords are high-frequency words, and the secondary keywords are synonyms or near-synonyms of the corresponding primary keywords; The step of obtaining target keywords based on the consultation service dialogue content and the corresponding keyword dictionary includes: If the content of the consultation service dialogue matches a first-level keyword in the keyword dictionary, the matched first-level keyword will be used as the target keyword. If the content of the consultation service dialogue matches a secondary keyword in the keyword dictionary, then the primary keyword corresponding to the matched secondary keyword will be used as the target keyword.
5. The consultation text generation method according to claim 1, characterized in that, The step of generating a standard-format consultation text based on the target keywords and the consultation service dialogue content specifically includes: Obtain preset key point reasoning rules; wherein, the key point reasoning rules are used to form consultation key points, and the key point reasoning rules are divided into trigger word reasoning rules and reverse reasoning rules; Each trigger word reasoning rule is traversed sequentially. It is determined whether the trigger word associated with the currently traversed trigger word reasoning rule is included in the consultation service dialogue content. If so, a consultation point is formed based on the included trigger word and the currently traversed trigger word reasoning rule. Iterate through each reverse reasoning rule in turn, and determine whether the consultation point associated with the currently traversed reverse reasoning rule has been formed. If so, form a new consultation point based on the already formed consultation point and the currently traversed reverse reasoning rule.
6. The consultation text generation method according to claim 1, characterized in that, The step of generating a standard-format consultation text based on the target keywords and the consultation service dialogue content also includes: Obtain a preset product knowledge graph; wherein, the product knowledge graph includes: multiple product categories, with a corresponding category dictionary set for each product category, and an item dictionary for each product item under each product category; Based on all the identified consultation points, the target product category and target product item are determined from the product knowledge graph; A product category introduction is generated based on the category dictionary of the target product category, and a product item introduction is generated based on the item dictionary of the target product item; Add the product category description and the product project description to the standard format consultation text.
7. The consultation text generation method according to claim 1, characterized in that, If the consultation service is skin management, the consultation points include at least one of the following: skin type, skin tone, and skin care needs.
8. A consultation text generation device, characterized in that, The device includes: The acquisition module is used to acquire the content of consultation service dialogues between customers and service personnel; The query module is used to obtain target keywords based on the content of the consultation service dialogue and a keyword dictionary corresponding to the consultation service; The generation module is used to generate a standard format consultation text based on the target keywords and the consultation service dialogue content; wherein, the standard format consultation text includes consultation points and consultation details.
9. A computer device, the computer device comprising: A memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that the processor, when executing the computer program, implements the steps of the method according to any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 7.