A sentiment analysis system based on multi-teacher knowledge distillation

By using a multi-teacher knowledge distillation-based sentiment analysis system, which leverages large-scale collaborative model generation of auxiliary information and construction of a multi-sentiment analysis teacher model, combined with mutual information-driven denoising and reinforcement learning, the system addresses the performance limitations of existing implicit sentiment analysis methods, achieving higher accuracy and robustness.

CN121561683BActive Publication Date: 2026-03-27EAST CHINA JIAOTONG UNIVERSITY
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-01-23
Publication Date
2026-03-27

AI Technical Summary

Technical Problem

Existing implicit sentiment analysis methods based on large models have poor performance, fail to fully utilize the explanatory and inference potential of large models, and fail to effectively filter noise in the generated data, affecting the accuracy and robustness of implicit sentiment recognition.

Method used

A sentiment analysis system based on multi-teacher knowledge distillation is adopted. Auxiliary information is generated through large-scale model collaboration, a multi-sentiment analysis teacher model is constructed, and a mutual information-driven denoising module is used to screen high-quality data. Combined with a multi-teacher-student knowledge distillation module that integrates reinforcement learning, the proportion of knowledge contribution is dynamically adjusted to achieve noise suppression and reasoning ability transfer.

Benefits of technology

It significantly improves the accuracy and robustness of implicit emotion recognition, fully leverages the collaborative advantages of multi-teacher models, and enhances the model's ability to understand and recognize implicit emotions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121561683B_ABST
    Figure CN121561683B_ABST
Patent Text Reader

Abstract

The application discloses a kind of sentiment analysis systems based on multi-teacher knowledge distillation, based on the auxiliary information generation module of big model cooperation generates two kinds of auxiliary training data, namely explanation and example sentence, multi-sentiment analysis teacher model construction module fuses the above auxiliary training data, constructs multiple sentiment analysis teacher models with difference, and the mutual information driven denoising module quantifies its reliability by calculating the mutual information value of generated auxiliary training data, and the multi-teacher-student knowledge distillation module based on the real-time training state of model adaptive learning fusion weight, dynamically controls the knowledge contribution proportion of each teacher model.The present application effectively utilizes the explanation and example sentence generated by big model as auxiliary training data, realizes noise suppression by mutual information screening and reinforcement learning, and migrates the reasoning ability of big model to small model under the multi-teacher knowledge distillation framework, significantly improves the accuracy and robustness of implicit sentiment recognition.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of natural language processing, and particularly relates to a sentiment analysis system based on multi-teacher knowledge distillation. BACKGROUND

[0002] Aspect-level sentiment classification aims to determine the sentiment polarity of specific aspects in text, and is one of the most in-depth directions in the field of sentiment analysis. Compared with document-level and sentence-level sentiment classification, aspect-level sentiment classification can identify the fine-grained sentiment tendency of multiple aspects in text, and is therefore more suitable for practical application scenarios. In e-commerce reviews, hotel and restaurant reviews, and other applications, users often discuss multiple aspects at the same time. For example, in the sentence "The restaurant has low prices, but the food tastes average", "price" corresponds to positive sentiment, while "taste" corresponds to negative sentiment. Aspect-level sentiment classification can capture the sentiment of different aspects, and provide more fine-grained sentiment information for upper-layer applications such as recommendation systems, intelligent customer service, and brand management. With the continuous expansion of application needs, aspect-level sentiment classification has received more and more attention in academia and industry.

[0003] In the aspect-level sentiment classification task, the model can accurately identify explicit sentiment expressions, i.e., there are obvious sentiment words in the sentence, such as "good", "like", and "hate". However, in user-posted reviews, emotions are often expressed implicitly, making it difficult to directly infer sentiment tendency from sentiment words. Implicit sentiment does not rely on obvious sentiment words, but rather conveys emotions through factual descriptions, scene context, or common sense knowledge. For example, in the sentence "The waiter spilled soup on me while serving", there are no negative sentiment words in the sentence, but based on common sense, it can be inferred that the user has a negative sentiment towards the "service" aspect. For another example, the sentence "The phone needs to be charged three times a day" also does not contain explicit sentiment words, but the user's sentiment towards "battery life" is obviously negative. The core difficulty of implicit sentiment analysis lies in the fact that sentiment information is not directly apparent, and the model needs to have certain reasoning ability, common sense understanding ability, and deep semantic modeling ability for context.

