Personalized cross-domain recommendation method based on federal learning

Through federated learning and differential privacy technology, personalized recommendations that improve system accuracy and privacy protection in cross-domain recommendations are realized, and the problems of insufficient accuracy and privacy leakage in cross-domain recommendations are solved.

CN118551108APending Publication Date: 2024-08-27HUIZHOU POWER SUPPLY BUREAU OF GUANGDONG POWER GRID CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202410664881.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-27
Publication Date
2024-08-27

AI Technical Summary

Technical Problem

The existing cross-domain recommendation technology needs to be optimized in terms of system recommendation accuracy, and because user information needs to be uploaded to the server, it may lead to privacy leakage issues.

Method used

A personalized cross-domain recommendation method based on federated learning is adopted. By finding common users and cold-start users in the source domain and target domain, the latent semantic model is used to generate user vectors, a common bridge neural network is constructed, and meta-learning is generated through federated meta-learning. Generate a network to achieve personalized cross-domain recommendations, while using differential privacy to encrypt model parameters to ensure user privacy protection.

Benefits of technology

It improves the accuracy and personalization of the recommendation system, ensures the protection of user privacy, avoids privacy leaks, and completes model training locally to enhance data protection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118551108A
    Figure CN118551108A
Patent Text Reader

Abstract

The invention provides a personalized cross-domain recommendation method based on federal learning, and the method comprises the steps: searching a common user and a cold start user in a source domain and a target domain according to the unique ID of a user in cross-domain recommendation; based on the common user, respectively generating a source domain vector and a target domain vector of the common user in the source domain and the target domain by using a latent semantic model; constructing a common bridge neural network by adopting transverse federated learning based on the source domain vector and the target domain vector of the common user; based on the common bridge neural network, generating a meta-learning generation network by utilizing federated meta-learning; training the meta learning generation network; and generating a target domain vector for the cold start user based on the trained meta-learning generation network, and realizing personalized cross-domain recommendation through the target domain vector. According to the method, the data of the user is fully utilized, personalized and accurate cross-domain recommendation is realized, meanwhile, the privacy of the user is protected, and the method has practical significance.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of cross-domain recommendation, and in particular relates to a personalized cross-domain recommendation method based on federated learning. Background Art

[0002] The rapid development of the Internet industry has led to an explosion of data, allowing people to easily access a vast and growing amount of information. However, it is becoming increasingly difficult to find the information people really need. To solve this problem, recommendation systems have become a valuable technology that helps users find what they are interested in. For example, Netflix and YouTube recommend videos and music, while Amazon recommends various products to users. Recommendation systems have now become an integral part of Internet media websites, allowing people to seamlessly find their favorite products. In a recommendation system, user preferences are identified by analyzing the user's behavior history, and then recommendations are provided based on the user's preferences. Traditional recommendation systems face two challenges: data sparsity and the cold start problem, both of which are caused by the lack of sufficient user interaction data information. Cross-domain Recommendation (CDR) is a feasible approach to solve these problems. Its goal is to integrate useful information from other domains to improve recommendations in the target domain. By analyzing the user's historical behavior information, we can capture the user's inherent preferences from multiple aspects, thereby enhancing the valuable data in the target domain and providing additional information to overcome the cold start problem.

[0003] Cross-domain recommendation transfers user preferences from another domain to the target domain, which is called user preference transfer. To achieve this, many current methods assume that all users have similar preference associations, and therefore, a common preference bridge is built for all users. However, due to the variability of user preferences, the complex connections of user preferences vary from person to person. It is difficult for a universal preference bridge to learn the preference transfer of all users. Therefore, some methods use personalized methods to build preference bridges for each user, however, since each user has his own preference bridge, the generalization ability of the bridge is limited because it is built using only one person's information. And to the best of our knowledge, cross-domain recommendation is currently mainly studied in the context of a centralized framework, which requires direct sharing of user information between the client and the server. However, these centralized methods may cause privacy issues for users. In cross-domain recommendation, users' personal information is often directly uploaded to the server for subsequent training. However, this information usually contains private data, which may cause privacy issues for users. Compared with traditional recommendation systems, cross-domain recommendation requires integrating user information from various domains, and if user information is not protected, the privacy leakage problem may be more serious. Therefore, on the whole, the accuracy of system recommendations in cross-domain recommendations needs to be further optimized, and since users' personal information often needs to be uploaded to the server, the user's privacy may be leaked to a certain extent. Summary of the invention

