Session quality inspection method and device, equipment, storage medium and program product
By constructing a message queue and using sensitive word matching strategies and multi-dimensional vector features to update risk levels, the problem of false positives and false negatives in existing intelligent quality inspection is solved, achieving high accuracy and reliability of session quality inspection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SHANGHAI PUDONG DEVELOPMENT BANK
- Filing Date
- 2025-11-26
- Publication Date
- 2026-04-10
AI Technical Summary
Existing intelligent quality inspection methods suffer from misjudgments and omissions, resulting in low accuracy of inspection results.
By identifying the messages to be inspected and their associated messages from the target session, a message queue is constructed. The initial risk level is updated using a set of sensitive word matching strategies and multi-dimensional vector features to determine the target risk level and finally the session quality inspection result.
It improves the accuracy and reliability of session quality inspection by integrating contextual information from multi-dimensional vector features to accurately assess risk levels, thereby enhancing the scientific rigor and comprehensiveness of the inspection results.
Smart Images

Figure CN121836451A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of natural language processing technology, and in particular to a conversation quality inspection method, apparatus, computer equipment, computer-readable storage medium, and computer program product. Background Technology
[0002] As a core component of customer service quality management, conversation quality inspection has undergone a leapfrog development from manual sampling to automated quality inspection.
[0003] Early manual quality inspection relied on inspectors listening to recorded calls or reading written transcripts to subjectively assess service compliance. With breakthroughs in natural language processing and machine learning technologies, intelligent quality inspection can effectively solve the problems of high cost, low efficiency, and low accuracy associated with manual sampling.
[0004] However, existing intelligent quality inspection methods still have problems with misjudgment and omission, resulting in a low accuracy rate of quality inspection results. Summary of the Invention
[0005] Therefore, it is necessary to provide a session quality inspection method, apparatus, computer equipment, computer-readable storage medium, and computer program product that can improve the accuracy of quality inspection in response to the above-mentioned technical problems.
[0006] Firstly, this application provides a session quality inspection method, the method comprising:
[0007] The message to be inspected and at least one associated message associated with the message to be inspected are determined from multiple candidate messages included in the target session, and a message queue is determined based on the message to be inspected and the at least one associated message.
[0008] The initial risk level of the message to be inspected is determined based on the set of sensitive word matching strategies and the target sensitive words in the message to be inspected; the set of sensitive word matching strategies includes the mapping relationship between different associated sensitive words and risk levels;
[0009] The message queue is parsed to obtain structured semantic features, and the structured semantic features and the message queue are encoded to obtain multi-dimensional vector features of the message queue;
[0010] The initial risk level is updated based on the multi-dimensional vector features and the set of sensitive word matching strategies to obtain the target risk level;
[0011] Based on the target risk level, the session quality inspection result of the message to be inspected is determined.
[0012] In one embodiment, determining the initial risk level of the message to be inspected based on the sensitive word matching strategy set and the sensitive words in the message to be inspected includes:
[0013] Determine the session context associated with the target session;
[0014] Obtain a set of sensitive word matching strategies, and determine at least one candidate matching strategy from the set of sensitive word matching strategies based on the session scenario;
[0015] For each target sensitive word in the message to be inspected, the target sensitive word is matched with the associated sensitive words included in the at least one candidate matching strategy to obtain the candidate risk level of the target sensitive word.
[0016] The initial risk level of the message to be inspected is obtained based on the candidate risk level of each of the target sensitive words.
[0017] In one embodiment, updating the initial risk level based on the multi-dimensional vector features and the sensitive word matching strategy set to obtain the target risk level includes:
[0018] For each of the candidate matching strategies, feature encoding is performed on at least one associated sensitive word included in the targeted candidate matching strategy to obtain sensitive word vector features;
[0019] Based on the multi-dimensional vector features and the sensitive word vector features, determine the level update method for the initial risk level;
[0020] Based on the level update method determined by each of the at least one candidate matching strategy, the initial risk level is updated to obtain the target risk level.
[0021] In one embodiment, parsing the message queue to obtain structured semantic features, and encoding the structured semantic features and the message queue to obtain multi-dimensional vector features of the message queue, includes:
[0022] The message queue is parsed to obtain object information, semantic relationship information, and risk word information in the message queue;
[0023] The object information, the semantic relationship information, the risk word information, and the message queue are feature-encoded to obtain the multi-dimensional vector features of the message queue.
[0024] In one embodiment, determining the message to be inspected and at least one associated message associated with the message to be inspected from multiple candidate messages included in the target session, and determining the message queue based on the message to be inspected and the at least one associated message, includes:
[0025] Obtain the target session; the target session includes multiple candidate messages;
[0026] If the target session meets the quality inspection triggering conditions, the message to be inspected is determined from the multiple candidate messages;
[0027] Determine the message interception window, and determine at least one associated message from the multiple candidate messages that is related to the message to be inspected according to the message interception window;
[0028] Based on the time information of the message to be inspected and the at least one associated message, the message to be inspected and the at least one associated message are combined to form a message queue.
[0029] In one embodiment, the method further includes:
[0030] If the session quality inspection result meets the risk review triggering condition, the risk confidence level of the session quality inspection result is determined based on the message to be inspected, the message queue, and the session quality inspection result.
[0031] The confidence level of the session quality inspection results is determined based on the risk confidence level.
[0032] The session quality inspection results are reviewed according to the review method corresponding to the quality inspection confidence level.
[0033] Secondly, this application also provides a session quality inspection device, the device comprising:
[0034] The message queue construction module is used to determine the message to be inspected and at least one associated message associated with the message to be inspected from multiple candidate messages included in the target session, and to determine the message queue based on the message to be inspected and the at least one associated message;
[0035] The risk level determination module is used to determine the initial risk level of the message to be inspected based on the sensitive word matching strategy set and the target sensitive words in the message to be inspected; the sensitive word matching strategy set includes the mapping relationship between different associated sensitive words and risk levels;
[0036] A semantic feature encoding module is used to parse the message queue to obtain structured semantic features, and to encode the structured semantic features and the message queue to obtain multi-dimensional vector features of the message queue.
[0037] The risk level update module is used to update the initial risk level based on the multi-dimensional vector features and the sensitive word matching strategy set to obtain the target risk level;
[0038] The quality inspection result generation module is used to determine the session quality inspection result of the message to be inspected based on the target risk level.
[0039] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of the method described above.
[0040] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method described above.
[0041] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the method described above.
[0042] The aforementioned session quality inspection method, apparatus, computer equipment, computer-readable storage medium, and computer program product determine the message to be inspected and at least one associated message from multiple candidate messages included in the target session, and determine a message queue based on the message to be inspected and at least one associated message; determine the initial risk level of the message to be inspected according to a set of sensitive word matching strategies and target sensitive words in the message to be inspected; the set of sensitive word matching strategies includes the mapping relationship between different associated sensitive words and risk levels; parse the message queue to obtain structured semantic features, and encode the structured semantic features and the message queue to obtain multi-dimensional vector features of the message queue; update the initial risk level based on the multi-dimensional vector features and the set of sensitive word matching strategies to obtain the target risk level; and determine the session quality inspection result of the message to be inspected based on the target risk level. By identifying the related messages preceding and following the message to be inspected, a message queue is obtained. The message queue is then parsed and encoded to obtain multi-dimensional vector features. These multi-dimensional vector features are combined with a pre-configured set of sensitive word matching strategies to update the initial risk level of the message and obtain the target risk level. This method can integrate multi-dimensional features, including contextual information, from the multi-dimensional vector features, making the risk level assessment more accurate. Finally, the session quality inspection result is determined based on the target level, which can effectively improve the accuracy and reliability of session quality inspection. Attached Figure Description
[0043] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0044] Figure 1 This is a diagram illustrating the application environment of a session quality inspection method in one embodiment.
[0045] Figure 2 This is a flowchart illustrating a session quality inspection method in one embodiment;
[0046] Figure 3 This is a flowchart illustrating the steps for determining the initial risk level in one embodiment;
[0047] Figure 4 This is a structural block diagram of a session quality inspection device in one embodiment;
[0048] Figure 5 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation
[0049] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.
[0050] It should be noted that the terms "first," "second," etc., used in this application can be used to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish the first element from the second element. The terms "comprising" and "having," and any variations thereof, used in this application, are intended to cover non-exclusive inclusion. The term "multiple" used in this application refers to two or more. The term "and / or" used in this application refers to one of the embodiments, or any combination of multiple embodiments.
[0051] In related technologies, sensitive words are typically presented as static lists during conversation quality inspection, and matched according to fixed rules. Sensitive words are usually categorized by business type, industry standards, or company-wide standards. These rules are simple: user-sent messages are compared against the sensitive word database one by one, and a match is considered a violation. This lack of differentiated sensitive word matching rules results in poor flexibility. Furthermore, matching usually only processes individual messages, lacking an understanding of the overall conversation context. An alert is triggered as soon as a message contains a sensitive word, regardless of the surrounding context or any risk warnings, leading to inaccurate risk assessment. Moreover, updates to the sensitive word database are mostly manual, making it difficult to quickly respond to business changes or emerging risks. In addition, most systems only provide notifications or generate reports for detected violations, lacking automated processing capabilities such as account freezing, risk escalation, or work order management. The entire process requires manual intervention, resulting in a large amount of manual review and insufficient automation.
[0052] The session quality inspection method provided in this application can be applied to, for example... Figure 1 In the application environment shown, terminal 102 communicates with server 104 via a network. A data storage system can store the data that server 104 needs to process. The data storage system can be integrated onto server 104 or placed on a cloud or other network server. Users can initiate a session quality inspection request to server 104 through terminal 102. Server 104, based on this request, retrieves session data from the backend of various interactive platforms via a data interface. After identifying the target session from the session data, it can determine the message to be inspected and at least one associated message from multiple candidate messages included in the target session. Based on the message to be inspected and at least one associated message, a message queue is determined. Then, server 104 can determine the initial risk level of the message to be inspected based on the sensitive word matching strategy set and the target sensitive words in the message to be inspected. The sensitive word matching strategy set includes the mapping relationship between different associated sensitive words and risk levels; the server 104 then parses the message queue to obtain structured semantic features, and encodes the structured semantic features and the message queue to obtain multi-dimensional vector features of the message queue; the server 104 can update the initial risk level based on the multi-dimensional vector features and the sensitive word matching strategy set to obtain the target risk level; and based on the target risk level, determine the session quality inspection result of the message to be inspected. After obtaining the session quality inspection result, the server 104 can return the session quality inspection result to the terminal 102.
[0053] Terminal 102 can be, but is not limited to, various personal computers, laptops, smartphones, tablets, drones, low-altitude aircraft, IoT devices, and portable wearable devices. IoT devices can include smart speakers, smart TVs, smart air conditioners, smart in-vehicle devices, and projection equipment. Portable wearable devices can include smartwatches, smart bracelets, and head-mounted displays. Head-mounted displays can be virtual reality (VR) devices, augmented reality (AR) devices, and smart glasses. Server 104 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services.
[0054] In one exemplary embodiment, such as Figure 2 As shown, a session quality inspection method is provided, which is applied to... Figure 1 Taking server 104 as an example, the explanation includes the following steps 202 to 210. Wherein:
[0055] Step 202: Determine the message to be inspected and at least one associated message from the multiple candidate messages included in the target session, and determine the message queue based on the message to be inspected and at least one associated message.
[0056] In this context, a target session refers to a dialogue in a communication or interaction scenario that requires quality inspection. A target session can be a chat conversation, a phone call record, or an online customer service interaction. It may include multiple messages, i.e., candidate messages, which can be information sent or received by users or customer service representatives during the session. A message to be inspected refers to a specific message identified from the candidate messages that requires quality inspection. This message is the object of the quality inspection process; by analyzing it, we can determine whether it poses a risk. Related messages refer to other messages that are semantically or contextually related to the message to be inspected. A message queue is a sequence consisting of the message to be inspected and at least one associated message arranged in a specific order. In practice, the message queue can carry information such as the sender's identity (e.g., customer / employee role), timestamp, and message type for each message.
[0057] For example, a user or system can initiate a session quality inspection request to the server. Based on this request, the server can retrieve session data from the backend of various interactive platforms via a data interface and determine the target session from the session data. The server can identify multiple candidate messages included in the target session and determine the message to be inspected from these candidate messages according to preset conditions. For example, the server can determine the message to be inspected from multiple candidate messages based on certain triggering conditions, or it can determine the message to be inspected from multiple candidate messages based on preset priority rules. After determining the message to be inspected, the server can further determine at least one associated message related to the message to be inspected based on semantic relevance, temporal relevance, etc. For example, the server can determine a certain number of messages before and after the message to be inspected as associated messages based on temporal relevance, or the server can determine a certain number of messages that are semantically related to the message to be inspected as associated messages based on semantic relevance. Then, the server can determine the message queue based on the message to be inspected and at least one related message; for example, the server can arrange the messages in chronological order to form a message sequence, or the server can arrange the messages in descending order of semantic relevance to form a message sequence.
[0058] Step 204: Determine the initial risk level of the message to be inspected based on the sensitive word matching strategy set and the target sensitive words in the message to be inspected.
[0059] The sensitive word matching strategy set refers to a predefined set of matching strategies, which includes the mapping relationship between different associated sensitive words and risk levels. Sensitive words are words that may cause risks, violations, or adverse effects in a conversational context. Associated sensitive words are the sensitive words configured in the sensitive word matching strategy set that may exist during the conversation, and target sensitive words are the sensitive words appearing in the message to be inspected. In specific implementation, the sensitive word matching strategy set can include multiple sensitive word matching strategies, each corresponding to a different mapping relationship between associated sensitive words and risk levels. For example, in a financial industry customer service system, for a certain sensitive word matching strategy, its associated sensitive words may include, but are not limited to, "guaranteed profit" and "no loss," corresponding to a risk level of 0.9; for another sensitive word matching strategy, its associated sensitive words may include, but are not limited to, "guarantee" and "guarantee," corresponding to a risk level of 0.5. Thus, the mapping relationship between different associated sensitive words and risk levels can be obtained, and combined to form the sensitive word matching strategy set.
[0060] Risk level refers to the degree of risk corresponding to a sensitive word. In practice, risk level can be represented by weights, such as 1 representing the highest risk level and 0 representing the lowest risk level. By defining the correspondence between sensitive words (i.e., associated sensitive words) and risk levels, the risk level of a message to be inspected containing the target sensitive word can be quickly determined. The initial risk level refers to the preliminary risk level of the message to be inspected, determined based on the sensitive word matching strategy set and the target sensitive word in the message to be inspected. The initial risk level is determined based on the risk level of the sensitive word itself.
[0061] For example, the server can obtain a pre-built set of sensitive word matching strategies and identify target sensitive words in the message to be inspected. Then, the server can determine the initial risk level of the message to be inspected based on the mapping relationship between different associated sensitive words and risk levels in the set of sensitive word matching strategies and the target sensitive words in the message to be inspected.
[0062] Step 206: Parse the message queue to obtain structured semantic features, and encode the structured semantic features and the message queue to obtain the multi-dimensional vector features of the message queue.
[0063] Structured semantic features refer to the semantically meaningful structured feature information extracted from the message queue through parsing. Structured semantic features can reflect the semantic content, logical relationships, and sentiment of messages in the message queue. Multi-dimensional vector features are vector representations obtained by encoding the structured semantic features and the message queue. Multi-dimensional vector features have multiple dimensions, each representing a specific aspect of the message queue's characteristics. Thus, multi-dimensional vector features can comprehensively and accurately describe the characteristics of the message queue.
[0064] For example, the server can parse the message queue to obtain structured semantic features. For instance, the server can invoke a natural language processing component to parse the message queue and obtain structured semantic features, which may include, but are not limited to, object information, semantic relationship information, and risk word information within the message queue. After obtaining the structured semantic features, the server can jointly encode the structured semantic features and the message queue to obtain multi-dimensional vector features of the message queue.
[0065] Step 208: Update the initial risk level based on multi-dimensional vector features and a set of sensitive word matching strategies to obtain the target risk level.
[0066] The target risk level refers to the risk level obtained after updating the initial risk level based on multi-dimensional vector features and a set of sensitive word matching strategies. Compared with the initial risk level, the target risk level comprehensively considers sensitive words and various factors such as context and semantics in the message queue, and can more accurately reflect the actual risk level of the message to be inspected. For example, if the message to be inspected in a financial customer service conversation contains the high-risk sensitive word "guaranteed profit," but after combining the multi-dimensional vector features of the context, the customer service provides a clear and effective risk warning, then the weight of the initial risk level can be reduced to obtain the target risk level.
[0067] For example, the server can determine whether there are risk warning statements that can reduce the risk level based on multi-dimensional vector features and a set of sensitive word matching strategies, and update the initial risk level based on the risk warning statements to obtain the target risk level.
[0068] Step 210: Determine the session quality inspection result of the message to be inspected based on the target risk level.
[0069] The session quality inspection result refers to the conclusion drawn after judging the quality of the messages to be inspected based on the target risk level. This result can be used to assess session quality, identify potential problems, and take corresponding measures (such as reminding customer service to improve, or penalizing violations). For example, if the target risk level has a weight of 0.2, it might be determined that the messages to be inspected in this financial customer service session have some risk, but have not yet reached the level of serious violation. The customer service representative should be reminded to pay more attention to the accuracy and professionalism of their responses.
[0070] For example, the server can divide the risk level into multiple weight intervals based on the weight of the risk level. Each weight interval can correspond to a session quality inspection result. The server can determine the weight interval to which the target risk level belongs based on the weight of the target risk level in order to match and obtain the corresponding session quality inspection result.
[0071] In the aforementioned session quality inspection method, the following steps are taken: First, the message to be inspected and at least one associated message are determined from multiple candidate messages in the target session. Then, a message queue is determined based on the message to be inspected and at least one associated message. Next, the initial risk level of the message to be inspected is determined according to a set of sensitive word matching strategies and target sensitive words in the message to be inspected. The set of sensitive word matching strategies includes mapping relationships between different associated sensitive words and risk levels. The message queue is parsed to obtain structured semantic features, and these features and the message queue are encoded to obtain multi-dimensional vector features of the message queue. The initial risk level is updated based on the multi-dimensional vector features and the set of sensitive word matching strategies to obtain the target risk level. Finally, the session quality inspection result of the message to be inspected is determined based on the target risk level. By identifying the related messages preceding and following the message to be inspected, a message queue is obtained. The message queue is then parsed and encoded to obtain multi-dimensional vector features. These multi-dimensional vector features are combined with a pre-configured set of sensitive word matching strategies to update the initial risk level of the message and obtain the target risk level. This method can integrate multi-dimensional features, including contextual information, from the multi-dimensional vector features, making the risk level assessment more accurate. Finally, the session quality inspection result is determined based on the target level, which can effectively improve the accuracy and reliability of session quality inspection.
[0072] In one embodiment, such as Figure 3 As shown, based on the sensitive word matching strategy set and the sensitive words in the message to be inspected, the initial risk level of the message to be inspected is determined, including:
[0073] Step 302: Determine the session scenario associated with the target session.
[0074] In this context, "conversation scenario" refers to the specific background, environment, and situation in which the target conversation occurs. Conversation scenarios can include, but are not limited to, conversation roles and conversation types. Conversation roles refer to the different entities participating in the communication within the target conversation; for example, conversation roles can include, but are not limited to, users, customers, customer service representatives, and administrators. Different conversation roles have different responsibilities and behavioral patterns within the conversation, and these differences can affect the content and risk level of the messages. Conversation type refers to the classification of the target conversation based on its topic, purpose, or business scenario. Conversation type helps identify potentially sensitive words and risk situations that may appear in the conversation, thus enabling more targeted quality control. For example, financial customer service conversations can be categorized into product recommendations, after-sales complaints, and order inquiries.
[0075] For example, the server can obtain information such as the sender's identity and message type carried in each message in the target session to determine the session scenario associated with the target session.
[0076] Step 304: Obtain a set of sensitive word matching strategies and determine at least one candidate matching strategy from the set of sensitive word matching strategies based on the conversation scenario.
[0077] In this context, a candidate matching strategy refers to a specific matching strategy selected from a set of sensitive word matching strategies based on the conversation scenario associated with the target conversation. Each candidate matching strategy includes at least one associated sensitive word related to the conversation scenario; specifically, it includes at least one associated sensitive word related to the conversation role and conversation type. These associated sensitive words are those that may appear for a specific role and conversation type. For example, in a financial customer service conversation, if the conversation roles are a VIP (Very Important Person) customer and a financial advisor, and the conversation type is financial product recommendation, then the candidate matching strategies selected from the set of sensitive word matching strategies could include sensitive words related to product recommendation, such as "guaranteed profit" and "no loss," along with the corresponding risk levels. In practice, different sensitive words in the same conversation scenario will have different risk levels, and the same sensitive words in different conversation scenarios will also have different risk levels. For instance, in conversations where a financial advisor is recommending financial products to a VIP customer and a regular customer, different risk levels can be configured for risky words like "guaranteed profit" and "no loss" due to the different conversation roles.
[0078] For example, the server can obtain a pre-configured set of sensitive word matching strategies and determine at least one candidate matching strategy from the set of sensitive word matching strategies based on the session scenario. For instance, the server can determine the session role and session type of the target session, and select at least one sensitive word matching strategy corresponding to the session role and session type of the target session from the set of sensitive word matching strategies as a candidate matching strategy.
[0079] In an optional embodiment, the sensitive word matching strategy set includes multiple pre-configured sensitive word matching strategies. Each sensitive word matching strategy can be associated with four dimensions: session role, session type, sensitive word, and risk level. When determining candidate matching strategies, the server can perform matching according to a multi-level index structure. For example, the server can find the sensitive word matching strategy that matches the session role of the target session from multiple sensitive word matching strategies, and then find the sensitive word matching strategy that matches the session type from the sensitive word matching strategies that match the session role, thus obtaining candidate matching strategies.
[0080] Step 306: For each target sensitive word in the message to be inspected, match the target sensitive word with at least one related sensitive word included in the candidate matching strategy to obtain the candidate risk level of the target sensitive word.
[0081] The message to be inspected may include multiple target sensitive words. In the same session scenario, different target sensitive words may have different risk levels. The candidate risk level refers to the risk level corresponding to each target sensitive word.
[0082] For example, for each candidate matching strategy, the server can identify at least one target sensitive word included in the message to be inspected. For each target sensitive word in the message to be inspected, the server can match the target sensitive word with the associated sensitive words in each candidate matching strategy one by one. During matching, the server can match according to fixed rules. If the target sensitive word and the associated sensitive words are completely identical, the match is considered successful. The server can also match the target sensitive word and the associated sensitive words according to semantic similarity. For example, the semantic similarity between the target sensitive word and each associated sensitive word can be calculated separately. Semantic similarity can be implemented using Euclidean distance or cosine similarity. The server can consider the associated sensitive word with the highest semantic similarity to be a successful match with the target sensitive word. Then, the server can determine the risk level corresponding to the successfully matched associated sensitive words as the candidate risk level of the target sensitive word.
[0083] In one optional embodiment, when determining the target sensitive words included in the message to be inspected, the server can first segment the message. For example, the server can use a dictionary-based segmentation algorithm (such as forward maximum matching, backward maximum matching, bidirectional maximum matching, etc.) to segment the message, obtaining multiple independent words. Then, the server can match each word with a preset set of sensitive words and select words that match the set as target sensitive words. In other embodiments, the server can also use a preset set of sensitive words as samples to train a sensitive word extraction model. The sensitive word extraction model can be implemented based on at least one of deep learning, neural networks, adversarial networks, etc. After training, the server can input the message to be inspected into the trained sensitive word extraction model, and the sensitive word extraction model will extract the sensitive words in the message to be inspected to obtain the target sensitive words.
[0084] Step 308: Based on the candidate risk levels of each target sensitive word, obtain the initial risk level of the message to be inspected.
[0085] For example, the server can determine the initial risk level of the message to be inspected based on the candidate risk levels of each target sensitive word. For instance, the server can compare the candidate risk levels of each target sensitive word and select the candidate risk level with the highest weight as the initial risk level of the message to be inspected. Alternatively, the server can determine the priority of each target sensitive word and use the candidate risk level corresponding to the target sensitive word with the highest priority as the initial risk level of the message to be inspected.
[0086] In some optional embodiments, the server can also determine the initial risk level of the message to be inspected by comprehensively considering the candidate risk levels of each target sensitive word. For example, the server can determine the initial risk level of the message to be inspected by averaging or weighted summing the candidate risk levels of all or some of the target sensitive words. When averaging or weighted summing a subset of target sensitive words, the server can select the target sensitive words with higher candidate risk levels to obtain the initial risk level of the message to be inspected. In specific implementation, when weighted summing the candidate risk levels of each target sensitive word, the server can also determine the priority of each target sensitive word, determine the weight of each candidate risk level of each target sensitive word based on the priority of each target sensitive word, and weight each candidate risk level according to the determined weight to obtain the initial risk level of the message to be inspected.
[0087] In this embodiment, by determining the session scenario associated with the target session, at least one candidate matching strategy can be selected from the set of sensitive word matching strategies. For the target sensitive words included in the message to be inspected, the target sensitive words are matched with the associated sensitive words to obtain the candidate risk levels corresponding to the target sensitive words. Then, the initial risk level is determined by combining the candidate risk levels of each target sensitive word. This allows for a scientific and comprehensive assessment of the initial risk level of the message to be inspected.
[0088] In one embodiment, the initial risk level is updated based on multi-dimensional vector features and a set of sensitive word matching strategies to obtain the target risk level, including:
[0089] For each candidate matching strategy, feature encoding is performed on at least one associated sensitive word included in the candidate matching strategy to obtain sensitive word vector features; based on the multi-dimensional vector features and sensitive word vector features, the level update method for the initial risk level is determined; based on the level update method determined by at least one candidate matching strategy, the initial risk level is updated to obtain the target risk level.
[0090] Among them, the sensitive word vector feature refers to the vector representation obtained by performing feature encoding on at least one associated sensitive word included in the candidate matching strategy. The sensitive word vector feature can describe the features of the associated sensitive word in numerical form. For example, in the word embedding method, the "guaranteed profit" in the associated sensitive word is encoded as a vector, and the numerical values in the vector represent a feature dimension of the risk word in the semantic space. The level update method refers to the method of adjusting the initial risk level determined based on the multi-dimensional vector feature and the sensitive word vector feature. By analyzing the multi-dimensional vector feature and the sensitive word vector feature, it can be judged whether the initial risk level needs to be adjusted and the direction and amplitude of the adjustment. For example, there are high-risk sensitive words in the message to be quality inspected, but if the multi-dimensional vector feature shows that the context of the message indicates a risk prompt, then the level update method can be to lower the initial risk level, or if the multi-dimensional vector feature shows that the context of the message does not indicate a risk prompt, then the level update method can be to maintain the initial risk level.
[0091] Exemplarily, for each candidate matching strategy, the server can perform feature encoding on each associated sensitive word included in the candidate matching strategy respectively. For example, the server can use the word embedding technology to convert the associated sensitive word into a vector with a fixed dimension to obtain the sensitive word vector feature. The server can determine the level update method for the initial risk level based on the multi-dimensional vector feature and the sensitive word vector feature; for example, the server can adopt the method of weighted summation, assign corresponding weights according to the importance of different dimension features and sensitive word vector features, calculate a comprehensive risk score, and determine the level update method based on this score (such as increasing the risk level if the score is higher than the threshold, and maintaining or lowering the risk level if it is lower than the threshold). After determining the level update method, the server can update the initial risk level based on the level update methods respectively determined for at least one candidate matching strategy to obtain the target risk level; for example, the server can compare the initial risk level with the determined threshold and take the larger one as the target risk level.
[0092] In some other embodiments, the server can also additionally construct a risk warning statement library, which may include pre-collected and generated risk warning statements such as "Investing involves risks" and "Returns are not guaranteed." The server can determine the similarity between the multi-dimensional vector features and the risk warning statement library, and determine the level update method based on the similarity. If the similarity is greater than or equal to the set similarity threshold, it indicates that there are enough risk warning statements in the multi-dimensional vector features (i.e., the message queue). In this case, the corresponding risk update magnitude value can be determined, and the initial risk level can be subtracted from the risk update magnitude value to reduce the risk level and obtain the target risk level. If the similarity is less than the set similarity threshold, it indicates that the risk warning statements in the multi-dimensional vector features (i.e., the message queue) are insufficient to attract the customer's attention. In this case, the corresponding risk update magnitude value can also be determined, and the initial risk level can be added to the risk update magnitude value to increase the risk level and obtain the target risk level, or the initial risk level can be directly determined as the target risk level. Optionally, when determining the risk update magnitude value, the server can determine it based on the difference between the similarity and the similarity threshold. The larger the difference, the larger the risk update magnitude value, and vice versa.
[0093] In this embodiment, the associated sensitive words in the candidate matching strategy are encoded into vector features, and the initial risk level update method is determined based on the multi-dimensional vector features and the sensitive word vector features. The initial risk level is then updated according to the determined update method to obtain the target risk level. This approach can comprehensively consider multiple factors and obtain a more accurate target risk level, effectively improving the accuracy and reliability of risk assessment.
[0094] In one embodiment, the message queue is parsed to obtain structured semantic features, and the structured semantic features and the message queue are encoded to obtain multi-dimensional vector features of the message queue, including:
[0095] The message queue is parsed to obtain object information, semantic relationship information, and risk word information. The object information, semantic relationship information, risk word information, and message queue are then feature-encoded to obtain multi-dimensional vector features of the message queue.
[0096] In this context, object information refers to entity information related to a message within the message queue. These entities can include, but are not limited to, individuals involved in the interaction (such as users, customers, customer service representatives, administrators, etc.), mentioned things (such as goods, services, locations, etc.), or other objects with clear identities or attributes (such as organizations). Semantic relationship information refers to the semantic associations between different messages in the message queue and between the components within a message. Semantic relationship information can be used to reflect the logical relationships between messages, such as question-and-answer relationships, causal relationships, and adversative relationships, as well as the semantic connections between words and phrases within a message. Risk word information refers to words appearing in the message queue that may cause risks, violations, or adverse effects. Feature encoding is the process of converting raw data such as object information, semantic relationship information, risk word information, and the message queue into numerical vectors or matrices.
[0097] For example, the server can parse the message queue. For instance, the server can call a natural language processing component to parse the message queue and obtain object information, semantic relationship information, and risk word information. Specifically, taking the financial field as an example, the server can use Named Entity Recognition (NER) algorithms (such as rule-based methods, statistical model-based methods, and deep learning methods) to identify the entities included in the message queue and their positions in the text, i.e., identify information such as names, institutions, and financial products in the message queue to obtain object information; the server can build a semantic dependency tree for the sentences in the message queue, determine the subject-verb-object and modification relationships in the sentences, and analyze the semantic association rules between nodes in the dependency tree to obtain semantic relationship information; the server can identify high-risk promise words in the message queue, such as "guarantee," "sure profit," and "absolute safety," by matching with a pre-set risk word dictionary or using a deep learning-based text classification model, and label each risk promise word with its corresponding risk word category, such as promise, guarantee, and return guarantee, to obtain risk word information. Afterwards, the server can perform feature encoding on object information, semantic relationship information, risk word information, and message queue. For example, the server can input object information, semantic relationship information, risk word information, and message queue into a pre-built vectorized model, and then use the vectorized model to extract and fuse features from the object information, semantic relationship information, risk word information, and message queue to obtain multi-dimensional vector features of the message queue.
[0098] In this embodiment, by parsing the message queue, object information, semantic relationship information, and risk word information in the message queue are obtained. The object information, semantic relationship information, and risk word information are then combined with the message queue for feature encoding, which is transformed into multi-dimensional vector features. This allows for in-depth mining of potential features in the message queue, providing accurate data support for subsequent risk level updates and improving the accuracy and reliability of risk level updates.
[0099] In one embodiment, determining the message to be inspected and at least one associated message from multiple candidate messages included in the target session, and determining a message queue based on the message to be inspected and at least one associated message, includes:
[0100] Obtain the target session; the target session includes multiple candidate messages; if the target session meets the quality inspection triggering conditions, determine the message to be inspected from the multiple candidate messages; determine the message interception window, and determine at least one associated message with the message to be inspected from the multiple candidate messages according to the message interception window; combine the message to be inspected and at least one associated message into a message queue according to the time information of the message to be inspected and at least one associated message.
[0101] Quality inspection trigger conditions refer to the preset conditions used to determine whether quality checks need to be performed on messages in a target session. These trigger conditions can be set based on factors such as business needs, risk assessment, and regulatory requirements. For example, quality inspection trigger conditions can be time-based, keyword-based, user-level-based, or message quantity-based. Specifically, time-based conditions can trigger quality inspection at a fixed time each day or at certain time intervals; keyword-based conditions can trigger quality inspection if the target session contains specific keywords, such as risky words; user-level-based conditions can trigger quality inspection based on user priority or quality; and message quantity-based conditions can trigger quality inspection when the number of messages exchanged between two session roles exceeds a certain threshold.
[0102] A message capture window is a method used to define the scope of related messages from multiple candidate messages that are associated with the message to be inspected. A message capture window can specify the time span or location range of messages that are temporally or logically related to the message to be inspected. For example, a message capture window can be a time window, a quantity window, or a logical window; specifically, a time window can be set to capture messages within a certain period before and after the message to be inspected, such as 1 minute or 5 minutes, then messages sent or received within this period will be considered related messages; a quantity window can be set to capture a certain number of messages before and after the message to be inspected, such as the first 3 messages or the last 2 messages, then the 3 messages sent or received before the message to be inspected and the 2 messages sent or received after the message to be inspected are related messages; a logical window can determine related messages based on logical factors such as question-and-answer relationships or topic coherence between messages, such as including all messages belonging to the same discussion stage as the message to be inspected within the scope of related messages.
[0103] For example, the server can obtain a target session from chat software and identify multiple candidate messages included in the target session. If the target session meets the quality inspection trigger conditions, the server determines the message to be inspected from the multiple candidate messages. Taking keyword conditions as an example, the server can identify keywords in messages sent by customer service in the target session. If the message contains preset high-risk keywords (such as those involving illegal marketing, improper promises, sensitive business terms, etc.), the server can identify the message as a message to be inspected. Then, the server can determine a message interception window. For example, the server can determine the message interception window according to a preset message quantity range (such as the first 3 messages and the last 2 messages of the message to be inspected). After determining the message interception window, the server can determine multiple associated messages related to the message to be inspected from the multiple candidate messages according to the message interception window. For example, the server can select a specified number of messages before and after the message to be inspected as associated messages according to the message quantity range. Finally, the server can obtain the timestamps of the message to be inspected and the multiple associated messages associated with it, and arrange the message to be inspected and the multiple associated messages associated with it in the order of timestamps to obtain a message queue.
[0104] In this embodiment, by acquiring the target session and multiple candidate messages therein, the message to be inspected is determined when the quality inspection triggering condition is met, and a message interception window is determined to find related messages. This can comprehensively consider the correlation between messages, and finally combine them into a message queue according to time information. This is beneficial for integrating context information in the subsequent quality inspection process, ensuring the accuracy of message quality inspection.
[0105] In one embodiment, the session quality inspection method further includes:
[0106] If the session quality inspection result meets the risk review triggering conditions, the risk confidence level of the session quality inspection result is determined based on the message to be inspected, the message queue, and the session quality inspection result; the quality inspection confidence level of the session quality inspection result is determined according to the risk confidence level; and the session quality inspection result is reviewed according to the review method corresponding to the quality inspection confidence level.
[0107] Among them, risk review trigger conditions refer to the conditions used to determine whether further risk review of the session quality inspection results is required. Risk review trigger conditions can be set based on factors such as business needs, risk sensitivity, and regulatory requirements. When the session quality inspection results meet the risk review trigger conditions, it indicates that there may be potential risks, requiring more in-depth review. For example, risk review trigger conditions can be level threshold conditions or experience-based conditions.
[0108] Risk confidence level refers to the quantitative assessment of the reliability of a session quality inspection result based on the message to be inspected, the message queue, and the session quality inspection result, to determine the probability of the session quality inspection result having a risk. For example, if a specific algorithm model calculates a risk confidence level of 0.8 for a session quality inspection result, it indicates that the probability of the session quality inspection result having a risk is relatively high. Quality inspection confidence level refers to classifying session quality inspection results into different levels based on the level of risk confidence, representing different levels of reliability and risk. These are typically divided into high, medium, and low levels, each corresponding to a different risk range and handling strategy. For example, a high confidence level can be greater than or equal to 0.8, a medium confidence level can be greater than or equal to 0.4 but less than 0.8, and a low confidence level can be less than 0.4. Review method refers to the specific review and processing methods adopted for session quality inspection results of different quality inspection confidence levels. The review method can be flexibly designed according to business needs and risk levels to ensure that high-risk results are rigorously reviewed and low-risk results are efficiently processed.
[0109] For example, the server can determine whether the session quality inspection result meets the risk review triggering condition. For instance, the server can use a trained model to determine if the session quality inspection result is questionable. This could involve generating a score for the session quality inspection result based on the model. If the score exceeds a certain threshold, it indicates that the session quality inspection result is questionable. In the case of a questionable session quality inspection result, i.e., the session quality inspection result meets the risk review triggering condition, the server can determine the risk confidence level of the session quality inspection result based on the message to be inspected, the message queue, and the session quality inspection result. For example, through a specific algorithm model, the server can comprehensively analyze the content features of the message to be inspected, the contextual information in the message queue, and the score data of the session quality inspection result, performing multi-dimensional weight calculations and risk probability derivation to obtain the risk confidence level of the session quality inspection result. Then, the server can match the risk confidence level with the confidence interval corresponding to a pre-defined quality inspection confidence level to determine the corresponding quality inspection confidence level. It can then obtain the corresponding review method according to the determined quality inspection confidence level, and finally review the session quality inspection result according to the determined review method.
[0110] In one optional embodiment, the quality inspection confidence level can have three levels: high, medium, and low. Correspondingly, the review method for the high confidence level can include the server automatically generating a quality inspection task and writing it into the quality inspection queue. Afterward, the quality inspection task can be pushed to the manual review end, where the reviewer can view the "original text, context, and AI judgment reasons". The review method for the medium confidence level can include the server automatically generating compliance rewriting suggestions and pushing them to the employee's end, prompting them to correct the wording. The low confidence level can include the server simply archiving the level without performing any other processing.
[0111] In an optional embodiment, after a message is sent, the server can also retrieve session data through the interface of the corresponding interactive platform and write it to a Kafka / RabbitMQ message queue. The server's quality inspection engine can consume the session data in real time. Subsequently, the server can determine if a violation exists based on the session quality inspection results or further review, and can automatically push violation information to relevant personnel. If the sender violates the rules multiple times within a set time window, the server can escalate the risk to "serious violation" and automatically report it to the administrator or freeze the sender's account. Simultaneously, the server can generate a compliance risk work order after each violation, which is reviewed and annotated by the quality inspector. The processing results are also written back to the training set for continuous optimization of the model and strategy.
[0112] In this embodiment, when the session quality inspection result triggers a risk review, the risk confidence level can be determined by comprehensively considering the message to be inspected, the message queue, and the session quality inspection result. This allows for an accurate assessment of the risk level of the session quality inspection result. Based on the risk confidence level, the quality inspection confidence level is divided, and the session quality inspection result is reviewed according to the review method corresponding to the quality inspection confidence level. Appropriate measures can be taken for different risk levels to improve the efficiency and accuracy of the review, effectively reduce the risk of misjudgment and omission, and ensure the reliability and quality of the session quality inspection result.
[0113] In one application example, a session quality inspection method is provided, which achieves real-time and accurate compliance monitoring through multi-dimensional strategies, contextual semantic analysis, and intelligent review of large models. The server establishes a multi-dimensional rule set including employee roles, customer levels (i.e., session roles), and session types. It dynamically loads a sensitive word library and matching rules, supporting strategy combinations, priority ranking, and real-time application. Session messages are retrieved locally via the interactive platform's interface, and a dynamic context window is constructed. Multiple related messages are incorporated into semantic analysis, and multi-dimensional semantic features (i.e., multi-dimensional vector features) are extracted using named entity recognition (i.e., object information), dependency parsing (i.e., semantic relationship information), and sentiment recognition (i.e., risk word information) to achieve contextual judgment of sensitive words. For suspected high-risk messages, the server can further input the message text (i.e., the message to be inspected), context (i.e., the message queue), and strategy rules (i.e., the set of sensitive word matching strategies) into an AI (Artificial Intelligence) model for contextual classification and risk scoring, generating risk confidence and reason tags, supporting multi-level risk handling. Simultaneously, the server can automatically generate quality inspection tasks, trigger notifications, or execute account freezing policies, achieving closed-loop management and continuous optimization. Specifically, this includes the following steps:
[0114] S1, Dynamic configuration of sensitive word strategy.
[0115] The server configures a dynamic sensitive word policy (i.e., sensitive word matching policy) on the management side, associating three dimensions—job role, customer level (job role and customer level are also known as session role), and session type—with sensitive words and matching policies. Each dimension is mapped to a sensitive word policy table, forming a "dimension-rule-thesaurus" relationship.
[0116] When performing quality checks, the server can call relevant services to obtain existing information and use this information as key-value pairs to pass to the rule matching module. The rule matching module locates the corresponding sensitive word groups and rule sets based on a multi-level index structure (such as job title → customer level → session type) to determine the sensitive words and their corresponding risk levels. For rule priority, the server can preset a weight field in the sensitive word matching strategy set. During matching, the server executes overwrite or merge logic according to the weight, thereby achieving differentiated control.
[0117] S2, Contextual semantic matching and AI large model-assisted quality inspection.
[0118] (1) Context window construction.
[0119] When a server performs quality inspection on a message (i.e., when inspecting a message to be inspected), it retrieves several related messages (e.g., the first 3 messages, the last 2) from the database or Elasticsearch (a distributed search and analytics engine). The message to be inspected and the related messages are concatenated in chronological order to form a context sequence (i.e., a message queue). Each message in the context sequence carries metadata such as the sender's identity (customer / employee), timestamp, and message type (session type). This context sequence serves as input data for subsequent semantic parsing, ensuring that the model does not make isolated judgments but rather considers the overall context of the dialogue.
[0120] (2) Semantic feature extraction.
[0121] The server invokes Natural Language Processing (NLP) components to parse the context sequence and generate structured semantic features, specifically including the following steps:
[0122] a. Named Entity Recognition (NER).
[0123] The server can identify information such as names, institutions, and financial products in the context sequence based on a financial domain dictionary and a pre-trained model, and obtain the entity category in the context sequence and the position of the entity category in the context sequence, that is, obtain the object information.
[0124] b. Dependency parsing.
[0125] The server can build a dependency tree for sentences, clarifying subject-verb-object and modifying relationships. For example, if the context includes "product-sure profit", it will be labeled with a "strong commitment", thus obtaining semantic relationship information.
[0126] c. Sentiment recognition and risk word labeling.
[0127] The server can use a sentiment analysis model to identify high-risk promises such as "guarantee," "sure profit," and "absolute safety" in the context sequence, and obtain the risk words and their categories (such as promise, guarantee, return guarantee, etc.) in the context sequence, thus obtaining risk word information.
[0128] d. Semantic vectorization encoding.
[0129] The server can input the above results (entities, dependencies, risk labels) along with the context sequence into the vectorization model to generate multi-dimensional vector features for subsequent AI model calls.
[0130] (3) Contextual judgment of sensitive words.
[0131] The server can identify risky words based on a pre-configured multi-dimensional sensitive word matching strategy. If "guaranteed profit" is found to appear in risk warning statements such as "investment involves risk" or "returns are not guaranteed," the risk weight is reduced. If no risk warning is found, the risk level remains high, thus obtaining the rule-based judgment result, i.e., the session quality inspection result.
[0132] (4) AI large model review.
[0133] For messages that remain questionable after rule-based evaluation, the server can invoke the Large Language Model (LLM) service to obtain a risk confidence level (0–1) and a risk justification (e.g., "involves promised benefits, lacks risk warning") based on the original message text (i.e., the message to be inspected), the context sequence, and the rule-based evaluation result (i.e., the session quality inspection result). The server can then automatically execute tiered actions based on the risk confidence level.
[0134] 1. High-risk confidence level (≥0.8).
[0135] The server automatically generates quality inspection tasks, writes them into the quality inspection task queue, and pushes them to the manual review end. Reviewers can view the "original text, context, and AI judgment reasons".
[0136] 2. Medium risk confidence level (0.4–0.8).
[0137] The server automatically generates compliance rewriting suggestions and pushes them to employees, prompting them to revise their wording.
[0138] 3. Low risk confidence level (<0.4).
[0139] The server only archives records and requires no intervention.
[0140] S3. Post-event detection and processing.
[0141] After a message is sent, the server can retrieve session data through the corresponding interface of the interaction platform and write it to the Kafka / RabbitMQ message queue. The quality inspection engine consumes the session data in real time. The server can automatically notify relevant personnel based on policies and AI to determine violations. If a user violates the rules multiple times within a set time window, the system risk is upgraded to "serious violation," and the server can automatically report to the administrator or freeze the account. Each violation generates a compliance risk work order, which is reviewed and marked by the quality inspector. At the same time, the processing results are written back to the training set for continuous optimization of the model and policies.
[0142] In this application example, to implement the above session quality inspection method, the following system can be used, specifically including:
[0143] 1. Strategy Configuration and Management Module: Supports dynamic configuration and real-time loading of multi-dimensional strategies.
[0144] 2. Contextual semantic analysis module: Constructs a context window and performs word segmentation, NER, dependency parsing analysis and sentiment recognition.
[0145] 3. AI-assisted quality inspection module: Based on a large model, suspicious messages are reviewed and risk-scored.
[0146] 4. Message Access and Queue Module: Connects to the WeChat Work interface to retrieve messages and write them to the message queue.
[0147] 5. Risk Assessment and Handling Module: Based on strategies and AI output, it classifies risks, automatically notifies users, generates work orders, and manages accounts.
[0148] Based on this, this example can achieve multiple technical effects, including: dynamic differentiated sensitive word management to improve the accuracy of sensitive word matching; contextual semantics and AI review to significantly improve the accuracy and efficiency of quality inspection; automated risk handling and graded routing to ensure timely response to violations; and continuous optimization mechanisms to enhance the system's intelligence level and strategy adaptability.
[0149] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages in other steps. It is understood that the steps in different embodiments can be freely combined as needed, and all non-contradictory solutions formed by such combinations are within the scope of protection of this application.
[0150] Based on the same inventive concept, this application also provides a session quality inspection device for implementing the session quality inspection method described above. The solution provided by this device is similar to the solution described in the above method; therefore, the specific limitations in one or more session quality inspection device embodiments provided below can be found in the limitations of the session quality inspection method described above, and will not be repeated here.
[0151] In one exemplary embodiment, such as Figure 4 As shown, a session quality inspection device is provided, including: an M module, an N module, and an L module, wherein:
[0152] The message queue construction module 402 is used to determine the message to be inspected and at least one associated message associated with the message to be inspected from multiple candidate messages included in the target session, and to determine the message queue based on the message to be inspected and at least one associated message.
[0153] The risk level determination module 404 is used to determine the initial risk level of the message to be inspected based on the sensitive word matching strategy set and the target sensitive words in the message to be inspected; the sensitive word matching strategy set includes the mapping relationship between different associated sensitive words and risk levels;
[0154] The semantic feature encoding module 406 is used to parse the message queue to obtain structured semantic features, and to encode the structured semantic features and the message queue to obtain the multi-dimensional vector features of the message queue.
[0155] The risk level update module 408 is used to update the initial risk level based on multi-dimensional vector features and a set of sensitive word matching strategies to obtain the target risk level;
[0156] The quality inspection result generation module 410 is used to determine the session quality inspection result of the message to be inspected based on the target risk level.
[0157] In an optional embodiment, the message queue construction module 402 is further configured to obtain a target session; the target session includes multiple candidate messages; if the target session meets the quality inspection triggering conditions, determine the message to be inspected from the multiple candidate messages; determine a message interception window, and determine at least one associated message associated with the message to be inspected from the multiple candidate messages according to the message interception window; and combine the message to be inspected and at least one associated message to form a message queue according to the time information of the message to be inspected and at least one associated message.
[0158] In an optional embodiment, the risk level determination module 404 is further configured to determine the session scenario associated with the target session; obtain a set of sensitive word matching strategies; determine at least one candidate matching strategy from the set of sensitive word matching strategies according to the session scenario; for each target sensitive word in the message to be inspected, match the target sensitive word with the associated sensitive words included in at least one candidate matching strategy to obtain the candidate risk level of the target sensitive word; and obtain the initial risk level of the message to be inspected based on the candidate risk level of each target sensitive word.
[0159] In an optional embodiment, the risk level determination module 404 is further configured to, for each candidate matching strategy, perform feature encoding on at least one associated sensitive word included in the candidate matching strategy to obtain sensitive word vector features; determine the level update method for the initial risk level based on the multi-dimensional vector features and the sensitive word vector features; and update the initial risk level based on the level update method determined by each of the at least one candidate matching strategy to obtain the target risk level.
[0160] In an optional embodiment, the semantic feature encoding module 406 is further configured to parse the message queue to obtain object information, semantic relationship information and risk word information in the message queue; and to perform feature encoding on the object information, semantic relationship information, risk word information and message queue to obtain multi-dimensional vector features of the message queue.
[0161] In an optional embodiment, the session quality inspection device further includes a quality inspection result review module, which is used to determine the risk confidence level of the session quality inspection result based on the message to be inspected, the message queue, and the session quality inspection result when the session quality inspection result meets the risk review triggering conditions; determine the quality inspection confidence level of the session quality inspection result according to the risk confidence level; and review the session quality inspection result according to the review method corresponding to the quality inspection confidence level.
[0162] Each module in the aforementioned session quality inspection device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in the processor of a computer device in hardware form or independent of it, or stored in the memory of a computer device in software form, so that the processor can call and execute the corresponding operations of each module.
[0163] In one exemplary embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 5As shown, this computer device includes a processor, memory, input / output interfaces (I / O), and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operating system and computer programs stored in the non-volatile storage media. The database stores session messages, sensitive word matching strategies, quality inspection trigger conditions, risk review trigger conditions, and other data. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communication with external terminals via a network connection. When the computer program is executed by the processor, it implements a session quality inspection method.
[0164] Those skilled in the art will understand that Figure 5 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0165] In one exemplary embodiment, a computer device is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the session quality inspection methods of the above embodiments.
[0166] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the session quality inspection methods of the above embodiments.
[0167] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the session quality inspection methods of the above embodiments.
[0168] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.
[0169] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.
[0170] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.
[0171] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.
Claims
1. A method for session quality monitoring, the method comprising: The method comprises: determining a message to be inspected and at least one associated message associated with the message to be inspected from a plurality of candidate messages included in a target session, and determining a message queue based on the message to be inspected and the at least one associated message; determining an initial risk level of the message to be inspected according to a set of sensitive word matching strategies and a target sensitive word in the message to be inspected; the set of sensitive word matching strategies comprises a mapping relationship between different associated sensitive words and risk levels; parsing the message queue to obtain structured semantic features, and encoding the structured semantic features and the message queue to obtain multi-dimensional vector features of the message queue; updating the initial risk level based on the multi-dimensional vector features and the set of sensitive word matching strategies to obtain a target risk level; determining a session inspection result of the message to be inspected based on the target risk level.
2. The method of claim 1, wherein, The method comprises: determining an initial risk level of the message to be inspected according to a set of sensitive word matching strategies and a target sensitive word in the message to be inspected; the set of sensitive word matching strategies comprises a mapping relationship between different associated sensitive words and risk levels; determining an initial risk level of the message to be inspected according to a set of sensitive word matching strategies and a target sensitive word in the message to be inspected; the set of sensitive word matching strategies comprises a mapping relationship between different associated sensitive words and risk levels; determining an initial risk level of the message to be inspected according to a set of sensitive word matching strategies and a target sensitive word in the message to be inspected; the set of sensitive word matching strategies comprises a mapping relationship between different associated sensitive words and risk levels. The method comprises:
3. The method of claim 2, wherein, determining an initial risk level of the message to be inspected according to a set of sensitive word matching strategies and a target sensitive word in the message to be inspected; the set of sensitive word matching strategies comprises a mapping relationship between different associated sensitive words and risk levels; determining an initial risk level of the message to be inspected according to a set of sensitive word matching strategies and a target sensitive word in the message to be inspected; the set of sensitive word matching strategies comprises a mapping relationship between different associated sensitive words and risk levels; determining an initial risk level of the message to be inspected according to a set of sensitive word matching strategies and a target sensitive word in the message to be inspected; the set of sensitive word matching strategies comprises a mapping relationship between different associated sensitive words and risk levels. The method comprises:
4. The method of claim 1, wherein, parsing the message queue to obtain structured semantic features, and encoding the structured semantic features and the message queue to obtain multi-dimensional vector features of the message queue; parsing the message queue to obtain structured semantic features, and encoding the structured semantic features and the message queue to obtain multi-dimensional vector features of the message queue; The method comprises:
5. The method of claim 1, wherein, obtaining a target session; the target session comprises a plurality of candidate messages; In a case where the target session meets a quality inspection triggering condition, a message to be inspected is determined from the plurality of candidate messages; A message interception window is determined, and at least one associated message associated with the message to be inspected is determined from the plurality of candidate messages according to the message interception window; According to time information of the message to be inspected and the at least one associated message, the message to be inspected and the at least one associated message are combined to form a message queue.
6. The method according to any one of claims 1 to 5, characterized in that, The method further comprises: In a case where the session quality inspection result meets a risk review triggering condition, a risk confidence degree of the session quality inspection result is determined based on the message to be inspected, the message queue, and the session quality inspection result; According to the risk confidence degree, a quality inspection confidence degree level of the session quality inspection result is determined; According to a review mode corresponding to the quality inspection confidence degree level, the session quality inspection result is reviewed.
7. A session quality monitoring apparatus characterized by comprising: The device comprises: A message queue construction module configured to determine a message to be inspected and at least one associated message associated with the message to be inspected from a plurality of candidate messages included in a target session, and determine a message queue based on the message to be inspected and the at least one associated message; A risk level determination module configured to determine an initial risk level of the message to be inspected according to a set of sensitive word matching strategies and a target sensitive word in the message to be inspected; the set of sensitive word matching strategies includes a mapping relationship between different associated sensitive words and risk levels; A semantic feature encoding module configured to parse the message queue to obtain structured semantic features, and encode the structured semantic features and the message queue to obtain a multi-dimensional vector feature of the message queue; A risk level updating module configured to update the initial risk level based on the multi-dimensional vector feature and the set of sensitive word matching strategies to obtain a target risk level; A quality inspection result generation module configured to determine a session quality inspection result of the message to be inspected based on the target risk level.
8. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that, The processor executes the computer program to implement the steps of the method of any one of claims 1 to 6.
9. A computer-readable storage medium having stored thereon a computer program, characterized in that, The computer program is executed by the processor to implement the steps of the method of any one of claims 1 to 6.
10. A computer program product comprising a computer program, characterized in that, The computer program is executed by the processor to implement the steps of the method of any one of claims 1 to 6.