[0004] Researchers have proposed various technical routes around the question of "how to make models have reasoning ability and common sense understanding ability". Early methods were mainly based on external knowledge enhancement, by introducing concept knowledge base or sentiment association rules to help the model identify implicit emotional tendencies. For example, using common sense atlas to infer the sentiment valence of events, or based on causal sentiment dictionary (such as some events usually lead to positive / negative emotions) to assist in judging implicit sentiment. After the rise of deep learning methods, implicit sentiment analysis based on neural networks gradually became the mainstream, capturing deep semantic and implicit emotional clues through attention mechanisms, structured semantic modeling, graph neural networks or multi-task learning. In recent years, with the advent of large language models, the performance of implicit sentiment analysis has been significantly improved. Pre-training on a vast amount of text enables such models to have certain common sense reasoning ability and semantic understanding ability, better capturing the semantic associations behind implicit sentiment. Researchers also make full use of the powerful text generation capabilities of large language models to explore data-augmented implicit sentiment analysis. A typical method is to generate explicit sentiment expressions corresponding to implicit sentiment expressions in the training data through large models, thereby constructing auxiliary training samples. For example, the sentence "mobile phone needs to be charged three times a day" can be converted by the large model into "the mobile phone battery has poor endurance, which makes people very dissatisfied", making the originally implicit negative sentiment explicit. Subsequently, using methods such as contrastive learning or multi-task learning, the model is trained to establish semantic associations between implicit sentiment expressions and explicit sentiment expressions, thereby improving the model's ability to recognize implicit sentiment.

[0005] However, existing data augmentation methods based on large models have the following two shortcomings: 1) poor performance of implicit sentiment analysis, these methods usually only use the ability of large models to generate explicit sentiment expressions, without fully utilizing the potential of large models to generate explanations or reasoning processes, so the model lacks understanding of the reasons for sentiment formation and context logic when learning implicit sentiment. 2) The data generated by large models often contains noise, such as semantic bias or sentiment polarity errors, and existing methods usually do not effectively filter these noises, which may affect the accuracy and robustness of implicit sentiment recognition. SUMMARY

[0006] Therefore, the present application proposes a sentiment analysis system based on multi-teacher knowledge distillation to solve the problems of poor performance of existing implicit sentiment analysis and ineffective filtering of noise, thereby improving the accuracy and robustness of implicit sentiment recognition.

[0007] The sentiment analysis system based on multi-teacher knowledge distillation according to an embodiment of the present application comprises an auxiliary information generation module based on large model collaboration, a multi-sentiment analysis teacher model construction module, an mutual information driven denoising module, and a multi-teacher-student knowledge distillation module fused with reinforcement learning.

[0008] The auxiliary information generation module based on large model cooperation includes a plurality of analysis large models and a summary large model, each analysis large model takes the target sentence and the given aspect in the training instance as input, and independently completes the explanation generation and similar example sentence construction of the corresponding sentiment category; the summary large model collects the output results of all analysis large models, and generates the final explanation and the final example sentence through integration, screening and de-duplication optimization;

[0009] The multi-sentiment analysis teacher model construction module is based on original training data, and fuses the final explanation and example sentence to construct an example sentence teacher model, an explanation teacher model and a combined teacher model, wherein the example sentence teacher model introduces the final example sentence as additional input to predict the sentiment tendency of the given aspect in the input sentence; the explanation teacher model introduces the final explanation as additional input to predict the sentiment tendency of the given aspect in the input sentence; the combined teacher model introduces the final explanation and the final example sentence as additional input to predict the sentiment tendency of the given aspect in the input sentence;

[0010] In the mutual information driven denoising module, the mutual information values between the final example sentence and the aspect word-sentiment information are calculated based on the example sentence teacher model, the mutual information values between the final explanation and the aspect word-sentiment information are calculated based on the explanation teacher model, and the mutual information values between the final explanation and the final example sentence and the aspect word-sentiment information are calculated based on the combined teacher model, then based on the obtained mutual information values, the credibility of each teacher model is calculated respectively, finally, the probability distribution of the sentiment category predicted by each teacher model is weighted and fused with the uniform distribution to obtain the denoised probability distribution for subsequent knowledge distillation training;

[0011] In the multi-teacher-student knowledge distillation module with reinforcement learning fusion, first, a sentiment analysis student model is constructed, then in the multi-teacher-student distillation framework, the knowledge in the example sentence teacher model, the explanation teacher model and the combined teacher model is transferred to the student model, and in the process of knowledge distillation training, an adaptive weight learning mechanism based on reinforcement learning is introduced to dynamically regulate the proportion of knowledge contribution of each teacher model.

