Neural collaborative filtering bidirectional recommendation method based on head-tail knowledge transfer
By classifying and normalizing the bidirectional rating data, a bidirectional nearest neighbor feature matrix is constructed. Combined with a neural collaborative filtering embedding layer and a fully connected layer, the problem of uneven distribution of long-tail items in the bidirectional recommendation system is solved, and a more efficient recommendation effect is achieved.
Patent Information
- Application Number
- CN202210852889.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-20
- Publication Date
- 2024-11-15
- Estimated Expiration
- 2042-07-20
AI Technical Summary
Existing two-way recommendation systems suffer from data imbalance in the distribution of long-tail items, resulting in poor recommendation performance. Furthermore, they fail to fully explore the two-way local relationship between users and items and lack effective utilization of top-performing items.
By classifying and normalizing bidirectional rating data, a bidirectional nearest neighbor feature matrix is constructed. Combined with a neural collaborative filtering embedding layer, local feature information of users and items is learned. Furthermore, network parameters are transferred through a fully connected layer to improve the recommendation effect of long-tail items from a few-sample model to a many-sample model.
It effectively alleviates the data imbalance problem of long-tail projects, improves the accuracy and recall of two-way recommendations, fully explores the local feature information between users and items, and improves the recommendation efficiency of long-tail projects.
Smart Images

