A data mining method and system for social robots

By combining multidimensional feature vectors and an improved sentiment analysis model with the sliding window retraining mechanism of the LSTM model, the problems of dirty data identification and sentiment tendency calculation bias in social robot data processing are solved, enabling accurate capture of user behavior and effective implementation of personalized interaction strategies.

CN120994807BActive Publication Date: 2026-03-24THE FIRST RES INST OF MIN OF PUBLIC SECURITY
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-07-30
Publication Date
2026-03-24

AI Technical Summary

Technical Problem

Existing technologies struggle to effectively identify and filter dirty data in social robot data processing. They lack global information redundancy assessment, leading to noise and repetitive text residues, biased sentiment calculations, and a lack of real-time incremental training mechanisms and proactive retraining strategies for long sequence modeling. User profiles are constructed in a single dimension, failing to accurately capture subtle emotional changes and behavioral inflection points.

Method used

User profiles are constructed using multidimensional feature vectors. An improved sentiment analysis model and an LSTM model are combined. A sliding window retraining mechanism is used, and a deduplication algorithm that sets a keyword quantity threshold and compares similarity sums is employed. Data cleaning and deduplication are performed through natural language processing and locality-sensitive hashing. The model is dynamically adjusted to adapt to changes in user behavior.

Benefits of technology

It improved data quality, accurately identified users' emotional states, enhanced the social robot's ability to capture the temporal characteristics of user behavior and the effectiveness of personalized interaction strategies, reduced noise interference, and enhanced the model's adaptability and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120994807B_ABST
    Figure CN120994807B_ABST
Patent Text Reader

Abstract

The application discloses a data mining method and system for a social robot. The method comprises the following steps: determining an interactive object currently communicating with the social robot and collecting social media data; performing word segmentation and vectorization processing on the text through a natural language processing algorithm, and extracting an emotional tendency value through an emotional analysis model, and dividing the data into multiple emotional grades according to a preset critical value; extracting keywords and topic fields based on word frequency statistics and topic clustering, and deleting the data if the number of keywords is lower than a threshold value; constructing time series data according to social behaviors and time stamps, predicting an active period and a behavior trend by using an LSTM model, and adjusting the model through a sliding window mechanism; and combining multi-dimensional feature vectors, and assigning personalized labels to the interactive object through clustering results. The application realizes accurate analysis of behavior and emotional characteristics of the interactive object, and provides an effective personalized interaction strategy for the social robot.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to a data mining method for social robots, and also to a corresponding data mining system, belonging to the field of data processing technology. Background Technology

[0002] For social robots to achieve truly human-like interaction, high-quality preprocessing of social media data is crucial. However, current technologies only perform simple regular expression matching or missing field removal during the data cleaning stage, making it difficult to identify and filter "dirty data" containing non-semantic characters or missing key fields. At the same time, content deduplication generally relies on local similarity threshold comparison, lacking a comprehensive assessment of global information redundancy, resulting in a large amount of noise and duplicate text residue, which directly reduces the accuracy of subsequent feature extraction and model training.

[0003] At the semantic understanding level, existing technologies mostly use static word vectors (such as Word2Vec) to represent text. Word weights are decoupled from frequency of occurrence, making it impossible to dynamically distinguish the true semantic value of high-frequency general words from low-frequency topic words, resulting in systematic biases in sentiment analysis. More seriously, when faced with complex emotions such as irony, humor, and metaphor, which are highly dependent on context and pragmatics, the recognition accuracy of existing sentiment dictionaries or shallow classifiers is generally below 60%, making it difficult for social robots to accurately capture users' instantaneous and subtle emotional changes.

[0004] With the introduction of the time dimension, the aforementioned problems become even more pronounced. Existing long sequence modeling still mainly relies on traditional RNN models or static LSTM models. Gradient vanishing and model solidification prevent the timely detection of "behavioral inflection points" such as sudden increases in user activity and abrupt changes in topic domains. The system lacks both a real-time incremental training mechanism and an active retraining strategy when prediction errors continuously exceed limits. After error accumulation, the accuracy drops by about 40% compared to dynamic models. In addition, user profile construction remains at a single dimension (word frequency or sentiment tags). Multi-dimensional features such as topic domains, sentiment levels, and activity cycles are not clustered collaboratively, causing the robot to only respond passively based on the current state. It cannot anticipate emotional fluctuations and adjust its language in advance, nor can it migrate across user groups and scenarios, severely restricting the emotional and intelligent upgrading of social robots. Summary of the Invention

[0005] The primary technical problem to be solved by this invention is to provide a data mining method for social robots.

[0006] Another technical problem to be solved by the present invention is to provide a data mining system for social robots.

[0007] To achieve the above-mentioned technical objectives, the present invention adopts the following technical solution:

[0008] According to a first aspect of the present invention, a data mining method for social robots is provided, comprising the following steps:

[0009] S1: Identify the current interaction partner with the social robot and collect the social media data that the interaction partner has authorized on the social platform; the social media data includes: text content, timestamps, and social behaviors;

[0010] S2: Natural language processing algorithms are used to segment and vectorize the text content; sentiment analysis models are used to extract the sentiment tendency value of each social media data and set several sentiment thresholds. Based on the sentiment tendency value and the sentiment threshold, each social media data is divided into different sentiment levels.

[0011] S3: Extract keywords and topic domains from text content based on word frequency statistics and topic clustering methods; if the number of keywords is lower than a preset threshold, delete the corresponding social media data;

[0012] S4: Based on social behavior and timestamps, construct time series data of interactive objects, build a time series prediction model based on LSTM model, and predict the future activity cycle and behavior trend of interactive objects; if the model deviation of the time series prediction model exceeds the deviation tolerance range, call the sliding window retraining mechanism to adjust the time series prediction model.

[0013] S5: Combine topic domain, keywords, sentiment values, activity cycles, and behavioral trends into a multi-dimensional feature vector of the interactive object. Input the multi-dimensional feature vector into the clustering model and assign personalized labels to the interactive object based on the clustering results.

[0014] Preferably, in step S1, after the social media data is collected, the method further includes: cleaning and deduplicating the social media data.

[0015] The cleaning process refers to: using regular expressions to remove non-semantic characters from the text content; and removing any social media data if it lacks the text content, timestamp, or social behavior.

[0016] The content deduplication process refers to: setting a similarity threshold in advance, using a locality-sensitive hashing algorithm to identify the similarity between any two text contents, and when the similarity is greater than or equal to the similarity threshold, calculating the sum of the similarities between the two text contents and all remaining text contents, and deleting the text contents with the relatively larger sum.

[0017] Preferably, in step S2, a natural language processing algorithm is used to segment and vectorize the text content, including the following steps:

[0018] First, word segmentation is performed based on a hidden Markov model;

[0019] Secondly, the co-occurrence frequency matrix between word segments is calculated based on the GloVe method. The co-occurrence frequency matrix is ​​decomposed to obtain the initial vector for each word segment. The magnitude of the initial vector is adjusted according to the occurrence frequency of each word in the collected text content to obtain the corrected vector. The direction of the corrected vector is consistent with the initial vector, and the corrected vector is calculated using the following formula:

[0020]

[0021] Among them, L a L0 is the correction vector; L0 is the initial vector; f is the number of times the current word appears in the collected text content; N is the amount of social media data.

[0022] Preferably, in step S2, extracting the sentiment tendency value of each piece of social media data using a sentiment analysis model includes the following steps:

[0023] Based on the sentiment lexicon, each word in the current text content is assigned a sentiment score. The sentiment tendency value is calculated based on the sentiment score and TF-IDF weights using the following formula:

[0024]

[0025] Among them, E sentiment S(w) represents the sentiment value, n represents the number of all words in the current text content, and S(w) represents the sentiment tendency value. i ) represents the sentiment score of the i-th word in the current text content, TF-IDF(w) i ) represents the TF-IDF weight of the i-th word in the current text content, w i This represents the i-th word in the current text content.

[0026] Preferably, in step S2, dividing each piece of social media data into multiple sentiment levels means: obtaining the maximum and minimum sentiment tendency values ​​among the sentiment tendency values, marking the minimum sentiment tendency value, the maximum sentiment tendency value, and two sentiment threshold values ​​on a number axis, dividing the line segment from the minimum sentiment tendency value to the maximum sentiment tendency value equally between the two sentiment threshold values ​​to form three intervals, which are respectively used as the first sentiment level, the second sentiment level, and the third sentiment level, and dividing the social media data into three sentiment levels according to the sentiment tendency value corresponding to each piece of social media data.

[0027] Preferably, step S3, which extracts keywords and topic domains from the text content based on word frequency statistics and topic clustering methods, includes the following steps:

[0028] First, obtain the product of the sentiment score and TF-IDF weight of each word segment, sort the product values ​​from largest to smallest, and select the top five words as keywords;

[0029] Secondly, the topic domain is obtained using the nonnegative matrix factorization method.

[0030] Preferably, in step S4, predicting the future activity cycle and behavioral trend of the interactive object refers to: acquiring social behavior, summarizing the social behavior according to a unified time unit based on the timestamp, converting the social behavior of the interactive object into an activity sequence grouped by time to obtain a time series dataset; inputting the time series dataset into a trained LSTM model to obtain the activity cycle and behavioral trend.

[0031] Preferably, in step S4, the sliding window retraining mechanism is invoked to adjust the time series prediction model, including the following sub-steps:

[0032] First, each time an active cycle and behavioral trend are generated, the current model deviation is obtained and compared with the preset tolerance range;

[0033] Secondly, when three consecutive model deviations are outside the tolerance range, the sliding window retraining mechanism is triggered.

[0034] The sliding window retraining mechanism involves using the data within the sliding window to incrementally train the time series prediction model. When the model deviation is not within the tolerance range after training, incremental training is repeated. When the model deviation is within the tolerance range after training, the incrementally trained time series prediction model is updated.

[0035] The model bias is the mean square error value of the prediction model.

[0036] Preferably, in step S5, assigning personalized labels to interactive objects based on clustering results and generating user profiles means: inputting the multidimensional feature vector of each interactive object into the K-means model, assigning the interactive object to the cluster closest to its cluster center, and using the cluster category to which the interactive object belongs as its personalized label.

[0037] According to a second aspect of the present invention, a data mining system for social robots is provided, including a data acquisition module, a text sentiment analysis module, a keyword extraction module, a behavior prediction module, and a user profile generation module;

[0038] The data collection module gathers authorized social media data from interacting users on social media platforms and sends this data to the text sentiment analysis module, keyword extraction module, and behavior prediction module. The text sentiment analysis module uses natural language processing algorithms to segment and vectorize the text content. It extracts the sentiment tendency value for each piece of social media data using a sentiment analysis model and sets several sentiment thresholds. Based on the sentiment tendency value and the thresholds, each piece of social media data is categorized into different sentiment levels. The keyword extraction module extracts keywords and topic domains from the text content based on word frequency statistics and topic clustering methods. If the number of keywords falls below a pre-set threshold, the corresponding social media data is deleted. The system collects and combines topic domains, keywords, sentiment values, activity cycles, and behavioral trends generated by the text sentiment analysis module, keyword extraction module, and behavior prediction module. It generates multi-dimensional feature vectors for interactive objects and inputs them into a clustering model. The clustering results are then used to assign personalized tags to the interactive objects. The behavior prediction module constructs time-series data of interactive objects based on social behavior and timestamps. It then builds a time-series prediction model based on an LSTM model to predict future activity cycles and behavioral trends. If the model deviation exceeds the tolerance range, a sliding window retraining mechanism is invoked to adjust the time-series prediction model.

[0039] Compared with existing technologies, this invention integrates multi-dimensional data to construct multi-dimensional feature vectors, comprehensively depicting user profiles. It employs an improved sentiment analysis model to enhance the accuracy of sentiment tendency value calculation, accurately identifying user emotional states. It innovatively combines an LSTM model with a sliding window retraining mechanism to effectively capture the temporal features of user behavior and dynamically adjust the model to adapt to changes in behavioral patterns. Simultaneously, it sets keyword quantity thresholds and a deduplication algorithm based on similarity summation to filter low-value and duplicate data, improving data quality. Finally, it generates personalized tags through clustering, achieving automatic identification of user interest groups and providing effective personalized interaction strategies for social robots. Attached Figure Description

[0040] Figure 1 This is a flowchart of a data mining method for social robots in the first embodiment of the present invention;

[0041] Figure 2 This is a schematic diagram of the structure of a data mining system for social robots in the second embodiment of the present invention. Detailed Implementation

[0042] The technical content of the present invention will now be described in detail with reference to the accompanying drawings and specific embodiments.

[0043] First Embodiment

[0044] like Figure 1 As shown, the first embodiment of the present invention provides a data mining method for social robots, which includes at least the following steps:

[0045] S1: Identify the current interaction partner with the social robot and collect the social media data that the interaction partner has authorized on the social platform; the social media data includes: text content, timestamps, and social behaviors.

[0046] S2: Natural language processing algorithms are used to segment and vectorize the text content; sentiment analysis models are used to extract the sentiment tendency value of each social media data and set several sentiment thresholds. Based on the sentiment tendency value and the sentiment threshold, each social media data is divided into different sentiment levels.

[0047] S3: Extract keywords and topic areas from text content based on word frequency statistics and topic clustering methods; if the number of keywords is lower than the preset threshold, delete the corresponding social media data.

[0048] S4: Based on social behavior and timestamps, construct time series data of interactive objects, build a time series prediction model based on LSTM model, and predict the future activity cycle and behavior trend of interactive objects; if the model deviation of the time series prediction model exceeds the deviation tolerance range, the sliding window retraining mechanism is called to adjust the time series prediction model.

[0049] S5: Combine topic domain, keywords, sentiment values, activity cycles, and behavioral trends into a multi-dimensional feature vector of the interactive object. Input the multi-dimensional feature vector into the clustering model and assign personalized labels to the interactive object based on the clustering results.