[0012] According to the emotion analysis system based on multi-teacher knowledge distillation, the auxiliary information generation module based on large model cooperation generates two types of auxiliary training data by means of large model cooperation, one is the explanation of the emotion category to which the instance belongs, and the other is the example sentence similar in semantics, which provides rich supplementary information for the training of the subsequent teacher model. The multi-emotion analysis teacher model construction module fuses the auxiliary training data generated above, constructs multiple emotion analysis teacher models with differences, provides multiple knowledge sources for subsequent knowledge distillation, and the mutual information driven denoising module quantifies the reliability of the generated auxiliary training data by calculating the mutual information value, filters out high-quality auxiliary information, effectively suppresses the interference of noise data on model training, and the multi-teacher-student knowledge distillation module based on reinforcement learning adaptively learns the fusion weight based on the real-time training state of the model, dynamically regulates the knowledge contribution proportion of each teacher model, so as to realize the optimal knowledge transfer efficiency and give full play to the synergistic advantage of the multi-teacher model. The present application effectively utilizes the explanation and example sentence generated by the large model as auxiliary training data, realizes noise suppression through mutual information filtering and reinforcement learning, and migrates the reasoning ability of the large model to the small model under the multi-teacher knowledge distillation framework, thereby significantly improving the accuracy and robustness of implicit sentiment recognition. BRIEF DESCRIPTION OF DRAWINGS

[0013] The above and / or additional aspects and advantages of the embodiments will become apparent and more readily appreciated from the following description of the embodiments, taken in conjunction with the accompanying drawings in which:

[0014] Figure 1 FIG. 1 is a structural schematic diagram of an emotion analysis system based on multi-teacher knowledge distillation according to an embodiment of the present application;

[0015] Figure 2 FIG. 2 is a structural schematic diagram of an exemplary auxiliary information generation module based on large model cooperation. DETAILED DESCRIPTION

[0016] To make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are some embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor fall within the scope of protection of the present application.

[0017] Referring to Figure 1 The embodiments of the present application propose an emotion analysis system based on multi-teacher knowledge distillation, which comprises an auxiliary information generation module based on large model cooperation, a multi-emotion analysis teacher model construction module, a mutual information driven denoising module, and a multi-teacher-student knowledge distillation module based on reinforcement learning.

[0018] Referring toFigure 2 The auxiliary information generation module based on large-scale model collaboration consists of multiple large analytical models and a large aggregation model, forming a collaborative architecture of "distributed generation - centralized aggregation". Each large analytical model takes the target sentence and given aspects from the training instances as input and independently completes the generation of explanations for the corresponding sentiment categories and the construction of similar example sentences. The aggregation model collects the output results of all large analytical models, and through integration, filtering, and deduplication optimization, generates high-quality final explanations and final example sentences, providing reliable auxiliary training data support for subsequent modules.

[0019] In the auxiliary information generation module based on large model collaboration, given the target sentence from the training instance... and aspects The true emotional category of the examples The explicit and implicit expression of emotions and instructions used for generation The explanation generated by the i-th large analytical model and example sentences The expression is:

[0020] ;

[0021] in, For the i-th large analysis model, the explicit / implicit representation of sentiment is 1 when it represents an implicit sample and 0 when it represents an explicit sample.

[0022] instruction The guided analysis model simultaneously generates inference explanations and example sentences, specifically as follows: 1) Generating inference explanations: If the sentiment is explicit, analyze the directly occurring sentiment words and explain how they express the sentiment. If the sentiment is implicit, discover implicit clues, factual descriptions, or common-sense connections, and gradually infer how they imply the sentiment. 2) Generating similar example sentences: Create a new example sentence with the same sentiment using different expressions; the sentence must be natural and fluent. In the specific implementation of this invention, multiple analysis models need to be selected from open-source models of different sources to avoid generating homogeneous explanations and example sentences, ensuring the diversity and differentiation of the output content.

[0023] The final explanation of the large model generation and the final example sentence The expression is:

[0024] ;

[0025] in, To summarize the large model, For summarizing instructions, This is the explanation generated for the first large analytical model. The explanation generated for the m-th large analytical model, where m is the total number of large analytical models. This is the first example sentence generated for the large analysis model. Example sentences generated for the m-th large analysis model.

[0026] The specific content is as follows: 1) Generate the final detailed explanation: Compare the three explanations, maintaining the best logic, insight, and clarity. Eliminate redundancy, errors, and ambiguities, and propose the clearest, most concise, and correct explanation. 2) Generate the best example sentence: Select or slightly rewrite the best example sentence, which must meet the following requirements: correctly convey the emotion of the words, read as if it were real and natural, and differ in style from the original sentence.