Figure CN115080861B_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the field of recommendation systems, and specifically relates to a neural collaborative filtering bidirectional recommendation method based on migrating head-tail knowledge. Background Art
[0002] A recommendation system is an information filtering system that discovers users' interests and hobbies by analyzing their historical behavior data and the characteristics of each user, and recommends items of interest to users. Traditional recommendation systems only need to satisfy users' one-way preferences to recommend items to users, such as shopping, playlists, etc., while two-way recommendation systems need to consider two-way preference relationships. Nowadays, there are more and more scenarios that require two-way recommendations in daily life, such as online dating platforms, job recruitment services, social networks, etc. A successful two-way recommendation means that the subject of the recommendation attracts the target object at the same time, and the target object attracts the subject of the recommendation. Two-way recommendation must also consider other factors that do not exist in traditional recommendation systems, such as the consequences of recommending a popular user to an unpopular user.
[0003] Building a recommendation system is challenging. One of the most famous problems is the long-tail distribution that is prevalent in user-item interactions: for items, a small number of popular items receive most of the user feedback, while most items have only a few user feedbacks. Therefore, a recommendation model trained on a dataset with such a long-tail item distribution will easily fall into a cycle of "rich getting richer" and "poor getting poorer". At the same time, compared with popular product recommendations, long-tail recommendations have the following benefits: 1) The market competitiveness of popular products is very strong, so the profit is very limited. However, long-tail items contain relatively large marginal profits; 2) Recommending long-tail products will surprise users and increase customer loyalty and satisfaction; 3) For two-way recommendations, recommending too many head items, while the number of head items accounts for a small proportion, greatly reduces the number of recommendation results that can satisfy both sides. Therefore, it is crucial to solve the long-tail item distribution problem of two-way recommendations.
[0004] At present, in two-way recommendation, the normalization of two-way rating datasets is aggregated according to a unified standard, and no differentiated sampling and aggregation is performed according to the popularity of the subject and the object in the two-way interaction. The traditional neural collaborative filtering network used for recommendation uses user ID and item ID information, adopts a one-hot encoding method, and does not fully explore the two-way local relationship between users and items; in addition, some recent studies to solve the long-tail distribution will use resampling to rebalance the dataset and reweight the tail items in the loss function to assign higher costs. However, these recommendations only focus on the tail items, without considering the connection with the head items (popular items) - which contain rich user feedback information and transferable contextual information related to the tail items, such as belonging to the same type. At the same time, almost no one pays attention to the problem of long-tail item recommendation in the two-way recommendation scenario. Summary of the invention
[0005] Based on the above technical problems, the present invention provides a neural collaborative filtering bidirectional recommendation method based on the transfer of head-tail knowledge. The present invention can be trained using a model-based method according to the user's historical rating information of the items to obtain the user's rating prediction for unevaluated items, which is used to improve the bidirectional recommendation efficiency of long-tail data.
[0006] The idea of the present invention to achieve the above purpose is: through the bilateral interactive popularity of the object and the subject of the two-way scoring data, the classification sampling is carried out, and then the scoring data is normalized, while deepening the representation of the long-tail project, preventing the long-tail phenomenon of the one-way scoring data after aggregation from becoming more serious. By constructing a two-way nearest neighbor feature matrix, the bilateral nearest neighbor features of the object and the subject are combined with the object and subject features corresponding to the neural collaborative filtering embedding layer, and continue to be input into the neural network for training, so as to fully explore the local feature information between the two-way object and the subject. By using the fully connected layer F() network to learn the changes in the parameters of the neural collaborative filtering network in the process of object-subject and subject-object head projects from a few sample models to a multi-sample model, the application is migrated to the long-tail project, and the recommendation of the two-way long-tail project is improved.
[0007] In order to achieve the above object, the specific implementation steps of the present invention are as follows:
[0008] The object-subject and subject-object two-way scoring data are collected and normalized preprocessed.
[0009] The similarity matrices of the object-subject and subject-object scoring data are calculated respectively to obtain two object similarity matrices and two subject similarity matrices.
[0010] Matrix decomposition training is performed on the object-subject and subject-object scoring data respectively to obtain corresponding object feature matrices and subject feature matrices. Based on the multiple similarity matrices obtained from the bidirectional data, the vectors corresponding to each object's nearest neighbor in the two object feature matrices are used to form an object nearest neighbor feature matrix, and the vectors corresponding to each subject's nearest neighbor in the two subject feature matrices are used to form a subject nearest neighbor feature matrix.
[0011] The popularity of the object-subject and subject-object scoring data is calculated respectively, sampling is performed according to certain rules according to the different popularity of the object-subject, and then the two-way scoring data is assigned different weights to combine into new object-subject and subject-object scoring data.
[0012] The new object-subject scoring data is divided into a few-sample data set and a multi-sample data set for multiple times, and input into a neural collaborative filtering recommendation network to obtain respective object and subject embedding features, which are then concatenated with the corresponding nearest neighbor feature vectors and continuously input into the neural network for training. The new subject-object scoring data is divided into a few-sample data set and a multi-sample data set for multiple times, and input into a neural collaborative filtering recommendation network to obtain respective subject and object embedding features, which are then concatenated with the corresponding nearest neighbor feature vectors and continuously input into the neural network for training.
[0013] Using the fully connected layer as the mapping network of F(), the changes of the parameters of the neural collaborative filtering recommendation network from the object-subject few-sample to the multi-sample data set training are learned. Using the fully connected layer as the mapping network of F(), the changes of the parameters of the neural collaborative filtering recommendation network from the subject-object few-sample to the multi-sample data set training are learned.
[0014] The trained neural collaborative filtering recommendation network is used to generate the object's rating of the subject and the subject's rating of the object, aggregate the two-way ratings, and evaluate the performance of the model.
[0015] Furthermore, the normalization preprocessing of the two-way scoring data includes:
[0016] The object-subject score data is normalized and mapped to [0,1] using the following formula: Among them, rating max , rating min are the maximum and minimum score values respectively.
[0017] The subject-object score data is normalized and mapped to [0,1] using the following formula: Among them, rating max , rating min are the maximum and minimum score values respectively.
[0018] Furthermore, the calculation of the similarity matrix of the object-subject rating data includes:
[0019] The object-subject scoring data is combined into an object-to-subject scoring matrix, wherein the rows of the scoring matrix are the object IDs, the columns are the subject IDs, and the number of rows and columns of the scoring matrix are the total number of objects and subjects, respectively.
[0020] The cosine similarity formula is used to calculate the similarity between all objects to form an object similarity matrix, and then the similarity between all subjects is calculated to form a subject similarity matrix.
[0021] The similarity matrix of the subject-object scoring data is calculated as follows:
[0022] The subject-object scoring data are combined into a subject-object scoring matrix, wherein the behavior of the scoring matrix is the subject number ID, the column is the object number ID, and the number of rows and columns of the scoring matrix are the total number of subjects and objects respectively.
[0023] The cosine similarity formula is used to calculate the similarity between all objects to form an object similarity matrix, and then the similarity between all subjects is calculated to form a subject similarity matrix.
[0024] Furthermore, the acquisition of the object and subject feature matrix includes:
[0025] The object-subject score matrix is decomposed, the object feature matrix and the subject feature matrix are initialized, and the object feature matrix and the subject feature matrix are multiplied to form a reconstruction training matrix. The reconstruction loss formula is used to Calculate the reconstruction error of the reconstruction matrix, where Y i,u represents the score of the i-th object on the u-th subject, I i represents the characteristics of the i-th object, U u represents the characteristics of the u-th subject, T is the transposition operation, λ is the regularization parameter, ‖‖ F is the norm of F. Using gradient descent, the object feature matrix and the subject feature matrix are updated, and the iteration is continued until convergence to obtain the implicit vectors of each object and subject.
[0026] The subject-object score matrix is decomposed, the subject feature matrix and the object feature matrix are initialized, and the subject feature matrix and the object feature matrix are multiplied to form a reconstruction training matrix. The reconstruction loss formula is used to Calculate the reconstruction error of the reconstruction matrix, where Y u,i represents the score of the u-th subject on the i-th object, U is the subject feature matrix, U u represents the characteristics of the u-th subject, I is the object feature matrix, and I i represents the characteristics of the i-th object, T is the transposition operation, λ is the regularization parameter, ‖‖ F The F norm is used to update the subject feature matrix and the object feature matrix by gradient descent, and the implicit feature vectors of each subject and object are obtained by continuous iteration until convergence.
[0027] The object similarity matrix obtained from the object-subject scoring data and the object similarity matrix obtained from the subject-object scoring data are respectively selected to obtain the nearest neighbors of each object, and the implicit vectors of the nearest neighbors of each object in the corresponding object feature matrix are concatenated to form an object nearest neighbor feature matrix.
[0028] The subject similarity matrix obtained from the subject-object scoring data and the subject similarity matrix obtained from the object-subject scoring data are respectively selected to obtain the nearest neighbors of each subject, and the implicit vectors of the nearest neighbors of each subject in the corresponding subject feature matrix are concatenated to form the subject nearest neighbor feature matrix.
[0029] Furthermore, the acquisition of new object-subject scores and subject-object data includes:
[0030] Calculate the popularity of each subject in the object-subject scoring data and the popularity of each object in the subject-object scoring data. The calculation formula is as follows:
[0031] Object popularity: ppk i =ln(1+|N i |)
[0032] Subject popularity: ppz u =ln(1+|N u |)
[0033] Among them, N i is the number of subjects who prefer the object, N u is the number of objects that prefer the subject.
[0034] The ppz obtained from the object-subject scoring data u The subjects with a value greater than or equal to k are regarded as head subjects, and those with a value less than k are regarded as long-tail subjects. The objects preferred by each subject in the subject-object rating data are divided into ppk i Sort from large to small, select the first k object interaction data of the long-tail subject in the subject-object rating data, select the first k object interaction data of the head subject in the subject-object rating data The object-subject score is updated by weighted combination of object interaction data. The calculation formula is as follows:
[0035]
[0036] in, is the object's preference score for the subject, y ui is the subject's preference score for the object, and α is the weight coefficient. Therefore, a new object-subject score matrix is obtained.
[0037] Calculate the popularity of each object in the subject-object scoring data and the popularity of each subject in the object-subject scoring data. The calculation formula is as follows:
[0038] Object popularity: ppk i =ln(1+|N i |)
[0039] Subject popularity: ppz u =ln(1+|Nu |)
[0040] Among them, N i is the number of subjects who prefer the object, N u is the number of objects that prefer the subject;
[0041] The ppk obtained from the subject-object scoring data i Objects with values greater than or equal to k are considered head objects, and objects with values less than k are considered long-tail objects. The subject preferred by each object in the object-subject rating data is divided into two groups according to ppz. u Sort from large to small, select the first k subject interaction data of the long-tail objects in the object-subject scoring data, and select the first k subject interaction data of the head objects in the object-subject scoring data. The subject-object score is updated by weighted combination of subject interaction data. The calculation formula is as follows:
[0042]
[0043] in, is the subject’s preference score for the object, y iu is the object's preference score for the subject, and α is the weight coefficient; thus, a new subject-object scoring matrix is obtained.
[0044] Furthermore, the forming of the few-sample data set and the many-sample data set includes:
[0045] Multi-sample object-subject dataset Contains all object feedback from the head and tail subjects, a few-shot object-subject dataset It consists of all interaction records of the long-tail subject and t records randomly sampled from each head subject.
[0046] Furthermore, the neural collaborative filtering recommendation network training process for the subject-object data set includes:
[0047] Given the target object i and subject u, the neural collaborative filtering recommendation method can be expressed as: in, represents the prediction score between object i and subject u; θ represents the model parameters; g represents the mapping function.
[0048] The object-subject dataset is used as the original input, and after one-hot encoding, it is transformed into an input vector that the model can directly process. Then, a linear embedding layer is used to convert the high-dimensional, sparse input vector into a low-dimensional, dense representation vector, thereby obtaining the embedding vectors of object i and subject u. The embedding integration layer is used to integrate the two types of representation vectors of the corresponding nearest neighbor vector to form the final representation vector v of the object and subject. i and vu .
[0049] For the matrix factorization MF part, v i and v u Perform element-wise product to get the matrix decomposition output vector For the multi-layer perceptron MLP part, v i and v u Splice them together to get the input vector v iu , and then v iu Input into the multi-layer perceptron to learn the interaction function between the object and the subject, and obtain the output vector of the multi-layer perceptron
[0050] Depend on The output vectors of the matrix decomposition and multilayer perceptron are concatenated and input into a fully connected layer to obtain the predicted score between object i and subject u, where h is the weight vector of the output layer; b represents the bias term of the output layer; and σ(·) is the Sigmoid function. As the loss function, θ is the model parameter, and the subject-object preference is trained as above.
[0051] The neural collaborative filtering recommendation network training process for the subject-object data set includes:
[0052] Given the target subject u and object i, the neural collaborative filtering recommendation method is expressed as: in, represents the prediction score between subject u and object i; θ represents the model parameter; g represents the mapping function;
[0053] The subject-object dataset is used as the original input, and after one-hot encoding, it is transformed into an input vector that the model can directly process. Then, a linear embedding layer is used to convert the high-dimensional, sparse input vector into a low-dimensional, dense representation vector, thereby obtaining the embedding vectors of subject u and object i. The embedding integration layer is used to integrate the two types of representation vectors, the embedding vector and the corresponding nearest neighbor vector, to form the final representation vector v of the subject and object. u and v i ;
[0054] For the matrix factorization MF part, v u and v i Perform element-wise product to get the matrix decomposition output vector For the multi-layer perceptron MLP part, v u and v i Splice them together to get the input vector v ui , and then v uiInput into the multi-layer perceptron to learn the interaction function between the object and the subject, and obtain the output vector of the multi-layer perceptron
[0055] Depend on The output vectors of the matrix decomposition and multilayer perceptron are concatenated and input into a fully connected layer to obtain the prediction score between subject u and object i, where h is the weight vector of the output layer; b represents the bias term of the output layer; σ(·) is the Sigmoid function, and As the loss function, θ is the model parameter.
[0056] Furthermore, the use of F() to obtain the model parameter changes includes:
[0057] Use a fully connected layer as the mapping network of F() to learn the last layer parameters of the object-subject neural collaborative filtering recommendation network, using this formula Find the multi-sample model parameters.
[0058] Then use the loss function Learn the parameter changes from the few-shot model to the multi-shot model, where F(θ;ω) uses the parameter ω to learn the meta-mapping from the few-shot model parameters to the multi-shot model parameters, and its input is the neural collaborative filtering recommendation model in The trained parameters θ, λ are regularization parameters that balance these two terms. * ‖ 2 The predicted multi-sample model parameters (via F(θ;ω)) and the multi-sample model parameters θ * Minimize the distance between them. Based on the training data set Train the neural collaborative filtering recommendation network to ensure It can also help learn F(θ;ω) with high recommendation performance on medium data.
[0059] Use a fully connected layer as the mapping network of F() to learn the last layer parameters of the subject-object neural collaborative filtering recommendation network, using this formula Find the multi-sample model parameters.
[0060] Then use the loss function Learning parameter changes from few-shot models to many-shot models, is a subject-object few-sample dataset. It is a subject-object multi-sample dataset.
[0061] Furthermore, obtaining the two-way score includes:
[0062] Get object-subject ratings: Select a series of {t j}Satisfy t1 <t2<t3…<t m , construct the dataset, and learn a series of F 1,2 (·)…F j,j+1 (·)…F m-1,m (·), where F j,j+1 (·) is learning from Dataset to The model parameter mapping of the dataset is determined by minimizing The final scoring data is obtained by the following formula: in θ * is the original multi-sample parameter, ω j,j+1 Learning for the fully connected layer arrive The parameters of the model change, θ j for Dataset model parameters.
[0063] Get subject-object ratings: Select a series of {t j}Satisfy t1 <t2<t3…<t m , construct the dataset, and learn a series of F 1,2 (·)…F j,j+1 (·)…F m-1,m (·), where F j,j+1 (·) is learning from Dataset to The model parameter mapping of the dataset is determined by minimizing The final scoring data is obtained by the following formula: in θ * is the original multi-sample parameter, ω j,j+1 Learning for the fully connected layer arrive The parameters of the model change, θ j for Dataset model parameters.
[0064] The two-way scores are aggregated by arithmetic mean and matched with the test set to verify the accuracy, recall and f1 value of the model.
[0065] The beneficial effect of the present invention is that the present invention classifies and samples according to the bilateral interaction popularity of the object and the subject of the two-way rating data, and then normalizes the rating data, thereby incorporating certain two-way preferences into the one-way preference data, thereby deepening the representation of long-tail items and preventing the long-tail phenomenon of the one-way rating data from becoming more serious after aggregation.
[0066] The present invention constructs a bidirectional nearest neighbor feature matrix, combines the bidirectional nearest neighbor features with the object and subject features of the neural collaborative filtering embedding layer, and inputs them into a fully connected neural network for training. It can further integrate the subject preference and object preference information learned from the subject-object scoring data on the basis of learning the object preference and subject preference obtained from the subject-object scoring data, and fully mine the local feature information between the object and the subject.
[0067] The present invention uses a fully connected layer F() network to learn the changes in neural collaborative filtering network parameters in the process of object-subject and subject-object head object / subject from a few-sample model to a multi-sample model, and migrates the application to long-tail objects / subjects, enriching long-tail objects / subjects with only a few-sample interactions and improving the recommendation of bidirectional long-tail items. BRIEF DESCRIPTION OF THE DRAWINGS
[0068] Figure 1 The present invention is a flowchart of a neural collaborative filtering bidirectional recommendation method based on migrating head-tail knowledge.
[0069] Figure 2 This is a method model of a neural collaborative filtering bidirectional recommendation method based on migrating head-tail knowledge in an embodiment of the present invention. DETAILED DESCRIPTION
[0070] It is easy to understand that according to the technical solution of the present invention, without changing the essential spirit of the present invention, a person skilled in the art can propose a variety of interchangeable structural modes and implementation modes. Therefore, the following specific implementation modes and drawings are only exemplary descriptions of the technical solution of the present invention, and should not be regarded as the whole of the present invention or as a limitation or restriction to the technical solution of the present invention.
[0071] Figure 2 It is a method model provided by an embodiment of the present invention. The process of the present invention is described by using shallow, linear matrix decomposition and deep, nonlinear multilayer perceptron as implementation methods. The specific content is as follows: Given the target object i and subject u, the object-subject recommendation method proposed by the present invention can be expressed as: in, represents the prediction score between object i and subject u; θ represents the model parameter; g represents the mapping function. Given the target subject u and object i, the subject-object recommendation method proposed in the present invention can be expressed as: in, represents the prediction score between subject u and object i; θ represents the model parameters; g represents the mapping function.
[0072] According to one embodiment of the present invention, Figure 1 A neural collaborative filtering bidirectional recommendation method based on migrating head-tail knowledge is shown, comprising the following steps:
[0073] S101, collect object-subject and subject-object two-way scoring data and perform normalization preprocessing.
[0074] Specifically, the above step S101 is as follows:
[0075] S1011, first normalize the object-subject score data and map it to [0,1], the formula is as follows:
[0076]
[0077] Among them, rating max , rating min are the maximum and minimum score values respectively.
[0078] S1012, normalize the subject-object score data and map it to [0,1], the formula is as follows:
[0079]
[0080] Among them, rating max , rating min are the maximum and minimum score values respectively.
[0081] S102, respectively calculating the similarity matrices of the object-subject and subject-object scoring data to obtain two object similarity matrices and two subject similarity matrices.
[0082] Specifically, the above step S102 is as follows:
[0083] S1021, form an object-to-subject scoring matrix from the object-subject scoring data, wherein the scoring matrix has the object ID number and the column number of the subject ID. The number of rows and columns of the scoring matrix are the total number of objects and subjects, respectively. The representation vector of object i is the score of all subjects in the i-th row, and the representation vector of subject u is the score of all objects to him in the u-th column.
[0084] S1022, using the cosine similarity formula, calculate the similarities between all objects to form an object similarity matrix, and then calculate the similarities between all subjects to form a subject similarity matrix.
[0085] S1023, forming a subject-to-object scoring matrix from the subject-to-object scoring data, wherein the scoring matrix has the subject ID number and the column ID number of the subject, the number of rows and the number of columns of the scoring matrix are the total number of subjects and objects respectively, the representation vector of subject u is the score of all objects in the u-th row, and the representation vector of object i is the score of all subjects to it in the i-th column;
[0086] S1024, using the cosine similarity formula, calculate the similarities between all objects to form an object similarity matrix, and then calculate the similarities between all subjects to form a subject similarity matrix.
[0087] S103, respectively performing matrix decomposition training on the object-subject and subject-object scoring data to obtain corresponding object feature matrices and subject feature matrices. According to the multiple similarity matrices obtained from the bidirectional data, the vectors corresponding to each object's nearest neighbor in the two object feature matrices are used to form an object nearest neighbor feature matrix, and the vectors corresponding to each subject's nearest neighbor in the two subject feature matrices are used to form a subject nearest neighbor feature matrix.
[0088] If only the object-subject and subject-object ratings are input into the recommendation network, the local feature information between the object and the subject cannot be fully mined. Therefore, the neighbor matrix of the object and the subject is combined. At the same time, the neighbor matrix obtained by learning the subject-object rating data can be further integrated with the subject preference and object preference information learned from the subject-object rating data on the basis of the object preference and subject preference obtained from the object-subject rating data, thereby enriching the neighbor matrix of the object and the subject.
[0089] Specifically, the above step S103 is as follows:
[0090] S1031, perform matrix decomposition on the object-subject score matrix, initialize the object feature matrix I (m*f) and the subject feature matrix U (n*f), where m and n are the number of objects and subjects respectively, and f is the dimension of the implicit vector. After multiplying the object feature matrix and the subject feature matrix, a reconstruction training matrix is formed. The reconstruction loss formula is used Calculate the reconstruction error of the reconstruction matrix, where Y i,u represents the score of the i-th object on the u-th subject, I i represents the characteristics of the i-th object, U u represents the characteristics of the u-th subject, T is the transposition operation, λ is the regularization parameter, ‖‖ F is the norm of F. Using gradient descent, update the object feature matrix and the subject feature matrix, repeat the above steps and iterate until convergence, and obtain the implicit vectors of each object and subject.
[0091] S1032, perform matrix decomposition on the subject-object scoring matrix, initialize the subject feature matrix U(n*f) and the object feature matrix I(m*f), where m and n are the number of objects and subjects respectively, and f is the dimension of the implicit vector, and multiply the subject feature matrix and the object feature matrix to form a reconstruction training matrix. Use the reconstruction loss formula to use the reconstruction loss formula Calculate the reconstruction error of the reconstruction matrix, where Y u,i represents the score of the u-th subject on the i-th object, U is the subject feature matrix, U u represents the characteristics of the u-th subject, I is the object feature matrix, and I i represents the characteristics of the i-th object, T is the transposition operation, λ is the regularization parameter, ‖‖ F The F-norm is used, and gradient descent is used to update the subject feature matrix and the object feature matrix. The algorithm is iterated continuously until convergence to obtain the implicit feature vectors of each subject and object.
[0092] S1033, the object similarity matrix obtained from the object-subject scoring data and the object similarity matrix obtained from the subject-object scoring data respectively select the nearest neighbor of each object, and concatenate the implicit vectors of the nearest neighbor of each object in the corresponding object feature matrix to form an object nearest neighbor feature matrix.
[0093] S1034, the subject similarity matrix obtained from the object-subject scoring data and the subject similarity matrix obtained from the subject-object scoring data respectively select the nearest neighbors of each subject, and concatenate the implicit vectors of the nearest neighbors of each subject in the corresponding subject feature matrix to form a subject nearest neighbor feature matrix.
[0094] S104, respectively calculating the popularity of the object-subject and subject-object scoring data, sampling according to certain rules based on the different popularity of the object-subject, and then assigning different weights to the two-way scoring data to combine into new object-subject and subject-object scoring data.
[0095] When training one-way preferences, such as the object's preference for the subject, in order to add some two-way selection factors to better achieve two-way recommendation matching and enrich the representation of long-tail data, the subject-object rating data is sampled according to certain rules and then fused with the object-subject rating. In order to prevent the long-tail phenomenon of one-way rating data from becoming more serious after aggregation, different strategies are used to sample the head and long-tail items, and then the two-way ratings are assigned different weights for weighted fusion.
[0096] Specifically, the above step S104 is as follows:
[0097] S1041, calculating the popularity of each subject in the object-subject scoring data and the popularity of each object in the subject-object scoring data, the calculation formula is as follows:
[0098] Object popularity: ppk i =ln(1+|N i |)
[0099] Subject popularity: ppz u =ln(1+|N u |)
[0100] Among them, N i is the number of subjects who prefer the object, N u is the number of objects that prefer the subject.
[0101] S1042, the ppz obtained from the object-subject scoring data u The subjects with a value greater than or equal to k are regarded as head subjects, and those with a value less than k are regarded as long-tail subjects. The objects preferred by each subject in the subject-object rating data are divided into ppk i Sort from large to small, select the first k object interaction data of the long-tail subject in the subject-object rating data, select the first k object interaction data of the head subject in the subject-object rating data Object interaction data
[0102] S1043, weighted combination update object-subject score, the calculation formula is as follows:
[0103]
[0104] in, is the object's preference score for the subject, y ui is the subject's preference score for the object, and α is the weight coefficient. Therefore, a new object-subject score matrix is obtained.
[0105] S1044, calculating the popularity of each object in the subject-object scoring data and the popularity of each subject in the object-subject scoring data, the calculation formula is as follows:
[0106] Object popularity: ppk i =ln(1+|N i |)
[0107] Subject popularity: ppz u =ln(1+|N u |)
[0108] Among them, N i is the number of subjects who prefer the object, N u is the number of objects that prefer the subject;
[0109] S1045, the ppk obtained from the subject-object scoring data i Objects with values greater than or equal to k are considered head objects, and objects with values less than k are considered long-tail objects. The subject preferred by each object in the object-subject rating data is divided into two groups according to ppz. u Sort from large to small, select the first k subject interaction data of the long-tail objects in the object-subject scoring data, and select the first k subject interaction data of the head objects in the object-subject scoring data. The subject interaction data.
[0110] S1046, weighted combination is used to update the subject-object score to obtain a new subject-object score matrix, and the calculation formula is as follows:
[0111]
[0112] in, is the subject’s preference score for the object, y iu is the object's preference score for the subject, and α is the weight coefficient; thus, a new subject-object scoring matrix is obtained.
[0113] S105, the new object-subject scoring data is divided into a few-sample data set and a multi-sample data set for multiple times, input into a neural collaborative filtering network, obtain the respective object and subject embedding features, then concatenate with the nearest neighbor feature vector, and input into a multi-layer perceptron. The new subject-object scoring data is divided into a few-sample data set and a multi-sample data set for multiple times, input into a neural collaborative filtering network, obtain the respective subject and object embedding features, then concatenate with the nearest neighbor feature vector, and input into a multi-layer perceptron.
[0114] The long-tail items are under-represented due to lack of data points, while we have fairly rich information and enough data points for the head items. We propose to explore the connection between the model parameters learned with only a few interaction examples and the model parameters learned with enough interaction examples for the same item. For example, given an item with user feedback, F() learns to implicitly add the model parameter changes during similar users providing feedback for the same item, allowing us to improve the representation quality even when there is not enough data. Therefore, it is necessary to construct few-shot and many-shot datasets to learn parameter changes for long-tail data.
[0115] Specifically, the above step S105 is as follows:
[0116] S1051, multi-sample object-subject dataset Contains all object feedback from the head and tail subjects, a few-shot object-subject dataset It consists of all interaction records of the long-tail subject and t records randomly sampled from each head subject.
[0117] S1052, using the object-subject dataset as the original input, after one-hot encoding, it is converted into an input vector that can be directly processed by the model, and then using a linear embedding layer to convert the high-dimensional, sparse input vector into a low-dimensional, dense representation vector, thereby obtaining the embedding vectors of the object i and the subject u, and using an embedding integration layer to integrate the two types of representation vectors of the embedding vector and the corresponding nearest neighbor vector to form the final representation vector v of the object and the subject i and v u .
[0118] S1053, in the neural collaborative filtering network, for the matrix decomposition MF part, v i and v u Perform element-wise product to get the matrix decomposition output vector For example, i =[a1, a2, … a f ] T , v u =[b1,b2,…b f ] T ,but For the multi-layer perceptron MLP part, v i and v u Splice them together to get the input vector v iu , for example, i =[a1, a2, … a f ] T , v u =[b1,b2,…b f ] T , then v iu =[a1, a2, … a f , b1, b2, … b f ] T . Then v iu Input into the multi-layer perceptron to learn the interaction function between the object and the subject, and obtain the output vector of the multi-layer perceptron Use the following formula
[0119]
[0120] …
[0121]
[0122] S1054, the design of the multilayer perceptron follows the common tower structure. Specifically, the number of hidden units in the next layer is half of that in the previous layer. For example, if the number of layers of the multilayer perceptron is L=3 and the prediction factor dL is 64, then its network structure is 256→128→64 and the embedding dimension is 64. Generally speaking, a three-layer multilayer perceptron can achieve very good results.
[0123] S1055, by The output vectors of the matrix decomposition and multilayer perceptron are concatenated and input into a fully connected layer to obtain the predicted score between object i and subject u, where h is the weight vector of the output layer; b represents the bias term of the output layer; and σ(·) is the Sigmoid function. As the loss function, θ is the model parameter, and the optimization method is the Adam algorithm. For different parameters, it can adaptively adjust the size of its learning rate.
[0124] S1056, multi-sample subject-object dataset Contains all subject feedback from the head and tail objects, a few-shot subject-object dataset It consists of all interaction records of the long-tail objects and t records randomly sampled from each head object.
[0125] S1057, using the subject-object dataset as the original input, after one-hot encoding, it is transformed into an input vector that the model can directly process, and then using a linear embedding layer to convert the high-dimensional, sparse input vector into a low-dimensional, dense representation vector, thereby obtaining the embedding vectors of the subject u and the object i, and using an embedding integration layer to integrate the two types of representation vectors, the embedded vector and the corresponding nearest neighbor vector, to form the final representation vector v of the subject and the object u and v i .
[0126] S1058, in the neural collaborative filtering network, for the matrix decomposition MF part, v u and v i Perform element-wise product to get the matrix decomposition output vector For example, i =[a1, a2, … a f ] T , v u =[b1,b2,…b f ] T ,but For the multi-layer perceptron MLP part, v u and v i Splice them together to get the input vector v ui , for example, i =[a1, a2, … a f ] T , v u =[b1,b2,…b f ] T , then v ui=[b1,b2,…b f , a1, a2, … a f ] T . Then v ui Input into the multi-layer perceptron to learn the interaction function between the object and the subject, and obtain the output vector of the multi-layer perceptron Use the following formula
[0127]
[0128] …
[0129]
[0130] S1059, the design of multilayer perceptron follows the common tower structure. Specifically, the number of hidden units in the next layer is half of that in the previous layer. For example, if the number of layers of the multilayer perceptron is L=3 and the prediction factor dL is 64, then its network structure is 256→128→64 and the embedding dimension is 64. Generally speaking, a three-layer multilayer perceptron can achieve very good results.
[0131] S10510, by The output vectors of the matrix decomposition and multilayer perceptron are concatenated and input into a fully connected layer to obtain the predicted score between subject u and object i, where h is the weight vector of the output layer; b represents the bias term of the output layer; and σ(·) is the Sigmoid function. As the loss function, θ is the model parameter, and the optimization method is the Adam algorithm. For different parameters, it can adaptively adjust the size of its learning rate.
[0132] S106, using the fully connected layer as the mapping network of F(), learning the changes of the parameters of the neural collaborative filtering network from the object-subject few-sample to the multi-sample data set training; using the fully connected layer as the mapping network of F(), learning the changes of the parameters of the neural collaborative filtering network from the subject-object few-sample to the multi-sample data set training.
[0133] Specifically, the above step S106 is as follows:
[0134] S1061, use a fully connected layer as the mapping network of F() to learn the last layer parameters of the object-subject neural collaborative filtering recommendation network, using this formula Find the multi-sample model parameters.
[0135] S1062, then use the loss function Learn the parameter changes from the few-shot model to the multi-shot model, where F(θ;ω) uses the parameter ω to learn the meta-mapping from the few-shot model parameters to the multi-shot model parameters, and its input is the neural collaborative filtering recommendation model in The trained parameters θ, λ are regularization parameters that balance these two terms. * ‖ 2 The predicted multi-sample model parameters (via F(θ;ω)) and the multi-sample model parameters θ * It ensures that the predicted multi-sample model parameters learned by F(θ;ω) can fit well The data sample in; the second item Based on the training data set Train the neural collaborative filtering recommendation network to ensure The high recommendation performance of medium data can also help learn F(θ; ω). Therefore, training the few-shot model and the loss function of F(θ; ω) simultaneously provides high-quality neural collaborative filtering recommendations and improves the accuracy of the F(θ; ω) model mapping.
[0136] S1063, use a fully connected layer as the mapping network of F() to learn the last layer parameters of the subject-object neural collaborative filtering recommendation network, using this formula Find the multi-sample model parameters.
[0137] S1064, then use the loss function Learning parameter changes from few-shot models to many-shot models, is a subject-object few-sample dataset. It is a subject-object multi-sample dataset.
[0138] S107, using the trained recommendation network to generate object-subject ratings and subject-to-object ratings, aggregate the two-way ratings, and evaluate the performance of the model.
[0139] In order to make the transfer learning between projects smoother, the present invention further changes the size of t to construct different data sets and recursively learns the dynamic trajectory of the model.
[0140] Specifically, the above step S107 is as follows:
[0141] S1071, obtain object-subject score: select a series of {t j}Satisfy t1 <t2<t3…<t m , construct the dataset, and learn a series of F 1,2 (·)…F j,j+1 (·)…F m-1,m (·), where Fj,j+1 (·) is learning from Dataset to The model parameter mapping of the dataset is determined by minimizing The final scoring data is obtained by the following formula: in θ * is the original multi-sample parameter, ω j,j+1 Learning for the fully connected layer arrive The parameters of the model change, θ j for Dataset model parameters.
[0142] S1072, obtain subject-object score: select a series of {t j}Satisfy t1 <t2<t3…<t m , construct the dataset, and learn a series of F 1,2 (·)…F j,j+1 (·)…F m-1,m (·), where F j,j+1 (·) is learning from Dataset to The model parameter mapping of the dataset is determined by minimizing The final scoring data is obtained by the following formula: in θ * is the original multi-sample parameter, ω j,j+1 Learning for the fully connected layer arrive The parameters of the model change, θ j for Dataset model parameters.
[0143] The two-way scores are aggregated by arithmetic mean and matched with the test set to verify the accuracy, recall and f1 value of the model.
[0144] The above description is only an embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent substitution, improvement, etc. made within the spirit and principle of the present invention should be included in the scope of the claims of the present invention.
Claims
1. A neural collaborative filtering bidirectional recommendation method based on migrating head and tail knowledge, characterized by: The neural collaborative filtering bidirectional recommendation method comprises the following steps: Step 1: Collect object-subject and subject-object bidirectional scoring data and perform normalization preprocessing; Step 2: Calculate the similarity matrices of the object-subject and subject-object scoring data respectively to obtain two object similarity matrices and two subject similarity matrices; Step 3: Perform matrix decomposition training on the object-subject and subject-object scoring data in step 1 respectively to obtain the corresponding object feature matrix and subject feature matrix. According to the two object similarity matrices and the two subject similarity matrices obtained in step 2, the vectors corresponding to each object's nearest neighbor in the two object feature matrices are used to form an object nearest neighbor feature matrix, and the vectors corresponding to each subject's nearest neighbor in the two subject feature matrices are used to form a subject nearest neighbor feature matrix. Step 4: Calculate the popularity of the object-subject and subject-object scoring data respectively, perform sampling according to the different popularity of the object-subject, and then assign different weights to the two-way scoring data to combine into new object-subject scoring data and new subject-object scoring data; Step 5: The new object-subject scoring data obtained in step 4 is divided into a few-sample data set and a multi-sample data set for multiple times, and input into the neural collaborative filtering recommendation network to obtain the respective object and subject embedding features, which are then spliced with the corresponding nearest neighbor feature vectors, and the training parameters are continuously input into the neural network; The new subject-object scoring data obtained in step 4 is divided into a few-sample data set and a multi-sample data set for multiple times, and input into the neural collaborative filtering recommendation network to obtain the respective subject and object embedding features, which are then spliced with the corresponding nearest neighbor feature vectors, and the training parameters are continuously input into the neural network; Step 6: Use the fully connected layer as the mapping network of F() to learn the changes in the parameters of the neural collaborative filtering recommendation network from the object-subject few-sample to the multi-sample dataset training; Use the fully connected layer as the mapping network of F() to learn the changes in the parameters of the neural collaborative filtering recommendation network from the subject-object few-sample to the multi-sample dataset training; Step 7: Use the trained neural collaborative filtering recommendation network to generate the object's rating of the subject and the subject's rating of the object, aggregate the two-way ratings, and evaluate the performance of the model. in: In step 4: Obtaining new object-subject scoring data includes the following steps: Calculate the popularity of each subject in the object-subject scoring data and the popularity of each object in the subject-object scoring data. The calculation formula is as follows: Object popularity: ppk i =ln(1+|N i |) Subject popularity: ppz u =ln(1+|N u |) Among them, N i is the number of subjects who prefer the object, N u is the number of objects that prefer the subject; The subject popularity ppz obtained from the object-subject scoring data u The subjects with a value greater than or equal to k are regarded as head subjects, and those with a value less than k are regarded as long-tail subjects. The objects preferred by each subject in the subject-object scoring data are ranked according to the object popularity ppk i Sort from large to small, select the first k object interaction data of the long-tail subject in the subject-object rating data, select the first k object interaction data of the head subject in the subject-object rating data The object interaction data is weighted and combined to update the object-subject score to obtain a new object-subject score matrix. The calculation formula is as follows: in, is the object's preference score for the subject, y ui is the subject's preference score for the object, and α is the weight coefficient; Obtaining new subject-object scoring data includes the following steps: Calculate the popularity of each object in the subject-object scoring data and the popularity of each subject in the object-subject scoring data. The calculation formula is as follows: Object popularity: ppk i =ln(1+|N i |) Subject popularity: ppz u =ln(1+|N u |) Among them, N i is the number of subjects who prefer the object, N u is the number of objects that prefer the subject; The object popularity ppk obtained by subject-object scoring data i Objects with a value greater than or equal to k are regarded as head objects, and objects with a value less than k are regarded as long-tail objects. The subject preferred by each object in the object-subject scoring data is ranked according to the subject popularity ppz u Sort from large to small, select the first k subject interaction data of the long-tail objects in the object-subject scoring data, and select the first k subject interaction data of the head objects in the object-subject scoring data. The subject interaction data is weighted and combined to update the subject-object score to obtain a new subject-object score matrix. The calculation formula is as follows: in, is the subject’s preference score for the object, y iu is the object's preference score for the subject, and α is the weight coefficient; In step 5, The composition of the object-subject few-sample data set and the multi-sample data set includes: the multi-sample object-subject data set Contains all object feedback from the head and tail subjects, a few-shot object-subject dataset It consists of all interaction records of the long-tail subject and t records randomly sampled from each head subject; The subject-object few-sample data set and the multi-sample data set are composed of: multi-sample subject-object data set Contains all subject feedback from the head and tail objects, a few-shot subject-object dataset It consists of all interaction records of the long-tail objects and t records randomly sampled from each head object; In step 5, the training process of the neural collaborative filtering recommendation network on the object-subject data set includes: Step 5-1-1: Given the target object i and subject u, the neural collaborative filtering recommendation method is expressed as: in, represents the prediction score between object i and subject u; θ represents the model parameter; g represents the mapping function; Step 5-1-2: Use the object-subject dataset as the original input, and after one-hot encoding, transform it into an input vector that the model can directly process. Then use the linear embedding layer to convert the high-dimensional, sparse input vector into a low-dimensional, dense representation vector, thereby obtaining the embedding vectors of object i and subject u. Use the embedding integration layer to integrate the embedding vector and the corresponding nearest neighbor vector to form the final representation vector v of the object and subject. i and v u ; Step 5-1-3: For the matrix decomposition MF part, v i and v u Perform element-wise product to get the matrix decomposition output vector For the multi-layer perceptron MLP part, v i and v u Splice them together to get the input vector v iu , and then v iu Input into the multi-layer perceptron to learn the interaction function between the object and the subject, and obtain the output vector of the multi-layer perceptron Step 5-1-4: The output vectors of the matrix decomposition and multilayer perceptron are concatenated and input into a fully connected layer to obtain the prediction score between object i and subject u, where h is the weight vector of the output layer; b represents the bias term of the output layer; σ(·) is the Sigmoid function, and As the loss function, θ is the model parameter; The neural collaborative filtering recommendation network training process for the subject-object data set includes: Step 5-2-1: Given the target subject u and object i, the neural collaborative filtering recommendation method is expressed as: in, represents the prediction score between subject u and object i; θ represents the model parameter; g represents the mapping function; Step 5-2-2: Use the subject-object dataset as the original input, and after one-hot encoding, transform it into an input vector that the model can directly process. Then use the linear embedding layer to convert the high-dimensional, sparse input vector into a low-dimensional, dense representation vector, thereby obtaining the embedding vectors of subject u and object i. Use the embedding integration layer to integrate the embedding vector and the corresponding nearest neighbor vector to form the final representation vector v of the subject and object. u and v i ; Step 5-2-3: For the matrix decomposition MF part, v u and v i Perform element-wise product to get the matrix decomposition output vector For the multi-layer perceptron MLP part, v u and v i Splice them together to get the input vector v ui , and then v ui Input into the multi-layer perceptron to learn the interaction function between the object and the subject, and obtain the output vector of the multi-layer perceptron Step 5-2-4: The output vectors of the matrix decomposition and multilayer perceptron are concatenated and input into a fully connected layer to obtain the prediction score between subject u and object i, where h is the weight vector of the output layer; b represents the bias term of the output layer; σ(·) is the Sigmoid function, and As the loss function, θ is the model parameter; In step 6, using F() to obtain parameter changes of the neural collaborative filtering model during the training process from a small sample to a large sample data set includes: Step 6-1: Use a fully connected layer as the mapping network of F() to learn the last layer parameters of the object-subject neural collaborative filtering recommendation network, using this formula is a multi-sample data set, argmin is the minimization loss function, and thus the multi-sample model parameter θ is obtained * ; Step 6-2: Using the loss function Learning the parameter changes from the object-subject few-shot model to the multi-shot model, where is an object-subject few-sample dataset, is an object-subject multi-sample dataset; F(θ;ω) uses parameter ω to learn the meta-mapping from the few-sample model parameters to the multi-sample model parameters, and its input is the neural collaborative filtering recommendation model in The trained parameters θ and λ are regularization parameters that balance these two terms, ‖F(θ;ω)-θ * ‖ 2 The predicted multi-sample model parameters are passed through F(θ;ω) and the multi-sample model parameters θ * Minimize the distance between Based on the training data set Train the neural collaborative filtering recommendation network to ensure High recommendation performance of the data, while helping to learn F(θ;ω); Step 6-3: Use a fully connected layer as the mapping network of F() to learn the last layer parameters of the subject-object neural collaborative filtering recommendation network, using this formula Find the parameters of the multi-sample model; Step 6-4: Then use the loss function Learning the parameter changes from the subject-object few-shot model to the multi-shot model, is a subject-object few-sample dataset. It is a subject-object few-sample dataset.
2. The neural collaborative filtering bidirectional recommendation method based on migrating head-tail knowledge according to claim 1 is characterized in that: The normalization preprocessing of the collected two-way scoring data in step 1 is as follows: The object-subject score data is normalized and mapped to [0,1] using the following formula: Among them, rating max , rating min are the maximum and minimum score values respectively; The subject-object score data is normalized and mapped to [0,1] using the following formula: Among them, rating max , rating min are the maximum and minimum score values respectively.
3. The neural collaborative filtering bidirectional recommendation method based on migrating head-tail knowledge according to claim 1 is characterized in that: In step 2, Calculating the similarity matrix of the object-subject scoring data, including: forming the object-subject scoring matrix of the object to the subject by the object-subject scoring data, wherein the behavior of the scoring matrix is the object number ID, the column is the subject number ID, the number of rows and the number of columns of the scoring matrix are respectively the total number of the object subjects, using the cosine similarity formula to calculate the similarity between all objects to form an object similarity matrix, and then calculating the similarity between all subjects to form a subject similarity matrix; Calculating the similarity matrix of subject-object scoring data, including: forming a subject-to-object scoring matrix of the subject-to-object scoring data, wherein the behavior of the scoring matrix is the subject number ID, the column is the object number ID, the number of rows and the number of columns of the scoring matrix are respectively the total number of subjects and objects, using the cosine similarity formula to calculate the similarity between all subjects to form a subject similarity matrix, and then calculating the similarity between all objects to form an object similarity matrix.
4. The neural collaborative filtering bidirectional recommendation method based on migrating head-tail knowledge according to claim 1 is characterized in that: In step 3, The object feature matrix and the subject feature matrix in the object-subject scoring matrix are obtained by performing matrix decomposition on the object-subject scoring matrix, initializing the object feature matrix and the subject feature matrix, multiplying the object feature matrix and the subject feature matrix to form a reconstruction training matrix, and using the reconstruction loss formula to obtain the object feature matrix and the subject feature matrix. Calculate the reconstruction error of the reconstruction matrix, where Y i,u represents the score of the i-th object on the u-th subject, I is the object feature matrix, I i represents the characteristics of the i-th object, U is the subject feature matrix, and U u represents the characteristics of the u-th subject, T is the transposition operation, λ is the regularization parameter, ‖‖ F The F norm is used to update the object feature matrix and the subject feature matrix by gradient descent, and the implicit feature vectors of each object and subject are obtained by continuous iteration until convergence. The subject feature matrix and the object feature matrix in the subject-object scoring matrix are obtained by performing matrix decomposition on the subject-object scoring matrix, initializing the subject feature matrix and the object feature matrix, multiplying the subject feature matrix and the object feature matrix to form a reconstruction training matrix, and using the reconstruction loss formula to obtain the subject feature matrix and the object feature matrix. Calculate the reconstruction error of the reconstruction matrix, where Y u,i represents the score of the u-th subject on the i-th object, U is the subject feature matrix, U u represents the characteristics of the u-th subject, I is the object feature matrix, and I i represents the feature of the i-th object, T is the transposition operation, λ is the regularization parameter, ‖‖ F The F norm is used to update the subject feature matrix and the object feature matrix using gradient descent, and the implicit feature vectors of each subject and object are obtained by continuous iteration until convergence; The object nearest neighbor feature matrix is obtained as follows: the object similarity matrix obtained from the object-subject scoring data and the object similarity matrix obtained from the subject-object scoring data are respectively selected as the nearest neighbors of each object, and the implicit vectors of the nearest neighbors of each object in the corresponding object feature matrix are concatenated to form the object nearest neighbor feature matrix; The subject nearest neighbor feature matrix is obtained specifically as follows: the nearest neighbors of each subject are selected from the subject similarity matrix obtained from the object-subject scoring data and the subject similarity matrix obtained from the subject-object scoring data, and the implicit vectors of the nearest neighbors of each subject in the corresponding subject feature matrix are concatenated to form the subject nearest neighbor feature matrix.
5. The neural collaborative filtering bidirectional recommendation method based on migrating head-tail knowledge according to claim 1 is characterized in that: The step 7 specifically includes: Step 7-1: Obtain object-subject scores: Select a series of {t j }Satisfy t1 <t2<t3…<t m , construct the dataset, and learn a series of F 1,2 (·)…F j,j+1 (·)…F m-1,m (·), where F j,j+1 (·) is learning from Dataset to The model parameter mapping of the dataset is determined by minimizing The final scoring data is obtained by the following formula: in θ * is the original multi-sample parameter, ω j,j+1 Learning for the fully connected layers arrive The parameters of the model change, θ j for Dataset Neural Collaborative Filtering Model Parameters; Step 7-2: Obtain subject-object scores: Select a series of {t j }Satisfy t1 <t2<t3…<t m , construct the dataset, and learn a series of F 1,2 (·)…F j,j+1 (·)…F m-1,m (·), where F j,j+1 (·) is learning from Dataset to The model parameter mapping of the dataset is determined by minimizing The final scoring data is obtained by the following formula: in θ * is the original multi-sample parameter, ω j,j+1 Learning for the fully connected layers arrive The parameters of the model change, θ j for Dataset Neural Collaborative Filtering Model Parameters; Step 7-3: Aggregate the two-way scores: Aggregate the two-way scores through the arithmetic mean, match them with the test set, and verify the accuracy, recall and f1 value of the model.