[0050] This invention achieves a comprehensive user profile by systematically integrating multi-dimensional data such as text content, timestamps, and social behavior (S1), and constructing a multi-dimensional feature vector (S5) that includes features such as sentiment, topic domain, and behavioral trends. Compared with traditional single-dimensional analysis methods, this method can more accurately reflect the comprehensive characteristics of users and provide data support for personalized interaction.

[0051] An improved sentiment analysis model (S2) incorporating TF-IDF weights is employed, significantly enhancing the accuracy of sentiment tendency calculations through dual calibration using a sentiment lexicon and semantic weights. Setting a sentiment threshold allows for sentiment level classification, enabling social robots to accurately identify users' emotional states (e.g., positive / neutral / negative), providing a quantitative basis for emotional responses.

[0052] This innovative approach employs an LSTM model combined with a sliding window retraining mechanism (S4), which not only captures the temporal characteristics of user behavior but also dynamically adjusts the model through real-time incremental training. Retraining is triggered when the prediction deviation exceeds the limit for three consecutive times, ensuring that the model always adapts to changes in user behavior patterns, resulting in a prediction accuracy improvement of approximately 40% compared to traditional static models.

[0053] By setting a keyword count threshold (S3) and using a deduplication algorithm based on similarity summation (as described in the manual), low-value content and duplicate data are effectively filtered out. Experiments show that this method can reduce noise interference by approximately 35%, while the topic domains extracted through non-negative matrix factorization are more semantically representative.

[0054] Finally, personalized tags (S5) generated through K-means clustering can automatically identify user interest groups. For example, users with "high-frequency activity - technology topics - positive emotions" can be labeled as "technology enthusiasts," enabling the chatbot to provide targeted information or product recommendations, resulting in a 28% increase in user satisfaction in actual testing.

[0055] In one embodiment of the present invention, step S1, after collecting social media data, further includes: cleaning and deduplicating the social media data;

[0056] Among them, cleaning refers to: using regular expressions to remove non-semantic characters from text content; and removing any social media data if it lacks text content, timestamps, or social behavior.

[0057] Content deduplication refers to: setting a similarity threshold in advance, using the Locality Sensitive Hash algorithm to identify the similarity between any two text contents, and when the similarity is greater than or equal to the similarity threshold, calculating the sum of the similarities between the two text contents and all remaining text contents, and deleting the text contents with the relatively larger sum.

[0058] It should be noted that this invention uses regular expressions to identify and remove non-semantic characters (such as special symbols, invalid emojis, garbled text, HTML tags, etc.), making the input text cleaner and more regular, thereby improving the ability of subsequent natural language processing models (such as BERT, LDA, sentiment analysis models, etc.) to understand the text content and extract features. By automatically removing abnormal data such as missing text content, timestamps, or social behaviors, it effectively prevents incomplete samples from misleading model training and semantic clustering results, ensuring the consistency and standardization of input data.

[0059] This invention introduces Locality Sensitive Hash (LSH) algorithms (such as SimHash and MinHash) to determine the similarity between any two social media texts and automatically identifies redundant information based on a set similarity threshold. Furthermore, by calculating the "total similarity sum" of similar texts and the entire dataset, more unique and representative text content is retained while highly redundant records are removed. This ensures the diversity, semantic coverage, and balanced feature distribution of the text set, contributing to improved generalization performance in social behavior modeling and user intent recognition.

[0060] The data deduplication process significantly reduces the number of duplicate or similar texts, enabling subsequent data processing workflows (such as word segmentation, word embedding, topic modeling, sentiment classification, etc.) to complete high-quality modeling on smaller datasets. This effectively reduces storage costs and computing resource consumption, making it particularly suitable for real-time data mining tasks in high-concurrency, large-scale social platform data scenarios, and improving overall response efficiency and scalability.

[0061] Cleaning and deduplication processes ensure the authenticity and independence of the input data, making the extracted user tags such as keywords, domain interests, and behavioral characteristics more accurate and discriminative, thereby significantly improving the completeness and interpretability of user profiles.

[0062] For user modeling methods based on neural networks or Transformer architectures, excessive repetition or invalid content can easily lead to training bias or overfitting. This invention addresses this by employing data cleaning and deduplication mechanisms, enabling the model to focus more on learning effective semantic features during training. This improves generalization ability across different data environments and ensures the model's stability and resilience during long-term operation.

[0063] The cleaning and deduplication scheme has the advantages of simple algorithm and flexible implementation. It can be integrated into the structured social data processing flow, or it can be embedded as a text preprocessing module into various third-party data analysis platforms or deep learning frameworks. It has good adaptability and transferability and is suitable for data processing needs of multiple language environments and multiple social media platforms.

[0064] In one embodiment of the present invention, step S2 involves using a natural language processing algorithm to segment and vectorize the text content, including the following steps:

[0065] First, word segmentation is performed based on a hidden Markov model;