[0027] The multi-sentiment analysis teacher model construction module, based on the original training data, integrates the final explanations and example sentences to construct multiple differentiated sentiment analysis teacher models, providing diverse knowledge sources for subsequent knowledge distillation. Specifically, it constructs example sentence teacher models, explanation teacher models, and combined teacher models. Each teacher model incorporates different auxiliary information as input to enhance the understanding of sentiment from different perspectives. The teacher models can be built based on current mainstream aspect-level sentiment classification models, with core components including an encoding module and a classification module. The encoding module learns the vector representation of the input sentence and the given aspect, while the classification module predicts the sentiment tendency corresponding to the target aspect based on the output of the encoding module.

[0028] Specifically, the example sentence teacher model introduces the final example sentence as additional input to predict the sentiment tendency of a given aspect in the input sentence. In this process, the following equation is satisfied:

[0029] ;

[0030] ;

[0031] in, and These are the encoding module and classification module of the example sentence teacher model, respectively. Taking the emotional semantic representation learned by the teacher model as an example, Example: Given aspects learned by the teacher model The vector representation of , The matrix formed by the vector representations of all words in the final example sentence learned by the example sentence teacher model is used to construct the matrix. Take, for example, the probability distribution of sentiment categories predicted by the teacher model. These are typically pre-trained models such as BERT or RoBERTa. The aspect-level sentiment classification model is usually a one-layer or multi-layer forward neural network. In the implementation of the application, the organization mode of the input needs to be adjusted accordingly to adapt to the input format requirements according to the aspect-level sentiment classification model used. One type of mainstream classification model uses a pre-trained model such as BERT as an encoder, and its input format is: [CLS] xsa. In this case, the output vector corresponding to [CLS] is taken as the sentiment semantic representation . Another type of mainstream model models the aspect-level sentiment classification task as a mask prediction task, and its input format is: [CLS] xsThe a is [MASK], and the output vector corresponding to the mask placeholder [MASK] is taken as the sentiment semantic representation . Wherein, [CLS] represents a global semantic placeholder, which is a separation mark used to distinguish different input segments.

[0032] The explanation teacher model introduces the final explanation as an additional input to predict the sentiment tendency of the given aspect in the input sentence. In this process, the following formula is satisfied:

[0033] ;

[0034] ;

[0035] Wherein, and are the encoding module and the classification module of the explanation teacher model, is the sentiment semantic representation learned by the explanation teacher model, is the vector representation of the given aspect learned by the explanation teacher model, is a matrix composed of the vector representations of all words in the final explanation learned by the explanation teacher model, is the probability distribution of the sentiment category predicted by the explanation teacher model.

[0036] The combined teacher model introduces the final explanation and the final example sentence as additional inputs to predict the sentiment tendency of the given aspect in the input sentence. In this process, the following formula is satisfied:

[0037] ;

[0038] ;

[0039] Wherein, and are the encoding module and the classification module of the combined teacher model, is the sentiment semantic representation learned by the combined teacher model, is the vector representation of the given aspect learned by the combined teacher model, a matrix composed of the vector representations of all words in the final explanation and the final example sentence learned by the teacher model, a probability distribution about the sentiment category predicted by the combined teacher model.

[0040] The example sentence teacher model, the explanation teacher model and the combined teacher model are trained independently of each other, and the cross-entropy cost used in the training process is respectively:

[0041]

[0042]

[0043]

[0044] wherein, is a manually annotated training data set, is a training instance in the is a one-hot vector representation of the true sentiment category of the training instance, is a function for calculating cross-entropy, and are the cross-entropy costs of the example sentence teacher model, the explanation teacher model and the combined teacher model, respectively.

[0045] In the mutual information driven denoising module, the mutual information value between the generated auxiliary training data and the aspect word-sentiment information is calculated to quantify the credibility, so as to filter high-quality auxiliary information and effectively suppress the interference of noise data on the subsequent knowledge distillation training. For the generated auxiliary training data with low mutual information value, the influence of the corresponding teacher model in the knowledge distillation training is reduced to weaken the adverse effects of low credibility information. In the present application, the mutual information value is not limited to the strict statistical mutual information definition, but is approximately calculated by using a mutual information measurement method that can represent the association strength between words and aspect word-sentiment information.

[0046] Specifically, the mutual information value between the final example sentence and the aspect word-sentiment information is calculated based on the example sentence teacher model, the mutual information value between the final explanation and the aspect word-sentiment information is calculated based on the explanation teacher model, and the mutual information value between the final explanation and the final example sentence and the aspect word-sentiment information is calculated based on the combined teacher model. Then, based on the obtained mutual information values, the credibility of each teacher model is calculated respectively, and finally, the probability distribution about the sentiment category predicted by each teacher model is weighted and fused with the uniform distribution to obtain the denoised probability distribution for subsequent knowledge distillation training.