[0004] The purpose of the present invention is to provide a personalized cross-domain recommendation method based on federated learning to solve the problem that the accuracy of system recommendations in cross-domain recommendations needs to be further optimized, and since users' personal information often needs to be uploaded to the server, the user's privacy may be leaked.

[0005] In order to achieve the above object, the present invention adopts the following technical scheme:

[0006] The present invention provides a personalized cross-domain recommendation method based on federated learning, which specifically includes the following steps:

[0007] S1. In cross-domain recommendation, based on the unique ID of the user, common users and cold start users are found in the source domain and the target domain;

[0008] S2. Based on the common users, the source domain vector and target domain vector of the common users are generated using latent semantic models in the source domain and target domain respectively;

[0009] S3, based on the source domain vector and target domain vector of common users, horizontal federated learning is used to build a public bridge neural network;

[0010] S4. Based on the common bridge neural network, a meta-learning generation network is generated by using federated meta-learning; the meta-learning generation network is trained to obtain a trained meta-learning generation network;

[0011] S5. Based on the trained meta-learning generative network, a target domain vector is generated for cold-start users, and personalized cross-domain recommendations are achieved through the target domain vector.

[0012] In some implementations, in S1 , a common user is a user having an ID in both the source domain and the target domain, and a cold-start user is a user having an ID only in the source domain.

[0013] In some implementations, step 2 is specifically as follows: in cross-domain recommendation, based on common users in the source domain and the target domain, latent semantic models are used to generate user vectors and item vectors, respectively, and then the source domain vectors and target domain vectors of the common users are represented by the user vectors.

[0014] Furthermore, S3 specifically uses a deep neural network to transfer the source domain vector and target domain vector of common users to form model parameters, then uses federated learning combined with differential privacy to encrypt the model parameters, and uses a gradient descent algorithm to optimize the encrypted model parameters, and finally updates the gradient and loss function of the optimized model parameters.

[0015] Furthermore, in S3, a model-agnostic meta-learning algorithm is used to optimize the encrypted model parameters as follows:

[0016] Select some user data from the user pool to form tasks, build a dataset by iteratively selecting subsets of tasks, and divide the user data into two non-overlapping sets U a and U b , and extract the corresponding data D a and D b , meta-training and meta-testing phases are simulated by two user sets respectively, and the loss function of meta-training is as follows:

[0017]

[0018] Among them, L θ For loss.

[0019] Furthermore, in S3, the gradient and loss function of the updated optimized model parameters are specifically:

[0020] Based on the loss calculated by the loss function, gradient descent is performed according to the following formula to obtain the updated parameters:

[0021]

[0022] Among them, λ is the learning rate of the meta-training stage, which isa The updated parameters θ' are obtained from the training data; the loss function of the meta-test phase is:

[0023]

[0024] The initial parameters of the updated model are:

[0025]

[0026] Here, η is the learning rate during the meta-test phase.

[0027] Furthermore, in S4, using federated meta-learning to generate a meta-learning generation network specifically includes:

[0028] Use the user's historical behavior information to create a user vector from the source domain. First, use the user vector to build a local preference bridge, and merge the preference bridge with the public bridge to obtain the user's personalized preference bridge; then input the user vector from the source domain into the personalized preference bridge to derive the user's target vector, and input the source user vector into the meta-network to obtain the user's local preference bridge:

[0029]