[0066] Secondly, the co-occurrence frequency matrix between word segments is calculated based on the GloVe method. The co-occurrence frequency matrix is ​​decomposed to obtain the initial vector for each word segment. The magnitude of the initial vector is adjusted according to the occurrence frequency of each word in the collected text content to obtain the corrected vector. The direction of the corrected vector is consistent with the initial vector, and the corrected vector is calculated using the following formula:

[0067]

[0068] Among them, L a L0 is the correction vector; L0 is the initial vector; f is the number of times the current word appears in the collected text content; N is the amount of social media data.

[0069] It should be noted that f is determined as follows: when the current word appears in the text content of any social media data (regardless of how many times it appears), the value of f is incremented by 1.

[0070] This invention calculates the co-occurrence frequency matrix of word segments based on the GloVe model to obtain initial word vectors, and then adjusts the size of each word vector according to its frequency of occurrence in the text set. The vector size of frequently occurring general words (such as prepositions, conjunctions, and common auxiliary words) is appropriately compressed, while the vector size of important but low-frequency topic words is relatively enhanced. This makes the word vectors more accurate in representing semantic features and effectively distinguishes the core information in the text from background noise.

[0071] By dynamically adjusting the word vector size, the model becomes more sensitive to identifying representative and discriminative lexical features in downstream tasks such as user profiling, semantic clustering, and sentiment analysis, thereby improving the accuracy of text modeling, fine-grained classification capabilities, and the ability to identify subtle sentiment tendencies.

[0072] Compared with traditional static word vector methods, the frequency adjustment mechanism provided by this invention effectively suppresses the dominant effect of high-frequency but low-semantic-value words on text representation, avoids the "stop word pollution" phenomenon, improves the sparsity and representation efficiency of the feature space, and promotes the performance optimization of tasks such as feature selection, topic mining and relation reasoning.

[0073] This invention adjusts word vectors based on the internal statistics of the actual collected social media dataset, without relying on external fixed dictionaries or preset rules. It has good adaptability and can flexibly adapt to text data of different scales and different thematic fields (such as finance, medical, entertainment, etc.), enhancing its versatility and cross-scenario transferability.

[0074] By reasonably controlling the distribution of initial vector sizes, the risk of gradient explosion or gradient vanishing can be reduced, which can accelerate the convergence speed of neural networks during training, while improving robustness to abnormal data and input noise, and ensuring stable and reliable performance output when facing complex social data in the real world.

[0075] In step S2, the sentiment tendency value of each piece of social media data is extracted using a sentiment analysis model, including the following steps:

[0076] Based on the sentiment lexicon, each word in the current text content is assigned a sentiment score. The sentiment tendency value is calculated based on the sentiment score and TF-IDF weights using the following formula:

[0077]

[0078] Among them, E sentiment S(w) represents the sentiment value, n represents the number of all words in the current text content, and S(w) represents the sentiment tendency value. i ) represents the sentiment score of the i-th word in the current text content, TF-IDF(w) i ) represents the TF-IDF weight of the i-th word in the current text content, w i This represents the i-th word in the current text content, where i is a positive integer.

[0079] It should be noted that by introducing TF-IDF weights to weight the sentiment scores of each word segment, the influence of words that frequently appear in the text but have weak or neutral sentiment tendencies is weakened, and keywords with significant sentiment polarity in the sentiment lexicon are highlighted, thereby improving the accuracy of sentiment tendency value calculation and the distinguishability of sentiment differences between texts.

[0080] Secondly, by using word-level sentiment scores combined with TF-IDF weighting, we can not only reflect the overall dominant emotional direction of the text, but also keenly capture prominent positive or negative emotional signals in certain areas, improving the ability to perceive emotional details and helping to achieve more detailed and multi-layered sentiment analysis.

[0081] This invention normalizes the data based on the number of words segmented, effectively overcoming the bias in sentiment analysis caused by texts of different lengths and language styles. This results in sentiment values ​​with good scale consistency and cross-text comparability, making it suitable for analysis of loosely structured and highly variable social media content.

[0082] By accurately quantifying the sentiment of text, high-quality input features are provided for subsequent downstream tasks such as user sentiment trend modeling, social behavior prediction, and interest preference recognition. This can effectively improve the intelligence level and responsiveness of social robots, human-computer interaction methods, or marketing decision-making models.

[0083] Compared to traditional methods that simply weight sentiment words based on their scores, this invention introduces a TF-IDF dynamic weight control mechanism, which effectively filters out irrelevant terms with low value or strong generalization, significantly reduces sentiment judgment errors caused by text noise and non-emotional language components, and improves the robustness of sentiment classification and polarity recognition.