[0047] wherein the mutual information value between the final example sentence and the aspect word-sentiment information is calculated based on the example sentence teacher model, and the expression is: ​​​​​

[0048] ;

[0049] ;

[0050] ;

[0051] ;

[0052] wherein, is the mutual information value between the final instance and the aspect term-sentiment information, is the number of words in the final instance , is the mutual information value between the i-th word in the final instance and the aspect term-sentiment information, is the mutual information value between the i-th word and the sentiment information, is the mutual information value between the i-th word and the aspect term, and are the vector representations of the i-th word and the -th word in the final instance, is the cosine similarity calculation function, is the exponential function.

[0053] Similarly, given the sentiment semantic representation learned by the explanation teacher model , the vector representation of the given aspect learned by the explanation teacher model , and the vector representations of all the words in the generated final explanation , a matrix can be calculated. The mutual information value between the final explanation and the aspect term-sentiment information . Given the sentiment semantic representation learned by the combination teacher model , the vector representation of the given aspect learned by the combination teacher model , and the vector representations of all the words in the generated final explanation and the final instance , a matrix can be calculated. The mutual information value between the final explanation and the instance and the aspect term-sentiment information .

[0054] Based on the obtained mutual information values, the credibility of each teacher model is calculated respectively, expressed as:

[0055] ;

[0056] ;

[0057] ;

[0058] wherein, is the confidence of the example sentence teacher model, is the confidence of the explanation teacher model, is the confidence of the combined teacher model, is an activation function, is the mutual information value between the final explanation and aspect word-sentiment information, is the mutual information value between the final explanation and the final example sentence and aspect word-sentiment information, is a preset mutual information threshold value, is a scaling coefficient. A larger can enhance the discrimination of the function, so that the high mutual information value corresponds to the confidence of the teacher model close to 1, and vice versa. In the process of implementing the present application, can be set to 0.1, can be set to 10.

[0059] Finally, the probability distribution of the sentiment category predicted by each teacher model is weighted and fused with the uniform distribution to obtain the denoised probability distribution, which is used for knowledge distillation training in the next module. The specific calculation is as follows:

[0060] ;

[0061] ;

[0062] ;

[0063] wherein, , and are the denoised probability distributions corresponding to the example sentence teacher model, the explanation teacher model and the combined teacher model, is a uniform distribution. For the teacher model corresponding to the high mutual information value, the original probability distribution is retained; otherwise, the probability distribution is aligned to the uniform distribution to achieve the purpose of filtering noise.

[0064] In the multi-teacher-student knowledge distillation module with reinforcement learning, a sentiment analysis student model is first constructed, and then the knowledge in the example sentence teacher model, the explanation teacher model and the combined teacher model is transferred to the student model in the multi-teacher-student distillation framework to improve the performance of the student model. In the process of knowledge distillation training, an adaptive weight learning mechanism based on reinforcement learning is introduced to dynamically regulate the knowledge contribution proportion of each teacher model, so as to realize the optimal knowledge transfer efficiency and fully exert the synergistic advantage of the multi-teacher model.

[0065] Specifically, the sentiment analysis student model includes an encoding module. and classification module Predict the input sentence Given aspects Their emotional tendencies are as follows:

[0066] ;

[0067] ;

[0068] in, The probability distribution of sentiment categories predicted by the student model. The emotional semantic representation learned by the student model.

[0069] The reinforcement learning-based adaptive weight learning mechanism includes two policy networks, which are optimized using a multi-objective reward function. When the input training instance is an explicit sentiment representation, the explicit policy network is invoked to calculate the weights of each teacher model; when the input training instance is an implicit sentiment representation, the implicit policy network is invoked to calculate the weights of each teacher model. The expression is as follows:

[0070] ;

[0071] ;

[0072] in, and These are explicit policy networks and implicit policy networks, respectively. When, it indicates that the current training instance is an explicit sentiment representation. When the current training instance is an implicit sentiment representation, it indicates that the current training instance is an implicit sentiment representation. , , These represent the weights of the example teacher model, the explanation teacher model, and the combined teacher model learned by the policy network, respectively. Let be the state vector of the system at the current moment. , , These are the state vectors of the example teacher model, the explanation teacher model, and the combined teacher model at the current moment, respectively.

[0073] Example sentence: State vector of the teacher model It consists of 5 dimensions, including: two prediction distributions and KL divergence, the accuracy of the teacher model on the validation set, and the predicted distribution of the teacher model. Compared with the true category one-hot vector representation Cross-entropy, student model predicted distribution and the cosine similarity of the cross-entropy of the teacher model, the sentiment representation learned by the student model and the teacher model. When the present application is implemented, and Both can use a multi-layer forward neural network, and the activation function of the output layer is Softmax.

