Product Recommendation Method, Device, Electronic Device and Storage Medium
By using a product recommendation method that integrates two-layer collaborative filtering model and semi-supervised algorithm in government and enterprise product marketing, the problems of strong subjectivity, long marketing cycle and low recommendation credibility in traditional marketing are solved, and more efficient product processing conversion rate and targeted marketing strategy are achieved.
Patent Information
- Application Number
- CN202110224255.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-02-25
- Publication Date
- 2025-05-30
- Estimated Expiration
- 2041-02-25
AI Technical Summary
In the marketing of government and enterprise products, the existing technology has defects such as strong subjectivity of account managers’ door-to-door service, long marketing cycle, low credibility in product recommendations, and cold start problems, which is difficult to meet the data-driven and user-oriented needs.
A product recommendation method based on the fusion of two-layer collaborative filtering model and semi-supervised algorithm is adopted. By building a collaborative filtering model and a semi-supervised model of product segmentation, interest correction functions and popular product punishment factors are introduced to make up for the cold start problem and improve recommendation accuracy.
It improves product processing conversion rate, enhances the pertinence of marketing strategies, solves the problem of insufficient subjectivity and flexibility of traditional marketing forms, and improves the accuracy and credibility of product recommendations.
Smart Images

Figure CN114969501B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of big data analysis, and particularly to a product recommendation method, apparatus, electronic device, and storage medium. Background Art
[0002] In response to the rapidly developing business requirements, the traditional, case-by-case product marketing model can no longer meet the ever-changing market demands. Especially for the government and enterprise services of the mobile group, it is necessary to realize data-driven and user-oriented, utilize big data capabilities, accurately identify potential customers, explore potential business needs, segment the market and customer groups, and improve the efficiency and success rate of business expansion as an urgent business development need.
[0003] At present, the marketing of government and enterprise products mainly adopts the forms of offline investigation, publicity, and on-site promotion by account managers to expand business. There are also a small number of business scenarios based on machine learning models. The machine learning models are mainly implemented in the following ways: One way is to analyze the product order data of users and build a collaborative filtering model to explore products that users may be interested in; another way is to explore the user characteristics of each ordered product and build a binary classification model to explore potential customers for each product.
[0004] Whether based on the traditional marketing method or the existing machine learning model, there are many deficiencies:
[0005] The marketing form of on-site service by account managers requires account managers to accurately understand the marketing products, accurately analyze customer attributes, which has high requirements for the business of account managers, and is subjective and lacks flexibility, easily resulting in a long marketing cycle and a low conversion rate of product handling;
[0006] Based on the product order situation of users, directly building a collaborative filtering recommendation model has a cold start problem. It can only model and recommend users who have already placed orders. The proportion of enterprise users with product orders is relatively small. Most users have not ordered any government and enterprise products, and the divided product categories are few, and there is an uneven distribution problem in the order volume of each product. Directly building a collaborative filtering model for the existing major product categories also has a low recommendation credibility.
[0007] Or, building a binary classification model based on the characteristics of users who order each product to explore potential customers for each product also requires clear positive and negative samples, and generally there are only positive samples of ordered products, lacking clear negative sample data.
[0008] Therefore, it is necessary to propose a new product recommendation method for government and enterprise services to overcome the above defects. Summary of the Invention
[0009] The present invention provides a product recommendation method, apparatus, electronic device, and storage medium to solve the defects existing in product recommendation in the prior art.
[0010] In a first aspect, the present invention provides a product recommendation method, including:
[0011] Obtain a set of products to be recommended;
[0012] Input the set of products to be recommended into a pre-trained product recommendation model to obtain a product recommendation result; wherein the product recommendation model is obtained by fusing a two-layer collaborative filtering model and a semi-supervised algorithm.
[0013] In one embodiment, the product recommendation model is obtained through the following steps:
[0014] Construct a collaborative filtering model and a per-product semi-supervised model based on the products to be recommended, and use the per-product semi-supervised model to make up for the preset defects caused by the cold start of the collaborative filtering model;
[0015] Construct a first-layer collaborative filtering model based on the subcategories of the products to be recommended, and construct a second-layer collaborative filtering model according to different application scenarios and multiple product combination methods. Use the second-layer collaborative filtering model to classify and summarize the first-layer collaborative filtering model to obtain a product category recommendation index value;
[0016] Introduce an interest correction function and a popular product penalty factor into the collaborative filtering model to obtain a collaborative filtering model with improved preset accuracy;
[0017] Construct a semi-supervised model based on the bootstrap strategy to make up for the negative samples in the training data of the collaborative filtering model.
[0018] In one embodiment, the step of constructing a collaborative filtering model and a per-product semi-supervised model based on the products to be recommended, and using the per-product semi-supervised model to make up for the preset defects caused by the cold start of the collaborative filtering model specifically includes:
[0019] Obtain the user subscription data and user basic attribute features of the set of products to be recommended;
[0020] Construct the collaborative filtering model based on the user subscription data;
[0021] Construct the per-product semi-supervised model based on the user subscription data and the user basic attribute features.
[0022] In one embodiment, the step of constructing the per-product semi-supervised model based on the user subscription data and the user basic attribute features specifically includes:
[0023] Filter out a user data set that has ordered more than one product from all user ordering data, build an item-based collaborative filtering model based on the user data set, obtain a TOP1 recommendation list for each user, and convert the TOP1 recommendation list to obtain a potential customer list for each product;
[0024] For all basic user data, the user ordering data is used as labels and the user basic attribute features are used as features, and several product-specific semi-supervised models are constructed according to products to obtain potential customer lists for several products;
[0025] The sublist of the potential customer list of each product is respectively unioned with the sublists in the potential customer lists of several products and then merged to obtain the product-based semi-supervised model.
[0026] In one embodiment, the first-layer collaborative filtering model is constructed based on the subcategories of the products to be recommended, specifically including:
[0027] Extract the top N products in the sub-category product recommendation index according to the product category, classify and summarize the top N sub-category product recommendation indexes according to the product category and calculate the average value, and use the product category with the largest average value as the final recommended product, where the product category with the largest average value has not yet generated any order behavior, otherwise it will be postponed to the next product category;
[0028] Alternatively, extract the top 1 in the sub-category product recommendation index according to the product category, where the product category corresponding to the top 1 has not generated any order behavior, otherwise it will be postponed to the next product category;
[0029] Alternatively, the TOP1 in the sub-category product recommendation index based on a first preset threshold value is extracted according to the product category, wherein the product category corresponding to the TOP1 has not generated any ordering behavior, otherwise it is postponed to the next product category.
[0030] In one embodiment, the introduction of the interest correction function and the hot product penalty factor into the collaborative filtering model to obtain a collaborative filtering model with improved preset accuracy specifically includes:
[0031] Determine the business volume of any product ordered by users, obtain a maximum business volume and a minimum business volume, and obtain an interest correction function of any product based on the maximum business volume, the minimum business volume and the business volume;
[0032] Obtaining an original user and product interest matrix, and correcting the original user and product interest matrix based on the interest correction function of any product to obtain a corrected user and product interest matrix;
[0033] Determine the number of users who like any one item and the number of users who like any other item, and obtain an item similarity calculation formula based on the number of users who like any one item and the number of users who like any other item;
[0034] Introduce a penalty factor based on the total number of users into the item similarity calculation formula to obtain a modified item similarity calculation formula;
[0035] Based on the modified user-product interest matrix and the modified item similarity calculation formula, modify the collaborative filtering model to obtain the collaborative filtering model with the preset accuracy improved.
[0036] In one embodiment, the semi-supervised model constructed based on the bootstrap strategy makes up for the negative samples in the training data of the collaborative filtering model, specifically including:
[0037] Obtain the full sample data and the positive sample data of any ordered product, and subtract the positive sample data from the full sample data to obtain the unlabeled sample data, where the full sample data is much larger than the positive sample data;
[0038] Randomly select random sampling data with the same quantity as the positive sample data from the unlabeled sample data, combine the positive sample data and the random sampling data to form a training data set, and record the part of the unlabeled sample data excluding the random sampling data as the remaining sample data;
[0039] Construct a classifier based on the training data set, use the positive sample data as the positive sample of the classifier, and the random sampling data as the negative sample of the classifier;
[0040] Predict the remaining sample data based on the classifier and record the prediction scores;
[0041] Repeat constructing the training data set, classifier and recording the prediction scores. After multiple iterations, obtain multiple prediction score values corresponding to multiple samples in the unlabeled sample data;
[0042] Take the average of the multiple prediction score values as the final prediction value of each unlabeled sample, and use the unlabeled samples with the final prediction value higher than the second preset threshold as the final prediction result of the unlabeled samples.
[0043] In a second aspect, the present invention also provides a product recommendation device, including:
[0044] An acquisition module, configured to acquire a set of products to be recommended;
[0045] A recommendation module for inputting the set of products to be recommended into a pre-trained product recommendation model to obtain a product recommendation result, where the product recommendation model is obtained by fusing a two-layer collaborative filtering model and a semi-supervised algorithm.
[0046] In a third aspect, the present invention further provides an electronic device, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, the steps of any one of the above-mentioned product recommendation methods are implemented.
[0047] In a fourth aspect, the present invention further provides a non-transitory computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the steps of any one of the above-mentioned product recommendation methods are implemented.
[0048] The product recommendation method, device, electronic device, and storage medium provided by the present invention are more targeted at the implementation strategy of product marketing through a product recommendation method based on the fusion of two-layer collaborative filtering and semi-supervised algorithms, and effectively improve the conversion rate of product handling. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following will briefly introduce the drawings required for use in the description of the embodiments or the prior art. Obviously, the drawings in the following description are some embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0050] Figure 1 is a flowchart of the product recommendation method provided by the present invention;
[0051] Figure 2 is a flowchart of constructing a combined model of collaborative filtering and semi-supervised provided by the present invention;
[0052] Figure 3 is a flowchart of constructing the semi-supervised algorithm provided by the present invention;
[0053] Figure 4 is a schematic structural diagram of the product recommendation device provided by the present invention;
[0054] Figure 5 is a schematic structural diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0055] To make the objectives, technical solutions and advantages of the present invention more clear, the following will clearly and completely describe the technical solutions in the present invention with reference to the accompanying drawings in the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all of the embodiments. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in the present invention without making creative efforts fall within the protection scope of the present invention.
[0056] Figure 1 is a schematic flowchart of the product recommendation method provided by the present invention. As Figure 1 shown, it includes:
[0057] 101, obtain a set of products to be recommended;
[0058] 102, input the set of products to be recommended into a pre-trained product recommendation model to obtain a product recommendation result; wherein the product recommendation model is obtained by fusing a two-layer collaborative filtering model and a semi-supervised algorithm.
[0059] Specifically, the business scenario targeted by the present invention is the recommendation of mobile government and enterprise products. In order to be able to implement marketing for government and enterprise products in a targeted manner and improve the conversion rate of product handling, the present invention constructs a product recommendation model by fusing a two-layer collaborative filtering and a semi-supervised algorithm, and through the optimization of the two layers of the collaborative filtering model, the correction of user interest degree scores, and the introduction of a popular product penalty factor, input the set of products to be recommended into this product recommendation model to obtain a more accurate and objective product recommendation result.
[0060] The product recommendation method based on the fusion of a two-layer collaborative filtering and a semi-supervised algorithm in the present invention is more targeted at the implementation strategy of product marketing and effectively improves the conversion rate of product handling.
[0061] Based on any of the above embodiments, the product recommendation model is obtained through the following steps:
[0062] Construct a collaborative filtering model and a product-specific semi-supervised model based on the products to be recommended, and use the product-specific semi-supervised model to make up for the preset defects caused by the cold start of the collaborative filtering model;
[0063] Construct a first-layer collaborative filtering model based on the subclasses of the products to be recommended, and construct a second-layer collaborative filtering model according to different application scenarios and multiple product combination methods. Use the second-layer collaborative filtering model to classify and summarize the first-layer collaborative filtering model to obtain a product category recommendation index value;
[0064] Introduce an interest degree correction function and a popular product penalty factor into the collaborative filtering model to obtain a collaborative filtering model with improved preset accuracy;
[0065] Build a semi-supervised model based on the bootstrap strategy to make up for the negative samples in the training data of the collaborative filtering model.
[0066] Specifically, the product recommendation model constructed by the present invention is constructed through the following steps:
[0067] First, build a combined model of collaborative filtering and semi-supervised algorithms to make up for the defects of cold start in collaborative filtering with the results of the semi-supervised model; further build a two-layer collaborative filtering recommendation model to solve the problem of low recommendation credibility caused by few product categories and uneven distribution; then improve the accuracy of the collaborative filtering algorithm by correcting the user interest score and introducing a popular product penalty factor; finally, build a semi-supervised algorithm to solve the problem of missing negative samples in the data, and obtain the final product recommendation model for product prediction.
[0068] Through the constructed product recommendation model, the present invention can classify and recommend products more accurately, providing an objective basis for business promotion.
[0069] Based on any of the above embodiments, the collaborative filtering model and the product-specific semi-supervised model are constructed based on the product to be recommended, and the preset defects generated by the cold start of the collaborative filtering model are made up for by the product-specific semi-supervised model, specifically including:
[0070] Obtain the user order data and user basic attribute features of the product set to be recommended;
[0071] Build the collaborative filtering model based on the user order data;
[0072] Build the product-specific semi-supervised model based on the user order data and the user basic attribute features.
[0073] Among them, the building of the product-specific semi-supervised model based on the user order data and the user basic attribute features specifically includes:
[0074] Screen out the user data set that has ordered more than one product from the full-scale user order data, build an item-based collaborative filtering model based on the user data set, obtain the TOP1 recommendation list for each user, and convert the TOP1 recommendation to obtain the potential customer list for each product;
[0075] For the full-scale user basic data, use the user order data as the label and the user basic attribute features as the features respectively, and build several product-specific semi-supervised models according to the products to obtain the potential customer lists for several products;
[0076] Take the union of the sub-lists of the potential customer list for each product and the sub-lists in the potential customer lists for several products respectively, and then merge them to obtain the product-specific semi-supervised model.
[0077] Specifically, a combined model of collaborative filtering and semi-supervised algorithm is constructed to make up for the defects of cold start in collaborative filtering with the results of the semi-supervised model.
[0078] It can be understood that the collaborative filtering algorithm is one of the most widely used algorithms in current recommendation algorithms. By mining the historical behavior data of users, the preferences of users are discovered. Based on different preferences, users are grouped and products with similar preferences are recommended. Collaborative filtering recommendations are mainly divided into user-based collaborative filtering and item-based collaborative filtering. User-based collaborative filtering mainly considers the similarity between users. As long as the items liked by similar users are found and the ratings of the target user for the corresponding items are predicted, several items with the highest ratings can be found and recommended to the user. While item-based collaborative filtering turns to find the similarity between items. As long as the ratings of the target user for some items are found, then the similar items with high similarity can be predicted, and several similar items with the highest ratings can be recommended to the user. Considering the algorithm operation efficiency, usually, the two methods can be selected according to the order of magnitude of the number of users and the number of products. When the number of users is much larger than the number of products, item-based collaborative filtering is applicable; while when the number of products is much larger than the number of users, it is suitable to construct user-based collaborative filtering. In the product recommendation involved in the present invention, the number of users is much larger than the number of product categories, so it is most appropriate to construct item-based collaborative filtering. However, both user-based collaborative filtering and item-based collaborative filtering have the problem of cold start, that is, they can only recommend to users who have had an ordering behavior, and in the present invention, the number of users who have not ordered any products is large. It is not appropriate to rely solely on collaborative filtering for recommendation. For users who have not ordered any products, the present invention mines potential customers by constructing semi-supervised models for each product. The specific method is as follows, and the specific flowchart is as Figure 2 shown:
[0079] 1) Screen out users who have ordered more than one product. According to the ordering data of this part of users, construct an item-based collaborative filtering model to obtain the TOP1 recommendation list for each user. By converting this list, the potential customer lists A1, A2,..., An for each product can be obtained;
[0080] 2) For all users, using the ordering data of each product as labels and the basic attribute data of group users as features, construct N semi-supervised models according to products to obtain the potential customer lists B1, B2,..., Bn for N products;
[0081] 3) Finally, the potential customer lists for each product are (A1 ∪ B1), (A2 ∪ B2),..., (An ∪ Bn).
[0082] Here, since the construction of collaborative filtering and semi-supervised models has different requirements for data sources, the collaborative filtering model needs to be built based on the user's product ordering data. In addition to the user's ordering data, the semi-supervised model also requires the user's basic attribute characteristics. Therefore, different feature data need to be extracted for the two models. Table 1 shows the collaborative filtering model input features, and Table 2 shows the semi-supervised model input features.
[0083] Table 1
[0084]
[0085] Table 2
[0086]
[0087]
[0088]
[0089] The present invention solves the problem of cold start of collaborative filtering model by constructing a fusion model of collaborative filtering and semi-supervision.
[0090] Based on any of the above embodiments, the step of constructing a first-layer collaborative filtering model based on subcategories of products to be recommended specifically includes:
[0091] Extract the top N products in the sub-category product recommendation index according to the product category, classify and summarize the top N sub-category product recommendation indexes according to the product category and calculate the average value, and use the product category with the largest average value as the final recommended product, where the product category with the largest average value has not yet generated any order behavior, otherwise it will be postponed to the next product category;
[0092] Alternatively, extract the top 1 in the sub-category product recommendation index according to the product category, where the product category corresponding to the top 1 has not generated any order behavior, otherwise it will be postponed to the next product category;
[0093] Alternatively, the TOP1 in the sub-category product recommendation index based on a first preset threshold value is extracted according to the product category, wherein the product category corresponding to the TOP1 has not generated any ordering behavior, otherwise it is postponed to the next product category.
[0094] Specifically, on the basis of the aforementioned embodiments, a two-layer collaborative filtering recommendation model is constructed to solve the problem of low credibility of recommendations due to the small number of major product categories and uneven distribution. Although the goal is to recommend major product categories to users, due to the small number of major product categories and the uneven distribution of order quantities of each product, it is impossible to mine product pairs with high correlation, and the credibility of the final recommendation results is also low. When users order a certain category of products, in most cases they order one or several sub-category products under this major category. Therefore, it is possible to preferentially construct a collaborative filtering model based on sub-category products, and implement different classification summaries on the recommendation index of each sub-category product according to the application scenario to obtain the final recommendation index values of the major product categories. Specifically, the following methods can be used to classify and summarize the results of the first layer of collaborative filtering:
[0095] The first method: adopt TOPN classification summary recommendation. First, select TOPN according to the sub-category product recommendation index according to the product category, and then classify and summarize the recommendation index of each sub-category product according to the product category to calculate the average. The product category with the largest average is the final recommended product, and the user of this product category has not yet placed an order, otherwise it will be postponed.
[0096] The second method: using TOP1 recommendation. According to the recommendation index ranking of sub-category products, the product category corresponding to the top 1 product sub-category is extracted as the final recommended product, and the user has not yet placed an order for this product category, otherwise it will be postponed.
[0097] The third method: Use the threshold-based TOP1 recommendation. According to the recommendation index distribution of all sub-category products, a certain threshold is set, and only the recommendation results above the threshold are retained. For the remaining recommendation results, the product category corresponding to the top 1 product sub-category is extracted as the final recommended product, and the user has not yet placed an order for this product category, otherwise it will be postponed.
[0098] The two-layer collaborative filtering model adopted in the present invention effectively solves the problem of low recommendation accuracy caused by few major product categories and uneven ordering.
[0099] Based on any of the above embodiments, the step of introducing an interest correction function and a hot product penalty factor into the collaborative filtering model to obtain a collaborative filtering model with improved preset accuracy specifically includes:
[0100] Determine the business volume of any product ordered by users, obtain a maximum business volume and a minimum business volume, and obtain an interest correction function of any product based on the maximum business volume, the minimum business volume and the business volume;
[0101] Obtain the original user-product interest matrix, and correct the original user-product interest matrix based on the interest correction function of any one of the products to obtain the corrected user-product interest matrix;
[0102] Determine the number of users who like any one item and the number of users who like any other item, and obtain an item similarity calculation formula based on the number of users who like any one item and the number of users who like any other item;
[0103] Introduce a penalty factor based on the total number of users into the item similarity calculation formula to obtain the corrected item similarity calculation formula;
[0104] Based on the corrected user-product interest matrix and the corrected item similarity calculation formula, correct the collaborative filtering model to obtain the collaborative filtering model with the preset accuracy improved.
[0105] Specifically, in order to obtain a more accurate product recommendation model, the present invention improves the accuracy of the collaborative filtering algorithm by correcting the user interest score and introducing a penalty factor for popular products.
[0106] The traditional collaborative filtering model needs to construct a user-item rating matrix, that is, it is necessary to obtain the interest degree value of the user for each item. However, in the actual application scenario, group users will not rate each product. Therefore, the business volume of each product ordered by the user is used as an indicator to measure its interest degree. Due to the different characteristics of each product, the order of magnitude of the business volume of each product is also different. For example, the order volume of group enterprise-government broadband products is relatively high, while the order volume of products such as cloud hosts is generally low. If no processing is done on the business volume value and it is directly used as an interest degree measurement index, there will be certain problems, resulting in generally high interest degrees for products with high business volumes caused by business characteristics. To solve this problem, the present invention corrects the interest degree of each product in a vertical normalization manner, and the specific correction formula is defined as follows:
[0107]
[0108] where x i represents the business volume of the user ordering product i, max(x i ) represents the maximum value of the business volume of the user ordering product i, and min(x i ) represents the minimum value of the business volume of the user ordering product i.
[0109] Here, assume that the original user-product interest matrix is as shown in Table 3:
[0110] Table 3
[0111] Product 1 Product 2 Product 3 User 1 0 100 0 User 2 2 200 70 User 3 3 0 52 User 4 2 700 30
[0112] The user-product interest matrix after correcting the interest degree according to formula (1) is shown in Table 4:
[0113] Table 4
[0114] Product 1 Product 2 Product 3 User 1 0 0.142857 0 User 2 0.666667 0.285714 1 User 3 1 0 0.742857 User 4 0.666667 1 0.428571
[0115] To further improve the accuracy of the collaborative filtering model, a popular product penalty factor is introduced. When a product is relatively popular and has a high proportion of orders, it will lead to a large co-occurrence probability between this product and other products. When calculating the similarity of items in the collaborative filtering process, it will also result in a high similarity between other products and this product, thus causing the final recommendation result to lose its personalization and turn into a popular product recommendation. To address this issue, this paper weakens the influence of popular products by introducing a popular product penalty factor into the item similarity calculation formula. The traditional item similarity calculation formula is:
[0116]
[0117] where N(i) represents the number of users who like item i, and N(j) represents the number of users who like item j.
[0118] The item similarity calculation formula after introducing the penalty factor is:
[0119]
[0120] where N represents the total number of users.
[0121] Here, assuming the total number of users is 10000 and the number of users who order a certain popular product is 7000, then the penalty index of this product is:
[0122] The present invention solves the order business volume magnitude gap caused by product characteristics by correcting the user interest degree value, and further introduces a popular product penalty factor, which can prevent the popular product recommendation index in the final recommendation result from being abnormally high.
[0123] Based on any of the above embodiments, the semi-supervised model constructed based on the bootstrap strategy makes up for the negative samples in the training data of the collaborative filtering model, specifically including:
[0124] Obtain the full-scale sample data and the positive sample data of ordering any product, and subtract the positive sample data from the full-scale sample data to obtain the unlabeled sample data, where the full-scale sample data is much larger than the positive sample data;
[0125] Randomly extract random sampling data with the same quantity as the positive sample data from the unlabeled sample data, combine the positive sample data and the random sampling data to form a training data set, and denote the part of the unlabeled sample data excluding the random sampling data as the remaining sample data;
[0126] Construct a classifier based on the training data set, use the positive sample data as the positive samples of the classifier, and the random sampling data as the negative samples of the classifier;
[0127] Predict the remaining sample data based on the classifier and record the prediction scores;
[0128] Repeat the construction of the training data set, the classifier, and the recording of the prediction scores. After multiple iterations, obtain multiple prediction score values corresponding to multiple samples in the unlabeled sample data;
[0129] Take the average value of the multiple prediction score values as the final prediction value of each unlabeled sample, and use the unlabeled samples with the final prediction value higher than the second preset threshold as the final prediction result of the unlabeled samples.
[0130] Specifically, in order to make up for the cold start defect of the collaborative filtering algorithm, another method needs to be adopted to recommend products to users who have never placed an order. The traditional method is to construct a product-specific binary classification model. By analyzing the feature distribution rules of users who have ordered a certain product (positive samples) and users who have been recommended but have not ordered a certain product (negative samples), users with a higher probability of ordering the product are mined for recommendation. However, accurate negative sample data is lacking in the actual data, and a binary classification model cannot be directly constructed. Therefore, the present invention constructs a semi-supervised model based on the bootstrap strategy to solve the problem of lack of negative samples in the data. The specific steps are as follows, and the specific construction process is as Figure 3 shown:
[0131] 1) Obtain the full sample data and denote it as R, obtain the positive sample data of ordering a certain product and denote it as P, and R is much larger than P; then the unlabeled sample data is (R - P), denoted as U;
[0132] 2) Through random sampling, extract sample data U1 with the same quantity as the sample set P from the sample set U, and combine it with the sample set P to form a training set. The remaining samples in U are denoted as OOB;
[0133] 3) Construct a classifier based on the training set generated in step 2), use the sample set P as the positive samples, and use the sample set U1 as the negative samples;
[0134] 4) Apply the classifier trained in step 3) to the sample set OOB for prediction and record its scores;
[0135] 5) After N iterations, repeat steps 2) - 4). The samples in set U have multiple predicted score values respectively. By taking the mean of these values, the final predicted value of each unlabeled sample can be obtained. Samples with predicted values higher than a given threshold are taken as the recommended samples for the product finally.
[0136] The present invention constructs a semi - supervised model to solve the problem that a binary classification model cannot be directly constructed when there are only positive - class labels in the actual application scenario, ensuring the integrity of the training data.
[0137] The product recommendation device provided by the present invention is described below. The product recommendation device described below can be correspondingly referred to the product recommendation method described above.
[0138] Figure 4 is a schematic structural diagram of the product recommendation device provided by the present invention, as Figure 4 shown, including: an acquisition module 41 and a recommendation module 42; where:
[0139] The acquisition module 41 is used to acquire the set of products to be recommended; the recommendation module 42 is used to input the set of products to be recommended into a pre - trained product recommendation model to obtain a product recommendation result; where the product recommendation model is obtained by fusing a two - layer collaborative filtering model and a semi - supervised algorithm.
[0140] Through the product recommendation method based on the fusion of a two - layer collaborative filtering and a semi - supervised algorithm, the present invention is more targeted at the implementation strategy of product marketing and effectively improves the conversion rate of product handling.
[0141] Figure 5 illustrates a schematic structural diagram of an electronic device, as Figure 5 shown. The electronic device may include: a processor 510, a communication interface 520, a memory 530, and a communication bus 540. Among them, the processor 510, the communication interface 520, and the memory 530 complete communication with each other through the communication bus 540. The processor 510 can call the logical instructions in the memory 530 to execute the product recommendation method, which includes: acquiring the set of products to be recommended; inputting the set of products to be recommended into a pre - trained product recommendation model to obtain a product recommendation result; where the product recommendation model is obtained by fusing a two - layer collaborative filtering model and a semi - supervised algorithm.
[0142] In addition, when the logical instructions in the above-mentioned memory 530 are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of this technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present invention. The aforementioned storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memories (ROM, Read-Only Memory), random access memories (RAM, Random Access Memory), magnetic disks, or optical discs that can store program codes.
[0143] On the other hand, the present invention also provides a computer program product. The computer program product includes a computer program stored on a non-transitory computer-readable storage medium. The computer program includes program instructions. When the program instructions are executed by a computer, the computer can execute the product recommendation method provided by the above-mentioned various methods. The method includes: obtaining a set of products to be recommended; inputting the set of products to be recommended into a pre-trained product recommendation model to obtain a product recommendation result; wherein the product recommendation model is obtained by fusing a two-layer collaborative filtering model and a semi-supervised algorithm.
[0144] On another aspect, the present invention also provides a non-transitory computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it is implemented to execute the product recommendation method provided by the above-mentioned various methods. The method includes: obtaining a set of products to be recommended; inputting the set of products to be recommended into a pre-trained product recommendation model to obtain a product recommendation result; wherein the product recommendation model is obtained by fusing a two-layer collaborative filtering model and a semi-supervised algorithm.
[0145] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separated. The components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. A person of ordinary skill in the art can understand and implement it without creative labor.
[0146] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the essence of the above technical solution, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0147] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements for some of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. Product recommendation method, It is characterized in that include: Get the product set to be recommended; Inputting the set of products to be recommended into a pre-trained product recommendation model to obtain product recommendation results; The product recommendation model is based on the fusion of a two-layer collaborative filtering model and a semi-supervised algorithm; The product recommendation model is obtained through the following steps: A collaborative filtering model and a product-by-product semi-supervised model are constructed based on the products to be recommended, and the product-by-product semi-supervised model makes up for the preset defects caused by the cold start of the collaborative filtering model; a first-layer collaborative filtering model is constructed based on the subcategories of the products to be recommended, and a second-layer collaborative filtering model is constructed according to different application scenarios and multiple product combinations. The second-layer collaborative filtering model classifies and summarizes the first-layer collaborative filtering model to obtain the product category recommendation index value; an interest correction function and a hot product penalty factor are introduced into the collaborative filtering model to obtain a collaborative filtering model with improved preset accuracy; a semi-supervised model is constructed based on the bootstrap strategy to make up for the negative samples of the training data in the collaborative filtering model; The collaborative filtering model and the product-based semi-supervised model are constructed based on the product to be recommended, and the product-based semi-supervised model makes up for the preset defects caused by the cold start of the collaborative filtering model, specifically including: Acquire user ordering data and user basic attribute characteristics of the set of products to be recommended; construct the collaborative filtering model based on the user ordering data; construct the product-based semi-supervised model based on the user ordering data and the user basic attribute characteristics; The step of constructing the product-based semi-supervised model based on the user ordering data and the user basic attribute features specifically includes: A user data set that has ordered more than one product is screened out from all user ordering data, an item-based collaborative filtering model is constructed based on the user data set to obtain a TOP1 recommendation list for each user, and the TOP1 recommendation is converted to obtain a potential customer list for each product; for all user basic data, the user ordering data is used as a label and the user basic attribute characteristics are used as features, and several product-specific semi-supervised models are constructed according to products to obtain potential customer lists for several products; a sub-list of the potential customer list of each product is respectively unioned with the sub-lists in the potential customer lists of several products and then merged to obtain the product-specific semi-supervised model.
2. The product recommendation method according to claim 1, It is characterized in that The first-layer collaborative filtering model is constructed based on the subcategories of the products to be recommended, specifically including: Extract the top N products in the sub-category product recommendation index according to the product category, classify and summarize the top N sub-category product recommendation indexes according to the product category and calculate the average value, and use the product category with the largest average value as the final recommended product, where the product category with the largest average value has not yet generated any order behavior, otherwise it will be postponed to the next product category; Alternatively, extract the top 1 in the sub-category product recommendation index according to the product category, where the product category corresponding to the top 1 has not generated any order behavior, otherwise it will be postponed to the next product category; Alternatively, the TOP1 in the sub-category product recommendation index based on a first preset threshold value is extracted according to the product category, wherein the product category corresponding to the TOP1 has not generated any ordering behavior, otherwise it is postponed to the next product category.
3. The product recommendation method according to claim 1, It is characterized in that The method of introducing an interest correction function and a hot product penalty factor into the collaborative filtering model to obtain a collaborative filtering model with improved preset accuracy specifically includes: Determine the business volume of any product ordered by users, obtain a maximum business volume and a minimum business volume, and obtain an interest correction function of any product based on the maximum business volume, the minimum business volume and the business volume; Obtaining an original user and product interest matrix, and correcting the original user and product interest matrix based on the interest correction function of any product to obtain a corrected user and product interest matrix; Determine the number of users who like any one item and the number of users who like any other item, and obtain an item similarity calculation formula based on the number of users who like any one item and the number of users who like any other item; A penalty factor based on the total number of users is introduced into the item similarity calculation formula to obtain a revised item similarity calculation formula; Based on the modified user-product interest matrix and the modified item similarity calculation formula, the collaborative filtering model is modified to obtain the collaborative filtering model with improved preset accuracy.
4. The product recommendation method according to claim 1, It is characterized in that The method of constructing a semi-supervised model based on the bootstrap strategy to compensate for negative samples of training data in the collaborative filtering model specifically includes: Obtain full sample data and positive sample data of ordering any product, and subtract the positive sample data from the full sample data to obtain unlabeled sample data, wherein the full sample data is much larger than the positive sample data; Randomly extract random sampling data of the same number as the positive sample data from the unlabeled sample data, merge the positive sample data and the random sampling data to form a training data set, and record the part of the unlabeled sample data excluding the random sampling data as the remaining sample data; Building a classifier based on the training data set, using the positive sample data as the positive sample of the classifier, and the randomly sampled data as the negative sample of the classifier; Predicting the remaining sample data based on the classifier and recording the prediction scores; Repeating the construction of training data sets, classifiers, and recording prediction scores, after multiple iterations, obtaining multiple prediction score values corresponding to multiple samples in the unlabeled sample data; Take the average of the multiple predicted score values as the final predicted value for each unlabeled sample, and use the unlabeled samples with the final predicted value higher than the second preset threshold as the final prediction result of the unlabeled samples.
5. Product recommendation device, characterized in that, comprising: An acquisition module for acquiring a set of products to be recommended; A recommendation module for inputting the set of products to be recommended into a pre-trained product recommendation model to obtain a product recommendation result; wherein the product recommendation model is obtained by fusing a two-layer collaborative filtering model and a semi-supervised algorithm; The product recommendation model is obtained through the following steps: Construct a collaborative filtering model and a product-specific semi-supervised model based on the products to be recommended, and use the product-specific semi-supervised model to make up for the preset defects caused by the cold start of the collaborative filtering model; construct a first-layer collaborative filtering model based on the subcategories of the products to be recommended, and construct a second-layer collaborative filtering model according to different application scenarios and multiple product combination methods, and use the second-layer collaborative filtering model to classify and summarize the first-layer collaborative filtering model to obtain a product category recommendation index value; introduce an interest correction function and a popular product penalty factor into the collaborative filtering model to obtain a collaborative filtering model with improved preset accuracy; construct a semi-supervised model based on the bootstrap strategy to make up for the negative samples in the training data of the collaborative filtering model; The construction of the collaborative filtering model and the product-specific semi-supervised model based on the products to be recommended, and the use of the product-specific semi-supervised model to make up for the preset defects caused by the cold start of the collaborative filtering model specifically includes: Obtain the user order data and user basic attribute features of the set of products to be recommended; construct the collaborative filtering model based on the user order data; construct the product-specific semi-supervised model based on the user order data and the user basic attribute features; The construction of the product-specific semi-supervised model based on the user order data and the user basic attribute features specifically includes: Screen out the user data set that has ordered more than one product from the full-volume user order data, construct an item-based collaborative filtering model based on the user data set to obtain the TOP1 recommendation list for each user, and convert the TOP1 recommendation to obtain the potential customer list for each product; for the full-volume user basic data, use the user order data as the label and the user basic attribute features as the features respectively, and construct several product-specific semi-supervised models according to the products to obtain the potential customer lists for several products; take the union of the sub-lists of the potential customer list for each product and the sub-lists in the potential customer lists for several products respectively and then merge them to obtain the product-specific semi-supervised model.
6. An electronic device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the product recommendation method according to any one of claims 1 to 4.
7. A non-transitory computer-readable storage medium, on which a computer program is stored, characterized in that, When the computer program is executed by a processor, it implements the steps of the product recommendation method according to any one of claims 1 to 4.
Citation Information
Patent Citations
Clustering and tagging engine for use in product support systems
CA3020971A1
Collaborative filtering recommendation method based on interval semi-supervised LDA
CN110377845A