[0084] In step S2, dividing each piece of social media data into multiple sentiment levels means: obtaining the maximum and minimum sentiment values ​​among the sentiment tendency values, marking the minimum sentiment tendency value, the maximum sentiment tendency value, and two sentiment thresholds on the number axis, dividing the line segment from the minimum sentiment tendency value to the maximum sentiment tendency value equally between the two sentiment thresholds to form three intervals, which are respectively used as the first sentiment level (negative), the second sentiment level (neutral), and the third sentiment level (positive). Based on the sentiment tendency value corresponding to each piece of social media data, the social media data is divided into three sentiment levels.

[0085] It should be noted that the positive sentiment level increases sequentially from the first sentiment level to the third sentiment level. When the sentiment tendency value is less than the first sentiment threshold, the corresponding social media data is classified into the first sentiment level (negative); when the sentiment tendency value is greater than or equal to the second sentiment threshold, it is classified into the third sentiment level (positive); otherwise, if the sentiment tendency value is between the two thresholds, it is classified into the second sentiment level (neutral).

[0086] In one embodiment of the present invention, step S3, which involves extracting keywords and topic domains from the text content based on word frequency statistics and topic clustering methods, includes the following steps:

[0087] First, obtain the product of the sentiment score and TF-IDF weight of each word segment, sort the product values ​​from largest to smallest, and select the top five words as keywords;

[0088] Secondly, the topic domain is obtained using the nonnegative matrix factorization method.

[0089] This invention normalizes text based on the number of word segments, effectively overcoming the bias in sentiment analysis caused by texts of varying lengths and styles. This results in sentiment values ​​exhibiting good scale consistency and cross-text comparability, making it suitable for analyzing loosely structured and highly variable social media content. By accurately quantifying the sentiment of text, it provides high-quality input features for subsequent downstream tasks such as user sentiment trend modeling, social behavior prediction, and interest preference identification, effectively improving the intelligence and responsiveness of social robots, human-computer interaction methods, and marketing decision-making models.

[0090] In one embodiment of the present invention, step S4, predicting the future activity cycle and behavior trend of the interactive object, refers to: acquiring social behavior, summarizing the social behavior according to a unified time unit based on the timestamp, converting the social behavior of the interactive object into an activity sequence grouped by time, and obtaining a time series dataset; inputting the time series dataset into a trained LSTM model to obtain the activity cycle and behavior trend.

[0091] It should be noted that social behavior includes the type of user behavior (such as liking, commenting, sharing, etc.), the timestamp of the behavior, and the corresponding intensity indicators of the behavior. For example, the intensity of liking behavior can be represented by the number of likes, the intensity of commenting behavior can be represented by the length of the comment content or the emotional intensity, and the intensity of sharing behavior can be represented by the number of shares, etc.

[0092] In step S4, the sliding window retraining mechanism is invoked to adjust the time series prediction model, including the following steps:

[0093] First, each time an active cycle and behavioral trend are generated, the current model deviation is obtained and compared with the preset tolerance range;

[0094] Secondly, when three consecutive model deviations are outside the tolerance range, the sliding window retraining mechanism is triggered.

[0095] The sliding window retraining mechanism uses data within the sliding window to incrementally train the time series prediction model. When the model bias is not within the tolerance range after training, incremental training is repeated. When the model bias is within the tolerance range after training, the incrementally trained time series prediction model is updated. Here, the model bias is the mean squared error value of the prediction model.

[0096] It's important to note that the sliding window mechanism is a common time series data processing technique, primarily used to ensure that the model can dynamically adapt to the latest time series data. Specifically, the sliding window mechanism moves a fixed-size time window at each time step, within which the model is trained and predictions are made.

[0097] Window size (W): Determines the amount of data used during each model training iteration. Assuming a window size of W, only the data from the most recent W time steps is used during each training iteration.

[0098] Slide step size (S): Determines the step size of the window each time it moves. It is usually set to 1, which means that the window slides forward by one time step each time.

[0099] The tolerance range for bias refers to the allowable error range between the model's predicted values ​​and the actual observed values. If the error of the model's predicted values ​​exceeds this tolerance range, it indicates that the model's predictive ability may have decreased, and adjustments are needed.

[0100] Prediction error: The accuracy of a model’s predictions is usually evaluated using metrics such as mean squared error (MSE) or mean absolute error (MAE).

[0101] Bias tolerance interval (E_max): This is a predefined threshold. When the prediction error exceeds this threshold, it means that the model needs to be retrained.

[0102] When the model's prediction error exceeds the set bias tolerance range, the system triggers a sliding window mechanism to retrain the LSTM model. The specific process is as follows:

[0103] Data updates: The sliding window mechanism adds new data (e.g., recent social behavior data) to the training set and removes the oldest data, keeping the data window size constant.

[0104] Retrain the model: Based on the updated data window, retrain the LSTM model. This ensures that the model is always trained with the latest data and adapts to changes in user behavior patterns.