[0074] Given the weights of the teacher model , , , define the multi-teacher knowledge distillation cost as:

[0075] ;

[0076] ;

[0077] wherein is a function for calculating the KL divergence between two probability distributions, is the probability distribution of the sentiment category predicted by the student model, is the weighted sum result of the probability distribution predicted by the three teacher models;

[0078] Finally, define the total training cost of the student model as:

[0079] ;

[0080] ;

[0081] wherein is the cross-entropy cost of the student model, is the weight coefficient of the multi-teacher knowledge distillation cost.

[0082] Under the reinforcement learning optimization framework, the policy network drives the weight learning through the reward. The reward of the policy network is defined based on the two indicators of classification performance and knowledge transfer, as shown in the following formula:

[0083] ;

[0084] ;

[0085] ;

[0086] wherein is the cross-entropy cost of the sample, is the knowledge distillation cost of the sample, and the smaller the cross-entropy cost of the sample , the better the fitting effect of the sentiment analysis student model to the real label, and the reward value The larger the reward value is, the higher the knowledge alignment between the student model and the teacher model is. The smaller the reward value is, the higher the knowledge alignment between the student model and the teacher model is. In the process of implementing the invention, It is usually set to be less than 1 to ensure that the student model meets the core requirement of the emotion classification task while realizing effective knowledge transfer.

[0087] The strategy network calculates the weight distribution of the teacher model fusion according to the distillation state, and obtains the corresponding reward according to the training effect of the student model after executing the fusion action. The strategy gradient method updates the parameters of the strategy network by maximizing the reward weighted logarithmic strategy probability, thereby guiding it to produce a better teacher model weight distribution in subsequent training. Secondly, in order to enhance the exploration ability of the strategy network and avoid the weight distribution converging to a single teacher scheme (i.e. the weight of a certain teacher model is too large) too early, is further introduced into the strategy optimization target. Therefore, the training target of the strategy network is defined as the weighted sum of the reward weighted logarithmic strategy probability and the strategy entropy, and the training cost of the strategy network The expression of the training cost of the strategy network is as follows:

[0088] ;

[0089] wherein, is the entropy of the weight distribution, is the weight coefficient corresponding to the entropy regularization term, which is usually set to be less than 1.

[0090] The whole training process of the method proposed in the present application mainly includes two steps: optimizing the emotion analysis student model based on the training cost and optimizing the strategy network based on the training cost The two optimization steps are alternately performed until convergence, and the student model obtained after the training is completed is the final emotion analysis model.

[0091] In summary, according to the emotion analysis system based on multi-teacher knowledge distillation of the embodiment, the auxiliary information generation module based on large model cooperation generates two types of auxiliary training data, one is the explanation of the emotion category to which the instance belongs, and the other is the example sentence with similar semantics, to provide rich supplementary information for the subsequent training of the teacher model. The multi-emotion analysis teacher model construction module fuses the auxiliary training data generated above to construct multiple emotion analysis teacher models with differences, providing multiple knowledge sources for subsequent knowledge distillation. The mutual information driven denoising module quantifies the reliability of the generated auxiliary training data by calculating the mutual information value, filters out high-quality auxiliary information, effectively suppresses the interference of noise data on model training, and fuses the multi-teacher-student knowledge distillation module based on reinforcement learning to adaptively learn the fusion weight based on the real-time training state of the model, dynamically regulates the knowledge contribution proportion of each teacher model, so as to realize the optimal knowledge transfer efficiency and give full play to the synergistic advantage of the multi-teacher model. The present application effectively utilizes the explanation and example sentence generated by the large model as auxiliary training data, realizes noise suppression through mutual information filtering and reinforcement learning, and migrates the reasoning ability of the large model to the small model under the multi-teacher knowledge distillation framework, significantly improving the accuracy and robustness of implicit sentiment recognition.

[0092] In the description of the present specification, the description referring to the terms "one embodiment", "some embodiments", "an example", "a specific example", or "some examples" and the like means that the specific features, structures, materials or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present application. In the present specification, the illustrative description of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described can be combined in any one or more embodiments or examples in a suitable manner.

[0093] Although the embodiments of the present application have been shown and described, those skilled in the art can understand that various changes, modifications, replacements and variations can be made to the embodiments without departing from the principles and spirit of the present application, and the scope of the present application is defined by the claims and their equivalents.

Claims