[0030] in, represents the user vector of the source domain, h is the meta-network function, Is user u i The local preference bridge parameter;

[0031] Will Combined with the parameter m of the general preference bridge, we get user u i The personalized preference bridge Feed their personalized preference bridge Get the user's target vector

[0032]

[0033] Furthermore, in S4, training the meta-learning generation network specifically includes:

[0034] The meta-network is trained to meta-learn the generative network by minimizing the following loss function:

[0035]

[0036] Among them, L is the square of the loss function, U o For public users, is the output of the personalized preference bridge, is the user vector of the user in the target domain.

[0037] A computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the personalized cross-domain recommendation method based on federated learning are implemented.

[0038] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of the personalized cross-domain recommendation method based on federated learning.

[0039] Compared with the prior art, the personalized cross-domain recommendation method based on federated learning in the present invention has the following beneficial technical effects.

[0040] The present invention discloses a personalized cross-domain recommendation method based on federated learning, which specifically includes the following steps: S1. In cross-domain recommendation, according to the unique ID of the user, common users and cold-start users are found in the source domain and the target domain; S2. Based on the common users, the source domain vector and the target domain vector of the common users are generated by using the latent semantic model in the source domain and the target domain respectively; S3. Based on the source domain vector and the target domain vector of the common users, a common bridge neural network is constructed by using horizontal federated learning; S4. Based on the common bridge neural network, a meta-learning generation network is generated by using federated meta-learning; the meta-learning generation network is trained to obtain a trained meta-learning generation network; S5. Based on the trained meta-learning generation network, a target domain vector is generated for the cold-start user, and personalized cross-domain recommendation is realized through the target domain vector. Based on the above, compared with the single-domain recommendation algorithm, the present invention can more accurately predict the content that meets the user's interests; and compared with the simple cross-domain recommendation algorithm, it not only realizes the protection of user privacy, but also can make more full use of the user's own data to realize more personalized and accurate recommendations.

[0041] In order to alleviate the cold start and data sparsity problems of the recommendation system, the present invention introduces a cross-domain recommendation system, integrates auxiliary domain data into the neural network, deeply explores the hidden relationship between data features to achieve transfer learning of multi-domain data, and thus fully extracts potential features to improve the accuracy of target domain recommendations. The present invention considers using a meta-learning generation network method to build a personalized cross-domain preference bridge for each user, thereby achieving personalized knowledge transfer and alleviating the cold start problem of the target domain.

[0042] In order to eliminate users' concerns about data privacy in cross-domain recommendation systems, this invention introduces federated learning, which can complete model training locally without uploading user privacy data to a third-party server. Afterwards, in order to further strengthen data protection and prevent certain network attacks, this invention introduces differential privacy technology to encrypt the intermediate parameters of the model, thereby preventing third parties from obtaining users' real personal data and protecting user privacy throughout the process. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] The drawings in the specification are used to provide further understanding of the present invention and constitute a part of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute improper limitations on the present invention.

[0044] Figure 1 A flowchart of a personalized cross-domain recommendation method based on federated learning according to the present invention;

[0045] Figure 2 The present invention is a personalized cross-domain recommendation method based on federated learning, which is a flow chart of encrypting the training of a meta-learning generation network in a federated learning scenario. DETAILED DESCRIPTION

[0046] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.

[0047] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0048] How to prevent third parties from obtaining users' real personal data, thereby protecting users' privacy to a certain extent; how to effectively improve the accuracy of cross-domain recommendations.

[0049] Based on this, the present invention provides a personalized cross-domain recommendation method based on federated learning, which specifically includes the following steps:

[0050] S1. In cross-domain recommendation, based on the unique ID of the user, common users and cold start users are found in the source domain and the target domain;

[0051] S2. Based on the common users, the source domain vector and target domain vector of the common users are generated using latent semantic models in the source domain and target domain respectively;

[0052] S3, based on the source domain vector and target domain vector of common users, horizontal federated learning is used to build a public bridge neural network;