[0105] Evaluation and Adjustment: After training, evaluate the model's predictive performance and check if the prediction error has returned to the normal range. If the deviation is still large, it may be necessary to adjust the model parameters or further optimize the data preprocessing steps.

[0106] In one embodiment of the present invention, step S5, assigning personalized tags to interactive objects based on clustering results and generating user profiles, means: inputting the multidimensional feature vector of each interactive object into the K-means model, assigning the interactive object to the cluster closest to its cluster center, and using the cluster category to which the interactive object belongs as its personalized tag.

[0107] Second Embodiment

[0108] Based on the above method, the second embodiment of the present invention provides a data mining system for social robots, including a data acquisition module, a text sentiment analysis module, a keyword extraction module, a behavior prediction module, and a user profile generation module;

[0109] The data collection module gathers authorized social media data from interacting users on social media platforms and sends this data to the text sentiment analysis module, keyword extraction module, and behavior prediction module. The text sentiment analysis module uses natural language processing algorithms to segment and vectorize the text content. It extracts the sentiment tendency value for each piece of social media data using a sentiment analysis model and sets several sentiment thresholds. Based on the sentiment tendency value and the thresholds, each piece of social media data is categorized into different sentiment levels. The keyword extraction module extracts keywords and topic domains from the text content based on word frequency statistics and topic clustering methods. If the number of keywords falls below a pre-set threshold, the corresponding social media data is deleted. The system collects and combines topic domains, keywords, sentiment values, activity cycles, and behavioral trends generated by the text sentiment analysis module, keyword extraction module, and behavior prediction module. It generates multi-dimensional feature vectors for interactive objects and inputs them into a clustering model. The clustering results are then used to assign personalized tags to the interactive objects. The behavior prediction module constructs time-series data of interactive objects based on social behavior and timestamps. It then builds a time-series prediction model based on an LSTM model to predict future activity cycles and behavioral trends. If the model deviation exceeds the tolerance range, a sliding window retraining mechanism is invoked to adjust the time-series prediction model.

[0110] It should be noted that the above embodiments are merely illustrative examples. The technical solutions of each embodiment can be combined, and all are within the protection scope of this invention.

[0111] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this invention, "a plurality of" means two or more, unless otherwise explicitly specified.

[0112] The data mining method and system for social robots provided by this invention have been described in detail above. Any obvious modifications made by those skilled in the art without departing from the essence of this invention will constitute an infringement of the patent rights of this invention and will incur corresponding legal liability.

Claims

1. A data mining method for social robots, characterized in that... Includes the following steps: S1: Identify the current interaction partner with the social robot and collect the social media data that the interaction partner has authorized on the social platform; the social media data includes: text content, timestamps, and social behaviors; S2: Natural language processing algorithms are used to segment and vectorize the text content; sentiment analysis models are used to extract the sentiment tendency value of each social media data and set several sentiment thresholds. Based on the sentiment tendency value and the sentiment threshold, each social media data is divided into different sentiment levels. S3: Extract keywords and topic domains from text content based on word frequency statistics and topic clustering methods; if the number of keywords is lower than a preset threshold, delete the corresponding social media data; S4: Based on social behavior and timestamps, construct time series data of interactive objects, build a time series prediction model based on LSTM model, and predict the future activity cycle and behavior trend of interactive objects; if the model deviation of the time series prediction model exceeds the deviation tolerance range, call the sliding window retraining mechanism to adjust the time series prediction model. S5: Combine topic domain, keywords, sentiment value, activity cycle and behavioral trend into a multi-dimensional feature vector of the interactive object, input the multi-dimensional feature vector into the clustering model, and assign personalized labels to the interactive object based on the clustering results; In step S2, the sentiment tendency value of each piece of social media data is extracted using a sentiment analysis model, including the following steps: Based on the sentiment lexicon, each word in the current text content is assigned a sentiment score. The sentiment tendency value is then calculated using the following formula, based on the sentiment score and TF-IDF weights: ; in, This represents the sentiment tendency value. This represents the number of all words in the current text content. The sentiment score for the i-th word in the current text content. The TF-IDF weight of the i-th word in the current text content. This represents the i-th word in the current text content, where i is a positive integer.

2. The data mining method as described in claim 1, characterized in that... In step S1, after the social media data is collected, the method further includes cleaning and deduplicating the social media data. The cleaning process refers to: using regular expressions to remove non-semantic characters from the text content; and removing any social media data if it lacks the text content, timestamp, or social behavior. The content deduplication process refers to: setting a similarity threshold in advance, using a locality-sensitive hashing algorithm to identify the similarity between any two text contents, and when the similarity is greater than or equal to the similarity threshold, calculating the sum of the similarities between the two text contents and all remaining text contents, and deleting the text contents with the relatively larger sum.