1. A sentiment analysis system based on multi-teacher knowledge distillation, characterized in that, The auxiliary information generation module based on large model cooperation, the multi-sentiment analysis teacher model construction module, the mutual information driven denoising module, and the multi-teacher-student knowledge distillation module fused with reinforcement learning are included. The auxiliary information generation module based on large model cooperation includes multiple analysis large models and a summary large model, each analysis large model takes the target sentence and the given aspect in the training instance as input, and independently completes the explanation generation and similar example sentence construction of the corresponding sentiment category. The summary large model collects the output results of all analysis large models, and generates the final explanation and the final example sentence through integration, screening and de-duplication optimization. The multi-sentiment analysis teacher model construction module is based on the original training data, and fuses the final explanation and the example sentence to construct an example sentence teacher model, an explanation teacher model and a combined teacher model, wherein the example sentence teacher model introduces the final example sentence as additional input to predict the sentiment tendency of the given aspect in the input sentence; the explanation teacher model introduces the final explanation as additional input to predict the sentiment tendency of the given aspect in the input sentence; the combined teacher model introduces the final explanation and the final example sentence as additional input to predict the sentiment tendency of the given aspect in the input sentence. In the mutual information driven denoising module, the mutual information values between the final example sentence and the aspect word-sentiment information are calculated based on the example sentence teacher model, the mutual information values between the final explanation and the aspect word-sentiment information are calculated based on the explanation teacher model, and the mutual information values between the final explanation and the final example sentence and the aspect word-sentiment information are calculated based on the combined teacher model, then, the credibility of each teacher model is calculated based on the obtained mutual information values, and finally, the probability distribution of the emotion category predicted by each teacher model is weighted and fused with the uniform distribution to obtain the denoised probability distribution for subsequent knowledge distillation training. In the multi-teacher-student knowledge distillation module fused with reinforcement learning, a sentiment analysis student model is first constructed, and then the knowledge in the example sentence teacher model, the explanation teacher model and the combined teacher model is transferred to the student model in the multi-teacher-student distillation framework, and an adaptive weight learning mechanism based on reinforcement learning is introduced in the process of knowledge distillation training to dynamically regulate the proportion of knowledge contribution of each teacher model.

2. The multi-teacher knowledge distillation based sentiment analysis system according to claim 1, wherein, In the auxiliary information generation module based on large model cooperation, the target sentence in the given training instance and aspects , the true sentiment category of the example , the explicit and implicit representation of emotion and instructions for generation , the i-th analysis large model generates an explanation and example sentence The expression is: ; wherein, is the i-th analysis large model; Aggregated final explanations generated by large models and final example sentences The expression is: ; wherein, to aggregate large models, for instructions for aggregation, generated by the first analysis large model, generated by the mth analysis large model, m being the total number of analysis large models, generated by the first analysis large model, generated by the mth analysis large model.

3. The multi-teacher knowledge distillation based sentiment analysis system according to claim 2, wherein, In the process of introducing the final example sentence as additional input into the example sentence teacher model to predict the sentiment tendency of the given aspect in the input sentence, the following formula is satisfied: ; ; in, and These are the encoding module and classification module of the example sentence teacher model, respectively. Taking the emotional semantic representation learned by the teacher model as an example, Example: Given aspects learned by the teacher model The vector representation of , The matrix formed by the vector representations of all words in the final example sentence learned by the example sentence teacher model is used to construct the matrix. For example, the probability distribution of sentiment categories predicted by the teacher model; In the process of introducing the final explanation as additional input into the explanation teacher model to predict the sentiment tendency of the given aspect in the input sentence, the following formula is satisfied: ; ; wherein, and are an encoding module and a classification module, respectively, that explain the teacher model, is a sentiment semantic representation learned by the explain teacher model, is a vector representation of a given aspect learned by the explain teacher model is a matrix of vector representations of all words in the final explanation learned by the explain teacher model, is a matrix of vector representations of all words in the final explanation learned by the explain teacher model, is a probability distribution over sentiment classes predicted by the explain teacher model; In the process of introducing the final explanation and the final example sentence as additional input into the combined teacher model to predict the sentiment tendency of the given aspect in the input sentence, the following formula is satisfied: ; ; wherein, and are the encoding module and the classification module of the combined teacher model, respectively, is the sentiment semantic representation learned by the combined teacher model, is the vector representation of a given aspect learned by the combined teacher model , is the matrix of the vector representation of all words in the final explanation and the final example sentence learned by the combined teacher model, is the probability distribution over sentiment classes predicted by the combined teacher model.

