Job recommendation method and device based on federated learning
By adopting a horizontal federated learning algorithm model in the online recruitment platform, using local resume features and target job features to compare, generate job scores, and obtain recommended jobs from similar clients, solving the problem of the inability to effectively protect job seekers' privacy data in the existing technology. The problem of this has achieved safe and accurate job recommendations.
Patent Information
- Application Number
- CN202110367781.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-04-06
- Publication Date
- 2024-12-03
- Estimated Expiration
- 2041-04-06
AI Technical Summary
When recommending positions, existing online recruitment platforms cannot effectively protect the job seeker's personal privacy data, which has security loopholes, which may lead to privacy data leakage.
Using a job recommendation method based on horizontal federated learning, through an algorithm model jointly trained by the client and the server, the local resume feature information and the target job feature information are compared, the job score is generated, and the recommendation results are obtained from recommended positions of similar clients. , without sending your resume to the server.
It effectively protects the personal privacy information of job seekers, avoids data leakage, and at the same time realizes the accuracy of job recommendations and the security of user privacy.
Smart Images

Figure CN113158241B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data recommendation technology, and in particular to a job recommendation method, device, client device and server based on horizontal federated learning. Background Art
[0002] With the development of online recruitment platforms, online recruitment has attracted a large number of job seekers to upload their resumes to the platform database with its many advantages such as wide coverage and low cost. The recruitment platform can recommend positions to job seekers based on the uploaded resumes and related recommendation algorithms.
[0003] However, there may be security loopholes in the online recruitment platform database, and hackers may have the opportunity to illegally invade the online recruitment platform database and obtain the job seekers' private data from personal resumes.
[0004] It can be seen that the way in which recruitment platforms in the prior art recommend positions to job seekers based on uploaded personal resumes and related recommendation algorithms may lead to the leakage of job seekers' private data and cannot effectively protect job seekers' personal privacy information. Summary of the invention
[0005] The purpose of the embodiments of the present invention is to provide a job recommendation method, apparatus, client device and server to recommend jobs to users under the premise of effectively protecting personal privacy information. The specific technical solution is as follows:
[0006] In a first aspect of an embodiment of the present invention, a job recommendation method is first provided, which is applied to a current client of an online recruitment platform. The method includes:
[0007] Obtain the resume characteristics specified in the target personal resume of the current client as local resume characteristic information;
[0008] Obtain target positions browsed by the user through the current client on the online recruitment platform and target position feature information of each target position;
[0009] For each target position, input the target position feature information of the target position and the local resume feature information into a horizontal federated learning algorithm model pre-trained with the server;
[0010] Obtaining the job score of each target job output by the horizontal federated learning algorithm model based on the comparison between the local resume feature information and the feature information of each target job;
[0011] The target positions and position scores of the current client are sent to the server, so that the server obtains similar clients that meet preset similarity conditions with the current client based on the target positions and position scores of the current client, obtains recommended positions from the target positions sent by the similar clients, and sends the recommended positions to the current client.
[0012] In a second aspect of the present invention, a job recommendation method is provided, which is applied to a server of an online recruitment platform. The method comprises:
[0013] Receive the target position and position score sent by the current client; the target position and position score are: after the current client inputs the target position feature information and local resume feature information of each target position into the horizontal federated learning algorithm model pre-trained with the server, the horizontal federated learning algorithm model obtains the position score of each target position output by comparing the local resume feature information with each target position feature information;
[0014] Based on the target position and position score of the current client, similar clients that meet preset similarity conditions with the current client are obtained, recommended positions are obtained from the target positions sent by the similar clients, and the recommended positions are sent to the current client.
[0015] In a third aspect of the present invention, a job recommendation device is provided, which is applied to a current client of an online recruitment platform, and the device comprises:
[0016] A resume feature information acquisition module is used to obtain the resume features specified in the target personal resume of the current client as local resume feature information;
[0017] A job characteristic information acquisition module, used to obtain target jobs browsed by the user through the current client on the online recruitment platform and target job characteristic information of each target job;
[0018] A model input module, for inputting, for each target position, target position feature information of the target position and the local resume feature information into a horizontal federated learning algorithm model pre-trained with the server;
[0019] A job score obtaining module, used to obtain the job score of each target job output by the horizontal federated learning algorithm model based on the comparison between the local resume feature information and the feature information of each target job;
[0020] The target position sending module is used to send the target positions and position scores of the current client to the server, so that the server obtains similar clients that meet the preset similarity conditions with the current client based on the target positions and position scores of the current client, obtains recommended positions from the target positions sent by the similar clients, and returns the recommended positions to the current client.
[0021] In a fourth aspect of the present invention, a job recommendation device is provided, which is applied to a server of an online recruitment platform, and the device comprises:
[0022] The target position receiving module is used to receive the target position and position score of the current client; the target position and position score are: the current client inputs the target position feature information and local resume feature information of each target position into the horizontal federated learning algorithm model pre-trained with the server, and the horizontal federated learning algorithm model obtains the position score of each target position output by comparing the local resume feature information with each target position feature information;
[0023] The recommended job sending module is used to obtain similar clients that meet the preset similarity conditions with the current client based on the target job and job score of the current client, obtain recommended jobs from the target jobs sent by the similar clients, and return the recommended jobs to the current client.
[0024] In another aspect of an embodiment of the present invention, a client device is provided, including a processor, a communication interface, a memory and a communication bus, wherein the memory is used to store computer programs; the processor is used to implement the above-mentioned job recommendation method for the current client of the online recruitment platform when executing the program stored in the memory.
[0025] In another aspect of an embodiment of the present invention, a server is provided, including a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus; the memory is used to store computer programs; and the processor is used to implement the above-mentioned job recommendation method for the server of the online recruitment platform when executing the program stored in the memory.
[0026] The embodiment of the present invention provides a job recommendation method, which obtains the specified resume features from the target personal resume of the current client and uses them as local resume feature information; and obtains the target positions browsed by the user through the corresponding client on the online recruitment platform and the target job feature information of each target position. The target job feature information and the local resume feature information are input into the horizontal federated learning algorithm model pre-trained with the server to obtain the job score for each target position, and then the target positions and job scores of the client are sent to the server, so that the server obtains similar clients that meet the preset similarity conditions with the current client based on the target positions and job scores of the current client, obtains recommended positions from the target positions sent by the similar clients, and sends the recommended positions to the current client.
[0027] By applying the embodiment of the present invention, the server can recommend a position for the current client based on the horizontal federated learning algorithm model that the current client has previously trained with the server, rather than recommending a position based on the resume sent by the client to the server. The current client does not need to send the target resume to the server, and the resume is always saved locally. Therefore, under the premise of effectively protecting personal privacy information, the server finds similar clients that meet the preset similarity conditions with the current client through the target position sent by the client and the score for the target position, obtains recommended positions from the target positions sent by similar clients, and sends the recommended positions to the current client. Of course, implementing any product or method of the present invention does not necessarily require achieving all of the advantages described above at the same time. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other embodiments can be obtained based on these drawings without paying creative work.
[0029] Figure 1 A flow chart of a job recommendation method for a current client of an online recruitment platform provided by an embodiment of the present invention.
[0030] Figure 2 for Figure 1 A training flowchart of the horizontal federated learning algorithm model in the illustrated embodiment.
[0031] Figure 3 for Figure 1 Another training flowchart of the horizontal federated learning algorithm model in the illustrated embodiment.
[0032] Figure 4An example interactive flow chart of a job recommendation method provided in an embodiment of the present invention.
[0033] Figure 5 A flow chart of a job recommendation method for a server of an online recruitment platform provided in an embodiment of the present invention.
[0034] Figure 6 This is a training flowchart of the horizontal federated learning algorithm model in an embodiment of the present invention.
[0035] Figure 7 A schematic diagram of the structure of a job recommendation device for a current client of an online recruitment platform provided by an embodiment of the present invention.
[0036] Figure 8 A schematic diagram of the structure of a job recommendation device for a server of an online recruitment platform provided by an embodiment of the present invention.
[0037] Fig. 9 A schematic diagram of the structure of a client device provided by an embodiment of the present invention.
[0038] Fig.10 A schematic diagram of the structure of a server provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0039] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions 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 are within the scope of protection of the present invention.
[0040] In order to recommend positions to users while ensuring privacy, embodiments of the present invention provide a position recommendation method, apparatus, client device, and server.
[0041] The following first introduces a job recommendation method for a current client of an online recruitment platform provided by an embodiment of the present invention.
[0042] like Figure 1 As shown, Figure 1 The flowchart of the job recommendation method for the current client of the online recruitment platform provided by the embodiment of the present invention may include the following specific steps:
[0043] Step 101, obtaining the resume characteristics specified in the target personal resume of the current client as local resume characteristic information;
[0044] The resume feature specified here can be the field value of the resume field specified in the feature alignment process before the horizontal federated learning algorithm model is trained in the embodiment of the present invention. Among them, the specified resume field can be used as a horizontal federated learning algorithm model variable, and the corresponding field value can be used as an attribute of the horizontal federated learning algorithm model variable. The specific example can be shown in the following table:
[0045] variable property variable property X1 Education X4 gender X2 major X5 Graduate School X3 Work Experience X6 Married
[0046] The current client can receive the resume feature attribute table obtained by the server using feature alignment from the server, and then adjust the target personal resume of the current client according to the resume feature attribute table, and use the resume features in the adjusted resume feature attribute table as local resume feature information.
[0047] Step 102, obtaining target positions browsed by the user through the current client on the online recruitment platform and target position feature information of each target position;
[0048] In this embodiment, the target position characteristic information may correspond to the resume characteristics, and may specifically refer to the specific requirements of the target position, such as: academic requirements, major requirements, school requirements, or work experience requirements.
[0049] Step 103, for each target position, inputting the target position feature information of the target position and the local resume feature information into a horizontal federated learning algorithm model pre-trained with the server;
[0050] For example, the horizontal federated learning algorithm model is: collaborative filtering model.
[0051] Specifically, the target position feature information and the local resume feature information can be converted into vectors according to category feature coding and input into the horizontal federated learning algorithm model for calculation.
[0052] Step 104, obtaining the job score of each target job output by the horizontal federated learning algorithm model based on the comparison between the local resume feature information and the feature information of each target job;
[0053] In this embodiment, the input of the horizontal federated learning algorithm model can be local feature resume information and target position feature information. The horizontal federated learning algorithm model then compares and calculates the local resume feature information with the target position feature information to obtain the similarity value between the local resume feature information and the target position feature information. The similarity value is used as the client's score for the target position. Of course, the similarity value can also be transformed into a value after an integer transformation as the score. The specific setting can be based on actual needs and is not limited here.
[0054] Step 105, sending the target positions and position scores of the current client to the server, so that the server obtains similar clients that meet the preset similarity conditions with the current client based on the target positions and position scores of the current client, obtains recommended positions from the target positions sent by the similar clients, and sends the recommended positions to the current client.
[0055] In this way, after receiving the score for the target position sent by the current client, the server can determine similar clients that meet the preset similarity conditions with the current client based on the target position and the position score of the current client, obtain recommended positions from the target positions sent by the similar clients, and then send the recommended positions to the current client.
[0056] By using the embodiment of the present invention, the current client does not need to send the resume to the server to obtain the position recommended by the server for the resume. The recommended position can be obtained by using the horizontal federated learning algorithm model pre-trained by the current client and the server. Since the resume is always stored locally, the user's personal privacy information is effectively protected.
[0057] based on Figure 1 The embodiment shown. Figure 2 As shown, Figure 2 for Figure 1 A training flow chart of the horizontal federated learning algorithm model in the embodiment shown is trained using the following steps:
[0058] Step 201, obtaining the user's ratings for each pre-specified sample position through the current client;
[0059] In order to train the horizontal federated learning algorithm model, sample data is required. The sample data includes: resume feature information, sample job feature information of sample jobs, and user ratings of each sample job.
[0060] Therefore, the server can first perform feature alignment and send sample positions. Specifically, when the user registers, the server can send the specified resume feature fields and the pre-specified sample positions to the current client, and guide the user to score each sample position.
[0061] Step 202, obtaining job characteristic information of each sample job as sample job characteristic information of each sample job;
[0062] Step 203: Based on the sample position feature information of each sample position and the local resume feature information, the horizontal federated learning algorithm model to be trained is locally trained to obtain the local training parameters of the current client;
[0063] The horizontal federated learning algorithm model can be locally trained based on the sample position feature information of each sample position and the local resume feature information. The obtained local training parameters are the weight number of each feature in the local resume feature.
[0064] When the horizontal federated learning algorithm model is a collaborative filtering model, the obtained local training parameters are the model parameters of the collaborative filtering model.
[0065] Step 204, sending the local training parameters to the server;
[0066] In this way, the server can perform a secure aggregation operation on the local training parameters sent by each client participating in the training to generate updated training parameters. Specifically, the current client can encrypt the local training parameters and send them to the server, so that the server can decrypt the local training parameters sent by each client and perform a secure aggregation operation to generate updated training parameters, and determine whether the horizontal federated learning algorithm model to be trained has converged, and encrypt the updated training parameters and the result of whether it has converged and send them to each client.
[0067] Specifically, the server performs a secure aggregation operation on the local training parameters sent by each client participating in the training to generate updated training parameters, which may include:
[0068] The updated training parameters are calculated according to the following formula:
[0069]
[0070] Among them, n k is the sample job feature information and local resume feature information of the Kth client, n is the sample job feature information and local resume feature information of all clients, is the parameter update value of the Kth client in the t+1th round of iteration, that is, the local training parameter sent by the client to the server in the t+1th round, ω t+1 The updated value of the federated parameter for the server-side iteration in round t+1.
[0071] The step of determining whether the horizontal federated learning algorithm model to be trained has converged includes:
[0072] The loss value is calculated according to the following loss function formula:
[0073] Among them, f i (ω)=l(x i ,y i ,ω), which is the loss value.
[0074] Among them, l(x i ,y i,ω) varies according to the selected model, which can be square loss function, absolute value loss function, 0-1 loss function, logarithmic loss function, etc., n k is the sample job feature information and local resume feature information of the Kth client, n is the sample job feature information and local resume feature information of all clients, P k is the total number of clients participating in the training, x i is the local resume feature information of the i-th client, y i is the score of the target position by the i-th client, and ω is the weight parameter of the local resume feature information. For example, when a logistic regression model is used, the loss function can be a logarithmic function.
[0075] Step 205, receiving updated training parameters and a result of whether convergence is achieved from the server;
[0076] Specifically, the current client receives and decrypts the encrypted updated training parameters and the result of whether convergence is achieved sent by the server.
[0077] Step 206: If the horizontal federated learning algorithm model to be trained converges, the updated training parameters are used as model parameters of the trained horizontal federated learning algorithm model;
[0078] Step 207: If the horizontal federated learning algorithm model to be trained does not converge, the updated training parameters are used as the initial training parameters for local training, and the process returns to step 203. Based on the sample position feature information of each sample position and the local resume feature information, the horizontal federated learning algorithm model to be trained is locally trained to obtain the local training parameters of the current client.
[0079] It can be seen that the training method of the horizontal federated learning algorithm model provided by the embodiment of the present invention realizes the training of the horizontal federated learning algorithm model.
[0080] Figure 3 for Figure 1 Another training flow chart of the horizontal federated learning algorithm model in the embodiment shown. Figure 2 Based on the process shown, before obtaining the user's ratings of each pre-specified sample position through the current client in step 201, the current client may further perform the following steps:
[0081] Step 301, receiving the designated sample job characteristics sent by the server;
[0082] Step 302, after feature alignment between the terminals, obtain the specified resume feature fields and field values from the target personal resume as the specified resume features.
[0083] Among them, feature alignment between terminals can be achieved based on privacy intersection technology, which can be achieved in the following two ways:
[0084] The first method is implemented through a third-party privacy server:
[0085] Each terminal sends its own resume features to a third-party privacy server, which calculates the intersection of the resume features of each terminal and returns the resume features in the intersection of the resume features to each terminal as aligned features. Each terminal retains the feature fields after feature alignment locally. In this way, feature alignment between terminals is achieved.
[0086] The second method: each terminal directly performs feature alignment operation on the resume features so that each client obtains the correct resume feature intersection, and each terminal retains the feature fields after feature alignment locally.
[0087] It can be seen that when the horizontal federated learning algorithm model starts to be trained, the current client can obtain resume features and sample positions by applying the embodiment of the present invention.
[0088] As a specific implementation of the embodiment of the present invention, Figure 4 This is an interactive flow chart of the job recommendation method, which can be implemented through the following steps.
[0089] The method consists of two stages: model training stage and job recommendation stage. Figure 4 In the process, steps 401 to 408 are the model training stage, and steps 409 to 411 are the job recommendation stage. Figure 4 :
[0090] First, the current client (i.e. Figure 4 There are two clients shown in FIG. 1 , client 1 and client 2. In actual applications, there are many clients participating in model training, which are only illustrated here. Steps 401 to 405 are performed respectively.
[0091] Step 401, the current client determines the common resume features through feature alignment as local resume feature information;
[0092] Step 402, obtaining the scores of the current client for each pre-specified sample position;
[0093] Step 403, obtaining the job characteristic information of each sample job as the sample job characteristic information of each sample job;
[0094] Step 404: input the sample job feature information of each sample job and the local resume feature information into the horizontal federated learning algorithm model for local training to obtain the local training parameters of the current client;
[0095] Step 405a, encrypting the local training parameters;
[0096] Step 405b, sending the encrypted parameters to the server;
[0097] Step 406a, the server performs a secure aggregation operation on the local training parameters sent by each client participating in the training, generates updated training parameters, and determines whether the horizontal federated learning algorithm model to be trained has converged;
[0098] Step 406b, sending the updated training parameters and the result of whether the model has converged to the current client;
[0099] After receiving the updated training parameters and the result of whether the training has converged, each client executes steps 407 to 410 respectively.
[0100] Step 407: If the model does not converge, the current client decrypts the parameters and performs a new round of training;
[0101] Step 408, when the model converges, obtain the target positions browsed by the current client on the online recruitment platform and target position feature information of each target position;
[0102] Step 409: Each client uses the trained horizontal federated learning algorithm model to compare the local resume feature information with the feature information of each target position to obtain a score for each target position;
[0103] Step 410, sending the score of the target position to the server;
[0104] Step 411a, the server obtains similar clients that meet a preset similarity condition with the current client based on the target job and job score of the current client, and obtains recommended jobs from the target jobs sent by the similar clients;
[0105] Step 411b, sending the recommended positions to the current client.
[0106] By applying the embodiment of the present invention, the server can recommend a position for the current client based on the horizontal federated learning algorithm model that the current client has previously trained with the server, rather than recommending a position based on the resume sent by the client to the server. The current client does not need to send the target resume to the server, and the resume is always saved locally. Therefore, under the premise of effectively protecting personal privacy information, the server finds similar clients that meet the preset similarity conditions with the current client through the target positions sent by the client and the scores for the target positions, obtains recommended positions from the target positions sent by the similar clients, and sends the recommended positions to the current client.
[0107] Figure 5 The flowchart of the job recommendation method for a server of an online recruitment platform provided in an embodiment of the present invention may include the following specific steps:
[0108] Step 501, receiving the target position and position rating sent by the current client;
[0109] The target position and position score are: for each target position, the current client inputs the target position feature information and local resume feature information of the target position into the horizontal federated learning algorithm model pre-trained with the server, and the horizontal federated learning algorithm model obtains the position score of each target position output by comparing the local resume feature information with each target position feature information. The position score of the target position output by the horizontal federated learning algorithm model can be the similarity value between the local resume feature information and the target position feature information obtained by comparing and calculating the local resume feature information with the target position feature information by the horizontal federated learning algorithm model. Among them, the horizontal federated learning algorithm model can be: a collaborative filtering model.
[0110] Step 502, based on the target position and position score of the current client, obtaining similar clients that meet a preset similarity condition with the current client;
[0111] Specifically, it can be: obtaining the first model parameters of the horizontal federated learning algorithm model corresponding to the current client; obtaining multiple second model parameters of multiple other horizontal federated learning algorithm models that have been trained; the other horizontal federated learning algorithm models are: horizontal federated learning algorithm models trained jointly by multiple other clients and servers that do not include the current client.
[0112] The model parameter difference between the first model parameter and each second model parameter is calculated, and the horizontal federated learning algorithm model with the smallest model parameter difference is used as a similar algorithm model; and each other client participating in the training of the similar algorithm model is used as a similar client. Specifically, the difference or ratio between the first model parameter and each second model parameter can be calculated, and the horizontal federated learning algorithm model with the smallest model parameter difference is determined based on the difference or ratio.
[0113] Step 503: Obtain recommended positions from the target positions sent by similar clients, and send the recommended positions to the current client.
[0114] Specifically, target positions with scores higher than a preset threshold among similar clients may be returned to the current client as recommended positions.
[0115] By applying the embodiment of the present invention, the server can recommend a position for the current client based on the horizontal federated learning algorithm model that the current client has previously trained with the server, rather than recommending a position based on the resume sent by the client to the server. The current client does not need to send the target resume to the server, and the resume is always saved locally. Therefore, under the premise of effectively protecting personal privacy information, the server finds similar clients that meet the preset similarity conditions with the current client through the target positions sent by the client and the scores for the target positions, obtains recommended positions from the target positions sent by the similar clients, and sends the recommended positions to the current client.
[0116] Figure 6 This is a training flow chart of the horizontal federated learning algorithm model in an embodiment of the present invention, and the training is performed using the following steps:
[0117] Step 601, receiving local training parameters sent by each client participating in the training;
[0118] For example, receiving encrypted local training parameters sent by each client participating in the training; the local training parameters are: each client participating in the training obtains the local training of the horizontal federated learning algorithm model to be trained based on the sample position feature information of each specified sample position and the local resume feature information after each client participating in the training performs local training; the clients participating in the training include the current client.
[0119] Step 602, performing a secure aggregation operation on the local training parameters sent by each client participating in the training to generate updated training parameters;
[0120] The local training parameters sent by each client participating in the training can be decrypted and then securely aggregated to generate updated training parameters. The server calculates the updated training parameters according to the following formula:
[0121]
[0122] Among them, n k is the sample job feature information and local resume feature information of the Kth client, n is the sample job feature information and local resume feature information of all clients, is the parameter update value of the Kth client in the t+1th round of iteration, that is, the local training parameter sent by the client to the server in the t+1th round, ω t+1 The updated value of the federated parameter for the server-side iteration in round t+1.
[0123] Step 603, determine whether the horizontal federated learning algorithm model to be trained has converged; send the updated training parameters and the result of whether it has converged to each client participating in the training.
[0124] The server can calculate the loss value according to the following loss function formula:
[0125] Among them, f i (ω)=l(x i ,y i ,ω), i.e., the loss value, l(x i ,y i ,ω) varies according to the selected model, which can be square loss function, absolute value loss function, 0-1 loss function, logarithmic loss function, etc., n k is the sample job feature information and local resume feature information of the Kth client, n is the sample job feature information and local resume feature information of all clients, P k For all clients participating in training, x i is the local resume feature information of the i-th client, y i is the score of the target position by the i-th client, and ω is the weight parameter of the local resume feature information. For example, when a logistic regression model is used, the loss function can be a logarithmic function.
[0126] Then, it is determined whether the horizontal federated learning algorithm model to be trained has converged based on the loss value. Specifically, it is determined whether the horizontal federated learning algorithm model to be trained has converged when the loss value is less than a preset threshold.
[0127] The server can encrypt the updated training parameters and the results of whether convergence has occurred and send them to each client, so that each client participating in the training can receive and decrypt the encrypted updated training parameters and the results of whether convergence has occurred and sent by the server.
[0128] When the horizontal federated learning algorithm model to be trained converges, each client participating in the training uses the updated training parameters as the model parameters of the trained horizontal federated learning algorithm model; and when the horizontal federated learning algorithm model to be trained does not converge, the updated training parameters are used as the initial training parameters for local training, and the next round of local training is performed on the horizontal federated learning algorithm model to be trained, and the local training parameters of each client participating in the training are obtained and sent to the server.
[0129] It can be seen that the application of the embodiments of the present invention can realize the training of the horizontal federated learning algorithm model.
[0130] As a specific implementation of the embodiment of the present invention, before the step of receiving local training parameters sent by each client participating in the training, it also includes: sending designated sample job features to each client participating in the training.
[0131] It can be seen that the embodiment of the present invention solves the problem of providing resume features and sample positions for users.
[0132] Secondly, the embodiment of the present invention also provides a structural diagram of a job recommendation device for a current client of an online recruitment platform, such as Figure 7 The device comprises:
[0133] The resume feature information obtaining module 701 is used to obtain the resume features specified in the target personal resume of the current client as local resume feature information;
[0134] The job characteristic information acquisition module 702 is used to obtain the target job and target job characteristic information of each target job that the user has browsed on the online recruitment platform through the current client;
[0135] A model input module 703 is used to input, for each target position, the target position feature information and the local resume feature information of the target position into a horizontal federated learning algorithm model pre-trained with the server;
[0136] A job score obtaining module 704 is used to obtain the job score of each target job output by the horizontal federated learning algorithm model based on the comparison between the local resume feature information and the feature information of each target job;
[0137] The target position sending module 705 is used to send the target positions and position scores of the current client to the server, so that the server obtains similar clients that meet the preset similarity conditions with the current client based on the target positions and position scores of the current client, obtains recommended positions from the target positions sent by the similar clients, and returns the recommended positions to the current client.
[0138] In the embodiment of the present invention, the current client does not need to send the personal resume to the server to obtain the position recommended by the server for the personal resume. It only needs to input the target position feature information and local resume feature information of the target position into the horizontal federated learning algorithm model pre-trained with the server through the model input module, obtain the position score of each target position by the position scoring module, and finally receive the recommended position based on the position score of each target position sent by the target position sending module. Since the personal resume is always saved locally, effective protection of personal privacy information is achieved.
[0139] In addition, the embodiment of the present invention also provides a structural diagram of a job recommendation device applied to a server of an online recruitment platform, such as Figure 8 The device comprises:
[0140] The target position receiving module 801 is used to receive the target position and position score of the current client; the target position and position score are: the current client inputs the target position feature information and local resume feature information of each target position into the horizontal federated learning algorithm model pre-trained with the server, and the horizontal federated learning algorithm model obtains the position score of each target position by comparing the local resume feature information with each target position feature information.
[0141] The recommended job sending module 802 is used to obtain similar clients that meet the preset similarity conditions with the current client based on the target job and job score of the current client, obtain recommended jobs from the target jobs sent by the similar clients, and return the recommended jobs to the current client.
[0142] By applying the embodiment of the present invention, the server can recommend a job for the current client through a recommended job sending module based on the horizontal federated learning algorithm model that the current client has previously trained with the server, rather than recommending a job based on the personal resume sent by the client to the server. The current client does not need to send the target personal resume to the server, and the personal resume is always saved locally. Therefore, under the premise of effectively protecting personal privacy information, the server receives the target job and the score for the target job sent by the client through the target job receiving module, finds similar clients that meet the preset similarity conditions with the current client, obtains recommended jobs from the target jobs sent by similar clients, and sends the recommended jobs to the current client.
[0143] Finally, an embodiment of the present invention provides a client device, such as Fig. 9As shown, it includes a processor 901, a communication interface 902, a memory 903 and a communication bus 904, wherein the processor 901, the communication interface 902, and the memory 903 communicate with each other through the communication bus 904;
[0144] Memory 903, used for storing computer programs;
[0145] The processor 901 is used to implement the following steps when executing the program stored in the memory:
[0146] Obtain the resume characteristics specified in the target personal resume of the current client as local resume characteristic information;
[0147] Obtain target positions browsed by the user through the current client on the online recruitment platform and target position feature information of each target position;
[0148] For each target position, input the target position feature information of the target position and the local resume feature information into a horizontal federated learning algorithm model pre-trained with the server;
[0149] Obtaining the job score of each target job output by the horizontal federated learning algorithm model based on the comparison between the local resume feature information and the feature information of each target job;
[0150] The target positions and position scores of the current client are sent to the server, so that the server obtains similar clients that meet preset similarity conditions with the current client based on the target positions and position scores of the current client, obtains recommended positions from the target positions sent by the similar clients, and sends the recommended positions to the current client.
[0151] The embodiment of the present invention further provides an electronic device, such as Fig.10 As shown, it includes a processor 1001, a communication interface 1002, a memory 1003 and a communication bus 1004, wherein the processor 1001, the communication interface 1002, and the memory 1003 communicate with each other through the communication bus 1004.
[0152] Memory 1003, used for storing computer programs;
[0153] The processor 1001 is used to execute the program stored in the memory 1003, and implements the following steps:
[0154] Receive the target position and position score of the current client; the target position and position score are: after the current client inputs the target position feature information and local resume feature information of each target position into the horizontal federated learning algorithm model pre-trained with the server, the horizontal federated learning algorithm model obtains the position score of each target position output by comparing the local resume feature information with each target position feature information;
[0155] Based on the target position and position score of the current client, similar clients that meet preset similarity conditions with the current client are obtained, recommended positions are obtained from the target positions sent by the similar clients, and the recommended positions are sent to the current client.
[0156] The communication bus mentioned in the above electronic device can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.
[0157] The communication interface is used for communication between the above electronic device and other devices.
[0158] The memory may include a random access memory (RAM) or a non-volatile memory (NVM), such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.
[0159] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0160] In another embodiment of the present invention, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program is executed by a processor, the steps of any of the above methods are implemented.
[0161] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented by software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present invention is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state hard disk Solid State Disk (SSD)), etc.
[0162] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0163] Each embodiment in this specification is described in a related manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0164] The above description is only a preferred embodiment of the present invention and is not intended to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention are included in the protection scope of the present invention.
Claims
1. A job recommendation method, characterized in that: The current client is applied to an online recruitment platform, and the online recruitment platform also includes a server. The method includes: Obtaining the resume features specified in the target personal resume of the current client as local resume feature information; the local resume feature information is the common resume features determined by the current client through feature alignment; the resume features are the field values of the resume fields; Obtain target positions browsed by the user through the current client on the online recruitment platform and target position feature information of each target position; For each target position, input the target position feature information of the target position and the local resume feature information into a horizontal federated learning algorithm model pre-trained with the server; Obtaining the job score of each target job output by the horizontal federated learning algorithm model based on the comparison between the local resume feature information and the target job feature information; the job score of the target job output by the horizontal federated learning algorithm model is: the horizontal federated learning algorithm model compares and calculates the local resume feature information with the target job feature information, and obtains the similarity value between the local resume feature information and the target job feature information; The target positions and position scores of the current client are sent to the server, so that the server obtains the first model parameters of the horizontal federated learning algorithm model corresponding to the current client based on the target positions and position scores of the current client, and obtains multiple second model parameters of multiple other horizontal federated learning algorithm models that have been trained, wherein the other horizontal federated learning algorithm models are: horizontal federated learning algorithm models trained jointly by multiple other clients excluding the current client and the server, calculate the model parameter difference between the first model parameter and each second model parameter, take the horizontal federated learning algorithm model with the smallest model parameter difference as the similar algorithm model, take each other client participating in the training of the similar algorithm model as a similar client, and return the target positions with scores higher than a preset threshold among the similar clients to the current client.
2. The method according to claim 1, characterized in that The horizontal federated learning algorithm model is trained using the following steps: Obtaining the user's ratings of each pre-specified sample position through the current client; Obtaining job characteristic information of each sample job as sample job characteristic information of each sample job; Based on the sample position feature information of each sample position and the local resume feature information, locally train the horizontal federated learning algorithm model to be trained to obtain the local training parameters of the current client; Sending the local training parameters to the server, so that the server performs a secure aggregation operation on the local training parameters sent by each client participating in the training, generates updated training parameters, and determines whether the horizontal federated learning algorithm model to be trained converges, and sends the updated training parameters and the result of whether it converges to each client; Receive the updated training parameters and convergence results sent by the server; If the horizontal federated learning algorithm model to be trained converges, the updated training parameters are used as model parameters of the trained horizontal federated learning algorithm model; If the horizontal federated learning algorithm model to be trained does not converge, the updated training parameters are used as the initial training parameters for local training, the sample position feature information based on the sample positions and the local resume feature information are returned, the horizontal federated learning algorithm model to be trained is locally trained, and the local training parameters of the current client are obtained.
3. The method according to claim 2, characterized in that Before the step of obtaining the user's ratings of each pre-specified sample position through the current client, the method further includes: Receiving the designated sample job characteristics sent by the server; After feature alignment is performed between the terminals, the specified resume feature fields and field values are obtained from the target personal resume as the specified resume features.
4. The method according to claim 2, characterized in that: The step of sending the local training parameters to the server so that the server performs a secure aggregation operation on the local training parameters sent by each client participating in the training, generates updated training parameters, and determines whether the horizontal federated learning algorithm model to be trained converges, and sends the updated training parameters and the result of whether convergence to each client participating in the training, includes: The local training parameters are encrypted and sent to the server, so that the server decrypts the local training parameters sent by each client and performs a secure aggregation operation to generate updated training parameters, and determines whether the horizontal federated learning algorithm model to be trained converges, and encrypts the updated training parameters and the result of whether it converges and sends them to each client; The step of receiving the updated training parameters and the result of whether the training parameters have converged sent by the server includes: Receive the encrypted updated training parameters and convergence results sent by the server and decrypt them.
5. The method according to claim 1, characterized in that: The horizontal federated learning algorithm model is: collaborative filtering model.
6. A job recommendation method, characterized in that: The method is applied to a server of an online recruitment platform, wherein the online recruitment platform also includes a plurality of clients. Receive the target position and position score sent by the current client; the target position and position score are: the current client inputs the target position feature information and local resume feature information of each target position into the horizontal federated learning algorithm model pre-trained with the server, and the horizontal federated learning algorithm model obtains the position score of each target position output by comparing the local resume feature information with each target position feature information; the local resume feature information is the common resume feature determined by the current client through feature alignment; the position score of the target position output by the horizontal federated learning algorithm model is: the horizontal federated learning algorithm model compares and calculates the local resume feature information with the target position feature information, and obtains the similarity value between the local resume feature information and the target position feature information; the resume feature is the field value of the resume field; Based on the target position and position score of the current client, obtain the first model parameter of the horizontal federated learning algorithm model corresponding to the current client; obtain multiple second model parameters of multiple other horizontal federated learning algorithm models that have been trained; the other horizontal federated learning algorithm models are: horizontal federated learning algorithm models trained jointly by multiple other clients and servers that do not include the current client; calculate the model parameter difference between the first model parameter and each second model parameter, and take the horizontal federated learning algorithm model with the smallest model parameter difference as the similar algorithm model; take each other client participating in the training of the similar algorithm model as a similar client; return the target position with a score higher than a preset threshold among similar clients to the current client.
7. The method according to claim 6, characterized in that The horizontal federated learning algorithm model is trained using the following steps: Receive local training parameters sent by each client participating in the training; the local training parameters are obtained by each client participating in the training after performing local training on the horizontal federated learning algorithm model to be trained based on the sample position feature information of each designated sample position and the local resume feature information; the clients participating in the training include the current client; Perform secure aggregation operations on the local training parameters sent by each client participating in the training to generate updated training parameters; Determining whether the horizontal federated learning algorithm model to be trained has converged; The updated training parameters and the results of whether they have converged are sent to each client participating in the training, so that when the horizontal federated learning algorithm model to be trained converges, each client participating in the training uses the updated training parameters as the model parameters of the trained horizontal federated learning algorithm model, and when the horizontal federated learning algorithm model to be trained does not converge, uses the updated training parameters as the initial training parameters of local training, performs the next round of local training on the horizontal federated learning algorithm model to be trained, obtains the local training parameters of each client participating in the training and sends them to the server.
8. The method according to claim 7, characterized in that Before the step of receiving the local training parameters sent by each client participating in the training, the method further includes: Send the specified sample job features to each client participating in the training.
9. The method according to claim 7, characterized in that: The step of receiving local training parameters sent by each client participating in the training includes: receiving encrypted local training parameters sent by each client participating in the training; The step of performing a secure aggregation operation on the local training parameters sent by each client participating in the training to generate updated training parameters includes: Decrypt the local training parameters sent by each client participating in the training and perform secure aggregation operations to generate updated training parameters; The step of sending the updated training parameters and the result of whether the training has converged to each client participating in the training includes: The updated training parameters and the result of whether convergence are encrypted and sent to each client, so that each client participating in the training receives and decrypts the encrypted updated training parameters and the result of whether convergence are sent by the server.
10. The method according to claim 7, characterized in that The server performs a security aggregation operation on the local training parameters sent by each client participating in the training to generate updated training parameters, including: The updated training parameters are calculated according to the following formula: in, For the The sample job feature information and local resume feature information of the client, n is the sample job feature information and local resume feature information of all clients, For the The parameter update value of the client in the t+1th round of iteration, The updated value of the federated parameter iterated on the server side in round t+1; The step of determining whether the horizontal federated learning algorithm model to be trained has converged includes: The loss value is calculated according to the following loss function formula: ,in, Represents the loss value corresponding to the i-th sample position of the client, is the total number of clients participating in the training, is the weight parameter of local resume feature information; Based on the loss value, it is determined whether the horizontal federated learning algorithm model to be trained has converged.
11. The method according to any one of claims 6 to 10, characterized in that: The horizontal federated learning algorithm model is: collaborative filtering model.
12. A job recommendation device, characterized in that: The current client is applied to an online recruitment platform, which also includes a server. The device includes: A resume feature information acquisition module, used to obtain the resume features specified in the target personal resume of the current client as local resume feature information; the local resume feature information is the common resume features determined by the current client through feature alignment; the resume features are the field values of the resume fields; A job characteristic information acquisition module, used to obtain target jobs browsed by the user through the current client on the online recruitment platform and target job characteristic information of each target job; A model input module, for inputting, for each target position, target position feature information of the target position and the local resume feature information into a horizontal federated learning algorithm model pre-trained with the server; A job score obtaining module is used to obtain the job score of each target job output by the horizontal federated learning algorithm model based on the comparison between the local resume feature information and each target job feature information; the job score of the target job output by the horizontal federated learning algorithm model is: the horizontal federated learning algorithm model compares and calculates the local resume feature information with the target job feature information, and obtains the similarity value between the local resume feature information and the target job feature information; A target position sending module is used to send the target positions and position scores of the current client to the server, so that the server obtains the first model parameters of the horizontal federated learning algorithm model corresponding to the current client based on the target positions and position scores of the current client, and obtains multiple second model parameters of multiple other horizontal federated learning algorithm models that have been trained. The other horizontal federated learning algorithm models are: horizontal federated learning algorithm models trained jointly by multiple other clients excluding the current client and the server, calculate the model parameter difference between the first model parameter and each second model parameter, take the horizontal federated learning algorithm model with the smallest model parameter difference as the similar algorithm model, take each other client participating in the training of the similar algorithm model as a similar client, and return the target positions with scores higher than a preset threshold among the similar clients to the current client.
13. A job recommendation device, characterized in that: A server applied to an online recruitment platform, the online recruitment platform also includes multiple clients, and the device includes: A target position receiving module is used to receive the target position and position score of the current client; the target position and position score are: the current client inputs the target position feature information and local resume feature information of each target position into the horizontal federated learning algorithm model pre-trained with the server, and the horizontal federated learning algorithm model obtains the position score of each target position based on the comparison between the local resume feature information and each target position feature information; the local resume feature information is the common resume feature determined by the current client through feature alignment; the position score of the target position output by the horizontal federated learning algorithm model is: the horizontal federated learning algorithm model compares and calculates the local resume feature information with the target position feature information, and obtains the similarity value between the local resume feature information and the target position feature information; the resume feature is the field value of the resume field; A recommended job sending module is used to obtain the first model parameter of the horizontal federated learning algorithm model corresponding to the current client based on the target job and job score of the current client; obtain multiple second model parameters of multiple other horizontal federated learning algorithm models that have been trained; the other horizontal federated learning algorithm models are: horizontal federated learning algorithm models trained jointly by multiple other clients and servers that do not include the current client; calculate the model parameter difference between the first model parameter and each second model parameter, and take the horizontal federated learning algorithm model with the smallest model parameter difference as a similar algorithm model; take each other client participating in the training of the similar algorithm model as a similar client; return the target job with a score higher than a preset threshold among similar clients to the current client.
14. A client device, characterized in that: It includes a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, for implementing any of the methods described in claims 1-5 when executing a program stored in a memory.
15. A server, characterized in that it includes a processor, a communication interface, a memory and a communication bus, wherein: The processor, the communication interface, and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, for implementing any of the methods described in claims 6-11 when executing a program stored in a memory.
16. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method described in any one of claims 1-5 or 6-11 is implemented.
