Emotional tendency judgment method fusing multiple features
By integrating multi-dimensional user data and using a multi-feature analysis model for sentiment prediction, this technology solves the problem of inaccurate sentiment analysis in existing technologies, achieving more accurate and comprehensive sentiment analysis and helping companies optimize their products and services.
Patent Information
- Application Number
- CN202510826195.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-19
- Publication Date
- 2025-11-18
AI Technical Summary
Existing sentiment analysis methods fail to fully utilize users' multi-dimensional behavioral data, resulting in inaccurate sentiment tendency judgments and a lack of in-depth analysis of user sentiment change trends, leading to incomplete analysis reports.
By acquiring multi-dimensional input data from users, including behavioral records, emotional states, and social network activities, a database is constructed and a multi-feature analysis model is used to extract users' sentiment tendency features, perform sentiment tendency prediction and matching, and generate sentiment tendency analysis reports.
It improves the accuracy and comprehensiveness of sentiment analysis, enabling early identification of user sentiment trends, providing personalized optimization suggestions, and enhancing user experience and satisfaction.
Smart Images

Figure CN120974018A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of sentiment analysis technology, specifically to a method for judging sentiment tendency by integrating multiple features. Background Technology
[0002] With the rapid development of the internet and social media, user feedback and emotional expression have become more diverse and convenient than ever before. By acquiring users' behavioral records, emotional states, and social network activities on various platforms, businesses can obtain users' true feelings and emotional tendencies towards their products or services. This emotional information has important guiding significance for decisions in product design, service optimization, and marketing. Sentiment analysis technology, as an important application of natural language processing, has been widely used in scenarios such as social media analysis and product evaluation analysis. Traditional sentiment analysis methods mostly rely on single text data or sentiment dictionaries. However, existing sentiment analysis methods do not fully utilize users' multi-dimensional behavioral data, such as purchase records, browsing history, and social comments, to make accurate judgments on sentiment tendencies. In addition, the results of user sentiment analysis are often discrete and lack in-depth analysis of user emotional change trends, resulting in analysis reports that are not comprehensive and accurate enough.
[0003] Therefore, sentiment analysis methods that integrate multi-dimensional data have become a research hotspot. This method integrates and analyzes user data from multiple sources to uncover users' emotional characteristics from multiple dimensions, including behavior, emotional state, and social networks, and then makes personalized sentiment predictions. Based on this, relevant companies can more effectively understand changes in user needs, improve customer experience, and optimize products and services. Summary of the Invention
[0004] To address the aforementioned technical problems, this paper provides a method for judging sentiment tendency by integrating multiple features. This technical solution solves the problems mentioned above.
[0005] To achieve the above objectives, the technical solution adopted by the present invention is as follows: A method for judging sentiment tendency by integrating multiple features, including: Acquire multi-dimensional input data from users, including user behavior records, emotional states, and social network activities; The acquired data will be used to build a database based on user IDs; Based on the user sentiment feature database, a multi-feature analysis model is used to extract users' sentiment tendency features and predict their sentiment tendency. By matching user sentiment characteristics with specific products, a sentiment analysis report is generated.
[0006] Preferably, the acquisition of multi-dimensional input data from users, including user behavior records, emotional states, and social network activities, specifically includes: The user behavior records in the multi-dimensional input data include the user's browsing history, the user's purchase history, and the user's social comments; Sentiment scoring is performed using natural language processing (NLP) techniques to obtain a sentiment score. The NLP formula is as follows:
[0007] In the formula, For emotional score, Natural Language Processing (NLP) technology For the first Social comment data The acquired data is used to build a database based on user IDs, and a recognition formula is used to identify users' emotional characteristics. The recognition formula is as follows:
[0008] In the formula, For users Emotional characteristics, For behavioral data, For emotional state data, This is for social comment data.
[0009] Preferably, data preprocessing is performed based on user behavior data, emotional state and social activity data extracted from the user emotional feature database, the preprocessing including removing missing values and outliers; The most representative features are extracted based on the correlation analysis formula using the Pearson correlation coefficient. The numerical features are standardized, and the categorical features are one-hot encoded. A sentiment prediction model is built based on a linear regression model. The model is trained using a training dataset, and hyperparameters are set. K-fold cross-validation was used to evaluate model performance. Based on the prediction results, analyze user sentiment trends, determine whether the user's sentiment inclination is positive, negative or neutral, and generate a sentiment inclination analysis report; Deploy the trained model to the production environment, perform sentiment prediction in real time, continuously monitor the model's prediction performance, and regularly update the training data and model to adapt to changes.
[0010] Preferably, the standardization of numerical features and one-hot encoding of categorical features specifically include: For each feature, obtain its mean and standard deviation, apply the standardization formula to standardize each feature value, and replace the original numerical feature with the standardized feature value. The standardized formula is as follows:
[0011] In the formula, These are the standardized eigenvalues. These are the original eigenvalues. The mean of the original features. The standard deviation of the original features; Identify the categorical features in the dataset that require one-hot encoding, create a new binary feature for the value of each categorical feature, add the one-hot encoded columns to the original dataset, and simultaneously delete the original categorical features.
[0012] Preferably, the extraction of the most representative features based on the Pearson correlation coefficient correlation analysis formula specifically includes: The formula for correlation analysis using the Pearson correlation coefficient is as follows:
[0013] Representing variables and variables The Pearson correlation coefficient between them These are sample data points for two variables. It is a variable and variables The mean.
[0014] Preferably, the model for predicting sentiment based on a linear regression model is trained using a training dataset, and the hyperparameters are specifically set as follows: The formula for the sentiment prediction model is as follows:
[0015] In the formula, For predicting sentiment tendencies, The intercept is... For the first The weights of each feature For the first 1 eigenvalue, For model parameters, Features.
[0016] Preferably, the use of K-fold cross-validation to evaluate model performance specifically includes: The K-fold cross-validation formula is as follows:
[0017] In the formula, For performance standard deviation, For the first One evaluation indicator, This represents average performance.
[0018] Preferably, the step of analyzing user sentiment trends based on prediction results, determining whether the user's sentiment tendency is positive, negative, or neutral, and generating a sentiment tendency analysis report specifically includes: The predicted sentiment outcomes of the model are categorized into positive sentiment, negative sentiment, and neutral sentiment. Based on the sentiment tags from user feedback, we further analyze the trends of sentiment, count the frequency of sentiment occurrence within a certain time range, and draw statistical charts to show the distribution of sentiment. Based on the results of sentiment analysis, summarize the overall situation of users' sentiment tendencies, including sentiment overview, sentiment change trends, sentiment hotspots, and provide optimization suggestions; Generate a structured sentiment analysis report, including a report summary, data sources and processing methods, sentiment analysis results, trend analysis, and conclusions and recommendations.
[0019] Preferably, the step of deploying the trained model to the production environment, performing sentiment prediction in real time, continuously monitoring the model's prediction performance, and regularly updating the training data and model to adapt to changes specifically includes: Export the trained model from the development environment to a format that can be loaded in the production environment, and configure the runtime environment in the production environment; Deploy the API service to the production environment to ensure that input data can be received and processed in real time and predictions can be made using the trained model. Monitor the model's predictive performance in real time, detecting prediction accuracy, latency, and throughput metrics; Monitor the accuracy, precision, and recall of the model's predictions to ensure the quality of sentiment analysis, and monitor the model's inference time in real time to ensure that it meets the requirements of real-time prediction. Monitor the health status of API services and data stream processing systems, set up an anomaly detection mechanism, and trigger an alarm if the performance of model predictions deteriorates or the deviation from the prediction results is large.
[0020] Preferably, the step of matching user sentiment characteristics with specific products to generate a sentiment analysis report specifically includes: Collect and clean user feedback data, use sentiment analysis models to classify and score user feedback based on sentiment, and match sentiment tendencies with products; Construct a report structure that displays sentiment distribution, trends, hot words, issues and suggestions. Present sentiment analysis results using charts and word clouds. Regularly update and optimize the sentiment analysis report to ensure data privacy and compliance.
[0021] Compared with the prior art, the beneficial effects of the present invention are as follows: This invention provides a multi-feature-integrated sentiment tendency judgment method that can fully utilize users' multi-dimensional input data, such as behavioral records, emotional states, and social network activities. By combining advanced sentiment analysis technology and multi-feature models, it can accurately judge users' sentiment tendencies and make trend predictions. This method not only improves the accuracy of sentiment analysis, but also provides enterprises with more valuable decision-making basis through real-time prediction and personalized matching, and helps enterprises continuously optimize products and services, improve user experience and satisfaction. Attached Figure Description
[0022] Figure 1 This is a flowchart illustrating the steps of the present invention. Detailed Implementation
[0023] The following description is intended to disclose the invention and enable those skilled in the art to implement it. The preferred embodiments described below are merely examples, and other obvious variations will occur to those skilled in the art.
[0024] Reference Figure 1 As shown, a sentiment tendency judgment method integrating multiple features includes: Acquire multi-dimensional input data from users, including user behavior records, emotional states, and social network activities; The acquired data will be used to build a database based on user IDs; Based on the user sentiment feature database, a multi-feature analysis model is used to extract users' sentiment tendency features and predict their sentiment tendency. By matching user sentiment characteristics with specific products, a sentiment analysis report is generated.
[0025] Acquiring multi-dimensional input data from users, including user behavior records, emotional states, and social network activities, specifically including: The user behavior records in the multi-dimensional input data include the user's browsing history, the user's purchase history, and the user's social comments; Sentiment scoring is performed using natural language processing (NLP) techniques to obtain a sentiment score. The NLP formula is as follows:
[0026] In the formula, For emotional score, Natural Language Processing (NLP) technology For the first Social comment data The acquired data is used to build a database based on user IDs, and a recognition formula is used to identify users' emotional characteristics. The recognition formula is as follows:
[0027] In the formula, For users Emotional characteristics, For behavioral data, For emotional state data, For social comment data; By integrating multi-dimensional data such as user behavior records, emotional states, and social network activities, this method can more comprehensively capture users' emotional tendencies. Traditional sentiment analysis methods often rely on single text data, which often cannot accurately express users' emotional states. The integration of multi-dimensional data can provide more information, thereby improving the accuracy and comprehensiveness of sentiment analysis.
[0028] Based on a user sentiment feature database, a multi-feature analysis model is used to extract users' sentiment tendency features and predict their sentiment tendency. Specifically, this includes: Data preprocessing is performed based on user behavior data, emotional state data, and social activity data extracted from a user emotional feature database. The preprocessing includes removing missing values and outliers. The most representative features are extracted based on the correlation analysis formula using the Pearson correlation coefficient. The numerical features are standardized, and the categorical features are one-hot encoded. A sentiment prediction model is built based on a linear regression model. The model is trained using a training dataset, and hyperparameters are set. K-fold cross-validation was used to evaluate model performance. Based on the prediction results, analyze user sentiment trends, determine whether the user's sentiment inclination is positive, negative or neutral, and generate a sentiment inclination analysis report; Deploy the trained model to the production environment, perform sentiment prediction in real time, continuously monitor the model's prediction performance, and regularly update the training data and model to adapt to changes. By establishing a multi-feature analysis model based on a user sentiment feature database and predicting sentiment tendencies, companies can identify changes in user sentiment trends in advance and make timely decisions. For example, before a product launch, they can predict users' sentiment tendencies toward new products and make corresponding marketing adjustments.
[0029] Standardizing numerical features and one-hot encoding categorical features specifically include: For each feature, obtain its mean and standard deviation, apply the standardization formula to standardize each feature value, and replace the original numerical feature with the standardized feature value. The standardized formula is as follows:
[0030] In the formula, These are the standardized eigenvalues. These are the original eigenvalues. The mean of the original features. The standard deviation of the original features; Identify the categorical features in the dataset that require one-hot encoding, create a new binary feature for the value of each categorical feature, add the one-hot encoded columns to the original dataset, and simultaneously delete the original categorical features.
[0031] The most representative features extracted based on the Pearson correlation coefficient correlation analysis formula include: The formula for correlation analysis using the Pearson correlation coefficient is as follows:
[0032] Representing variables and variables The Pearson correlation coefficient between them These are sample data points for two variables. It is a variable and variables The mean; This method can match users' emotional tendencies with specific products or services to generate personalized emotional tendency analysis reports. Businesses can not only understand which products or services are favored by users and which may trigger negative emotions, but also provide targeted optimization suggestions based on the analysis results, such as improving product design and adjusting customer service.
[0033] A sentiment prediction model based on linear regression is established. The model is trained using a training dataset, and the hyperparameters are specifically set as follows: The formula for the sentiment prediction model is as follows:
[0034] In the formula, For predicting sentiment tendencies, The intercept is... For the first The weights of each feature For the first 1 eigenvalue, For model parameters, Features.
[0035] Using K-fold cross-validation to evaluate model performance specifically includes: The K-fold cross-validation formula is as follows:
[0036] In the formula, For performance standard deviation, For the first One evaluation indicator, This represents average performance.
[0037] Based on the prediction results, analyze user sentiment trends, determine whether users' sentiment inclination is positive, negative, or neutral, and generate a sentiment tendency analysis report, which specifically includes: The predicted sentiment outcomes of the model are categorized into positive sentiment, negative sentiment, and neutral sentiment. Based on the sentiment tags from user feedback, we further analyze the trends of sentiment, count the frequency of sentiment occurrence within a certain time range, and draw statistical charts to show the distribution of sentiment. Based on the results of sentiment analysis, summarize the overall situation of users' sentiment tendencies, including sentiment overview, sentiment change trends, sentiment hotspots, and provide optimization suggestions; Generate a structured sentiment analysis report, including a report summary, data sources and processing methods, sentiment analysis results, trend analysis, and conclusions and recommendations.
[0038] Deploying the trained model to the production environment, performing sentiment prediction in real time, continuously monitoring the model's prediction performance, and regularly updating the training data and model to adapt to changes specifically includes: Export the trained model from the development environment to a format that can be loaded in the production environment, and configure the runtime environment in the production environment; Deploy the API service to the production environment to ensure that input data can be received and processed in real time and predictions can be made using the trained model. Monitor the model's predictive performance in real time, detecting prediction accuracy, latency, and throughput metrics; Monitor the accuracy, precision, and recall of the model's predictions to ensure the quality of sentiment analysis, and monitor the model's inference time in real time to ensure that it meets the requirements of real-time prediction. Monitor the health status of API services and data stream processing systems, set up an anomaly detection mechanism, and trigger an alarm if the performance of model predictions deteriorates or the deviation from the prediction results is large.
[0039] Matching user sentiment traits with specific products to generate a sentiment analysis report includes: Collect and clean user feedback data, use sentiment analysis models to classify and score user feedback based on sentiment, and match sentiment tendencies with products; Construct a report structure that displays sentiment distribution, trends, hot words, issues and suggestions. Present sentiment analysis results using charts and word clouds. Regularly update and optimize the sentiment analysis report to ensure data privacy and compliance.
[0040] In summary, the advantages of this invention are as follows: By integrating multi-dimensional data such as user behavior records, emotional states, and social network activities, this method can more comprehensively capture users' emotional tendencies. Traditional sentiment analysis methods often rely on single text data, which often cannot accurately express users' emotional states. The integration of multi-dimensional data can provide more information, thereby improving the accuracy and comprehensiveness of sentiment analysis. By establishing a multi-feature analysis model based on a user sentiment feature database and predicting sentiment tendencies, companies can identify changes in user sentiment trends in advance and make timely decisions. For example, before a product launch, they can predict users' sentiment tendencies toward new products and make corresponding marketing adjustments. This method can match users' emotional tendencies with specific products or services to generate personalized emotional tendency analysis reports. Businesses can not only understand which products or services are favored by users and which may trigger negative emotions, but also provide targeted optimization suggestions based on the analysis results, such as improving product design and adjusting customer service. This method deploys a trained sentiment prediction model to a production environment, enabling real-time prediction of user sentiment. Enterprises can make dynamic adjustments based on real-time sentiment analysis results, respond to users' negative emotions in a timely manner, and provide corresponding solutions, thereby enhancing user satisfaction and loyalty. By combining visualization technologies such as charts and word clouds, the sentiment analysis report is not only clearly structured but also easy for decision-makers to understand. Through data visualization, companies can see sentiment distribution, trends, and hotspots more intuitively, helping decision-makers make more accurate strategic adjustments in a short period of time. This method possesses self-updating and optimization capabilities. By regularly monitoring the model's predictive performance and updating the training data, the model can adapt to changes in user behavior and sentiment, ensuring the accuracy and timeliness of predictions. In this way, businesses can remain sensitive to market trends and continuously improve their products and services. This method emphasizes data privacy protection and compliance, ensuring that data collection, processing and analysis comply with relevant laws and regulations. For the processing of sensitive data, it can adopt technical means such as anonymization and encryption to ensure that users' privacy is not violated.
[0041] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely principles of the invention. Various changes and modifications can be made to the invention without departing from its spirit and scope, and all such changes and modifications fall within the scope of the claimed invention. The scope of protection claimed by the appended claims and their equivalents is defined.
Claims
1. A method for fusing multi-features sentiment tendency judgment, characterized in that, The application relates to a method for predicting the emotional tendency of a user, and a system thereof. The method comprises the following steps: acquiring multi-dimensional input data of a user, the data comprising the behavior record, emotional state and social network activity of the user; constructing a database according to the user ID of the acquired data; based on the user emotional feature database, using a multi-feature analysis model to extract the emotional tendency features of the user and performing emotional tendency prediction; 2.The method according to claim 1, characterized in that, matching the emotional tendency features of the user with a specific product to generate an emotional tendency analysis report. The method for acquiring multi-dimensional input data of a user, the data comprising the behavior record, emotional state and social network activity of the user specifically comprises the following steps: the user behavior record in the multi-dimensional input data comprises the browsing history of the user, the purchase record of the user and the social comment of the user; In the formula, is an emotional score, is a natural language processing technique, is a first social comment data using a natural language processing technology to perform emotional scoring to obtain an emotional score, wherein the natural language processing technology formula is: wherein is a user emotional feature, is behavioral data, is emotional state data, is social comment data. 3.The method according to claim 2, characterized in that, constructing a database according to the user ID of the acquired data, and using an identification formula to identify the emotional features of the user, wherein the identification formula is: based on the user emotional feature database, using a multi-feature analysis model to extract the emotional tendency features of the user and performing emotional tendency prediction specifically comprises the following steps: based on the behavior data, emotional state and social activity data of the user extracted from the user emotional feature database, performing data preprocessing, wherein the preprocessing comprises removing missing values and abnormal values; based on a Pearson correlation coefficient correlation analysis formula, extracting the most representative features; performing standardization processing on the numerical features and performing one-hot encoding on the classification features; based on a linear regression model, establishing an emotional tendency prediction model, using a training data set to train the model, and setting hyperparameters; using K-fold cross validation to evaluate the performance of the model; according to the prediction result, analyzing the emotional trend of the user, determining whether the emotional tendency of the user is positive, negative or neutral, and generating an emotional tendency analysis report; 4. The method of claim 3, wherein the method further comprises: deploying the trained model to a production environment to perform real-time emotional tendency prediction, continuously monitoring the prediction performance of the model, and regularly updating the training data and the model to adapt to changes. The method for performing standardization processing on the numerical features and performing one-hot encoding on the classification features specifically comprises the following steps: for each feature, obtaining the mean and standard deviation thereof, applying a standardization formula to standardize each feature value, and replacing the original numerical feature with the standardized feature value; In the formula, is the standardized feature value, is the original feature value, is the mean value of the original feature, is the standard deviation value of the original feature; wherein the standardization formula is:
5. The method of claim 4, wherein the method further comprises: determining the classification features in the data set that need to be one-hot encoded, creating new binary features for the value of each classification feature, and adding the one-hot encoded columns to the original data set while selecting to delete the original classification features. The method for extracting the most representative features based on a Pearson correlation coefficient correlation analysis formula specifically comprises the following steps: denotes a variable and a variable , the Pearson correlation coefficient between is a sample data point of two variables is a variable and a variable .
6. The method of claim 3, wherein the method further comprises: wherein the Pearson correlation coefficient correlation analysis formula is: The method for establishing an emotional tendency prediction model based on a linear regression model, using a training data set to train the model, and setting hyperparameters specifically comprises the following steps: wherein the emotional tendency prediction model formula is: wherein is the predicted sentiment tendency, is the intercept, is the weight of the th feature, is the th feature value, is the model parameter, is the feature.
7. The method of claim 6, wherein the step of fusing the multi-features is performed by using a fusion algorithm. The method for using K-fold cross validation to evaluate the performance of the model specifically comprises the following steps: wherein the K-fold cross validation formula is: The method for analyzing the emotional trend of the user according to the prediction result, determining whether the emotional tendency of the user is positive, negative or neutral, and generating an emotional tendency analysis report specifically comprises the following steps: In the formula, is the performance standard deviation, is the performance of the evaluation index, is the average performance.
8. The method of claim 7, wherein the method further comprises: Classifying the model-predicted sentiment results into positive, negative, and neutral sentiments; Based on the user feedback sentiment labels, further analyze the sentiment trends, count the frequency of sentiment occurrence within a certain time range, and draw statistical charts to show the distribution of sentiment; According to the results of sentiment analysis, summarize the overall situation of user sentiment tendency, including sentiment overview, sentiment change trend, sentiment hotspots, and provide optimization suggestions; Generate structured sentiment tendency analysis report, including report abstract, data source and processing method, sentiment analysis result, trend analysis and conclusion and suggestion.
9. The method of claim 8, wherein the method further comprises: The trained model is deployed to the production environment for real-time sentiment tendency prediction, and the model prediction performance is continuously monitored, and the training data and model are updated regularly to adapt to changes, which specifically includes: Export the trained model from the development environment to a format that can be loaded in the production environment, and configure the running environment in the production environment; Deploy the API service to the production environment to ensure that it can receive and process input data in real time and make predictions through the trained model; Monitor the prediction performance of the model in real time to detect the accuracy, delay, and throughput of the prediction; Monitor the accuracy, precision, and recall rate of the model prediction to ensure the quality of sentiment analysis, and monitor the inference time of the model in real time to ensure that it meets the real-time prediction requirements; Monitor the health status of the API service and data flow processing system, set up an anomaly detection mechanism, and trigger an alarm once the model prediction performance drops significantly or the prediction result deviates greatly.
10. The method of claim 9, wherein the method further comprises: The matching of user sentiment tendency features with specific products to generate sentiment tendency analysis report specifically includes: Collect and clean user feedback data, use sentiment analysis model to classify and score user feedback, and match sentiment tendency with products; Build a report structure to show sentiment distribution, trend, hot words, questions and suggestions, display sentiment analysis results through charts and word clouds, regularly update and optimize sentiment analysis report, and ensure data privacy and compliance.