[0053] S4. Based on the common bridge neural network, a meta-learning generation network is generated by using federated meta-learning; the meta-learning generation network is trained to obtain a trained meta-learning generation network;

[0054] S5. Based on the trained meta-learning generative network, a target domain vector is generated for cold-start users, and personalized cross-domain recommendations are achieved through the target domain vector.

[0055] like Figure 1 As shown in the figure, the present invention first aligns common users in different fields, then uses latent semantic models to obtain user vectors and item vectors, and uses deep neural networks to build public preference bridges. Then, a meta-learning generation network is used to generate personalized preference bridges for each user. Finally, a differential privacy algorithm is used to encrypt and interact the intermediate results and feature gradients to protect the privacy of users.

[0056] The present invention realizes personalized knowledge transfer and alleviates the cold start problem of the target domain. Afterwards, federated learning is introduced, which can complete model training locally without uploading user privacy data to a third-party server. Afterwards, in order to further strengthen data protection and prevent certain network attacks, the present invention introduces differential privacy technology to encrypt the intermediate parameters of the model, thereby preventing third parties from obtaining the user's real personal data, which not only improves the accuracy of the recommendation system, but also protects the user's privacy to a certain extent.

[0057] The personalized cross-domain recommendation method based on federated learning of the present invention is further described and elaborated in detail below in conjunction with the accompanying drawings and specific embodiments.

[0058] Step 1: In cross-domain recommendation, there is a source domain and a target domain, each domain has a user set U = {u1,…,u m}, item set V = {v1,…,v n} and the user-item rating matrix R = [r ij ] m*n , where r ij ≥0 indicates the rating of item j by user i. To distinguish the two domains, the user, item set, and rating matrix of the source domain are represented as U s ,V s ,R s , the target domain is represented by U t ,V t ,R t The overlapping users between the two domains are defined as U o =Us ∩U t . And V s and V t are disjoint, which means there are no shared items between the two domains.

[0059] Step 2: Use latent semantic models to generate vector representations of users and items. and They represent the vectors of user i and item j respectively, where k represents the dimension of the vector and d∈{s,t} represents the domain label.

[0060] Step 3: Build a common bridge neural network and improve the generalization of the common bridge neural network based on the model agnostic meta-learning (MAML) algorithm design. i represents the loss of the i-th task, and then the losses of all tasks are added together to get the total loss of all N tasks. This is the optimization goal of meta-learning. Using the MAML algorithm, the public preference bridge can obtain a good initialization parameter, so as to better transform it into a personalized preference bridge. The method includes selecting some user data from the common user pool to form a separate task, and constructing a mini-batch dataset by iteratively selecting a subset of these tasks. In each task, the user is divided into two non-overlapping sets U a and U b , and extract the corresponding data D a and D b , forming two user sets.

[0061] These two user sets simulate the meta-training and meta-testing stages respectively. The loss function of the meta-training stage is expressed as:

[0062]

[0063] To obtain the second common preference bridge, we first calculate the loss L θ , and perform gradient descent to obtain the updated parameters:

[0064]

[0065] where λ is the learning rate in the meta-training phase. a The updated parameters θ' are obtained from the training data. The loss function for the next stage is Afterwards, update the initial parameters of the model as follows:

[0066]

[0067] Here, η is the learning rate during the meta-test phase.

[0068] Step 4: Based on the common bridge neural network, a federated meta-learning generative network is used to generate a personalized cross-domain transfer neural network.

[0069] Step 5: Finally, we use the meta-learning generative network to generate a personalized cross-domain preference bridge for each cold start user, generate its target domain user vector, and then perform recommendation services;

[0070] like Figure 2 As shown, the personalized cross-domain recommendation method based on federated learning of the present invention has the following specific training details for the meta-learning generation network and the implementation details of the personalized preference bridge:

[0071] The meta-learning generative network used in this invention: This network uses the user's historical behavior information to create a user vector from the source domain. This user vector is then used to build a local preference bridge, which will be merged with the public bridge to obtain the user's personalized preference bridge. We then input the user vector from the source domain into the personalized preference bridge to derive the user's target vector. Here, the source user vector is fed into the meta-network to obtain the user's local preference bridge:

[0072]

[0073] in represents the user vector of the source domain, and h is the meta-learning generation network. Is user u i The local preference bridge parameter.

[0074] The personalized preference bridge used in the present invention: We combine the local preference bridge parameters with the public preference bridge parameters m to obtain the user u i Personalized preference bridge The user vector Send it into its personalized preference bridge to get the user's target vector

[0075]

[0076] We can then train the meta-network by minimizing the following loss function:

[0077]

[0078] Among them, L is the square of the loss function, U o For public users, is the output of the personalized preference bridge, is the user vector of an ordinary user in the target domain. In the cold start task in the target domain, use As the initialization user vector.

[0079] In the method of the present invention, all models are trained using a federated learning framework. Specifically, a horizontal federated learning framework is used to obtain user and item embeddings, while a federated transfer learning framework is used to train general and personalized preference bridges. In order to ensure the privacy of user data, we mainly use differential privacy, that is, adding differential privacy noise to the model parameters uploaded by the user to the server. This method prevents the server from extracting any useful information from the uploaded parameters.

[0080] The public and personalized preference bridges are trained using a federated transfer learning framework, and differential privacy is used to further ensure the privacy of user data, that is, differential privacy noise is added to the model parameters uploaded by the user to the server. This method prevents the server from extracting any useful information from the uploaded parameters. Although federated learning allows each participant to store their private training data locally, privacy attacks may still occur if malicious participants or servers attempt to extract intermediate parameters to infer private data. Differential privacy is widely used to protect participants from such attacks. Its key principle is to blur personal information in the dataset when an attacker attempts to query the dataset, thereby preventing personal-level information from being identified by the query results.

[0081] The specific process of training the model using federated learning can be described as follows. First, for each user’s model parameter Θ i , we use the learning rate of α to calculate the model loss L on their respective datasets i The model parameters Θ for each user i Updated as follows:

[0082]

[0083] Then, each user adds their own model parameters with differential privacy to obtain the parameters M(Θ i ), where M represents the differential privacy function to protect user privacy. These parameters are then sent to the server for aggregation. The server updates the parameters using the aggregated data and sends the updated Θ i Sent back to all clients. The server updates the parameters as follows:

[0084]

[0085] Where n is the number of clients.

[0086] Finally, based on the locally stored data and models of each user, we can conveniently build a personalized preference bridge through the meta-network.

[0087] In summary, the present invention first aligns common users in different fields, then uses latent semantic models to obtain user vectors and item vectors, and uses deep neural networks to build public preference bridges. After that, a meta-learning generation network is used to generate personalized preference bridges for each user. Finally, a differential privacy algorithm is used to encrypt and interact the intermediate results and feature gradients to protect user privacy. The present invention utilizes the characteristics of local training data in federated learning, uses differential privacy to prevent user data leakage, and then uses a meta-learning generation network to generate personalized preference bridges, which not only improves the accuracy of cross-domain recommendations, but also protects user privacy to a certain extent, and improves the confidentiality coefficient of cross-domain recommendations. Improves user experience.

[0088] Finally, it should be noted that the above are only preferred embodiments of the present invention and are 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 replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A personalized cross-domain recommendation method based on federated learning, It is characterized in that The specific steps include: S1. In cross-domain recommendation, based on the unique ID of the user, common users and cold start users are found in the source domain and the target domain; S2. Based on the common users, the source domain vector and target domain vector of the common users are generated using latent semantic models in the source domain and target domain respectively; S3, based on the source domain vector and target domain vector of common users, horizontal federated learning is used to build a public bridge neural network; S4, based on the common bridge neural network, using federated meta-learning to generate a meta-learning generative network; Train the meta-learning generation network to obtain a trained meta-learning generation network; S5. Based on the trained meta-learning generative network, a target domain vector is generated for cold-start users, and personalized cross-domain recommendations are achieved through the target domain vector.