4. The multi-teacher knowledge distillation based sentiment analysis system according to claim 3, wherein, The example sentence teacher model, the explanation teacher model and the combined teacher model are trained independently, and the cross-entropy cost used in the training process is respectively: ; ; ; wherein, is a human-annotated training dataset, is is one training instance in is a one-hot vector representation of the true sentiment class for the training instance, is a function that computes cross-entropy, , and are the cross-entropy costs of the example teacher model, the explanation teacher model, and the combined teacher model, respectively.

5. The multi-teacher knowledge distillation based sentiment analysis system according to claim 4, wherein, The mutual information values between the final example sentence and the aspect word-sentiment information are calculated based on the example sentence teacher model, and the expression is: ; ; ; ; wherein, is the mutual information value between the final example sentence and the aspect term-sentiment information, is the final example sentence is the number of words in the final example sentence, is the final example sentence is the mutual information value between the i-th word in the final example sentence and the aspect term-sentiment information, is the mutual information value between the i-th word and the sentiment information, is the mutual information value between the i-th word and the aspect term, and are respectively is the vector representation of the i-th word and the -th word in the final example sentence, is the cosine similarity calculation function, is the exponential function.

6. The multi-teacher knowledge distillation based sentiment analysis system according to claim 5, wherein, The credibility of each teacher model is calculated based on the obtained mutual information values, and the expression is: ; ; ; wherein, is the confidence of the example sentence teacher model, is the confidence of the explanation teacher model, is the confidence of the combined teacher model, is the activation function, is the mutual information value between the final explanation and aspect word-sentiment information, is the mutual information value between the final explanation and aspect word-sentiment information, is the preset mutual information threshold value, is the scaling coefficient.

7. The multi-teacher knowledge distillation based sentiment analysis system according to claim 6, wherein, The probability distribution of the emotion category predicted by each teacher model is weighted and fused with a uniform distribution to obtain a denoised probability distribution, expressed as: ; ; ; wherein, , and are the de-noised probability distributions corresponding to the example teacher model, the explanation teacher model and the combined teacher model, respectively, is a uniform distribution.

8. The multi-teacher knowledge distillation based sentiment analysis system according to claim 7, wherein, The adaptive weight learning mechanism based on reinforcement learning includes two policy networks, and a multi-objective reward function is used to optimize the policy networks. When the input training instance is an explicit sentiment representation, the explicit policy network is called to calculate the weight of each teacher model. When the input training instance is an implicit sentiment representation, the implicit policy network is called to calculate the weight of each teacher model, expressed as: The probability distribution of the emotion category predicted by each teacher model is weighted and fused with a uniform distribution to obtain a denoised probability distribution, expressed as: The adaptive weight learning mechanism based on reinforcement learning includes two policy networks, and a multi-objective reward function is used to optimize the policy networks. When the input training instance is an explicit sentiment representation, the explicit policy network is called to calculate the weight of each teacher model. When the input training instance is an implicit sentiment representation, the implicit policy network is called to calculate the weight of each teacher model, expressed as: ; ; wherein, and are an explicit policy network and an implicit policy network, respectively, , , are weight values of the example sentence teacher model, the explanation teacher model, and the combined teacher model learned by the policy network, respectively, is a state vector of the system at the current time, , , are state vectors of the example sentence teacher model, the explanation teacher model, and the combined teacher model at the current time, respectively. Based on , , , the multi-teacher knowledge distillation cost is defined as: ; ; wherein, is a function to compute the KL divergence between two probability distributions, is a probability distribution predicted by the student model about the sentiment class, is a weighted sum of the three teacher model predicted probability distributions; Finally, the total training cost of the student model is defined as: f = ∑i=1n (Ci - Ci*). ; ; wherein, is the cross-entropy cost for the student model, is a weight coefficient for the multi-teacher knowledge distillation cost.

9. The multi-teacher knowledge distillation based sentiment analysis system of claim 8, wherein, Training cost of policy network The expression is: ; ; ; ; wherein, is a reward for the policy network, is an entropy for the weight distribution, is a weight coefficient corresponding to the entropy regularizer, is a cross-entropy cost for the sample, is a knowledge distillation cost for the sample.

10. The multi-teacher knowledge distillation based sentiment analysis system of claim 9, wherein, In the multi-teacher-student knowledge distillation module of fusion reinforcement learning, based on Optimize the student model, based on Optimize the strategy network, the two optimization steps are alternated until convergence, and the trained student model is the final sentiment analysis model.

Citation Information

Patent Citations

  • Discourse relation recognition method and device based on knowledge distillation and multi-task learning

    CN112395876A

  • Deep fusion multi-cross-domain few-sample classification method based on knowledge distillation

    CN118799645A