False comment detection method based on accidental popular integration strategy
By adopting unexpected epidemic integration strategy and Bert preprocessing model in false comment detection, combining multiple individual classifiers and unexpected epidemic algorithms, the problem of difficult identification of false comments is solved, and a high-accuracy false comment detection is achieved.
Patent Information
- Application Number
- CN202411265889.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-11
- Publication Date
- 2025-03-25
AI Technical Summary
False comments attract public attention and discussion through artificial manipulation, disrupt the order of the network, and it is difficult for the existing technology to effectively identify false comments.
Using a false comment detection method based on unexpected popular integration strategy, the text is preprocessed through the Bert preprocessing model, multiple individual classifiers are constructed, classification confidence is calculated, and integrated learning is combined with unexpected popular algorithms, and the identification of false comments is finally realized.
The accuracy of false comment detection is improved, and experimental data show that the accuracy rate reaches more than 85% on multiple data sets, which is significantly better than traditional integration methods.
Smart Images

Figure SMS_3 
Figure SMS_8 
Figure SMS_19
Abstract
Description
Technical Field
[0001] The invention belongs to the field of computer science, and in particular relates to a false review detection method based on an unexpected popular integration strategy. Background Art
[0002] With the rapid development of the Internet, social networking platforms have become the main channels for people to obtain information, share opinions and communicate, and online comments have also become an important form of information sharing. However, while online comments bring people fast information exchange, they also bring challenges in information security. For some purpose, some online accounts will flood into posts to post comments, trying to attract public attention and discussion through artificial manipulation, thereby creating public opinion influence. Some of these false comments have similar wording and positions, and some are even copy-pasted, thus forming a large amount of similar content in a short period of time, causing the popularity of posts to soar exponentially.
[0003] Such false comments disrupt the order of the Internet and may also confuse people and mislead them to make wrong judgments. Therefore, maintaining the health of the Internet environment and the authenticity of information, and managing the phenomenon of false comments on the Internet has become an important task, and false comment detection research has emerged. Summary of the invention
[0004] The present invention proposes a false review detection method based on the unexpected popularity integration strategy. Firstly, the Bert preprocessing model is used to preprocess the text and remove stop words. Then, the currently known common binary classifiers are integrated, a model is trained for each classifier and each sample is predicted based on the classification confidence. The prior and posterior probabilities are calculated at the same time, and individual classifiers are constructed and their prediction results are combined with the idea of the unexpected popularity algorithm to obtain the final prediction result, so as to achieve the purpose of correctly identifying false comments.
[0005] A false review detection method based on an unexpected popular ensemble strategy is characterized by comprising the following steps: 1. Preprocessing a data set, removing stop words, and inputting the data set into a Bert model to obtain a character vector corresponding to the text; 2. Constructing multiple individual classifiers; 3. Calculating the classification confidence of each classifier for a test sample; and 4. Learning an unexpected popular ensemble strategy is realized in combination with the confidence.
[0006] The present invention mainly utilizes natural language processing technology, uses the Bert preprocessing model and ensemble learning as the main method to detect false comments. The text is preprocessed using the Bert model and stop words are removed. Then, individual classifiers are constructed, confidence and prior and posterior probabilities are calculated at the same time, and finally detection is performed through integration. The present invention effectively improves the detection accuracy by combining the unexpected popularity algorithm and confidence ensemble learning detection. DETAILED DESCRIPTION
[0007] The present invention designs a false review detection method based on an unexpected popular integration strategy, and the steps of the generation method thereof include: 1. preprocessing a data set, removing stop words, and inputting the data set into a Bert model to obtain a character vector corresponding to the text; 2. constructing a plurality of individual classifiers; 3. calculating the classification confidence of each classifier for a test sample; and 4. realizing unexpected popular integration strategy learning in combination with the confidence.
[0008] Step 1: Preprocess the data set, remove stop words, input it into the Bert model, and obtain the character vector corresponding to the text
[0009] The role of data preprocessing in text datasets is to clean the data, including removing meaningless symbols and words, and preparing it into the input format required by the Bert model. The Bert model is a Transformer-based language representation model proposed by Google, which is suitable for natural language processing tasks. Its structure includes a combination of Token Embeddings, Segment Embeddings, and Position Embeddings. Among them, Token Embeddings is a word vector, Segment Embeddings is used to distinguish sentences, and Position Embeddings is obtained through learning.
[0010] The Bert model uses the masked language model (MLM) as a pre-training target and predicts by randomly masking 15% of the words. This method forces the model to rely more on contextual information for prediction, while giving the model a certain error correction capability. The advantage of the Bert model is that it can handle a variety of NLP tasks and effectively deal with long-distance dependency problems.
[0011] By processing the text into character vectors and removing stop words through BertTokenizer, the subsequent operation process can be simplified.
[0012] Multiple review datasets were used for training and testing of algorithm models.
[0013] Randomly select 50% of the processed data as the training set and the remaining 50% as the test set.
[0014] Step 2: Construct multiple individual classifiers
[0015] The following five classifiers are used to obtain preliminary prediction results: Random Forest
[0016] In order to make the classifier more diversified, three different noise rates were introduced to flip the data labels, and three individual classifiers were trained on the data sets processed with the three kinds of noise for each of the above classifiers. A total of 15 different classifiers were obtained as individual classifiers, and two regression models were trained for each of the 15 classifiers.
[0017] Step 3: Calculate the classification confidence of each classifier for the test sample
[0018] For different individual classifiers, different confidence algorithms are adopted:
[0019] 1. For random forest, use weighted voting method to calculate confidence:
[0020] Confidence
[0021] where w i represents the weight of the i-th decision tree, v i Represents the number of votes predicted by the tree for this class.
[0022] 2. For logistic regression, the output probability represents the probability that each sample belongs to a certain category. The maximum result of each category probability is output to represent the confidence level:
[0023] Confidence C = max(p1, p2, ..., p i )
[0024] where p i It represents the predicted probability of the i-th category, and the max() function represents the maximum value of all items in the brackets.
[0025] 3. For the support vector machine, the distance measurement algorithm is also used to calculate the distance from the test sample to the support vector, normalize it with the maximum distance from all samples in the training set to the support vector, and use the normalized result as the confidence:
[0026] Confidence
[0027] Where dis is the distance from the test sample to the support vector, and max dis is the maximum distance from all samples in the support vector training set to the support vector.
[0028] 4. For the multilayer perceptron, output the maximum result output in each category of probability to indicate the confidence level:
[0029] Confidence C = max(p1, p2, ..., p i )
[0030] where p i It represents the predicted probability of the i-th category, and the max() function represents the maximum value of all items in the brackets.
[0031] 5. For the gradient boosting tree, for sample x i , calculate its distance to the kth classifier dis i , where dis i Represents the distance from the sample point to the classification hyperplane, i = 1, 2, ..., k, and is brought into the classification function sigmoid(x) to obtain the confidence prob before normalization +i :
[0032]
[0033] Then prob +i Normalize it to get the probability that the sample belongs to the i-th category, that is, the confidence level:
[0034] Confidence
[0035] Step 4: Combine confidence to achieve unexpected popular integration strategy learning
[0036] Given a training set sample D, select a total of N individual classifiers. For the kth classifier, calculate the consistency ratio of the other N-1 classifiers that agree with the classification result of "it", which is recorded as (represents the belief score of the k-th classifier for the i-th sample). The classification confidence of the k-th classifier for the i-th sample is recorded as Indicates that for all N-1 classifiers except the kth classifier, the sample x i The sum of the classification confidences of represents the classification confidence of the j-th classifier for the i-th sample. j (x i ) takes a value of 0 or 1, indicating that the jth classifier is good at classifying sample x i The classification result, f k (x i ) takes a value of 0 or 1, indicating that the kth classifier is good at classifying sample x i The classification results.
[0037] The calculation is as follows:
[0038]
[0039] This result is used as the new label for each training sample and As a new one-dimensional feature of the sample, x i Together they constitute the features of the sample, that is, the new training sample is recorded as Construct a new training data set D k , and divide the new training set into and Train two regression models for individual classifiers on these two training sets respectively (select random forest regression model) and For a total of N individual classifiers, the above process is performed.
[0040] For each sample in the test set, the prior probability of its label being 1 is calculated using the corresponding regression model based on the actual prediction results of each classifier. The calculation formula is as follows: Indicates The regression model for sample x i The regression value obtained; Indicates The regression model for sample x i The regression value obtained.
[0041]
[0042] After obtaining the predicted regression results of all individual classifiers, the prior and posterior probabilities of each sample are calculated according to the following formula:
[0043]
[0044] Where P(X i , 1) represents sample X i The prior probability of the classification result being 1, Q(X i , 1) represents sample X i The posterior probability of the classification result being 1
[0045] If P(X i , 1) <Q(X i , 1), label 1 is regarded as the true answer of "unexpected", that is, the final classification result is 1. Otherwise, 0 is regarded as the final classification result.
[0046] The present invention fully combines the classification confidence and the unexpected popularity algorithm to obtain a false review detection method with a wide range of applications and high accuracy. Experimental data proves that the accuracy rate reaches more than 85% in a given multiple data sets. The experimental results show that our method shows superior performance on multiple data sets, significantly outperforming traditional ensemble methods.
Claims
1. A fake review detection method based on unexpected popularity ensemble strategy, characterized by The following steps are involved: Step 1: Preprocess the data set, remove stop words, input it into the Bert model, and obtain the character vector corresponding to the text Step 2: Construct multiple individual classifiers The following five classifiers were selected to obtain preliminary prediction results: random forest, logistic regression, support vector machine, multilayer perceptron, and gradient boosting tree; Three different noise rates were introduced to flip the data labels. Three individual classifiers were trained on the data sets processed with the three noises for each of the above classifiers. A total of 15 different classifiers were obtained as individual classifiers, and two regression models were trained for each of the 15 classifiers. Step 3: Calculate the classification confidence of each classifier for the test sample For different individual classifiers, different confidence algorithms are adopted: 1) For random forest, the confidence is calculated using the weighted voting method: Confidence where w i represents the weight of the i-th decision tree, v i Indicates the number of votes predicted by the tree for this category; 2) For logistic regression, the output probability represents the probability that each sample belongs to a certain category; the maximum result in each category probability is output to represent the confidence level: Confidence C = max(p1,p2,······,p i ) where p i It represents the predicted probability of the i-th category, and the max() function represents the maximum value of all items in the brackets; 3) For the support vector machine, the distance metric algorithm is also used to calculate the distance from the test sample to the support vector, normalize it with the maximum distance from all samples in the training set to the support vector, and use the normalized result as the confidence: Confidence Where dis is the distance from the test sample to the support vector, and max dis is the maximum distance from all samples in the support vector training set to the support vector; 4) For the multi-layer perceptron, the maximum output of each probability is output to indicate the confidence level: Confidence C = max(p1,p2,······,p i ) where p i It represents the predicted probability of the i-th category, and the max() function represents the maximum value of all items in the brackets; 5) For the gradient boosting tree, for sample x i , calculate its distance to the kth classifier dis i , where dis i Represents the distance from the sample point to the classification hyperplane, i = 1, 2, ..., k, and is brought into the classification function sigmoid(x) to obtain the confidence prob before normalization +i : Then prob +i Normalize it to get the probability that the sample belongs to the i-th category, that is, the confidence level: Confidence Step 4: Combine confidence to achieve unexpected popular integration strategy learning Given a training set sample D, select a total of N individual classifiers. For the kth classifier, calculate the consistency ratio of the other N-1 classifiers that agree with the classification result of "it", which is recorded as represents the belief score of the k-th classifier for the i-th sample; the classification confidence of the k-th classifier for the i-th sample is recorded as Indicates that for all N-1 classifiers except the kth classifier, the sample x i The sum of the classification confidences of represents the classification confidence of the j-th classifier for the i-th sample; f j (x i ) takes a value of 0 or 1, indicating that the jth classifier is good at classifying sample x i The classification result,f k (x i ) takes a value of 0 or 1, indicating that the kth classifier is good at classifying sample x i The classification results; The calculation is as follows: This result is used as the new label for each training sample and As a new one-dimensional feature of the sample, x i Together they constitute the features of the sample, that is, the new training sample is recorded as Construct a new training data set D k , and divide the new training set into and Train 2 regression models for individual classifiers on these two training sets respectively and After training N individual classifiers; For each sample in the test set, the prior probability of its label being 1 is calculated using the corresponding regression model according to the actual prediction results of each classifier. The calculation formula is as follows: Indicates The regression model for sample x i The regression value obtained; Indicates The regression model for sample x i The regression value obtained; After obtaining the predicted regression results of all individual classifiers, the prior and posterior probabilities of each sample are calculated according to the following formula: Where P(X i ,1) represents sample X i The prior probability of the classification result being 1, Q(X i ,1) represents sample X i The posterior probability of the classification result being 1; If P(X i ,1) <Q(X i ,1), label 1 is regarded as the true answer of "unexpected", that is, the final classification result is 1; otherwise, 0 is regarded as the final classification result.