2. According to the personalized cross-domain recommendation method based on federated learning according to claim 1, It is characterized in that In S1, a common user is a user having an ID in both the source domain and the target domain, and a cold start user is a user having an ID only in the source domain.

3. According to the personalized cross-domain recommendation method based on federated learning according to claim 1, It is characterized in that Step 2 is as follows: In cross-domain recommendation, based on common users in the source domain and target domain, latent semantic models are used to generate user vectors and item vectors respectively, and then the source domain vectors and target domain vectors of common users are represented by user vectors.

4. According to claim 1, the personalized cross-domain recommendation method based on federated learning, It is characterized in that Specifically, S3 is as follows: a deep neural network is used to transmit the source domain vector and the target domain vector of the common user to form model parameters, and then the model parameters are encrypted by using federated learning combined with differential privacy, and the encrypted model parameters are optimized by using a gradient descent algorithm, and finally the gradient and loss function of the optimized model parameters are updated.

5. According to claim 4, the personalized cross-domain recommendation method based on federated learning, It is characterized in that In S3, the encrypted model parameters are optimized using a model-agnostic meta-learning algorithm as follows: Select some user data from the user pool to form tasks, build a dataset by iteratively selecting subsets of tasks, and divide the user data into two non-overlapping sets U a and U b , and extract the corresponding data D a and D b , meta-training and meta-testing phases are simulated by two user sets respectively, and the loss function of meta-training is as follows: Among them, L θ For loss.

6. The personalized cross-domain recommendation method based on federated learning according to claim 5, It is characterized in that In S3, the gradient and loss function of the model parameters after updating and optimization are specifically: Based on the loss calculated by the loss function, gradient descent is performed according to the following formula to obtain the updated parameters: Among them, λ is the learning rate of the meta-training phase, θ is the model parameter, and a The updated parameters θ' are obtained from the training data; the loss function of the meta-test phase is: The initial parameters of the updated model are: Here, η is the learning rate during the meta-test phase.

7. The personalized cross-domain recommendation method based on federated learning according to claim 1, It is characterized in that In S4, generating a meta-learning network by using federated meta-learning specifically includes: Use the user's historical behavior information to create a user vector from the source domain. First, use the user vector to build a local preference bridge, and merge the preference bridge with the public bridge to obtain the user's personalized preference bridge; then input the user vector from the source domain into the personalized preference bridge to derive the user's target vector, and input the source user vector into the meta-network to obtain the user's local preference bridge: in, represents the user vector of the source domain, h is the meta-network function, Is user u i The local preference bridge parameter; Will Combined with the parameter m of the general preference bridge, we get user u i The personalized preference bridge Feed their personalized preference bridge Get the user's target vector 8. According to claim 7, the personalized cross-domain recommendation method based on federated learning, It is characterized in that In S4, training the meta-learning generation network specifically includes: The meta-network is trained to meta-learn the generative network by minimizing the following loss function: Among them, L is the square of the loss function, U o For public users, is the output of the personalized preference bridge, is the user vector of the user in the target domain.

9. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, It is characterized in that When the processor executes the computer program, the steps of the personalized cross-domain recommendation method based on federated learning as claimed in any one of claims 1 to 8 are implemented.

10. A computer-readable storage medium storing a computer program. It is characterized in that When the computer program is executed by a processor, the steps of the personalized cross-domain recommendation method based on federated learning as claimed in any one of claims 1 to 8 are implemented.

Citation Information

Cited By

  • Data privacy protection method under federated learning framework and medical service system

    CN119312400A

  • Generation method of federal cross-domain recommendation model based on graph neural network

    CN120162481A