A product recommendation method, device, equipment, storage medium and product
Patent Information
- Application Number
- CN202611205643.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-10
- Publication Date
- 2026-10-27
AI Technical Summary
[0003]本申请提供一种产品推荐方法、装置、设备、存储介质及产品,以解决现有技术中采用单层次聚类,导致推荐粒度粗,推荐结果不够精准的问题
[0016]为实现上述目的,本申请实施例还提供了一种计算机程序产品,包括计算机程序/指令,该计算机程序/指令被处理器执行时实现如上述的产品推荐方法。
Smart Images

Figure CN122986180A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of artificial intelligence technology, and in particular to a product recommendation method, apparatus, device, storage medium, and product. Background Technology
[0002] For product recommendations, existing technologies employ single-level clustering, resulting in coarse-grained recommendations. This approach often matches the same user category with a single product category as a whole, failing to capture the diverse, or even contradictory, product needs within the same user group, thus leading to inaccurate recommendation results. Summary of the Invention
[0003] This application provides a product recommendation method, apparatus, device, storage medium, and product to solve the problem that the existing technology uses single-level clustering, resulting in coarse recommendation granularity and inaccurate recommendation results.
[0004] To achieve the above objectives, embodiments of this application provide a product recommendation method, including: Obtain the feature vector of each of the multiple target users; wherein, the feature vector of the target user includes a non-product demand feature vector and a product demand feature vector; Clustering is performed on the non-product demand feature vector of each target user to obtain multiple clusters; For each cluster, the cluster is further clustered according to the product demand feature vector of the target user to obtain multiple sub-clusters included in the cluster. For each sub-cluster, based on the model domain characteristics, a decision model is matched for the sub-cluster from the decision model library. Using the matched decision model, the weights of the product demand attributes corresponding to each dimension of the product demand feature vector within the sub-cluster are obtained. The decision model library includes at least one decision model, which is trained based on the product demand feature vector samples and weight label values in the training sample set. Product recommendations are made to the target user based on the weights.
[0005] As an improvement to the above scheme, before obtaining the feature vector of each of the multiple target users, the method further includes: Obtain the feature vector for each user among multiple users; Standardize each element value in the feature vector of each user to obtain the standard value of each element value; A comprehensive value for each user is obtained by comprehensively calculating the standard value of each element. Based on each user's overall score, select multiple target users from the multiple users.
[0006] As an improvement to the above scheme, the standardization process for each element value in the feature vector of each user to obtain a standard value for each element value includes: For each element value in the feature vector of each user, calculate the mean and standard deviation of the dimension to which the element value belongs, and standardize the element value according to the mean and standard deviation to obtain the standard value of the element value.
[0007] As an improvement to the above scheme, the step of matching a decision model for the sub-cluster from the decision model library based on the model domain characteristics includes: The domain features of each decision model in the decision model library are obtained and vectorized to obtain the domain feature vector of each decision model. Calculate the first similarity between the feature vector of the sub-cluster and the domain feature vector of each decision model in the decision model library. Based on the first similarity, match the decision model with the largest first similarity for the sub-cluster from the decision model library.
[0008] As an improvement to the above scheme, one of the decision models in the decision model library is obtained through the following steps: Obtain the training sample set; wherein, the training sample set includes multiple sub-cluster samples, and each sub-cluster sample includes: multiple product demand feature vector samples and the weight label value corresponding to each product demand feature vector sample; For each sub-cluster sample, the multiple product demand feature vector samples of the sub-cluster sample are input into a preset neural network model to determine the weight prediction value of each product demand feature vector sample of the sub-cluster sample. The neural network model is updated using the weight label values and the weight prediction values to obtain a trained decision model.
[0009] As an improvement to the above scheme, the step of using the matched decision model to obtain the weight of the product demand attribute corresponding to each dimension of the product demand feature vector within the sub-cluster includes: Using the matched decision model, the conditional probability of each product demand feature vector in the sub-cluster is calculated. Based on the comprehensive calculation of each conditional probability, the weight of the product demand attribute corresponding to each dimension of the product demand feature vector in the sub-cluster is obtained.
[0010] As an improvement to the above scheme, the step of recommending products to the target user based on the weight includes: Based on the weights, a recommendation analysis report is obtained for different target users under different product demand attributes; Based on the recommendation analysis report, a strategy approximation algorithm is used to obtain product recommendation strategies for different target users. Based on the product recommendation strategy, product recommendations are made to the target user.
[0011] As an improvement to the above scheme, the step of clustering based on the non-product demand feature vector of each target user to obtain multiple clusters includes: The non-product demand feature vector of each target user is standardized to obtain the non-product demand standard feature vector of each target user. Calculate the second similarity between the non-product demand standard feature vectors of each pair of target users; Clustering is performed based on the second similarity.
[0012] As an improvement to the above scheme, the standardization process for the non-product demand feature vector of each target user to obtain the non-product demand standard feature vector of each target user includes: For each target user's non-product demand feature vector, each element value in the non-product demand feature vector is standardized according to the mean and standard deviation of each element value in its own dimension to obtain a non-product demand standard feature vector.
[0013] To achieve the above objectives, embodiments of this application also provide a product recommendation device, comprising: The acquisition module is used to acquire the feature vector of each of the multiple target users; wherein, the feature vector of the target user includes a non-product demand feature vector and a product demand feature vector; The first clustering module is used to cluster based on the non-product demand feature vector of each target user to obtain multiple clusters; The second clustering module is used to cluster each cluster according to the product demand feature vector of the target user, so as to obtain multiple sub-clusters included in the cluster. The matching module is used to match a decision model from the decision model library for each sub-cluster based on the model domain characteristics, and use the matched decision model to obtain the weight of the product demand attribute corresponding to each dimension of the product demand feature vector within the sub-cluster; wherein, the decision model library includes at least one decision model, and the decision model is trained based on the product demand feature vector samples and weight label values in the training sample set. The recommendation module is used to recommend products to the target user based on the weights.
[0014] To achieve the above objectives, embodiments of this application also provide a product recommendation device, including a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein the processor implements the product recommendation method as described above when executing the computer program.
[0015] To achieve the above objectives, embodiments of this application also provide a computer-readable storage medium, the computer-readable storage medium including a stored computer program; wherein, when the computer program is executed, it controls the device where the computer-readable storage medium is located to perform the product recommendation method as described above.
[0016] To achieve the above objectives, embodiments of this application also provide a computer program product, including a computer program / instructions, which, when executed by a processor, implement the product recommendation method as described above.
[0017] Compared with existing technologies, the product recommendation method, apparatus, device, storage medium, and product provided in this application embodiment employs a two-layer clustering approach. Specifically, it clusters users based on their non-product demand feature vectors to obtain multiple clusters. Then, it performs secondary clustering on each cluster based on the target users' product demand feature vectors, achieving a refined division of user needs. This effectively solves the problems of coarse recommendation granularity and inaccurate user-product matching caused by a single clustering mechanism, significantly improving the accuracy and personalization of recommendation results. Furthermore, for each sub-cluster obtained from the second-layer clustering, a dedicated decision model is matched and invoked for weight calculation. This not only improves the throughput of big data processing but also avoids the performance limitations of general models in specific scenarios, leading to a lack of domain-specificity in recommendation results. This greatly enhances the scientific rigor of the recommendation effect and has strong scenario applicability. Attached Figure Description
[0018] Figure 1 This is a flowchart of a product recommendation method provided in an embodiment of this application; Figure 2 This is a flowchart of another product recommendation method provided in the embodiments of this application. Figure 3 This is a structural block diagram of a product recommendation device provided in an embodiment of this application; Figure 4 This is a structural block diagram of a product recommendation device provided in an embodiment of this application. Detailed Implementation
[0019] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of this application.
[0020] In the description of this application, the sequence number of each process does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.
[0021] In this application description, the terms "exemplary" or "for example" are used to indicate examples, illustrations, or explanations. Any embodiment or design described as "exemplary" or "for example" in the embodiments of this application should not be construed as being more preferred or advantageous than other embodiments or designs. Specifically, the use of terms such as "exemplary" or "for example" is intended to present the relevant concepts in a specific manner.
[0022] In this application description, the terms "first," "second," etc., are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented, for example, in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus. The term "based on" means "at least partially based on." The term "according to" means "at least partially according to." The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments." The term "and / or" means at least one of the connected objects, such as A and / or B, indicating three cases: including only A, only B, and both A and B. Unless otherwise stated, the term "multiple" means two or more.
[0023] It should be noted that the information (including but not limited to user device information, user personal information, etc.), data (including but not limited to data used for analysis, data stored, data displayed, etc.) and signals involved in this application are all authorized by the user or fully authorized by all parties, and the collection, use and processing of related data must comply with relevant laws, regulations and standards.
[0024] See Figure 1 and Figure 2 The product recommendation method provided in this application includes: S1. Obtain the feature vector of each of the multiple target users; wherein, the feature vector of the target user includes a non-product demand feature vector and a product demand feature vector; It's worth noting that the target user can be any user, or it can be a user selected from those who meet preset requirements. These preset requirements are not specifically limited; for example, they could be users with specific behavioral characteristics or attributes. This targeted screening effectively eliminates abnormal users and improves the accuracy of clustering results.
[0025] The feature vector of the target user includes the non-product demand feature vector and the product demand feature vector of the target user; The target user's non-product requirement feature vector contains multiple dimensions (or multiple feature dimensions), each corresponding to one type of non-product requirement attribute: Demographic attributes, such as age, sex, marital status, education level, occupation, income, etc.; User behavior attributes, such as usage frequency, usage duration, and historical click-through rate; Value attributes, such as average order value; Other business tags (industry, region).
[0026] In other words, the non-product demand feature vector is a multi-dimensional vector, and the value of each dimension is a feature value obtained by quantifying at least one of the above non-product demand attributes. Using the non-product demand feature vector for clustering can divide users into macro-level clusters that are highly similar in overall attributes (such as "high-income middle-aged active users"), providing a benchmark for subsequent demand segmentation.
[0027] The target user's product requirement feature vector contains multiple dimensions (or multiple feature dimensions), each corresponding to one of the following product requirement attributes: Explicit / implicit demand ratings, such as ratings obtained through actions like clicking, saving, purchasing, and reviewing; Demand intensity (weight) or preference distribution, such as 0-1 normalization; Optional contextual dimensions, such as usage scenario, usage time period, etc.
[0028] In other words, the product demand feature vector is a multi-dimensional vector, and the value of each dimension is a feature value obtained by quantifying at least one of the above product demand attributes. Within the same macro cluster, the product demand attributes are further subdivided into finer-grained categories, so that users within the same cluster form more compact sub-clusters in the product demand space (such as "high-income users who prefer high-risk investment products").
[0029] In an optional embodiment, before obtaining the feature vector of each of the multiple target users, the method further includes: Obtain the feature vector for each user among multiple users; Standardize each element value in the feature vector of each user to obtain the standard value of each element value; A comprehensive value for each user is obtained by comprehensively calculating the standard value of each element. Based on each user's overall score, select multiple target users from the multiple users.
[0030] It is worth noting that the user's feature vector contains multiple feature dimensions, each corresponding to a type of user attribute. These user attributes can be divided into two main categories: non-product demand attributes and product demand attributes. Non-product demand attributes include demographic attributes, user behavior attributes, value attributes, and other business tags; product demand attributes include explicit / implicit demand ratings, demand intensity (weight) or preference distribution, and optional contextual dimensions. This application's embodiment obtains a comprehensive standard value for users through their feature information, and then filters target users based on this comprehensive standard value. This can eliminate abnormal users, ensure data validity, and improve the accuracy of clustering results.
[0031] Specifically, obtaining the feature vector of each user among multiple users includes: Retrieve user information for each user among multiple users; Feature extraction is performed on each user's information to obtain each user's feature information; The feature information of each user is vectorized to obtain the feature vector of each user.
[0032] It is worth noting that this application embodiment is based on big data mining methods, obtaining user information for each user according to user identifiers. Regarding the method of obtaining user information, user information can be crawled from databases storing user behavior data using user identifiers, or it can be crawled from interactive platforms such as browsers and social media software. User information can be information that reflects user characteristics, such as education level, family member information, consumption patterns, age, wealth level, consumption amount, industry, etc. The above information is obtained through open ports, without involving the acquisition of user privacy information. Multiple sets of user information can be obtained, and tags are configured for different user information in corresponding databases. Ultimately, different databases corresponding to different information are established, and information tags are set in the databases so that user feature information can be extracted from the databases later.
[0033] The user's feature information includes information on at least one of the aforementioned user attributes. For example, the user's age, income, consumption frequency, and tutorial level can be combined to form a user feature vector of [35, 20000, 8, 5], where 35, 20000, 8, and 5 represent the element values of the feature vector in each dimension, 35 indicates the age attribute, 20000 indicates the income attribute, 8 indicates the consumption frequency attribute, and 5 indicates the tutorial level attribute.
[0034] Specifically, the standardization process for each element value within the feature vector of each user to obtain a standard value for each element value includes: For each element value in the feature vector of each user, calculate the mean and standard deviation of the dimension to which the element value belongs, and standardize the element value according to the mean and standard deviation to obtain the standard value of the element value.
[0035] In this application embodiment, each element value in the feature vector is standardized based on the mean and standard deviation of its own dimension. This can place each element value under the benchmark of the entire user group, truly reflect its relative level in the corresponding dimension, avoid distortion caused by the difference in the feature distribution of individual users, and improve the accuracy and objectivity of the screening.
[0036] Specifically, the step of filtering the multiple target users from the multiple users based on the comprehensive standard value of each user includes: Based on the comprehensive standard value of each user, users whose comprehensive standard value is greater than a preset threshold are selected from the multiple users as target users.
[0037] In one specific embodiment, the first is calculated according to the following formula. Comprehensive standard value for individual customers : ; In the formula, Indicates the first The feature vector of the nth customer is in the... The element values of each valid dimension; Indicates the first The feature vector of the nth customer is in the... The standard value of each element in each effective dimension follows a distribution with a mean of 0 and a standard deviation of 1, ensuring that data from different attributes are of the same order of magnitude. , The feature vectors of multiple customers represent the feature vectors in the th... The average value of the elements in each valid dimension. , Indicates the total number of customers. The feature vectors of multiple customers represent the feature vectors in the th... The standard deviation of the element values in each effective dimension. ; Indicates the first The number of valid dimensions of a customer's feature vector, i.e. the number of non-empty dimensions, reflects data integrity. An index for customers, used to distinguish different customers, with a range of... ; This represents the effective dimension index of a feature vector, used to distinguish different attribute dimensions of a single feature vector, and its range is [range missing]. .
[0038] Filter from multiple users The target users are those users, among whom This is a preset threshold. It is an approximate value for the proportion of outlier data. The larger the threshold, the higher the detection rate, but also the higher the false positive rate. Statistical experience suggests that the probability of a user's feature set being "contaminated," i.e., the probability of abnormal data, is usually less than 5%, and at most no more than 15%. Therefore, the threshold is generally set... It is set to around 0.05, preferably 0.05.
[0039] S2. Cluster the non-product demand feature vectors of each target user to obtain multiple clusters; In this embodiment, clustering is performed based on the non-product demand feature vectors of target users to obtain multiple clusters. Each cluster represents a type of target user, and the non-product demand feature information of target users within each cluster is highly similar, thus achieving the first layer of clustering.
[0040] In one optional embodiment, the step of clustering based on the non-product demand feature vector of each target user to obtain multiple clusters includes: The non-product demand feature vector of each target user is standardized to obtain the non-product demand standard feature vector of each target user. Calculate the second similarity between the non-product demand standard feature vectors of each pair of target users; Clustering is performed based on the second similarity.
[0041] This application embodiment uses the second similarity between the non-product demand standard feature vectors of pairwise target users for clustering. This not only eliminates the influence of dimensions through standardization and improves the calculation accuracy of the second similarity, but also groups target users with similar non-product demand feature information together, thus achieving the first layer of clustering.
[0042] In an optional embodiment, the standardization process for the non-product demand feature vector of each target user to obtain a standardized non-product demand feature vector for each target user includes: For each target user's non-product demand feature vector, each element value in the non-product demand feature vector is standardized according to the mean and standard deviation of each element value in its own dimension to obtain a non-product demand standard feature vector.
[0043] In one specific embodiment, the following formula is used for the first... Non-product demand feature vector of a target user In the element values of each dimension After standardization, the first... Non-product demand standard feature vector of a target user : ; In the formula, Indicates the first The non-product demand feature vector of the target customer is in the first... The standard value of the element value of a dimension follows a distribution with a mean of 0 and a standard deviation of 1, so that the data of different attributes are of the same order of magnitude; This represents the non-product demand feature vectors of multiple target customers in the th... The average value of the elements in the dimension. , Indicates the total number of target customers; This represents the non-product demand feature vectors of multiple target customers in the th... The standard deviation of the element values of a dimension. . An index for target customers, used to differentiate between different target customers, with a range of... ; The dimension index representing the non-product demand feature vector. It is used to distinguish the different attribute dimensions of a single feature vector. Indicates the total number of dimensions.
[0044] In one specific embodiment, cosine similarity is used to calculate the second similarity between the non-product demand standard feature vectors of any two target users. : ; In the formula, Indicates target user Non-product demand standard feature vectors, Indicates target user Non-product demand standard feature vectors, Indicates target customers The non-product demand feature vector in the first The standard values of the element values of a dimension. Indicates target customers The non-product demand feature vector in the first The standard values of the element values of a dimension. Indicates the total number of dimensions. The value range is [-1, 1] or [0, 1]. The closer the value is to 1, the more similar the two target users are.
[0045] Based on the above calculation results, a similarity matrix is established. After calculating the similarity between each target customer and other target customers (i.e., the second similarity between the non-product demand standard feature vectors of target users), hierarchical clustering (AGNES) algorithm is used for clustering. The specific steps are as follows: Initialization: Hierarchical clustering (AGNES) algorithm is used, with a similarity matrix... As input.
[0046] Iterative merging: in the similarity matrix In the process, find the pair of clusters with the second highest similarity among all current clusters. and If the second largest similarity between clusters ,(in If a preset similarity threshold is used, then clustering will be performed. and They are merged into a new cluster.
[0047] Update the similarity matrix Then, recalculate the similarity between the new cluster and all other clusters.
[0048] Termination condition: Repeat the iterative merging step until the highest second similarity among all clusters is less than the similarity threshold. Or reach the preset number of clusters.
[0049] Output: The final clustering result. The clustering results include There are 5 clusters, and the non-product demand characteristics of the target users within each cluster are highly similar.
[0050] S3. For each cluster, the cluster is clustered according to the product demand feature vector of the target user to obtain multiple sub-clusters included in the cluster. This application embodiment performs secondary clustering on each cluster based on the product demand feature vector of the target user, resulting in multiple sub-clusters included in each cluster. This solution can employ the same clustering method described above, which will not be elaborated further here. For example, for clusters... Clustering was performed to obtain multiple sub-clusters. For clusters Clustering was performed to obtain multiple sub-clusters. The rest will not be elaborated upon.
[0051] S4. For each sub-cluster, based on the model domain characteristics, a decision model is matched for the sub-cluster from the decision model library. Using the matched decision model, the weight of the product demand attribute corresponding to each dimension of the product demand feature vector within the sub-cluster is obtained. The decision model library includes at least one decision model, which is trained based on the product demand feature vector samples and weight label values in the training sample set. It's worth noting that the decision model library includes at least one built-in decision model. This model is trained using product demand feature vector samples and weight labels within the training sample set. Different decision models correspond to different sub-cluster samples within the training sample set. For example, if the training sample set includes three sub-cluster samples: sub-cluster sample 1, sub-cluster sample 2, and sub-cluster sample 3, then the decision model is trained using all product demand feature vectors from sub-cluster sample 1 and the weight labels for each of those vectors. This model is suitable for users similar to those in sub-cluster sample 1. Sub-cluster samples 2 and 3 are used to train other decision models, with similar training processes, which will not be elaborated upon here. The acquisition of sub-cluster samples follows the same method as described above, for example, by filtering target users from sample users and then performing two-level clustering on the target users. This process will not be further elaborated upon here.
[0052] Specifically, the decision-making model is obtained through the following steps: Obtain the training sample set; wherein, the training sample set includes multiple sub-cluster samples, and each sub-cluster sample includes: multiple product demand feature vector samples and the weight label value corresponding to each product demand feature vector sample; For each sub-cluster sample, the multiple product demand feature vector samples of the sub-cluster sample are input into a preset neural network model to determine the weight prediction value of each product demand feature vector sample of the sub-cluster sample. The neural network model is updated using the weight label values and the weight prediction values to obtain a trained decision model.
[0053] The weighted label values in this application embodiment can preferentially adopt the historical conversion rate or explicit rating of sample users; if the above data is missing, the behavior intensity normalized value weighted by business rules is adopted. Here, the historical conversion rate refers to the number of purchases or transactions divided by the number of exposures for each user-product pair. Explicit ratings refer to user ratings (1-5 stars) or likes / dislikes for the product, which can be directly mapped to weighted label values (e.g., 5 stars = 1.0, 1 star = 0.2). The behavior intensity normalized value refers to the value that can be normalized linearly mapped to the range of 0-1 through behaviors such as duration, deep clicks, and number of times added to the shopping cart.
[0054] The embodiments of this application can match a suitable decision model to a sub-cluster based on the similarity between the sub-cluster and the model's domain features.
[0055] In one specific embodiment, the matching of the decision model is achieved through the following formula: ; In the formula, For decision models matched within the decision model library, For the model domain characteristics of the decision-making model, For sub-clusters The first similarity between the model and the domain features of the decision model.
[0056] Specifically, the similarity between sub-clusters and model domain features can be obtained using the first similarity between the feature vectors of the sub-clusters and the domain feature vectors obtained by vectorizing the model domain features. The specific matching steps are as follows: The domain features of each decision model in the decision model library are obtained and vectorized to obtain the domain feature vector of each decision model. Calculate the first similarity between the feature vector of the sub-cluster and the domain feature vector of each decision model in the decision model library. Based on the first similarity, match the decision model with the largest first similarity for the sub-cluster from the decision model library.
[0057] It is worth noting that the feature vector of a sub-cluster can be obtained by averaging all feature vectors in the cluster, or by using a single feature vector from the cluster as the feature vector of the sub-cluster.
[0058] Model domain features describe the business scenarios, product categories, or user characteristic distributions that a decision model can effectively handle. User attributes from sub-cluster samples used by the decision model can be selected as its domain features. Common attribute dimensions include: industry tags (finance, e-commerce, entertainment, etc.), product categories (insurance, wealth management, electronic products), user profile tags (high income - middle-aged - active), and spatiotemporal dimensions (seasonality, promotional periods). By vectorizing the model domain features of the decision model, we obtain the domain feature vector of the decision model.
[0059] In an optional embodiment, the step of using the matched decision model to obtain the weight of the product demand attribute corresponding to each dimension of the product demand feature vector within the sub-cluster includes: Using the matched decision model, the conditional probability of each product demand feature vector in the sub-cluster is calculated. Based on the comprehensive calculation of each conditional probability, the weight of the product demand attribute corresponding to each dimension of the product demand feature vector in the sub-cluster is obtained.
[0060] It is understandable that for each sub-cluster, the product demand feature vectors of all target users within that sub-cluster are input into the matched decision model, and the weight of each dimension of the product demand feature vector within that sub-cluster is output. This weight can be understood as the weight of each user within that sub-cluster on the product demand attributes involved in that sub-cluster.
[0061] In one specific embodiment, the decision model calculates the first... The weights of product demand attributes corresponding to each dimension : ; In the formula, Indicates product demand attributes In sub-clusters The conditional probability in the product demand attributes can be calculated using Bayesian algorithms. It refers to the first sub-cluster within the sub-cluster The first in the product demand feature vector of the target user Product demand attributes corresponding to the dimensions; Sub-clusters The target number of users is used for Laplace smoothing.
[0062] S6. Recommend products to the target user based on the weights.
[0063] This application first clusters the target users' non-product demand feature vectors to form multiple clusters. Then, it performs secondary clustering on these clusters based on the target users' product demand feature vectors, enabling micro-level segmentation of demand within each cluster. This effectively solves the problems of coarse recommendation granularity and inaccurate user-product matching caused by single clustering mechanisms, significantly improving the accuracy and personalization of recommendation results. For example, among users belonging to the "high-income middle-aged group," some prefer high-risk investment products, while others prefer stable asset preservation products. Single clustering can only complete the macro-level user group segmentation, making it difficult to uncover the personalized demand differences within the same group. This application, through secondary clustering, can accurately segment the subgroups within the same cluster, clearly distinguishing users with different product demand types such as high-risk investment preferences and stable asset preservation. This application achieves a leap from "recommending a type of product to a type of person" to "recommending specific products that a group of people with common characteristics are most likely to be interested in," greatly improving the accuracy and personalization of recommendations and directly solving the problems of "product mismatch and low conversion rate."
[0064] Furthermore, for each sub-cluster obtained from the second-layer clustering, a dedicated decision model is matched and invoked for weight calculation. This not only improves the throughput of big data processing, but also avoids the problem of the lack of domain specificity in recommendation results due to the performance limitations of general models in specific scenarios. This greatly improves the scientific nature of the recommendation effect and has strong applicability to various scenarios.
[0065] In one optional embodiment, recommending products to the target user based on the weights includes: Based on the weights, a recommendation analysis report is obtained for different target users under different product demand attributes; Based on the recommendation analysis report, a strategy approximation algorithm is used to obtain product recommendation strategies for different target users. Based on the product recommendation strategy, product recommendations are made to the target user.
[0066] Based on the aforementioned weights, this application performs recommendation analysis to obtain the products most needed by the target users, and then outputs a recommendation analysis report for the target users under different product demand attributes. Next, a strategy approximation algorithm is used to obtain product recommendation strategies for different target users, and finally, product recommendations are made to the target users according to the product recommendation strategies.
[0067] In one specific embodiment, the steps of using the policy approximation algorithm are as follows: Data preparation: The weight W of each user in its sub-cluster is used as the state S, and the action space A is constructed as the set of candidate products.
[0068] Reward function definition: The primary reward is the actual probability of a user clicking / purchasing, and the secondary reward is the business objective (e.g., profit margin) or a weighted average of multiple objectives.
[0069] Policy network construction: The input layer is a weight vector W, the hidden layer is "several fully connected layers + ReLU (Rectified Linear Unit) / Layer Normalization", and the output layer is the probability distribution of each product in A.
[0070] Training process: First, initialize the policy network, and then perform sampling.
[0071] Inference (obtaining recommendation strategy): For each target user, its weight W is fed into the trained policy network, the action probability distribution is output, and the top T products with the highest probability are selected as the recommendation list.
[0072] Online updates: A hybrid "offline-online" approach is adopted, with the model retrained offline once a day and fine-tuned online based on the latest click / purchase feedback.
[0073] See Figure 3 , Figure 3 This is a structural block diagram of a product recommendation device 10 provided in an embodiment of this application. The product recommendation device 10 includes: The acquisition module 11 is used to acquire the feature vector of each of the multiple target users; wherein, the feature vector of the target user includes a non-product demand feature vector and a product demand feature vector; The first clustering module 12 is used to cluster according to the non-product demand feature vector of each target user to obtain multiple clusters; The second clustering module 13 is used to cluster each cluster according to the product demand feature vector of the target user to obtain multiple sub-clusters included in the cluster. The matching module 14 is used to match a decision model from the decision model library for each sub-cluster based on the model domain characteristics, and use the matched decision model to obtain the weight of the product demand attribute corresponding to each dimension of the product demand feature vector within the sub-cluster; wherein, the decision model library includes at least one decision model, and the decision model is trained based on the product demand feature vector samples and weight label values in the training sample set. Recommendation module 15 is used to recommend products to the target user based on the weights.
[0074] Optionally, the device further includes: The filtering module is used to obtain the feature vector of each user among multiple users; to standardize each element value in the feature vector of each user to obtain the standard value of each element value; to perform a comprehensive calculation based on the standard value of each element value to obtain the comprehensive value of each user; and to filter multiple target users from the multiple users based on the comprehensive value of each user.
[0075] Optionally, the standardization process for each element value within the feature vector of each user to obtain a standard value for each element value includes: For each element value in the feature vector of each user, calculate the mean and standard deviation of the dimension to which the element value belongs, and standardize the element value according to the mean and standard deviation to obtain the standard value of the element value.
[0076] Optionally, matching a decision model for the sub-cluster from the decision model library based on model domain characteristics includes: The domain features of each decision model in the decision model library are obtained and vectorized to obtain the domain feature vector of each decision model. Calculate the first similarity between the feature vector of the sub-cluster and the domain feature vector of each decision model in the decision model library. Based on the first similarity, match the decision model with the largest first similarity for the sub-cluster from the decision model library.
[0077] Optionally, one of the decision models in the decision model library is obtained through the following steps: Obtain the training sample set; wherein, the training sample set includes multiple sub-cluster samples, and each sub-cluster sample includes: multiple product demand feature vector samples and the weight label value corresponding to each product demand feature vector sample; For each sub-cluster sample, the multiple product demand feature vector samples of the sub-cluster sample are input into a preset neural network model to determine the weight prediction value of each product demand feature vector sample of the sub-cluster sample. The neural network model is updated using the weight label values and the weight prediction values to obtain a trained decision model.
[0078] Optionally, the step of using the matched decision model to obtain the weight of the product demand attribute corresponding to each dimension of the product demand feature vector within the sub-cluster includes: Using the matched decision model, the conditional probability of each product demand feature vector in the sub-cluster is calculated. Based on the comprehensive calculation of each conditional probability, the weight of the product demand attribute corresponding to each dimension of the product demand feature vector in the sub-cluster is obtained.
[0079] Optionally, the step of recommending products to the target user based on the weight includes: Based on the weights, a recommendation analysis report is obtained for different target users under different product demand attributes; Based on the recommendation analysis report, a strategy approximation algorithm is used to obtain product recommendation strategies for different target users. Based on the product recommendation strategy, product recommendations are made to the target user.
[0080] Optionally, the step of clustering based on the non-product demand feature vector of each target user to obtain multiple clusters includes: The non-product demand feature vector of each target user is standardized to obtain the non-product demand standard feature vector of each target user. Calculate the second similarity between the non-product demand standard feature vectors of each pair of target users; Clustering is performed based on the second similarity.
[0081] Optionally, the standardization process for the non-product demand feature vector of each target user to obtain the non-product demand standard feature vector of each target user includes: For each target user's non-product demand feature vector, each element value in the non-product demand feature vector is standardized according to the mean and standard deviation of each element value in its own dimension to obtain a non-product demand standard feature vector.
[0082] It is worth noting that the working process of each module in the product recommendation device 10 described in this application embodiment can refer to the working process of the product recommendation method described in the above embodiment, and achieve the same beneficial effect, which will not be repeated here.
[0083] Furthermore, this application also provides a computer-readable storage medium, which includes a stored computer program; wherein, when the computer program is executed, it controls the device where the computer-readable storage medium is located to perform the product recommendation method as described in any of the above embodiments.
[0084] Furthermore, this application also provides a computer program product, including a computer program / instructions, which, when executed by a processor, implements the product recommendation method as described in any of the above embodiments.
[0085] See Figure 4 , Figure 4 This is a structural block diagram of a product recommendation device 20 provided in an embodiment of this application. The product recommendation device 20 includes: a processor 21, a memory 22, and a computer program stored in the memory 22 and executable on the processor 21. When the processor 21 executes the computer program, it implements the steps in the above-described product recommendation method embodiments. Alternatively, when the processor 21 executes the computer program, it implements the functions of each module / unit in the above-described device embodiments.
[0086] For example, the computer program may be divided into one or more modules / units, which are stored in the memory 22 and executed by the processor 21 to complete this application. The one or more modules / units may be a series of computer program instruction segments capable of performing a specific function, which describe the execution process of the computer program in the product recommendation device 20.
[0087] The product recommendation device 20 may include, but is not limited to, a processor 21 and a memory 22. Those skilled in the art will understand that the schematic diagram is merely an example of the product recommendation device 20 and does not constitute a limitation on the product recommendation device 20. It may include more or fewer components than illustrated, or combine certain components, or different components. For example, the product recommendation device 20 may also include input / output devices, network access devices, buses, etc.
[0088] The processor 21 can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor. The processor 21 is the control center of the product recommendation device 20, connecting all parts of the product recommendation device 20 via various interfaces and lines.
[0089] The processor 21 can be any one of a CPU (Central Processing Unit), GPU (Graphics Processing Unit), TPU (Tensor Processing Unit), NPU (Neural Network Processing Unit), DPU (Deep Learning Processing Unit), APU (Accelerated Processing Unit), and GPGPU (General-Purpose Computing on Graphics Processing Unit). The processor 21 is the control center of the product recommendation device 20, connecting various parts of the electronic device via various interfaces and lines.
[0090] The memory 22 can be used to store the computer programs and / or modules. The processor 21 implements various functions of the product recommendation device 20 by running or executing the computer programs and / or modules stored in the memory 22 and calling the data stored in the memory 22. The memory 22 may mainly include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function, etc.; the data storage area may store relevant data, etc. In addition, the memory 22 may include high-speed random access memory, and may also include non-volatile memory, such as hard disk, memory, plug-in hard disk, smart media card (SMC), secure digital card (SD card), flash card, at least one disk storage device, flash memory device, or other volatile solid-state storage device.
[0091] Wherein, if the modules / units integrated in the product recommendation device 20 are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments can also be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by the processor 21, it can implement the steps of the various method embodiments described above. Wherein, the computer program includes computer program code, which can be in the form of source code, object code, executable file, or some intermediate form, etc. The computer-readable medium can include: any entity or device capable of carrying the computer program code, recording media, USB flash drive, portable hard drive, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal, and software distribution medium, etc.
[0092] It should be noted that the device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Furthermore, in the accompanying drawings of the device embodiments provided in this application, the connection relationships between modules indicate that they have communication connections, which can be specifically implemented as one or more communication buses or signal lines. Those skilled in the art can understand and implement this without any creative effort.
[0093] The above description is the preferred embodiment of this application. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of this application, and these improvements and modifications are also considered to be within the scope of protection of this application.
Claims
1. A product recommendation method, characterized in that, include: Obtain the feature vector of each of the multiple target users; wherein, the feature vector of the target user includes a non-product demand feature vector and a product demand feature vector; Clustering is performed on the non-product demand feature vector of each target user to obtain multiple clusters; For each cluster, the cluster is further clustered according to the product demand feature vector of the target user to obtain multiple sub-clusters included in the cluster. For each sub-cluster, based on the model domain characteristics, a decision model is matched for the sub-cluster from the decision model library. Using the matched decision model, the weights of the product demand attributes corresponding to each dimension of the product demand feature vector within the sub-cluster are obtained. The decision model library includes at least one decision model, which is trained based on the product demand feature vector samples and weight label values in the training sample set. Product recommendations are made to the target user based on the weights.
2. The product recommendation method as described in claim 1, characterized in that, Before obtaining the feature vector of each of the multiple target users, the method further includes: Obtain the feature vector for each user among multiple users; Standardize each element value in the feature vector of each user to obtain the standard value of each element value; A comprehensive value for each user is obtained by comprehensively calculating the standard value of each element. Based on each user's overall score, select multiple target users from the multiple users.
3. The product recommendation method as described in claim 2, characterized in that, The standardization process for each element value within the feature vector of each user, to obtain a standard value for each element value, includes: For each element value in the feature vector of each user, calculate the mean and standard deviation of the dimension to which the element value belongs, and standardize the element value according to the mean and standard deviation to obtain the standard value of the element value.
4. The product recommendation method as described in claim 1, characterized in that, The step of matching a decision model to the sub-cluster from the decision model library based on the model domain characteristics includes: The domain features of each decision model in the decision model library are obtained and vectorized to obtain the domain feature vector of each decision model. Calculate the first similarity between the feature vector of the sub-cluster and the domain feature vector of each decision model in the decision model library. Based on the first similarity, match the decision model with the largest first similarity for the sub-cluster from the decision model library.
5. The product recommendation method as described in claim 1, characterized in that, One of the decision models in the decision model library was obtained through the following steps: Obtain the training sample set; wherein the training sample set includes multiple sub-cluster samples, and each sub-cluster sample includes: multiple product demand feature vector samples and the weight label value corresponding to each product demand feature vector sample; For each sub-cluster sample, the multiple product demand feature vector samples of the sub-cluster sample are input into a preset neural network model to determine the weight prediction value of each product demand feature vector sample of the sub-cluster sample. The neural network model is updated using the weight label values and the weight prediction values to obtain a trained decision model.
6. The product recommendation method as described in claim 1, characterized in that, The step of using the matched decision model to obtain the weights of product demand attributes corresponding to each dimension of the product demand feature vector within the sub-cluster includes: Using the matched decision model, the conditional probability of each product demand feature vector in the sub-cluster is calculated. Based on the comprehensive calculation of each conditional probability, the weight of the product demand attribute corresponding to each dimension of the product demand feature vector in the sub-cluster is obtained.
7. The product recommendation method as described in claim 1, characterized in that, The process of recommending products to the target user based on the weights includes: Based on the weights, a recommendation analysis report is obtained for different target users under different product demand attributes; Based on the recommendation analysis report, a strategy approximation algorithm is used to obtain product recommendation strategies for different target users. Based on the product recommendation strategy, product recommendations are made to the target user.
8. The product recommendation method as described in claim 1, characterized in that, The clustering based on the non-product demand feature vector of each target user yields multiple clusters, including: The non-product demand feature vector of each target user is standardized to obtain the non-product demand standard feature vector of each target user. Calculate the second similarity between the non-product demand standard feature vectors of each pair of target users; Clustering is performed based on the second similarity.
9. The product recommendation method as described in claim 8, characterized in that, The standardization process for the non-product demand feature vector of each target user to obtain the non-product demand standard feature vector of each target user includes: For each target user's non-product demand feature vector, each element value in the non-product demand feature vector is standardized according to the mean and standard deviation of each element value in its own dimension to obtain a non-product demand standard feature vector.
10. A product recommendation device, characterized in that, include: The acquisition module is used to acquire the feature vector of each of the multiple target users; wherein, the feature vector of the target user includes a non-product demand feature vector and a product demand feature vector; The first clustering module is used to cluster based on the non-product demand feature vector of each target user to obtain multiple clusters; The second clustering module is used to cluster each cluster according to the product demand feature vector of the target user, so as to obtain multiple sub-clusters included in the cluster. The matching module is used to match a decision model from the decision model library for each sub-cluster based on the model domain characteristics, and use the matched decision model to obtain the weight of the product demand attribute corresponding to each dimension of the product demand feature vector within the sub-cluster; wherein, the decision model library includes at least one decision model, and the decision model is trained based on the product demand feature vector samples and weight label values in the training sample set. The recommendation module is used to recommend products to the target user based on the weights.
11. A product recommendation device, characterized in that, It includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein the processor, when executing the computer program, implements the product recommendation method as described in any one of claims 1 to 9.
12. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a stored computer program; wherein, when the computer program is executed, it controls the device on which the computer-readable storage medium is located to perform the product recommendation method as described in any one of claims 1 to 9.
13. A computer program product, characterized in that, Includes a computer program / instruction that, when executed by a processor, implements the product recommendation method as described in any one of claims 1 to 9.