3. The data mining method as described in claim 1, characterized in that... In step S2, a natural language processing algorithm is used to segment and vectorize the text content, including the following steps: First, word segmentation is performed based on a hidden Markov model; Secondly, the co-occurrence frequency matrix between word segments is calculated based on the GloVe method. This matrix is ​​then decomposed to obtain an initial vector for each word. The magnitude of the initial vector is adjusted according to the frequency of each word's occurrence in the collected text content to obtain a corrected vector. The corrected vector follows the same direction as the initial vector and is calculated using the following formula: ; in, For correction vectors; Use the initial vector; This represents the number of times the current word segment appears in the collected text content; The amount of social media data.

4. The data mining method as described in claim 1, characterized in that... In step S2, dividing each piece of social media data into multiple sentiment levels means: obtaining the maximum and minimum sentiment tendency values ​​among the sentiment tendency values, marking the minimum sentiment tendency value, the maximum sentiment tendency value, and two sentiment threshold values ​​on the number axis, dividing the line segment from the minimum sentiment tendency value to the maximum sentiment tendency value equally between the two sentiment threshold values ​​to form three intervals, which are respectively used as the first sentiment level, the second sentiment level, and the third sentiment level. Based on the sentiment tendency value corresponding to each piece of social media data, the social media data is divided into three sentiment levels.

5. The data mining method as described in claim 1, characterized in that... In step S3, the keywords and topic domains of the text content are extracted based on word frequency statistics and topic clustering methods, including the following steps: First, obtain the product of the sentiment score and TF-IDF weight of each word segment, sort the product values ​​from largest to smallest, and select the top five words as keywords; Secondly, the topic domain is obtained using the nonnegative matrix factorization method.

6. The data mining method as described in claim 1, characterized in that... In step S4, predicting the future activity cycle and behavior trend of the interactive object refers to: acquiring social behavior, summarizing the social behavior according to a unified time unit based on the timestamp, converting the social behavior of the interactive object into an activity sequence grouped by time to obtain a time series dataset; inputting the time series dataset into a trained LSTM model to obtain the activity cycle and behavior trend.

7. The data mining method as described in claim 1, characterized in that... In step S4, the sliding window retraining mechanism is invoked to adjust the time series prediction model, including the following steps: First, each time an active cycle and behavioral trend are generated, the current model deviation is obtained and compared with the preset tolerance range; Secondly, when three consecutive model deviations are outside the tolerance range, the sliding window retraining mechanism is triggered. The sliding window retraining mechanism involves using the data within the sliding window to incrementally train the time series prediction model. When the model deviation is not within the tolerance range after training, incremental training is repeated. When the model deviation is within the tolerance range after training, the incrementally trained time series prediction model is updated. The model bias is the mean square error value of the prediction model.

8. The data mining method as described in claim 1, characterized in that... In step S5, assigning personalized labels to interactive objects based on clustering results and generating user profiles means: inputting the multidimensional feature vector of each interactive object into the K-means model, assigning the interactive object to the cluster closest to its cluster center, and using the cluster category to which the interactive object belongs as its personalized label.

9. A data mining system for social robots, used to implement the data mining method according to any one of claims 1 to 8, characterized in that... It includes a data acquisition module, a text sentiment analysis module, a keyword extraction module, a behavior prediction module, and a user profile generation module; The data collection module gathers authorized social media data from interacting users on social media platforms and sends this data to the text sentiment analysis module, keyword extraction module, and behavior prediction module. The text sentiment analysis module uses natural language processing algorithms to segment and vectorize the text content. It extracts the sentiment tendency value for each piece of social media data using a sentiment analysis model and sets several sentiment thresholds. Based on the sentiment tendency value and the thresholds, each piece of social media data is categorized into different sentiment levels. The keyword extraction module extracts keywords and topic domains from the text content based on word frequency statistics and topic clustering methods. If the number of keywords falls below a pre-set threshold, the corresponding social media data is deleted. The system collects and combines topic domains, keywords, sentiment values, activity cycles, and behavioral trends generated by the text sentiment analysis module, keyword extraction module, and behavior prediction module. It generates multi-dimensional feature vectors for interactive objects and inputs them into a clustering model. The clustering results are then used to assign personalized tags to the interactive objects. The behavior prediction module constructs time-series data of interactive objects based on social behavior and timestamps. It then builds a time-series prediction model based on an LSTM model to predict future activity cycles and behavioral trends. If the model deviation exceeds the tolerance range, a sliding window retraining mechanism is invoked to adjust the time-series prediction model.

Citation Information

Patent Citations

  • Social media emotion situation analysis method based on multi-dimensional data

    CN118152641A

  • Artificial intelligence-based sentiment analysis system for monitoring social media

    DE202025101480U1