Content marketing user behavior prediction method and system based on big data analysis
By preprocessing and feature enhancement of user behavior data, combined with transfer learning and federated learning, the problems of feature representation and data security in user behavior prediction in content marketing are solved, enabling precise marketing strategy optimization and privacy protection, and improving the accuracy of prediction results and the reliability of the system.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEIJING GALAXY GRAVITY TECHNOLOGY CO LTD
- Filing Date
- 2025-10-20
- Publication Date
- 2026-04-14
AI Technical Summary
In existing technologies, content marketing user behavior prediction suffers from problems such as difficulty in establishing a unified feature representation space and insufficient protection of user data security and privacy by traditional centralized prediction models.
By collecting user behavior data, establishing user identifier mapping relationships, performing preprocessing and feature enhancement, constructing a unified feature representation space using transfer learning methods, performing distributed prediction by combining clustering algorithms and federated learning, and adopting reinforcement learning optimization strategies to achieve data privacy protection.
It improves the expressive power and generalization performance of user behavior characteristics, ensures data security, and enhances the accuracy and conversion effect of content marketing.
Smart Images

Figure CN121350658B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of content marketing technology, and in particular to a method and system for predicting user behavior in content marketing based on big data analysis. Background Technology
[0002] With the rapid development of internet technology and big data analytics, content marketing has become an important means for businesses to reach users and promote their brands.
[0003] By analyzing and predicting user behavior data on content marketing platforms, businesses can better understand user needs and formulate precise marketing strategies. Mainstream content marketing platforms have accumulated massive amounts of user behavior data, including multi-dimensional information such as browsing, clicking, collecting, and sharing, which contains rich user preferences and behavioral pattern characteristics, providing an important data foundation for achieving precision marketing.
[0004] However, in existing technologies, content marketing user behavior prediction still faces problems such as difficulty in establishing a unified feature representation space, the need for traditional centralized prediction models to centrally store and process all user data, significant risks in data security and user privacy protection, and limited ability to express user behavior characteristics.
[0005] Therefore, a solution is urgently needed to address the problems existing in the current technology. Summary of the Invention
[0006] This invention provides a method and system for predicting user behavior in content marketing based on big data analysis, which can at least solve some of the problems existing in the prior art.
[0007] A first aspect of this invention provides a method for predicting user behavior in content marketing based on big data analysis, comprising:
[0008] Collect users' historical behavior data on content marketing platforms, establish user identifier mapping relationships, preprocess the historical behavior data, and generate user behavior feature vectors by removing abnormal data, normalizing, and reducing feature dimensionality.
[0009] The user behavior feature vector is enhanced based on the transfer learning method. A unified feature representation space is established for user behavior feature vectors in different scenarios through cross-scenario feature mapping. The weight coefficients are dynamically allocated according to the feature importance score to achieve adaptive adjustment of feature weights.
[0010] The enhanced user behavior feature vectors are processed using a clustering algorithm to calculate the similarity distance between user features and to divide users into a first user group, a second user group, and a third user group based on the similarity distance.
[0011] A distributed prediction method based on federated learning is constructed. Local prediction algorithms are independently trained on various data sources through local training units. The parameters of multiple local prediction algorithms are fused by weighted averaging, and random noise is added to the algorithm parameters to protect data privacy.
[0012] The data of the first user group, the second user group, and the third user group are respectively input into the distributed prediction method to obtain user behavior prediction results. The user behavior prediction results are then optimized by a reinforcement learning algorithm according to a preset reward function to generate content marketing strategy data.
[0013] In one alternative implementation,
[0014] Collecting historical user behavior data on content marketing platforms, establishing user identifier mapping relationships, and preprocessing the historical behavior data to generate user behavior feature vectors through outlier removal, normalization, and feature dimensionality reduction include:
[0015] Collect users’ historical behavior data on the content marketing platform. The historical behavior data includes user identifier, behavior type and timestamp.
[0016] The user identifiers in the historical behavior data are uniformly mapped, a cross-platform user identifier association table is established, and historical behavior data with the same user identifier are associated and merged.
[0017] The interquartile range of numerical features is calculated using box plots. Data exceeding 1.5 times the interquartile range above and below the quartile are marked as outliers and deleted. Missing values are filled according to the mean of the feature they belong to. The numerical features are normalized to their maximum and minimum values, mapping the feature values to the [0, 1] interval. Categorical features are one-hot encoded. Principal component analysis is used to reduce the dimensionality of high-dimensional features. Principal components with a cumulative contribution rate reaching a preset threshold are selected to construct a standardized user behavior feature vector.
[0018] In one alternative implementation,
[0019] The user behavior feature vector is enhanced using transfer learning. A unified feature representation space is established for user behavior feature vectors in different scenarios through cross-scenario feature mapping. Weight coefficients are dynamically allocated based on feature importance scores to achieve adaptive adjustment of feature weights.
[0020] The system receives user behavior feature vectors from a source domain feature space and user behavior feature vectors from a target domain feature space, wherein the user behavior feature vectors from the source domain feature space and the user behavior feature vectors from the target domain feature space have different distribution characteristics.
[0021] A dual-stream neural network structure is constructed through cross-scene feature mapping. The dual-stream neural network structure includes a source domain feature extraction subnetwork and a target domain feature extraction subnetwork. A first mapping feature is obtained by nonlinearly transforming the user behavior feature vector in the source domain feature space using a first feature mapping function pre-set in the source domain feature extraction subnetwork. A second mapping feature is obtained by nonlinearly transforming the user behavior feature vector in the target domain feature space using a second feature mapping function pre-set in the target domain feature extraction subnetwork.
[0022] The feature distribution difference is obtained by calculating the L2 distance between the mean of the first mapped feature sample and the mean of the second mapped feature sample in the regenerating kernel Hilbert space based on the maximum mean difference criterion. The feature distribution difference is then input into a dynamic kernel selection mechanism, which includes multiple preset Gaussian kernel functions. The optimal kernel function combination is obtained by iteratively optimizing the weight coefficients of the multiple preset Gaussian kernel functions through the gradient descent method.
[0023] The system receives the first mapping feature and the second mapping feature, performs a linear transformation using a pre-set learnable transformation matrix, and then obtains the feature hidden layer representation through the hyperbolic tangent activation function. The system then performs an inner product operation between the pre-set learnable attention vector and the feature hidden layer representation to obtain the importance score for each feature dimension.
[0024] The feature importance scores are normalized using softmax to obtain feature weight coefficients. L1 norm sparsity regularization constraints are applied to the feature weight coefficients. The sparsity of the feature weights is controlled by setting the regularization coefficients to obtain sparsified feature weight coefficients.
[0025] The sparse feature weight coefficients are applied to the first mapping feature and the second mapping feature respectively to obtain the enhanced feature representation in the unified feature representation space, wherein the sparse feature weight coefficients are used to highlight the contribution of important feature dimensions and suppress the influence of irrelevant feature dimensions.
[0026] In one alternative implementation,
[0027] After performing a linear transformation using a pre-set learnable transformation matrix, a feature hidden layer representation is obtained through a hyperbolic tangent activation function. The importance score for each feature dimension is then obtained by performing an inner product operation between the pre-set learnable attention vector and the feature hidden layer representation, including:
[0028] An adversarial learning module is constructed, which includes a feature generator and a feature discriminator. The feature generator receives input features and generates adversarial features. The feature discriminator outputs a discrimination probability based on the input features and the adversarial features. The feature generator is trained based on the discrimination probability.
[0029] The input features and the adversarial features are linearly transformed using a learnable transformation matrix to obtain a first feature representation and an adversarial feature representation, respectively. The learnable transformation matrix is then adversarially trained based on the discriminant probability. The first feature representation and the adversarial feature representation are then input into a hyperbolic tangent activation function to obtain a feature hidden layer representation and an adversarial feature hidden layer representation, respectively. The feature hidden layer representation and the adversarial feature hidden layer representation are used to construct contrastive learning samples.
[0030] A dynamically maintained feature queue is constructed based on the contrastive learning samples. The historical representations of the feature hidden layer representations are stored in the feature queue. Positive sample pairs are constructed based on the historical representations and the current feature hidden layer representations in the feature queue. Negative sample pairs are constructed based on the adversarial feature hidden layer representations. The similarity between the positive sample pairs and the similarity between the negative sample pairs are calculated. The calculation result of the similarity is used as the contrastive loss. The contrastive loss is used to optimize the feature hidden layer representations to obtain the optimized feature hidden layer representations.
[0031] Initialize a learnable attention vector, update the parameters of the learnable attention vector based on the contrastive loss, and perform an inner product operation between the updated learnable attention vector and the optimized feature hidden layer representation to obtain the importance score of each feature dimension.
[0032] In one alternative implementation,
[0033] The enhanced user behavior feature vectors are processed using a clustering algorithm. The similarity distance between user features is calculated, and users are divided into a first user group, a second user group, and a third user group based on this similarity distance.
[0034] The system receives historical behavior data from users, encodes the time information in the historical behavior data into a time-series feature vector using a time-series encoder, and fuses the time-series feature vector with the user behavior feature vector to obtain a feature enhancement vector. The feature enhancement vector contains the time-series correlation information of user behavior.
[0035] The cosine similarity between the feature enhancement vectors is calculated to obtain a similarity distance matrix, where each element of the similarity distance matrix represents the degree of difference in behavioral patterns between the corresponding two users;
[0036] Spectral clustering analysis is performed on the similarity distance matrix, and users are divided into three user groups based on the clustering results: the first user group, the second user group, and the third user group.
[0037] In one alternative implementation,
[0038] A distributed prediction method based on federated learning is constructed. Local prediction algorithms are independently trained on various data sources using local training units. A weighted average method is used to fuse the parameters of multiple local prediction algorithms. Random noise is added to the algorithm parameters to protect data privacy, including:
[0039] A distributed prediction method based on federated learning is constructed. On each data source, a local prediction algorithm is independently trained based on the local dataset corresponding to the current data source. For each data source, a loss function including a prediction loss term and a regularization term is calculated. The prediction loss term is the mean of the sample prediction loss, and the regularization term is the L2 norm of the model parameters. The parameters of the local prediction algorithm are obtained by optimizing the loss function using the stochastic gradient descent method.
[0040] The number of samples in each data source is obtained, and the number of samples in each data source is divided by the total number of samples in all data sources to obtain the corresponding weight coefficient. Based on the weight coefficient, the parameters of multiple local prediction algorithms are fused using a weighted average method to obtain the global algorithm parameters.
[0041] The variance of Gaussian noise is calculated based on preset sensitivity coefficients and function sensitivity. The variance of Gaussian noise is equal to the product of the sensitivity coefficients and the function sensitivity divided by the current privacy budget. The current privacy budget is obtained by multiplying the initial privacy budget by an exponential function of the decay coefficient. The decay coefficient is related to the training round.
[0042] The importance score of each layer parameter is determined based on the variance of the Gaussian noise, and random noise with a mean of zero is generated. The random noise is added to the global algorithm parameters to obtain the noise-perturbed global algorithm parameters. An evaluation index set is constructed and a dynamic adjustment factor is calculated. Based on the dynamic adjustment factor, the noise-perturbed global algorithm parameters are distributed to the data source.
[0043] The parameters of the local prediction algorithm are updated using the global algorithm parameters after noise perturbation, and the local training, parameter aggregation and privacy protection steps are repeated until training converges.
[0044] In one alternative implementation,
[0045] The importance score of each layer parameter is determined based on the variance of the Gaussian noise, and random noise with a mean of zero is generated. The random noise is added to the global algorithm parameters to obtain the noise-perturbed global algorithm parameters. An evaluation index set is constructed and a dynamic adjustment factor is calculated. Based on the dynamic adjustment factor, the noise-perturbed global algorithm parameters are distributed to the data source, including:
[0046] The weight distribution of global algorithm parameters is calculated based on the variance of the Gaussian noise to obtain the importance score of each layer parameter. Based on the importance score, the global algorithm parameters are divided into core parameter group and non-core parameter group. The first Gaussian noise variance of the core parameter group and the second Gaussian noise variance of the non-core parameter group are generated according to the preset noise intensity benchmark value. The first Gaussian noise variance is the noise intensity benchmark value multiplied by a first proportional coefficient, and the second Gaussian noise variance is the noise intensity benchmark value multiplied by a second proportional coefficient. The first proportional coefficient is less than the second proportional coefficient.
[0047] A first random noise with a mean of zero is generated based on the variance of the first Gaussian noise, and a second random noise with a mean of zero is generated based on the variance of the second Gaussian noise. The first random noise is added to the core parameter group to obtain the core parameters after noise perturbation, and the second random noise is added to the non-core parameter group to obtain the non-core parameters after noise perturbation.
[0048] An evaluation index set is constructed to calculate the parameter distribution change, performance loss rate, and privacy protection strength of the core parameters and non-core parameters after noise perturbation relative to the original parameters. A dynamic adjustment factor is calculated based on the parameter distribution change, performance loss rate, and privacy protection strength.
[0049] When the dynamic adjustment factor exceeds the preset threshold, a compensation term is constructed based on the difference between the historical parameter mean and the current parameter and the compensation weight. The compensation term is then added to the core parameters after noise perturbation and the non-core parameters after noise perturbation to obtain the global algorithm parameters after noise perturbation.
[0050] The computing power of the data source is rated to obtain different capability levels. Based on the capability level, the global algorithm parameters after noise perturbation are compressed at different ratios to obtain different versions of parameter packages. The different versions of parameter packages are distributed to the data source corresponding to the capability level.
[0051] In one alternative implementation,
[0052] The data from the first user group, the second user group, and the third user group are respectively input into the distributed prediction method to obtain user behavior prediction results. The user behavior prediction results are then optimized using a reinforcement learning algorithm based on a preset reward function to generate content marketing strategy data, including:
[0053] The data of the first, second, and third user groups are respectively input into the distributed prediction method. The distributed prediction method constructs feature vectors based on the user's historical browsing data, interaction behavior data, and purchase record data. The feature vectors are then input into a pre-trained deep learning model for prediction to obtain user behavior prediction results.
[0054] Construct a reward function based on user behavior prediction results. The reward function includes a weighted combination of three factors: user click-through rate, user conversion rate, and marketing cost. The weight coefficient of user click-through rate is positively correlated with user activity, the weight coefficient of user conversion rate is positively correlated with user purchasing power, and the weight coefficient of marketing cost is negatively correlated with marketing budget.
[0055] According to the reinforcement learning algorithm, the user behavior prediction results are iteratively optimized based on the reward function. The reinforcement learning algorithm maximizes the expected value of the reward function by combining exploratory strategy sampling and exploitation strategy evaluation. The exploratory strategy randomly selects marketing actions based on the ε-greedy algorithm, and the exploitation strategy determines the marketing strategy based on the historical best results. The optimal marketing strategy is determined by dynamically balancing the proportions of the exploratory strategy and the exploitation strategy.
[0056] A second aspect of this invention provides a content marketing user behavior prediction system based on big data analysis, comprising:
[0057] The first unit is used to collect users' historical behavior data on the content marketing platform, establish user identifier mapping relationship, preprocess the historical behavior data, and generate user behavior feature vectors by removing abnormal data, normalizing and reducing feature dimensionality.
[0058] The second unit is used to enhance the user behavior feature vector based on the transfer learning method. It establishes a unified feature representation space for user behavior feature vectors in different scenarios through cross-scenario feature mapping, and dynamically allocates weight coefficients according to feature importance scores to achieve adaptive adjustment of feature weights.
[0059] The third unit is used to process the enhanced user behavior feature vectors through clustering algorithms, calculate the similarity distance between user features, and divide users into a first user group, a second user group, and a third user group based on the similarity distance.
[0060] The fourth unit is used to construct a distributed prediction method based on federated learning. Local prediction algorithms are trained independently on each data source through local training units. The parameters of multiple local prediction algorithms are fused by weighted averaging, and random noise is added to the algorithm parameters to protect data privacy.
[0061] The fifth unit is used to input the data of the first user group, the second user group, and the third user group into the distributed prediction method to obtain user behavior prediction results, and to optimize the user behavior prediction results according to a preset reward function through a reinforcement learning algorithm to generate content marketing strategy data.
[0062] In this invention, historical user behavior data is collected through a data acquisition module, and a user identifier mapping relationship is established. Combined with a transfer learning model for feature enhancement, a unified representation and adaptive weight adjustment of user behavior features across scenarios are achieved, improving the expressive power and generalization performance of user behavior features, making the prediction results more accurate and reliable. A distributed prediction system based on a federated learning framework is adopted, achieving collaborative modeling of multiple data sources through local training and model aggregation. A differential privacy protection mechanism is introduced to ensure data security, guaranteeing both the performance of the prediction model and effectively protecting user privacy data, thus enhancing the system's practicality and reliability. Furthermore, a user classification module is used to segment users into groups, and reinforcement learning algorithms are employed to optimize the prediction results, enabling the formulation of personalized marketing strategies for different user groups. This improves the accuracy and conversion rate of content marketing and has strong practical application value. Attached Figure Description
[0063] Figure 1 This is a flowchart illustrating the content marketing user behavior prediction method based on big data analysis, as described in an embodiment of the present invention.
[0064] Figure 2 This is a performance comparison chart of feature importance calculation for the content marketing user behavior prediction method based on big data analysis in this invention.
[0065] Figure 3 This is a comparison chart of parameter importance distribution and noise variance allocation strategies for the content marketing user behavior prediction method based on big data analysis in an embodiment of the present invention. Detailed Implementation
[0066] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0067] The technical solution of the present invention will be described in detail below with reference to specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments.
[0068] Figure 1 This is a flowchart illustrating the content marketing user behavior prediction method based on big data analysis according to an embodiment of the present invention. Figure 1 As shown, the method includes:
[0069] Collect users' historical behavior data on content marketing platforms, establish user identifier mapping relationships, preprocess the historical behavior data, and generate user behavior feature vectors by removing abnormal data, normalizing, and reducing feature dimensionality.
[0070] The user behavior feature vector is enhanced based on the transfer learning method. A unified feature representation space is established for user behavior feature vectors in different scenarios through cross-scenario feature mapping. The weight coefficients are dynamically allocated according to the feature importance score to achieve adaptive adjustment of feature weights.
[0071] The enhanced user behavior feature vectors are processed using a clustering algorithm to calculate the similarity distance between user features and to divide users into a first user group, a second user group, and a third user group based on the similarity distance.
[0072] A distributed prediction method based on federated learning is constructed. Local prediction algorithms are independently trained on various data sources through local training units. The parameters of multiple local prediction algorithms are fused by weighted averaging, and random noise is added to the algorithm parameters to protect data privacy.
[0073] The data of the first user group, the second user group, and the third user group are respectively input into the distributed prediction method to obtain user behavior prediction results. The user behavior prediction results are then optimized by a reinforcement learning algorithm according to a preset reward function to generate content marketing strategy data.
[0074] In one alternative implementation,
[0075] Collecting historical user behavior data on content marketing platforms, establishing user identifier mapping relationships, and preprocessing the historical behavior data to generate user behavior feature vectors through outlier removal, normalization, and feature dimensionality reduction include:
[0076] Collect users’ historical behavior data on the content marketing platform. The historical behavior data includes user identifier, behavior type and timestamp.
[0077] The user identifiers in the historical behavior data are uniformly mapped, a cross-platform user identifier association table is established, and historical behavior data with the same user identifier are associated and merged.
[0078] The interquartile range of numerical features is calculated using box plots. Data exceeding 1.5 times the interquartile range above and below the quartile are marked as outliers and deleted. Missing values are filled according to the mean of the feature they belong to. The numerical features are normalized to their maximum and minimum values, mapping the feature values to the [0, 1] interval. Categorical features are one-hot encoded. Principal component analysis is used to reduce the dimensionality of high-dimensional features. Principal components with a cumulative contribution rate reaching a preset threshold are selected to construct a standardized user behavior feature vector.
[0079] We continuously monitor and collect all user interactions on content marketing platforms. Each piece of behavioral data records detailed user identification information, such as account information and login information during user registration; it also records specific behavior types, such as user clicks, browsing, saving, and sharing of content; and it accurately records the exact time of each behavior, down to the second, ensuring that the chronological order of user actions can be accurately reconstructed.
[0080] After acquiring the raw behavioral data, it is necessary to handle the user identifier mapping problem between different platforms and devices through a user identifier association unit. A user identifier association table is established to record the user's identity information on each platform. By analyzing user login information, device characteristics, behavioral habits, and other data from multiple dimensions, various identity identifiers of the same user on different platforms or devices are identified. A unique identity number is assigned to each identified real user, and this correspondence is recorded in the association table. Based on this association table, behavioral data from different sources but belonging to the same user are associated and merged to form a complete user behavior trajectory.
[0081] The data preprocessing stage involves handling outliers. Box plots are used to identify outliers: for each numerical feature, the first and third quartiles are calculated to obtain the interquartile range. Based on statistics, a range for outlier determination is established. Data points outside this range are marked as outliers. Marked outliers are then removed from the dataset to prevent them from interfering with subsequent analysis.
[0082] For missing values in the dataset, the missing value situation for each feature dimension is statistically analyzed. For features with missing values, the average value of that feature in the non-missing data is calculated, and then this average value is used to replace all missing values. This approach ensures data integrity while maintaining the data distribution characteristics.
[0083] All numerical features are normalized. A maximum-minimum normalization method is used: for each feature, its maximum and minimum values are found, and then mathematical operations are performed to map all values to the interval between zero and one. This process eliminates differences in numerical magnitude between different features, ensuring that each feature has equal importance in subsequent analysis.
[0084] For categorical features, a one-hot encoding method is used. For each possible value of each categorical feature, a new binary feature is created. If a sample's value for a given feature belongs to a certain category, it is marked as "yes" on that feature; other features are marked as "no." This encoding method can convert categorical information into a numerical form that a computer can directly process.
[0085] To reduce the dimensionality of the feature space, principal component analysis (PCA) is used. First, the correlations between features are calculated, then the most important main feature directions in the data are identified. By calculating the importance of each feature direction and setting an importance threshold, feature directions that meet the requirements are selected, and the original data is transformed to these main feature directions, thus obtaining dimensionality-reduced standardized user behavior feature data.
[0086] For example, suppose a user accesses a shopping platform on both a mobile phone and a computer. On the mobile phone, the user, using an account registered with their mobile phone number, browsed women's clothing category items, including dresses, and added them to their shopping cart. On the computer, the user, using an account registered with their email address, added the same dress to their favorites. The system analyzes the data and finds that the two accounts share the same mobile phone number, confirming they belong to the same user. Therefore, the user's data is merged. The merged data shows that the user browsed women's clothing category items 15 times in the past week, with an average browsing time of 20 minutes per session, added three items to their favorites, added two items to their shopping cart, and purchased one item. The system removes abnormal browsing records (such as records with browsing time less than five seconds) and replaces the missing favorites time with the user's average daily activity time, ultimately generating the user's behavioral characteristic data.
[0087] In this embodiment, user identifier association technology is used to achieve unified association of user behavior data across platforms, which solves the problem of scattered user identifiers and improves the completeness and accuracy of user profiles. Data preprocessing methods such as box plot outlier handling, mean filling, and feature normalization are used to effectively remove noise in the data, improve data quality, and provide a reliable data foundation for subsequent analysis. Through one-hot encoding and principal component analysis dimensionality reduction, high-dimensional sparse user behavior features are transformed into low-dimensional dense feature vector representations, which not only retains the main information of the original data but also reduces computational complexity and improves model training efficiency.
[0088] In one alternative implementation,
[0089] The user behavior feature vector is enhanced using transfer learning. A unified feature representation space is established for user behavior feature vectors in different scenarios through cross-scenario feature mapping. Weight coefficients are dynamically allocated based on feature importance scores to achieve adaptive adjustment of feature weights.
[0090] The system receives user behavior feature vectors from a source domain feature space and user behavior feature vectors from a target domain feature space, wherein the user behavior feature vectors from the source domain feature space and the user behavior feature vectors from the target domain feature space have different distribution characteristics.
[0091] A dual-stream neural network structure is constructed through cross-scene feature mapping. The dual-stream neural network structure includes a source domain feature extraction subnetwork and a target domain feature extraction subnetwork. A first mapping feature is obtained by nonlinearly transforming the user behavior feature vector in the source domain feature space using a first feature mapping function pre-set in the source domain feature extraction subnetwork. A second mapping feature is obtained by nonlinearly transforming the user behavior feature vector in the target domain feature space using a second feature mapping function pre-set in the target domain feature extraction subnetwork.
[0092] The feature distribution difference is obtained by calculating the L2 distance between the mean of the first mapped feature sample and the mean of the second mapped feature sample in the regenerating kernel Hilbert space based on the maximum mean difference criterion. The feature distribution difference is then input into a dynamic kernel selection mechanism, which includes multiple preset Gaussian kernel functions. The optimal kernel function combination is obtained by iteratively optimizing the weight coefficients of the multiple preset Gaussian kernel functions through the gradient descent method.
[0093] The system receives the first mapping feature and the second mapping feature, performs a linear transformation using a pre-set learnable transformation matrix, and then obtains the feature hidden layer representation through the hyperbolic tangent activation function. The system then performs an inner product operation between the pre-set learnable attention vector and the feature hidden layer representation to obtain the importance score for each feature dimension.
[0094] The feature importance scores are normalized using softmax to obtain feature weight coefficients. L1 norm sparsity regularization constraints are applied to the feature weight coefficients. The sparsity of the feature weights is controlled by setting the regularization coefficients to obtain sparsified feature weight coefficients.
[0095] The sparse feature weight coefficients are applied to the first mapping feature and the second mapping feature respectively to obtain the enhanced feature representation in the unified feature representation space, wherein the sparse feature weight coefficients are used to highlight the contribution of important feature dimensions and suppress the influence of irrelevant feature dimensions.
[0096] User behavior feature data is received from different scenarios, including user behavior feature vectors from the source domain (e.g., e-commerce platform) and the target domain (e.g., social platform). Because these two scenarios have different characteristics, the manifestations of user behavior also differ, resulting in different data distribution characteristics for the feature vectors in the two domains.
[0097] To achieve cross-scene feature mapping, a two-stream neural network structure is constructed. This structure comprises two parallel sub-networks: a source domain feature extraction sub-network and a target domain feature extraction sub-network. The source domain sub-network processes the feature vectors from the source domain, performing a nonlinear transformation through a multi-layer neural network to map the original features to a new feature space, obtaining the first mapped features. The target domain sub-network receives the feature vectors from the target domain and performs a nonlinear transformation through a similar network structure to obtain the second mapped features.
[0098] The distributional difference between two mapped features is evaluated. The maximum mean difference is used as the metric. Specifically, the average value of the two mapped features at the sample level is calculated, and then the distance between these two means is calculated in a specific mathematical space to obtain the feature distributional difference value. A dynamic kernel selection mechanism is used, with multiple Gaussian kernel functions with different parameters pre-prepared. By continuously adjusting the weight ratios of these kernel functions, the optimal combination of kernel functions is gradually found, minimizing the feature distributional difference.
[0099] A feature attention module is constructed to achieve adaptive feature adjustment. The feature attention module consists of a feature transformation layer and an attention computation layer. The feature transformation layer first receives two mapped features, performs a linear transformation on the features using a learnable transformation matrix, and then obtains the hidden layer representation of the features through an activation function. The attention computation layer contains a learnable vector, which calculates the importance of each feature dimension by performing an inner product operation with the hidden layer representation of the features, thus obtaining an importance score.
[0100] The obtained importance scores are normalized to convert the scores of all dimensions into a probability distribution, resulting in preliminary feature weight coefficients. To highlight key features and suppress the influence of irrelevant features, sparsity constraints are added to these weight coefficients. By setting appropriate constraint strength, the sparsity of the final weight distribution is controlled, resulting in sparsified feature weight coefficients.
[0101] The sparsity weights are applied to the two mapped features separately. Important feature dimensions receive larger weights, while unimportant feature dimensions are given smaller weights or even completely suppressed. After this processing, the features from both domains are mapped to a unified feature representation space, forming an enhanced feature representation.
[0102] For example, suppose that in an e-commerce platform (source domain), a user's behavioral characteristics include: browsing time percentage of 0.8%, shopping cart usage frequency of 0.6%, number of favorited items of 0.4%, and number of search keywords of 0.3. In a social media platform (target domain), the user's behavioral characteristics include: content dwell time of 0.7%, number of likes of 0.5%, number of comments of 0.3%, and number of shares of 0.4.
[0103] After processing by a dual-stream neural network, the features of e-commerce platforms were mapped as follows: content interaction level 0.75, purchase intention level 0.65, and interest breadth 0.35. The features of social media platforms were mapped as follows: content activity level 0.7, social influence 0.6, and interest tendency 0.4.
[0104] Attention mechanism analysis revealed that content interaction and content activity were the most important feature dimensions, with a weight of 0.5; purchase intention and social influence were the next most important, with a weight of 0.3; and interest-related dimensions had the lowest weight, at 0.2. Ultimately, in a unified feature space, the user's behavioral characteristics were represented as: interaction activity 0.72, influence index 0.62, and interest characteristics 0.38. This unified feature representation retains the common behavioral characteristics of the user across both platforms while highlighting the most representative behavioral dimensions.
[0105] In this embodiment, a unified mapping of user behavior features under different scenarios is achieved through a two-stream neural network structure, which solves the problem of inconsistent feature distribution between the source and target domains, improves the consistency and transferability of feature representation, and enhances the nonlinear expressive power of feature mapping by adaptively combining multiple kernel functions, making feature distribution alignment more accurate and improving the effect of transfer learning. The combination of feature attention mechanism and sparse regularization realizes the automatic discovery of feature importance and dynamic adjustment of weights, highlights the contribution of key features, suppresses the interference of noisy features, and improves the discriminative performance of feature representation.
[0106] In one alternative implementation,
[0107] After performing a linear transformation using a pre-set learnable transformation matrix, a feature hidden layer representation is obtained through a hyperbolic tangent activation function. The importance score for each feature dimension is then obtained by performing an inner product operation between the pre-set learnable attention vector and the feature hidden layer representation, including:
[0108] An adversarial learning module is constructed, which includes a feature generator and a feature discriminator. The feature generator receives input features and generates adversarial features. The feature discriminator outputs a discrimination probability based on the input features and the adversarial features. The feature generator is trained based on the discrimination probability.
[0109] The input features and the adversarial features are linearly transformed using a learnable transformation matrix to obtain a first feature representation and an adversarial feature representation, respectively. The learnable transformation matrix is then adversarially trained based on the discriminant probability. The first feature representation and the adversarial feature representation are then input into a hyperbolic tangent activation function to obtain a feature hidden layer representation and an adversarial feature hidden layer representation, respectively. The feature hidden layer representation and the adversarial feature hidden layer representation are used to construct contrastive learning samples.
[0110] A dynamically maintained feature queue is constructed based on the contrastive learning samples. The historical representations of the feature hidden layer representations are stored in the feature queue. Positive sample pairs are constructed based on the historical representations and the current feature hidden layer representations in the feature queue. Negative sample pairs are constructed based on the adversarial feature hidden layer representations. The similarity between the positive sample pairs and the similarity between the negative sample pairs are calculated. The calculation result of the similarity is used as the contrastive loss. The contrastive loss is used to optimize the feature hidden layer representations to obtain the optimized feature hidden layer representations.
[0111] Initialize a learnable attention vector, update the parameters of the learnable attention vector based on the contrastive loss, and perform an inner product operation between the updated learnable attention vector and the optimized feature hidden layer representation to obtain the importance score of each feature dimension.
[0112] The adversarial learning module comprises two mutually competitive components: a feature generator and a feature discriminator. The feature generator employs a multi-layer neural network structure, with each layer containing linear transformations and non-linear activation functions. Upon receiving input features, the generator encodes them through the first layer of the neural network, mapping the original features to a high-dimensional space. It then performs feature transformations through intermediate layers, progressively generating adversarial feature representations. Finally, the output layer maps the features back to the original dimensional space, yielding the adversarial features. The feature discriminator also uses a multi-layer neural network structure, receiving both the original input features and the generated adversarial features. The discriminator extracts features layer by layer, finally outputting a probability value between zero and one, representing the probability that the input feature is a true feature. This probability value guides the generator's training process, as the generator continuously improves its generation capabilities by maximizing the discriminator's discrimination error.
[0113] A linear transformation matrix is introduced. Each element of the transformation matrix is a learnable parameter, initially obtained through random initialization. When transforming the input features, the feature vector is multiplied by the transformation matrix to obtain the first feature representation; similarly, the adversarial features are multiplied by the same transformation matrix to obtain the adversarial feature representation. To make the transformation process adversarially robust, an adversarial training method is adopted: the difference between the transformed features and the original features is calculated, and this difference is combined with the discriminant probability to construct an adversarial loss function; then, based on the loss function, the parameters of the transformation matrix are updated through the backpropagation algorithm, so that the transformed features retain the original information while possessing the ability to resist adversarial interference. The two sets of features after linear transformation are then subjected to nonlinear transformation through the hyperbolic tangent activation function to obtain the feature hidden layer representation and the adversarial feature hidden layer representation. This activation process can introduce nonlinear characteristics to enhance the expressive power of the features.
[0114] A dynamic feature queue is established for contrastive learning. The feature queue is dynamically updated using a first-in, first-out (FIFO) approach, and its length is pre-defined. Whenever a new hidden feature representation is generated, it is added to the queue; if the queue is full, the oldest added feature representation is removed. When constructing positive sample pairs, the current hidden feature representation is paired with each historical representation in the queue, forming multiple positive sample pairs. For constructing negative sample pairs, the current hidden feature representation is paired with an adversarial hidden feature representation. The similarity between sample pairs is calculated: for each pair of feature representations, a cosine similarity method is used to obtain a similarity value between zero and one. Positive sample pairs should have higher similarity, while negative sample pairs should have lower similarity. Based on this principle, a contrastive loss function is constructed: aiming to maximize the similarity of positive sample pairs while minimizing the similarity of negative sample pairs. By minimizing this contrastive loss, the parameters of the feature extraction network are updated through backpropagation, optimizing the hidden feature representation.
[0115] The attention computation layer is constructed and optimized. The core of the attention computation layer is a learnable vector with the same dimensions as the feature hidden layer representation. The parameter update process of this vector is closely related to the contrastive loss: a large contrastive loss indicates that the current feature representation is not ideal and requires significant adjustment of the attention vector; a small contrastive loss indicates that the feature representation is already good, and the adjustment of the attention vector can be reduced accordingly. The updated attention vector is then multiplied by the optimized feature hidden layer representation to obtain the importance score for each feature dimension. This calculation process essentially measures the contribution of each dimension to the final task: a higher score indicates a greater contribution to the feature representation and that it should receive more attention in subsequent tasks.
[0116] For example, in a user behavior analysis task on an e-commerce platform, the input raw features include user behavior data from multiple dimensions: the average time a user spends on a product details page is three minutes, the number of products viewed per day is twenty, the number of products saved is five, the number of times a product is added to the shopping cart is three, the number of historical purchases is two, the number of search keywords is ten, the number of user comments is four, and the number of times a product is shared is two.
[0117] After receiving this raw data, the feature generator generates adversarial features through its neural network structure: adjusting the average dwell time to three and a half minutes, the number of products viewed per day to eighteen, the number of products saved to six, the number of times products are added to the cart to four, keeping the number of historical purchases unchanged, the number of search keywords to eight, the number of user comments to five, and the number of times products are shared to three.
[0118] The feature discriminator analyzes the original features and adversarial features, and outputs the discrimination probability through the discriminative network. The discrimination probability for the original features is 0.85, indicating that this set of features is highly likely to represent genuine user behavior; the discrimination probability for the adversarial features is 0.6, indicating that the authenticity of this set of features has a certain degree of uncertainty.
[0119] The transformation matrix transforms the two sets of features. The transformed first feature representation shows: user activity score of 0.75, purchase intention score of 0.65, social influence score of 0.4, and interest breadth score of 0.55. The adversarial feature representation shows: activity score of 0.7, purchase intention score of 0.68, social influence score of 0.45, and interest breadth score of 0.5.
[0120] After processing with the hyperbolic tangent activation function, the hidden layer representation of these features reflects that the user exhibits a high browsing volume but a moderate purchase conversion rate, and has a moderate tendency to share on social media. The adversarial hidden layer representation highlights that the user has a high purchase intention but relatively low activity level.
[0121] The feature queue stores the user's behavioral feature representations for the past week. Comparative learning results show a significant difference between the user's weekend shopping behavior and weekday behavior: longer browsing time and more frequent product interaction on weekends, while weekday browsing is primarily quick and less in-depth. Similarity calculations show that the user's weekday behavior similarity is 0.85, weekend behavior similarity is 0.9, while the similarity between weekday and weekend behavior is only 0.6.
[0122] Based on these analysis results, the attention calculation layer calculates the importance scores for each feature dimension: dwell time scores 0.3, reflecting its importance in judging user interest; shopping cart operations score 0.25, indicating its significant contribution to predicting purchase intention; the comprehensive score for product interaction behavior (including collection, comment, and sharing) is 0.28, showing the important position of social attributes in user behavior analysis; and the score for search behavior is 0.17, indicating its relatively low weight in the overall behavioral features.
[0123] In this embodiment, adversarial learning enhances the robustness of feature representations against noise and adversarial examples, thus improving the overall robustness of feature learning. Dynamic feature queues and contrastive learning capture the temporal evolution of feature representations, enhancing their expressive power. An attention mechanism enables adaptive calculation of feature dimension importance, further strengthening the discriminative power of feature representations. This multi-layered feature learning strategy significantly improves the quality of feature representations, providing more reliable feature support for downstream tasks.
[0124] In existing technologies, the feature learning process mainly relies on a single feature extraction network, which is easily affected by data noise and adversarial examples, resulting in insufficient robustness of feature representation. Traditional methods use uniform weights for different feature dimensions, which cannot accurately identify and highlight the importance of key features, thus reducing the discriminativeness of feature representation. Existing technologies lack consideration for the temporal nature of features and cannot effectively capture the dynamic characteristics of feature representation as it changes over time.
[0125] Figure 2 This chart compares the feature importance calculation performance of the content marketing user behavior prediction method based on big data analysis according to an embodiment of the present invention. It shows the comparison between the present technical solution and the LIME and DeepSHAP methods in terms of feature importance calculation and model accuracy. The horizontal axis represents the 10 key feature dimensions of e-commerce platform user behavior and the final model accuracy, while the vertical axis represents the importance score of each feature and the percentage of model accuracy.
[0126] This technical solution (circular marker lines) identifies a more reasonable distribution of feature importance through adversarial learning, particularly assigning a high importance score of 32.8% to the "purchase frequency" feature. "Dwell time" and "shopping cart" actions also receive relatively high weights of 30.0% and 25.4% respectively, closely aligning with the key nodes of the e-commerce conversion funnel. In contrast, the LIME method (square marker lines) assesses the importance of "purchase frequency" at 26.4%, and the DeepSHAP method (triangle marker lines) only gives 19.6%, significantly lower than the accuracy of this solution.
[0127] More importantly, based on the different feature importance assignments, the three methods show significant differences in the final model accuracy: our proposed solution achieves a high accuracy of 92.3%, significantly outperforming the LIME method's 85.7% and the DeepSHAP method's 81.2%, representing improvements of 6.6 and 11.1 percentage points, respectively. This difference mainly stems from our unique adversarial and contrastive learning mechanisms, which better capture the interrelationships between features and their contribution to the target.
[0128] Experimental data shows that the importance distribution of this technical solution across various feature dimensions is more balanced and reasonable, rather than the DeepSHAP method which overemphasizes "dwell time" (22.3%) while generally scoring other dimensions lower. The feature importance calculation method based on adversarial contrastive learning not only improves the overall accuracy of the model but also enhances its adaptability to different user behavior patterns, providing more reliable technical support for accurate recommendations and user behavior analysis on e-commerce platforms.
[0129] In one alternative implementation,
[0130] The enhanced user behavior feature vectors are processed using a clustering algorithm. The similarity distance between user features is calculated, and users are divided into a first user group, a second user group, and a third user group based on this similarity distance.
[0131] The system receives historical behavior data from users, encodes the time information in the historical behavior data into a time-series feature vector using a time-series encoder, and fuses the time-series feature vector with the user behavior feature vector to obtain a feature enhancement vector. The feature enhancement vector contains the time-series correlation information of user behavior.
[0132] The cosine similarity between the feature enhancement vectors is calculated to obtain a similarity distance matrix, where each element of the similarity distance matrix represents the degree of difference in behavioral patterns between the corresponding two users;
[0133] Spectral clustering analysis is performed on the similarity distance matrix, and users are divided into three user groups based on the clustering results: the first user group, the second user group, and the third user group.
[0134] It receives users' historical behavior data, including their browsing history, dwell time, click count, purchase behavior, and favorites behavior on content platforms. The historical behavior data also includes the specific timestamps of these actions.
[0135] For the received historical behavior data, a temporal encoder is used to encode the temporal information into a temporal feature vector. The temporal encoder can employ a Long Short-Term Memory (LSTM) network structure. The input to the temporal encoder is a sequence of user behaviors arranged in chronological order, with each behavior including its type and occurrence time. During the encoding process, each timestamp is positionally encoded, converting it into a fixed-dimensional vector representation. The temporal encoder processes this sequence data through a multi-layered network structure, outputting a feature vector that represents the temporal pattern of user behavior. For example, for a user's browsing behavior over the past 30 days, the temporal encoder can identify that the user tends to browse specific types of content on weekday evenings and exhibits different browsing patterns on weekends.
[0136] The obtained temporal feature vector is fused with the original user behavior feature vector to obtain the feature enhancement vector. The user behavior feature vector typically contains basic user behavioral characteristics, such as content preferences and interaction frequency. The fusion process employs an attention mechanism, assigning different weights to different features to highlight important behavioral patterns. Specifically, the attention score between the temporal feature vector and the user behavior feature vector is calculated, and a weighted sum is performed based on the attention score to obtain the feature enhancement vector. The feature enhancement vector contains temporal correlation information of user behavior and can more comprehensively describe user behavioral patterns. For example, the feature enhancement vector can reflect changes in user preferences for different types of content at different times; for instance, users may pay more attention to professional content on weekdays and prefer entertainment content on weekends.
[0137] The cosine similarity between feature enhancement vectors is calculated to obtain a similarity distance matrix. For any two feature enhancement vectors of users A and B, the cosine similarity is calculated to obtain a value between -1 and 1. The closer the value is to 1, the more similar the behavioral patterns of the two users are; the closer it is to -1, the more different their behavioral patterns are. The cosine similarity calculation considers the direction of the vectors rather than their magnitude, effectively measuring the similarity of user behavioral patterns. Cosine similarity is calculated pairwise for all users, resulting in an n×n similarity distance matrix, where n is the total number of users. Each element of this matrix represents the degree of difference in behavioral patterns between the corresponding two users. For example, if the similarity between users A and B is 0.85, while the similarity between users A and C is 0.35, it indicates that users A and B have more similar behavioral patterns.
[0138] Spectral clustering analysis is performed on the similarity distance matrix. Based on the clustering results, users are divided into different user groups, and an adjacency graph is constructed, where nodes represent users and edge weights are determined by similarity distance. The Laplacian matrix of the adjacency graph is calculated, and eigenvalue decomposition is performed on the Laplacian matrix. The eigenvectors corresponding to the k smallest eigenvalues are selected to form a new feature matrix. In the new feature space, the K-means clustering algorithm is used to divide users into three predefined user groups. Spectral clustering algorithms can effectively handle non-convex data distributions and are suitable for identifying complex user behavior patterns.
[0139] Cluster analysis categorized users into three groups: Group 1 (highly active users), Group 2 (frequently interacting with content), and Group 3 (interested in various content types). Group 1 likely consists of moderately active users with specific content preferences who visit the platform regularly but interact at a moderate frequency. Group 3 likely consists of inactive users with low visit frequency and limited interest in the platform's content.
[0140] In this embodiment, a temporal encoder is used to process the time information in the user's historical behavior data, transforming the time-dimensional features into a computable temporal feature vector. This effectively captures the patterns and regularities of user behavior changes over time. By assigning appropriate weights to different features through an attention mechanism, key information in the temporal pattern is highlighted, avoiding information redundancy and noise interference that may result from simple splicing. Cosine similarity focuses on the direction of the vector rather than its magnitude, accurately capturing the essential similarity of user behavior patterns. It is not affected by the absolute value difference of user activity and accurately reflects the structural characteristics within the user group, providing a reliable foundation for subsequent clustering analysis. This enables content marketing strategies to be more personalized and targeted, significantly improving marketing efficiency and conversion rates.
[0141] In one alternative implementation,
[0142] A distributed prediction method based on federated learning is constructed. Local prediction algorithms are independently trained on various data sources using local training units. A weighted average method is used to fuse the parameters of multiple local prediction algorithms. Random noise is added to the algorithm parameters to protect data privacy, including:
[0143] A distributed prediction method based on federated learning is constructed. On each data source, a local prediction algorithm is independently trained based on the local dataset corresponding to the current data source. For each data source, a loss function including a prediction loss term and a regularization term is calculated. The prediction loss term is the mean of the sample prediction loss, and the regularization term is the L2 norm of the model parameters. The parameters of the local prediction algorithm are obtained by optimizing the loss function using the stochastic gradient descent method.
[0144] The number of samples in each data source is obtained, and the number of samples in each data source is divided by the total number of samples in all data sources to obtain the corresponding weight coefficient. Based on the weight coefficient, the parameters of multiple local prediction algorithms are fused using a weighted average method to obtain the global algorithm parameters.
[0145] The variance of Gaussian noise is calculated based on preset sensitivity coefficients and function sensitivity. The variance of Gaussian noise is equal to the product of the sensitivity coefficients and the function sensitivity divided by the current privacy budget. The current privacy budget is obtained by multiplying the initial privacy budget by an exponential function of the decay coefficient. The decay coefficient is related to the training round.
[0146] The importance score of each layer parameter is determined based on the variance of the Gaussian noise, and random noise with a mean of zero is generated. The random noise is added to the global algorithm parameters to obtain the noise-perturbed global algorithm parameters. An evaluation index set is constructed and a dynamic adjustment factor is calculated. Based on the dynamic adjustment factor, the noise-perturbed global algorithm parameters are distributed to the data source.
[0147] The parameters of the local prediction algorithm are updated using the global algorithm parameters after noise perturbation, and the local training, parameter aggregation and privacy protection steps are repeated until training converges.
[0148] When receiving historical behavior data, the user classification module extracts dimensional information such as behavior type, behavior intensity, and behavior time. The temporal encoder processes the time information into a vector representation: by calculating the relative time interval between behavior occurrences, it maps the data to a high-dimensional space using a sinusoidal positional encoding method, thereby generating a positional encoding vector that fully preserves the chronological order of behavior occurrences. Next, the user behavior feature vector is normalized, and the normalized feature vector is concatenated with the positional encoding vector. A transformation layer is then applied to obtain a feature enhancement vector that incorporates temporal correlation.
[0149] After normalizing the feature enhancement vectors using the L2 norm and checking for dimensionality consistency, the dot product between the vectors is calculated and then divided by the product of the vector magnitudes to obtain a cosine similarity value in the range [-1, 1]. The similarity value is then converted into a distance metric, and a symmetric distance matrix is constructed with the diagonal elements set to 1, thus forming a complete similarity distance matrix.
[0150] A Laplacian matrix is constructed based on the similarity distance matrix, and its eigenvalues and eigenvectors are calculated. Important eigenvectors are selected to construct a new feature space, in which the K-means clustering algorithm is applied. By iteratively optimizing the cluster centroids, the user group is ultimately divided into three categories, and the group type is determined based on the behavioral characteristics of each group.
[0151] When training the prediction algorithm independently on each data source, the algorithm structure is first initialized, and the learning rate and batch size are set. The loss function is defined with two parts: the prediction loss term uses the average of the sample prediction errors, and the regularization term uses the product of the L2 norm of the algorithm parameters and the regularization coefficient. The algorithm parameters are updated using stochastic gradient descent by calculating the gradient of the loss function with respect to the parameters, and the change in loss value in each training round is recorded.
[0152] Obtain sample count information from all data sources, calculate the total number of samples, and divide the sample count from each data source by the total number of samples to obtain the corresponding weight coefficient. Collect all local algorithm parameters, perform a weighted average using the weight coefficients, and generate the fused global algorithm parameters.
[0153] When adding privacy protection, the privacy budget for the current training epoch is updated based on the training epoch, and the function sensitivity is calculated using a preset sensitivity coefficient to obtain the variance value of the Gaussian noise. Based on the importance of parameters in the algorithm, the importance score of each layer's parameters is determined, and random noise following a Gaussian distribution is generated. This noise is added to the global parameters, and after calculating a dynamic adjustment factor, it is distributed to various data sources.
[0154] After receiving the noisy global parameters, each data source updates its local prediction algorithm parameters. The training, aggregation, and protection steps are repeated until the training loss value stabilizes or the preset training rounds are completed.
[0155] For example, an e-commerce platform collects user behavior data for the past 30 days. User A's original behavior data includes: browsing duration sequence [45, 60, 30, 90] minutes, click count sequence [20, 25, 15, 30] times, purchase amount sequence [0, 200, 0, 300] yuan, and the behavior occurred [1, 3, 5, 7] days ago. The temporal encoder encodes the time information into a vector [0.2, 0.4, 0.6, 0.8], which is then fused with the behavioral features to obtain the feature enhancement vector [0.2, 45, 20, 0, 0.4, 60, 25, 200, 0.6, 30, 15, 0, 0.8, 90, 30, 300].
[0156] The similarity distance matrix among the three users was calculated as [[1.0, 0.85, 0.45], [0.85, 1.0, 0.55], [0.45, 0.55, 1.0]]. Users were categorized into three groups using spectral clustering: high-activity users (average browsing time > 60 minutes, purchase frequency > 0.3), medium-activity users (average browsing time 30-60 minutes, purchase frequency 0.1-0.3), and low-activity users (average browsing time < 30 minutes, purchase frequency < 0.1).
[0157] In distributed training, the sample sizes of the three data sources are [2000, 1500, 1000], and the weight coefficients are calculated to be [0.44, 0.33, 0.23]. An initial privacy budget of 1.0 and a decay coefficient of 0.98 are set. The privacy budget for round t is 1.0 × (0.98)^t, and the Gaussian noise variance of 0.01 / εt is calculated accordingly. After multiple training iterations, the entire training process ends when the loss function converges and the privacy budget is exhausted.
[0158] In this embodiment, a federated learning framework is used to achieve distributed training without data leaving the local machine, thus protecting data privacy and security. At the same time, multiple local model parameters are fused by weighted averaging, which improves the overall performance of the model. A differential privacy protection mechanism is adopted, which adds random noise to the model parameters to protect data privacy. Furthermore, the noise intensity is controlled by a dynamic adjustment factor, achieving a balance between protecting privacy and maintaining model performance. The system design is flexible and scalable, supporting collaborative training from multiple data sources, and each data source can be trained independently locally, improving the system's availability and practicality.
[0159] In one alternative implementation,
[0160] The importance score of each layer parameter is determined based on the variance of the Gaussian noise, and random noise with a mean of zero is generated. The random noise is added to the global algorithm parameters to obtain the noise-perturbed global algorithm parameters. An evaluation index set is constructed and a dynamic adjustment factor is calculated. Based on the dynamic adjustment factor, the noise-perturbed global algorithm parameters are distributed to the data source, including:
[0161] The weight distribution of global algorithm parameters is calculated based on the variance of the Gaussian noise to obtain the importance score of each layer parameter. Based on the importance score, the global algorithm parameters are divided into core parameter group and non-core parameter group. The first Gaussian noise variance of the core parameter group and the second Gaussian noise variance of the non-core parameter group are generated according to the preset noise intensity benchmark value. The first Gaussian noise variance is the noise intensity benchmark value multiplied by a first proportional coefficient, and the second Gaussian noise variance is the noise intensity benchmark value multiplied by a second proportional coefficient. The first proportional coefficient is less than the second proportional coefficient.
[0162] A first random noise with a mean of zero is generated based on the variance of the first Gaussian noise, and a second random noise with a mean of zero is generated based on the variance of the second Gaussian noise. The first random noise is added to the core parameter group to obtain the core parameters after noise perturbation, and the second random noise is added to the non-core parameter group to obtain the non-core parameters after noise perturbation.
[0163] An evaluation index set is constructed to calculate the parameter distribution change, performance loss rate, and privacy protection strength of the core parameters and non-core parameters after noise perturbation relative to the original parameters. A dynamic adjustment factor is calculated based on the parameter distribution change, performance loss rate, and privacy protection strength.
[0164] When the dynamic adjustment factor exceeds the preset threshold, a compensation term is constructed based on the difference between the historical parameter mean and the current parameter and the compensation weight. The compensation term is then added to the core parameters after noise perturbation and the non-core parameters after noise perturbation to obtain the global algorithm parameters after noise perturbation.
[0165] The computing power of the data source is rated to obtain different capability levels. Based on the capability level, the global algorithm parameters after noise perturbation are compressed at different ratios to obtain different versions of parameter packages. The different versions of parameter packages are distributed to the data source corresponding to the capability level.
[0166] When calculating the parameter weight distribution, it is necessary to track and record the impact of each parameter on the algorithm's prediction results. Backpropagation is used to calculate the gradient value of each parameter. The absolute value of the gradient over all training samples is then averaged to obtain the average influence of that parameter on the algorithm's output. The gradient values of all parameters in each layer of the network are normalized, and the normalized values are used as the importance score of the parameter. The normalization process uses a minimax scaling method to ensure that the score ranges between 0 and 1.
[0167] After calculating the parameter importance scores, all parameters are sorted in descending order of their scores. The score distribution is analyzed to determine a suitable split threshold. Typically, the inflection point of the score distribution is chosen as the split boundary, or the top 30% of parameters are directly selected as core parameters. Parameters above the threshold are grouped into the core parameter group; these parameters have a significant impact on algorithm performance and require strong protection. Parameters below the threshold are grouped into the non-core parameter group; these parameters have a relatively smaller impact on algorithm performance and can tolerate greater noise disturbances.
[0168] A baseline noise intensity value is established, which determines the overall noise disturbance level. A smaller scaling factor (e.g., 0.3) is used for the core parameter group, and a larger scaling factor (e.g., 0.7) is used for the non-core parameter group. The baseline value is multiplied by each scaling factor to obtain the Gaussian noise variance for the two parameter groups. A smaller noise variance better protects the valid information in the core parameters, while a larger noise variance provides stronger privacy protection for the non-core parameters.
[0169] When generating random noise, two independent uniformly distributed random numbers are produced. The uniform distribution is then converted to a standard normal distribution using a Box-Muller transform. The resulting standard normal random numbers are multiplied by the standard deviations of the two sets of parameters (the square roots of the noise variances) to obtain Gaussian noise that satisfies the desired variance. The mean of this noise is zero, and its variance is equal to the two previously calculated noise variance values.
[0170] Add a first set of random noise to each parameter in the core parameter set, and a second set of random noise to each parameter in the non-core parameter set. After adding noise, the new value of each parameter is equal to the original value plus the corresponding random noise value. Since the noise mean is zero, the expected value of the parameter remains unchanged, only producing random perturbations around the original value.
[0171] When evaluating the effect of parameter perturbation, three specific indicators are calculated: the degree of change in parameter distribution is measured using KL divergence to determine the difference in parameter distribution before and after perturbation; the algorithm performance loss rate is calculated by testing on a validation dataset to determine the relative decrease in algorithm accuracy before and after perturbation; and the privacy protection strength is calculated based on differential privacy theory to determine the consumed privacy budget. These three indicators are assigned weights of 0.3, 0.4, and 0.3 respectively, and a weighted sum is obtained to obtain the dynamic adjustment factor.
[0172] When the adjustment factor exceeds a preset threshold (e.g., 0.3), the parameter compensation mechanism is triggered. First, the historical average value of each parameter in the last 20 training iterations is calculated. The difference between the current parameter value and the historical average value is used to obtain the parameter offset. A compensation weight is set (e.g., 0.4), and the parameter offset is multiplied by the compensation weight to obtain the compensation term. The compensation term is then added to both the perturbed core parameters and non-core parameters to obtain the final global model parameters.
[0173] When evaluating the computing power of a data source, CPU floating-point operation speed, available memory capacity, network data transfer rate, and storage read / write speed are tested separately. After standardizing each indicator, a weighted sum is calculated to obtain a comprehensive capability score for the data source. Based on the score, data sources are divided into three levels: high, medium, and low. High-capability data sources receive the complete parameter package, medium-capability data sources receive a parameter package compressed to 75% of its original size, and low-capability data sources receive a parameter package compressed to 50% of its original size.
[0174] For example, taking the content marketing recommendation algorithm of an e-commerce platform as an example, the algorithm parameters include dimensions such as user interest characteristics, product attribute characteristics, and interaction behavior characteristics. The parameter matrix of the user interest profile module is selected for processing; this matrix contains the user's preference weights for different types of content.
[0175] By analyzing user behavior data such as clicks, dwell time, sharing, and favorites during content interactions, an importance score was calculated for each feature parameter. The product category preference feature scored 0.95; the content topic preference feature scored 0.92; the interaction time feature scored 0.88; and the creator preference feature scored 0.85. Other features, such as device type and access frequency, had relatively lower scores, ranging from 0.65 to 0.75.
[0176] The importance score threshold was set at 0.8. Core features above this threshold included product category preference, content topic preference, interaction time, and creator preference. These features directly affected the accuracy of content recommendations. Non-core features below the threshold included environmental factors such as device type, access frequency, and geographic location, which had a relatively smaller impact on recommendation performance.
[0177] With a noise baseline of 0.1, a scaling factor of 0.3 is used for core features, resulting in a noise variance of 0.03; a scaling factor of 0.7 is used for non-core features, resulting in a noise variance of 0.07. The generated random noise causes the preference weights of core features to fluctuate by ±2% from their original values, and the weights of non-core features to fluctuate by ±5%.
[0178] When evaluating the effect of the perturbation, the weight distribution change was calculated to be 0.25, indicating that the overall shape of the user preference distribution remained stable. Recommendation accuracy decreased from 85% to 72%, a drop within an acceptable range. The privacy protection strength reached 0.8, effectively preventing the reverse inference of user preference data.
[0179] Since the overall score of the evaluation index is 0.35, exceeding the threshold of 0.3, parameter compensation is initiated: Analyzing the user preference change trend over the past 20 days, it was found that the current weight differs from the historical average by ±5%. A compensation weight of 0.4 is adopted to add ±2% compensation adjustment to the perturbed parameters.
[0180] Data source capability assessment shows: Site A has an average daily content update volume of 100,000 items and complete user interaction data, rated as high capability level; Site B has an average daily update volume of 50,000 items and slightly missing interaction data, rated as medium capability level; Site C has an average daily update volume of 10,000 items and retains only core interaction data, rated as low capability level. The original feature weight package size is 100MB, and 100%, 75%, and 50% of the feature dimensions are retained for different capability levels respectively.
[0181] In this embodiment, by calculating the degree of influence of parameters on the algorithm output, the parameters are divided into core parameter groups and non-core parameter groups. Different intensities of noise perturbation are applied to each group to provide more precise protection for important parameters. An evaluation index set is constructed, including parameter distribution variation, algorithm performance loss rate, and privacy protection strength, to monitor the effect of parameter perturbation in real time. When the performance loss caused by the perturbation exceeds expectations, a parameter compensation mechanism is used to correct the perturbed parameters.
[0182] In existing technologies, a uniform privacy protection strategy is usually adopted when sharing algorithm parameters. Random noise of the same intensity is added to all parameters, ignoring the differences in the importance of different parameters to the algorithm performance. This results in excessive perturbation of key feature parameters, which significantly reduces the recommendation accuracy of the algorithm. At the same time, existing technologies lack the evaluation and correction mechanism for the effect of parameter perturbation, and cannot detect and adjust the performance loss caused by excessive perturbation in a timely manner.
[0183] This embodiment effectively reduces the negative impact of parameter perturbation on algorithm performance while ensuring strong privacy protection. The differentiated noise addition strategy provides more precise protection for core feature parameters, resulting in a significantly lower loss in model recommendation accuracy compared to a uniform perturbation scheme. The differentiated parameter distribution strategy, tailored to different computing capabilities, increases the participation of resource-constrained data sources and expands the scale of joint training. It exhibits good versatility and scalability, allowing for adjustments to parameter grouping strategies and perturbation strength based on specific application scenarios, achieving a flexible trade-off between privacy protection and algorithm performance.
[0184] Figure 3This diagram compares the parameter importance distribution and noise variance allocation strategies of the content marketing user behavior prediction method based on big data analysis, as described in this embodiment of the invention. It illustrates the parameter importance distribution and the corresponding noise variance allocation strategies. The diagram uses circular data points and continuous curves to represent parameter importance scores, arranged in descending order, clearly showing the long-tail distribution characteristics. The parameter importance distribution shows that the top 10% of parameters in the model have an importance score as high as 0.92, while the bottom 10% have an importance score of only 0.04. The data points are connected by smooth curves, intuitively demonstrating the imbalance in parameter importance.
[0185] The left side of the figure marks the top 30% of core parameters, with a vertical dashed line (parameter importance score = 0.85) serving as the boundary between core and non-core parameters. This technical solution (marked by squares) applies a lower noise variance (0.03) to core parameters, while gradually increasing the noise variance for non-core parameters as importance decreases, from 0.05 to 0.10. This differentiated noise allocation strategy shows a clear negative correlation with the parameter importance curve, consistent with the design principle of "less perturbation for important parameters, more perturbation for less important parameters." In contrast, the traditional uniform noise variance method (marked by triangles on the horizontal line) applies the same noise intensity (0.06) to all parameters, without considering differences in parameter importance. This approach fails to provide adequate protection for critical parameters (due to excessive noise) and imposes unnecessary constraints on non-critical parameters (due to insufficient noise), thus failing to achieve reasonable resource allocation. This technical solution achieves the differentiated privacy protection goal of "less perturbation for critical parameters and more perturbation for non-critical parameters," effectively resolving the inherent contradiction between performance and privacy protection in traditional differential privacy methods such as the DP-SGD algorithm.
[0186] In one alternative implementation,
[0187] The data from the first user group, the second user group, and the third user group are respectively input into the distributed prediction method to obtain user behavior prediction results. The user behavior prediction results are then optimized using a reinforcement learning algorithm based on a preset reward function to generate content marketing strategy data, including:
[0188] The data of the first, second, and third user groups are respectively input into the distributed prediction method. The distributed prediction method constructs feature vectors based on the user's historical browsing data, interaction behavior data, and purchase record data. The feature vectors are then input into a pre-trained deep learning model for prediction to obtain user behavior prediction results.
[0189] Construct a reward function based on user behavior prediction results. The reward function includes a weighted combination of three factors: user click-through rate, user conversion rate, and marketing cost. The weight coefficient of user click-through rate is positively correlated with user activity, the weight coefficient of user conversion rate is positively correlated with user purchasing power, and the weight coefficient of marketing cost is negatively correlated with marketing budget.
[0190] According to the reinforcement learning algorithm, the user behavior prediction results are iteratively optimized based on the reward function. The reinforcement learning algorithm maximizes the expected value of the reward function by combining exploratory strategy sampling and exploitation strategy evaluation. The exploratory strategy randomly selects marketing actions based on the ε-greedy algorithm, and the exploitation strategy determines the marketing strategy based on the historical best results. The optimal marketing strategy is determined by dynamically balancing the proportions of the exploratory strategy and the exploitation strategy.
[0191] The distributed prediction algorithm receives data input from three user groups. For each user, it collects their historical browsing data, including the type of content viewed, browsing duration, and browsing frequency; it collects interaction behavior data, including records of actions such as clicks, favorites, shares, and comments; and it collects purchase record data, including the type of goods purchased, purchase amount, and purchase frequency.
[0192] The collected data is converted into feature vectors: browsing data is converted into content preference features, including the distribution of user attention to different types of content; interaction behavior is converted into activity features, including the frequency and intensity of various interactive operations; and purchase records are converted into spending power features, including purchasing power level and purchase intention strength. These feature vectors are input into a pre-trained deep learning model, which extracts the complex relationships between features through multi-layered neural networks, outputting user behavior prediction results in different marketing scenarios.
[0193] When constructing the reward function, the following weights are calculated: Click-through rate (CTR) weight: A weighting coefficient is set based on user activity; users with higher activity levels receive a greater CTR weight. Conversion rate weight: A weighting coefficient is set based on user purchasing power; users with higher purchasing power receive a greater conversion rate weight. Marketing cost weight: A weighting coefficient is set based on the available marketing budget; the more abundant the budget, the smaller the cost weight. Multiplying these three weighting coefficients by their corresponding factors and summing the results yields the complete reward function.
[0194] Reinforcement learning algorithms optimize marketing decisions through two strategies: exploration and exploitation. The exploration strategy employs an ε-greedy algorithm: an initial exploration probability ε is set, and marketing actions are randomly selected for trial with probability ε, while the optimal action is chosen with probability 1-ε. The exploitation strategy makes decisions based on the best-performing marketing strategies from historical data. As the training epochs increase, the exploration probability ε is gradually decreased, while the proportion of exploiting the optimal strategy is increased.
[0195] For example, an e-commerce platform collects user data: highly active users spend more than 2 hours browsing per day, interact more than 50 times per week, and spend more than 1,000 yuan per month; moderately active users browse for 1 hour per day, interact 30 times per week, and spend 500 yuan per month; and inactive users browse for 30 minutes per day, interact 10 times per week, and spend 100 yuan per month.
[0196] User A's data is converted into a feature vector: Content preference features show that they pay the most attention to the beauty category, followed by the clothing category; recent interaction behavior is mainly clicks and favorites, with fewer comments and shares; purchase history shows that they prefer low- to mid-priced products and are relatively cautious in their purchases. The feature vector is input into a deep learning model to predict the user's response probability to different marketing methods.
[0197] Construct the reward function: User A belongs to a moderately active group, with a click-through rate weight of 0.3; their purchasing power is at a moderate level, with a conversion rate weight of 0.4; currently in a promotional period with a sufficient marketing budget, the cost weight is set to 0.3. Multiply the user's expected click-through rate, expected conversion rate, and marketing cost by their respective weights and sum them to obtain the reward value for this marketing strategy.
[0198] The reinforcement learning optimization process: Initially, the exploration probability ε was set to 0.3, meaning there was a 30% probability of randomly trying new marketing strategies and a 70% probability of using the best-performing strategy historically. After multiple iterations, it was found that the combination of coupons and image / text content recommendations was the most effective strategy for this user group. As the number of training rounds increased, ε was reduced to 0.1, primarily employing proven effective marketing strategies. Finally, the optimal marketing strategy combination for this user group was determined.
[0199] In this embodiment, a distributed prediction model is used to accurately profile and predict the behavior of different types of users, which improves the accuracy of user analysis and the reliability of prediction, making marketing strategies more targeted. A reinforcement learning algorithm is used to dynamically optimize the marketing strategy, find a balance between exploration and utilization, continuously improve the strategy effect, avoid getting stuck in local optima, and improve marketing effectiveness. Based on the design of a multi-factor weighted reward function, multiple dimensions such as user activity, purchasing power and marketing costs are comprehensively considered, making marketing decisions more comprehensive and reasonable, and achieving efficient allocation of marketing resources.
[0200] A content marketing user behavior prediction system based on big data analytics includes:
[0201] The first unit is used to collect users' historical behavior data on the content marketing platform, establish user identifier mapping relationship, preprocess the historical behavior data, and generate user behavior feature vectors by removing abnormal data, normalizing and reducing feature dimensionality.
[0202] The second unit is used to enhance the user behavior feature vector based on the transfer learning method. It establishes a unified feature representation space for user behavior feature vectors in different scenarios through cross-scenario feature mapping, and dynamically allocates weight coefficients according to feature importance scores to achieve adaptive adjustment of feature weights.
[0203] The third unit is used to process the enhanced user behavior feature vectors through clustering algorithms, calculate the similarity distance between user features, and divide users into a first user group, a second user group, and a third user group based on the similarity distance.
[0204] The fourth unit is used to construct a distributed prediction method based on federated learning. Local prediction algorithms are trained independently on each data source through local training units. The parameters of multiple local prediction algorithms are fused by weighted averaging, and random noise is added to the algorithm parameters to protect data privacy.
[0205] The fifth unit is used to input the data of the first user group, the second user group, and the third user group into the distributed prediction method to obtain user behavior prediction results, and to optimize the user behavior prediction results according to a preset reward function through a reinforcement learning algorithm to generate content marketing strategy data.
[0206] This invention can be a method, apparatus, system, and / or computer program product. The computer program product may include a computer-readable storage medium having computer-readable program instructions loaded thereon for performing various aspects of the invention.
[0207] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present invention.
Claims
1. A content marketing user behavior prediction method based on big data analysis, characterized in that, include: Collect users' historical behavior data on content marketing platforms, establish user identifier mapping relationships, preprocess the historical behavior data, and generate user behavior feature vectors by removing abnormal data, normalizing, and reducing feature dimensionality. The user behavior feature vector is enhanced using transfer learning. A unified feature representation space is established for user behavior feature vectors in different scenarios through cross-scenario feature mapping. Weight coefficients are dynamically allocated based on feature importance scores to achieve adaptive adjustment of feature weights, including: The system receives user behavior feature vectors from a source domain feature space and user behavior feature vectors from a target domain feature space, wherein the user behavior feature vectors from the source domain feature space and the user behavior feature vectors from the target domain feature space have different distribution characteristics. A dual-stream neural network structure is constructed through cross-scene feature mapping. The dual-stream neural network structure includes a source domain feature extraction subnetwork and a target domain feature extraction subnetwork. A first mapping feature is obtained by nonlinearly transforming the user behavior feature vector in the source domain feature space using a first feature mapping function pre-set in the source domain feature extraction subnetwork. A second mapping feature is obtained by nonlinearly transforming the user behavior feature vector in the target domain feature space using a second feature mapping function pre-set in the target domain feature extraction subnetwork. The feature distribution difference is obtained by calculating the L2 distance between the mean of the first mapped feature sample and the mean of the second mapped feature sample in the regenerating kernel Hilbert space based on the maximum mean difference criterion. The feature distribution difference is then input into a dynamic kernel selection mechanism, which includes multiple preset Gaussian kernel functions. The optimal kernel function combination is obtained by iteratively optimizing the weight coefficients of the multiple preset Gaussian kernel functions through the gradient descent method. The system receives the first mapping feature and the second mapping feature, performs a linear transformation using a pre-set learnable transformation matrix, and then obtains the feature hidden layer representation through the hyperbolic tangent activation function. The system then performs an inner product operation between the pre-set learnable attention vector and the feature hidden layer representation to obtain the importance score for each feature dimension. The feature importance scores are normalized using softmax to obtain feature weight coefficients. L1 norm sparsity regularization constraints are applied to the feature weight coefficients. The sparsity of the feature weights is controlled by setting the regularization coefficients to obtain sparsified feature weight coefficients. The sparsified feature weight coefficients are applied to the first mapping feature and the second mapping feature respectively to obtain the enhanced feature representation in the unified feature representation space, wherein the sparsified feature weight coefficients are used to highlight the contribution of important feature dimensions and suppress the influence of irrelevant feature dimensions. The enhanced user behavior feature vectors are processed using a clustering algorithm to calculate the similarity distance between user features and to divide users into a first user group, a second user group, and a third user group based on the similarity distance. A distributed prediction method based on federated learning is constructed. Local prediction algorithms are independently trained on various data sources through local training units. The parameters of multiple local prediction algorithms are fused by weighted averaging, and random noise is added to the algorithm parameters to protect data privacy. The data of the first user group, the second user group, and the third user group are respectively input into the distributed prediction method to obtain user behavior prediction results. The user behavior prediction results are then optimized by a reinforcement learning algorithm according to a preset reward function to generate content marketing strategy data.
2. The method according to claim 1, characterized in that, Collecting historical user behavior data on content marketing platforms, establishing user identifier mapping relationships, and preprocessing the historical behavior data to generate user behavior feature vectors through outlier removal, normalization, and feature dimensionality reduction include: Collect users’ historical behavior data on the content marketing platform. The historical behavior data includes user identifier, behavior type and timestamp. The user identifiers in the historical behavior data are uniformly mapped, a cross-platform user identifier association table is established, and historical behavior data with the same user identifier are associated and merged. The interquartile range of numerical features is calculated using the box plot method. Data that exceed 1.5 times the interquartile range of the upper and lower quartiles are marked as outliers and deleted. Missing values are filled according to the mean of the feature they belong to, and the maximum and minimum values of numerical features are normalized to map the feature values to the interval [0, 1]. One-hot encoding is performed on categorical features, and principal component analysis is used to reduce the dimensionality of high-dimensional features. Principal components with cumulative contribution rates reaching a preset threshold are selected to construct standardized user behavior feature vectors.
3. The method according to claim 1, characterized in that, After performing a linear transformation using a pre-set learnable transformation matrix, a feature hidden layer representation is obtained through a hyperbolic tangent activation function. The importance score for each feature dimension is then obtained by performing an inner product operation between the pre-set learnable attention vector and the feature hidden layer representation, including: An adversarial learning module is constructed, which includes a feature generator and a feature discriminator. The feature generator receives input features and generates adversarial features. The feature discriminator outputs a discrimination probability based on the input features and the adversarial features. The feature generator is trained based on the discrimination probability. The input features and the adversarial features are linearly transformed using a learnable transformation matrix to obtain a first feature representation and an adversarial feature representation, respectively. The learnable transformation matrix is then adversarially trained based on the discriminant probability. The first feature representation and the adversarial feature representation are then input into a hyperbolic tangent activation function to obtain a feature hidden layer representation and an adversarial feature hidden layer representation, respectively. The feature hidden layer representation and the adversarial feature hidden layer representation are used to construct contrastive learning samples. A dynamically maintained feature queue is constructed based on the contrastive learning samples. The historical representations of the feature hidden layer representations are stored in the feature queue. Positive sample pairs are constructed based on the historical representations and the current feature hidden layer representations in the feature queue. Negative sample pairs are constructed based on the adversarial feature hidden layer representations. The similarity between the positive sample pairs and the similarity between the negative sample pairs are calculated. The calculation result of the similarity is used as the contrastive loss. The contrastive loss is used to optimize the feature hidden layer representations to obtain the optimized feature hidden layer representations. Initialize a learnable attention vector, update the parameters of the learnable attention vector based on the contrastive loss, and perform an inner product operation between the updated learnable attention vector and the optimized feature hidden layer representation to obtain the importance score of each feature dimension.
4. The method according to claim 1, characterized in that, The enhanced user behavior feature vectors are processed using a clustering algorithm. The similarity distance between user features is calculated, and users are divided into a first user group, a second user group, and a third user group based on this similarity distance. The system receives historical behavior data from users, encodes the time information in the historical behavior data into a time-series feature vector using a time-series encoder, and fuses the time-series feature vector with the user behavior feature vector to obtain a feature enhancement vector. The feature enhancement vector contains the time-series correlation information of user behavior. The cosine similarity between the feature enhancement vectors is calculated to obtain a similarity distance matrix, where each element of the similarity distance matrix represents the degree of difference in behavioral patterns between the corresponding two users; Spectral clustering analysis is performed on the similarity distance matrix, and users are divided into three user groups based on the clustering results: the first user group, the second user group, and the third user group.
5. The method according to claim 1, characterized in that, A distributed prediction method based on federated learning is constructed. Local prediction algorithms are independently trained on various data sources using local training units. A weighted average method is used to fuse the parameters of multiple local prediction algorithms. Random noise is added to the algorithm parameters to protect data privacy, including: A distributed prediction method based on federated learning is constructed. On each data source, a local prediction algorithm is independently trained based on the local dataset corresponding to the current data source. For each data source, a loss function including a prediction loss term and a regularization term is calculated. The prediction loss term is the mean of the sample prediction loss, and the regularization term is the L2 norm of the model parameters. The parameters of the local prediction algorithm are obtained by optimizing the loss function using the stochastic gradient descent method. The number of samples in each data source is obtained, and the number of samples in each data source is divided by the total number of samples in all data sources to obtain the corresponding weight coefficient. Based on the weight coefficient, the parameters of multiple local prediction algorithms are fused using a weighted average method to obtain the global algorithm parameters. The variance of Gaussian noise is calculated based on preset sensitivity coefficients and function sensitivity. The variance of Gaussian noise is equal to the product of the sensitivity coefficients and the function sensitivity divided by the current privacy budget. The current privacy budget is obtained by multiplying the initial privacy budget by an exponential function of the decay coefficient. The decay coefficient is related to the training round. The importance score of each layer parameter is determined based on the variance of the Gaussian noise, and random noise with a mean of zero is generated. The random noise is added to the global algorithm parameters to obtain the noise-perturbed global algorithm parameters. An evaluation index set is constructed and a dynamic adjustment factor is calculated. Based on the dynamic adjustment factor, the noise-perturbed global algorithm parameters are distributed to the data source. The parameters of the local prediction algorithm are updated using the global algorithm parameters after noise perturbation, and the local training, parameter aggregation and privacy protection steps are repeated until training converges.
6. The method according to claim 5, characterized in that, The importance score of each layer parameter is determined based on the variance of the Gaussian noise, and random noise with a mean of zero is generated. The random noise is added to the global algorithm parameters to obtain the noise-perturbed global algorithm parameters. An evaluation index set is constructed and a dynamic adjustment factor is calculated. Based on the dynamic adjustment factor, the noise-perturbed global algorithm parameters are distributed to the data source, including: The weight distribution of global algorithm parameters is calculated based on the variance of the Gaussian noise to obtain the importance score of each layer parameter. Based on the importance score, the global algorithm parameters are divided into core parameter group and non-core parameter group. The first Gaussian noise variance of the core parameter group and the second Gaussian noise variance of the non-core parameter group are generated according to the preset noise intensity benchmark value. The first Gaussian noise variance is the noise intensity benchmark value multiplied by a first proportional coefficient, and the second Gaussian noise variance is the noise intensity benchmark value multiplied by a second proportional coefficient. The first proportional coefficient is less than the second proportional coefficient. A first random noise with a mean of zero is generated based on the variance of the first Gaussian noise, and a second random noise with a mean of zero is generated based on the variance of the second Gaussian noise. The first random noise is added to the core parameter group to obtain the core parameters after noise perturbation, and the second random noise is added to the non-core parameter group to obtain the non-core parameters after noise perturbation. An evaluation index set is constructed to calculate the parameter distribution change, performance loss rate, and privacy protection strength of the core parameters and non-core parameters after noise perturbation relative to the original parameters. A dynamic adjustment factor is calculated based on the parameter distribution change, performance loss rate, and privacy protection strength. When the dynamic adjustment factor exceeds the preset threshold, a compensation term is constructed based on the difference between the historical parameter mean and the current parameter and the compensation weight. The compensation term is then added to the core parameters after noise perturbation and the non-core parameters after noise perturbation to obtain the global algorithm parameters after noise perturbation. The computing power of the data source is rated to obtain different capability levels. Based on the capability level, the global algorithm parameters after noise perturbation are compressed at different ratios to obtain different versions of parameter packages. The different versions of parameter packages are distributed to the data source corresponding to the capability level.
7. The method according to claim 1, characterized in that, The data from the first user group, the second user group, and the third user group are respectively input into the distributed prediction method to obtain user behavior prediction results. The user behavior prediction results are then optimized using a reinforcement learning algorithm based on a preset reward function to generate content marketing strategy data, including: The data of the first, second, and third user groups are respectively input into the distributed prediction method. The distributed prediction method constructs feature vectors based on the user's historical browsing data, interaction behavior data, and purchase record data. The feature vectors are then input into a pre-trained deep learning model for prediction to obtain the user behavior prediction results. Construct a reward function based on user behavior prediction results. The reward function includes a weighted combination of three factors: user click-through rate, user conversion rate, and marketing cost. The weight coefficient of user click-through rate is positively correlated with user activity, the weight coefficient of user conversion rate is positively correlated with user purchasing power, and the weight coefficient of marketing cost is negatively correlated with marketing budget. According to the reinforcement learning algorithm, the user behavior prediction results are iteratively optimized based on the reward function. The reinforcement learning algorithm maximizes the expected value of the reward function by combining exploratory strategy sampling and exploitation strategy evaluation. The exploratory strategy randomly selects marketing actions based on the ε-greedy algorithm, and the exploitation strategy determines the marketing strategy based on the historical best results. The optimal marketing strategy is determined by dynamically balancing the proportions of the exploratory strategy and the exploitation strategy.
8. A content marketing user behavior prediction system based on big data analysis, used to implement the method of any one of claims 1-6, characterized in that, include: The first unit is used to collect users' historical behavior data on the content marketing platform, establish user identifier mapping relationship, preprocess the historical behavior data, and generate user behavior feature vectors by removing abnormal data, normalizing and reducing feature dimensionality. The second unit is used to enhance the user behavior feature vector based on the transfer learning method. It establishes a unified feature representation space for user behavior feature vectors in different scenarios through cross-scenario feature mapping, and dynamically allocates weight coefficients according to feature importance scores to achieve adaptive adjustment of feature weights. The third unit is used to process the enhanced user behavior feature vectors through clustering algorithms, calculate the similarity distance between user features, and divide users into a first user group, a second user group, and a third user group based on the similarity distance. The fourth unit is used to construct a distributed prediction method based on federated learning. Local prediction algorithms are independently trained on each data source through local training units. The parameters of multiple local prediction algorithms are fused by weighted averaging, and random noise is added to the algorithm parameters to protect data privacy. The fifth unit is used to input the data of the first user group, the second user group, and the third user group into the distributed prediction method to obtain user behavior prediction results, and to optimize the user behavior prediction results according to a preset reward function through a reinforcement learning algorithm to generate content marketing strategy data.
Citation Information
Patent Citations
Artificial intelligence advertisement pushing method based on multi-dimensional historical data analysis
CN120298046A
Online resource adaptive recommendation method for multi-modal learning behavior analysis
CN120561380A