Sorting model training methods and sorting methods
By combining a multi-objective network model and a multilayer perceptron, the ranking position bias is eliminated, and the trained ranking model can accurately reflect the value of information. This solves the problem of high time cost for users to obtain valuable information in existing technologies and improves the user experience.
Patent Information
- Application Number
- CN202111676612.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-31
- Publication Date
- 2026-03-06
- Estimated Expiration
- 2042-03-06
AI Technical Summary
Existing ranking model training methods cannot accurately reflect the value of information to users, resulting in high time costs for users to obtain valuable information and poor user experience.
By combining a multi-objective network model and a multilayer perceptron, the scores of training samples are determined, eliminating ranking bias. The resulting ranking model can more accurately reflect the value of information to users.
It improves the accuracy of information sorting, reduces the time cost for users to obtain valuable information, and enhances the user experience.
Smart Images

Figure CN114330752B_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of information processing technology, specifically relating to a sorting model training method and a sorting method. Background Technology
[0002] With the rapid development of the internet, the amount of online information is also increasing. Therefore, before pushing multiple pieces of information to a user's terminal device, or after multiple service backends push various types of information to a user's terminal device, it is necessary to use a sorting model to sort this information so that the user can view it.
[0003] Currently, the main training method for ranking models is to use users' historical feedback information as information sample labels to train the ranking model. However, information ranked higher in the historical ranking has a higher probability of being clicked and viewed by users due to its ranking advantage, while information ranked lower in the historical ranking has a lower probability of being clicked and viewed by users due to its ranking disadvantage. This makes the trained ranking model unable to accurately reflect the value of information to users. Therefore, in related technologies, the time cost for users to obtain information that is valuable to them is high, resulting in a poor user experience. Summary of the Invention
[0004] The purpose of this application is to provide a ranking model training method and a ranking method that can solve the problems of high time cost and poor user experience required for users to obtain valuable information.
[0005] In a first aspect, embodiments of this application provide a method for training a ranking model, the method comprising:
[0006] Obtain target information and its corresponding historical ranking position to generate training samples;
[0007] A first score and a second score are determined using a multi-objective network model, wherein the first score is the score corresponding to the existence of a sorting position deviation in the sorting, and the second score is the score corresponding to the absence of the sorting position deviation in the sorting.
[0008] Using a multilayer perceptron, the third score value corresponding to the training sample is determined based on the historical sorting position, wherein the third score value is the score value corresponding to the sorting position deviation;
[0009] Based on the first score, the second score, and the third score, the multi-objective network model is trained to obtain the ranking model.
[0010] Secondly, embodiments of this application provide a sorting method, the method comprising:
[0011] Obtain N pieces of information corresponding to a first user, wherein the first user is the user corresponding to the terminal device receiving the N pieces of information;
[0012] The ranking model is used to eliminate the predicted ranking position deviation of the N pieces of information, and the information score value corresponding to each piece of information is obtained. The ranking model is trained based on a multi-objective network model and a multilayer perceptron.
[0013] Based on the information score corresponding to each piece of information, the N pieces of information are sorted and the sorted N pieces of information are displayed.
[0014] Where N is a positive integer and N≥2.
[0015] Thirdly, embodiments of this application provide a ranking model training apparatus, the apparatus comprising:
[0016] The sample generation module is used to obtain target information and its corresponding historical sorting position to generate training samples;
[0017] The first determining module is used to determine the first score and the second score corresponding to the training sample using a multi-objective network model, wherein the first score is the score corresponding to the existence of a sorting position deviation in the sorting, and the second score is the score corresponding to the absence of the sorting position deviation in the sorting.
[0018] The second determining module is used to determine the third score value corresponding to the training sample based on the historical sorting position using a multilayer perceptron, wherein the third score value is the score value corresponding to the sorting position deviation.
[0019] The model training module is used to train the multi-objective network model based on the first score, the second score, and the third score to obtain the ranking model.
[0020] Fourthly, embodiments of this application provide a sorting apparatus, the apparatus comprising:
[0021] The information acquisition module is used to acquire N pieces of information corresponding to a first user, wherein the first user is the user corresponding to the terminal device that receives the N pieces of information;
[0022] The bias elimination module is used to eliminate the predicted ranking position bias of the N information using the ranking model, and obtain the information score value corresponding to each information. The ranking model is trained based on a multi-objective network model and a multilayer perceptron.
[0023] The information sorting module is used to sort the N pieces of information according to the information score value corresponding to each piece of information, and display the sorted N pieces of information;
[0024] Where N is a positive integer and N≥2.
[0025] Fifthly, embodiments of this application provide an electronic device including a processor and a memory, the memory storing programs or instructions executable on the processor, the programs or instructions, when executed by the processor, implementing the steps of the method described in the first or second aspect.
[0026] In a sixth aspect, embodiments of this application provide a readable storage medium on which a program or instructions are stored, which, when executed by a processor, implement the steps of the method described in the first or second aspect.
[0027] In a seventh aspect, embodiments of this application provide a chip, the chip including a processor and a communication interface, the communication interface being coupled to the processor, the processor being used to run programs or instructions to implement the methods described in the first or second aspect.
[0028] Eighthly, embodiments of this application provide a computer program product stored in a storage medium, which is executed by at least one processor to implement the method as described in the first or second aspect.
[0029] In this embodiment, a multi-objective network model is used to determine the biased first score and the unbiased second score corresponding to the training samples, and a multilayer perceptron is used to determine the biased third score. Therefore, when training the multi-objective network model using the first, second, and third scores, the model can more accurately determine the second score. This eliminates the bias caused by the historical arrangement of the target information, resulting in a more accurate second score after bias elimination. Thus, the information arrangement order determined based on this second score prioritizes information valuable to the user. This allows the ranking model trained using the method provided in this embodiment to accurately reflect the value of information to the user, effectively reducing the time cost for users to obtain valuable information and improving the user experience. Attached Figure Description
[0030] Figure 1 This is one of the flowcharts illustrating a ranking model training method according to an exemplary embodiment;
[0031] Figure 2 This is a schematic diagram illustrating a model training structure according to an exemplary embodiment;
[0032] Figure 3This is a second flowchart illustrating a sorting model training method according to an exemplary embodiment;
[0033] Figure 4 This is a schematic diagram illustrating a model training improvement structure according to an exemplary embodiment;
[0034] Figure 5 This is a flowchart illustrating a sorting method according to an exemplary embodiment;
[0035] Figure 6 This is a schematic diagram illustrating the sorting of notification bar information in an electronic device according to an exemplary embodiment;
[0036] Figure 7 This is a structural block diagram of a sorting model training apparatus according to an exemplary embodiment;
[0037] Figure 8 This is a structural block diagram of a sorting device according to an exemplary embodiment;
[0038] Figure 9 This is a structural block diagram of an electronic device according to an exemplary embodiment;
[0039] Figure 10 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of this application. Detailed Implementation
[0040] The technical solutions of the embodiments of this application will be clearly described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application are within the scope of protection of this application.
[0041] The terms "first," "second," etc., used in the specification and claims of this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such use of data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein, and the objects distinguished by "first," "second," etc., are generally of the same class and the number of objects is not limited; for example, a first object can be one or more. Furthermore, in the specification and claims, "and / or" indicates at least one of the connected objects, and the character " / " generally indicates that the preceding and following objects are in an "or" relationship.
[0042] The following description, in conjunction with the accompanying drawings, details the sorting model training method and sorting method provided in this application through specific embodiments and application scenarios.
[0043] The ranking model training method and ranking method provided in this application can be applied to scenarios where information received by a user or to be pushed to the user for display needs to be ranked. The information can be, for example, a recommendation message from an application, the content of which includes, but is not limited to, videos, text, and images. This recommendation message can be recommended to specific users as a notification in the device's notification bar.
[0044] With the development of internet technology, users receive an increasing amount of notification information daily, such as from electronic device notifications. This includes functional information like verification codes or bills, as well as push notifications like news feeds or recommended playlists from music apps. While this information facilitates users' lives and broadens their horizons, the imbalance between publishers and receivers is inevitable in the face of this massive amount of information. Low-quality, low-value, and useless information is mixed in with the flood of messages, making it difficult for users to quickly and accurately obtain useful information. For example, music apps push dozens of recommended songs daily, arranged by the time the user receives them. Due to limited time, users may only listen to the first few, missing potentially desirable songs later. The abundance of notifications on electronic devices coupled with limited user engagement time is one of the main contradictions in the internet environment. Currently, almost all notification information is simply sorted by time or alphabetical order, or simply sorted based on historical user feedback, using a model trained on that model. Therefore, it fails to identify, or cannot accurately identify, which information is of higher value to the user.
[0045] Based on this, embodiments of this application provide a sorting model training method and a sorting method.
[0046] Furthermore, the ranking model training method provided in this application can be executed by a ranking model training device. This ranking model training device can be a server or a terminal device, and is not limited thereto. This application uses the execution of the ranking model training method by a ranking model training device as an example to illustrate the ranking model training method provided in this application.
[0047] Figure 1 This is a flowchart illustrating a sorting model training method according to an exemplary embodiment.
[0048] like Figure 1 As shown, the training method for this ranking model may include steps S110-S140, and each step is explained in detail below.
[0049] S110. Obtain target information and its corresponding historical ranking position, and generate training samples.
[0050] Here, the target information can be any historical information obtained from the historical information log, and the historical sorting position corresponding to the target information can be the sorting position of the target information recorded in the historical information log.
[0051] For example, before model training, multiple pieces of information and their corresponding historical sorting position index values can be obtained by parsing the historical information logs in the background, and multiple training samples can be generated. Each training sample may include a piece of historical information and its corresponding historical sorting position index value, and then the multiple training samples can be used for model training.
[0052] S120. Use a multi-objective network model to determine the first score and the second score corresponding to the training sample, wherein the first score is the score corresponding to the sorting position deviation, and the second score is the score corresponding to the sorting position deviation.
[0053] Here, the multi-objective network model can be, for example, an MMOE (Multi-gate Mixture-of-Experts) model, or an OMOE (One-gate Mixture-of-Experts) model, etc., without limitation. The training objectives of this multi-objective network model can include outputting a biased score (i.e., the first score) that is not reasonable enough, and a more reasonable score after eliminating the bias (i.e., the second score).
[0054] When presenting multiple pieces of information to a user, even if their value is similar, the information displayed first inherently has an advantage and is more likely to attract the user's attention, thus creating a positional bias. In other words, the positional bias in this embodiment can be the difference between an unreasonable ranking and a more reasonable ranking. During model training, the first score determined by the multi-objective network model can be the original score before eliminating the positional bias, while the second score can be the score after eliminating the positional bias.
[0055] S130. Using a multilayer perceptron, determine the third score value corresponding to the training sample based on the historical ranking position, where the third score value is the score value corresponding to the ranking position deviation.
[0056] Here, in this embodiment of the application, an MLP (Multilayer Perceptron) is added as an auxiliary training model during the model training process. This MLP can be used to determine the score corresponding to the prediction bias caused by the historical ranking position, that is, the third score. This third score can be the difference between an unreasonable score and a more reasonable score.
[0057] MLP can continuously separate the third score from the first score during model training, which is caused by the ranking position deviation. This improves the accuracy of the second score output by the multi-objective network model and eliminates the ranking position deviation.
[0058] It should be noted that the execution order between S120 and S130 is not limited; they can be executed simultaneously or S130 can be executed first.
[0059] S140. Based on the first, second, and third scores, train a multi-objective network model to obtain a ranking model.
[0060] For example, the sum of the second and third scores can be used to dynamically equal the first score to train the multi-objective network model, thereby continuously eliminating the bias scores in the second score caused by the ranking position deviation, until the multi-objective network model converges, and the converged multi-objective network model is used as the final ranking model.
[0061] In this way, by using a multi-objective network model to determine the biased first score and the unbiased second score corresponding to the training samples, and using a multilayer perceptron to determine the biased third score, the multi-objective network model can more accurately determine the second score when training with the first, second, and third scores. This eliminates the bias caused by the historical arrangement of the target information, resulting in a more accurate second score after bias elimination. Therefore, the information arrangement order determined based on this second score prioritizes information valuable to the user. This allows the ranking model trained using the method provided in this application to accurately reflect the value of information to the user, effectively reducing the time cost for users to obtain valuable information and improving the user experience.
[0062] In some possible embodiments, the training samples mentioned above may include information features, user features, and scene features corresponding to the target information.
[0063] Based on this, the aforementioned S120 may specifically include:
[0064] The information features, user features, and scene features are input into the multi-objective network model, and the first and second scores corresponding to the training samples are output.
[0065] Here, user features can refer to the characteristics of logged-in users on the terminal devices receiving target information. These user features can include numerical features and profile features. Numerical features include, but are not limited to, features that can be directly represented by continuous values or discrete codes, such as the logged-in user's age, age group, gender, marital status, and income level. Profile features include, but are not limited to, features that require discrete sparse coding, such as the user's interest tags and entity tags. Specifically, profile features include, but are not limited to, the logged-in user's primary and secondary categories, various interest tags, and entities, all of which require discrete sparse coding. Here, profile features can be calculated using either edge-side data or cloud-side data; no limitation is made here to meet the data upload needs of different users.
[0066] For example, user characteristics may include the contents shown in Table 1 below:
[0067] Table 1. User Characteristics
[0068]
[0069] Furthermore, scene features can be the characteristics of the historical scene in which the terminal device was located when recording logs corresponding to the target information. These scene features include, but are not limited to, time and location. Here, scene features can be designed from multiple perspectives, and even a single perspective such as time can be extended to various related features, including both continuous numerical values and discrete codes.
[0070] For example, scene features may include the contents shown in Table 2 below:
[0071] Table 2. Scene Characteristics
[0072]
[0073] Furthermore, information features can be characteristics of the target information itself. Similar to user features, they can also include numerical features, content features, etc. Here, the design of information features can be approached from multiple perspectives. Whether targeting numerical or content features, in various scenarios such as news recommendations, advertising recommendations, system messages, and chat software messages, they can all be mathematically represented from multiple angles.
[0074] For example, information features may include the contents shown in Table 3 below:
[0075] Table 3. Information Characteristics
[0076]
[0077]
[0078]
[0079] It should be noted that information features, user features, and scene features can all be multi-dimensional vector features, and no restrictions are imposed here.
[0080] For example, such as Figure 2 As shown, during model training using training samples, the user features 41, information features 42, and scene features 43 corresponding to the training samples can be input into the MMOE base model 45. The MMOE base model 45 can output two target values: the first target value is the original score 451 (denoted as init_logit, with a value range of -inf to +inf), which is the first score. This score has a positional bias, and the results of sorting based on this score are usually not reasonable. The second target value is the score 452 after eliminating the positional bias (denoted as raw_logit, with a value range of -inf to +inf), which is the second score. This score does not have a positional bias, and the results of sorting based on this score are usually more reasonable.
[0081] By using the three dimensions of information features, user features, and scene features as input features during the training of the multi-objective network model, the model can learn the value of target information to users more comprehensively. This allows the final ranking model to more accurately assess the value of each piece of information to different users, thereby improving the effectiveness and reliability of model training.
[0082] In addition, in some implementations, the training samples may also include position index values corresponding to the historical sorting positions.
[0083] Based on this, the aforementioned S130 may specifically include:
[0084] The scene features and location index values are input into the multilayer perceptron, and the output is the third score value corresponding to the training sample.
[0085] Here, in this embodiment of the application, the index value of the historical sorting position of each piece of information can also be recorded by embedding points. For example, the index value of the first position is 0, the index value of the second position is 1, etc.
[0086] For example, a log can be recorded when the user's device receives information. The log content may include the information identifier, user identifier, information content, information reception time, device location, and sorting position index. Additionally, a log can be recorded when the user clicks to view information. In addition to the above content, the log content may also include user feedback information and feedback time. The information identifier can be the ID encoding of the information itself, and the user identifier can be the IMEI encoding of the user's device. Alternatively, it can be a unique identifier such as the user account logged into the device; no limitation is imposed here.
[0087] Based on this, the input features of the multilayer perceptron can include two categories: the first category is the location index value, and the second category is the scene features, specifically including the feature content shown in Table 4 below:
[0088] Table 4. Input features of the multilayer perceptron
[0089]
[0090] Using MLP as a supplementary model, the output of this model can be single-objective, that is, predicting the bias score (denoted as bias_logit, with a value range of -inf to +inf) caused by the positional deviation of the target information in the training samples, which is also the third score. The larger this value is, the greater the advantage that the information at that sorting position index value gains due to the positional deviation. In other words, the earlier the information is, the higher the probability that the user will click on it, even if the information is not necessarily high-value information for the user.
[0091] For example, such as Figure 2 As shown, during the model training process using training samples, the sorting position index value 44 and scene features corresponding to the training samples can also be input into the MLP supplementary model 46. The MLP supplementary model 46 can output the bias score 461 (bias_logit) of the target information due to the sorting position deviation.
[0092] In this way, by using the two dimensions of sorting position index value and scene features as input features during MLP training, the MLP can learn more deeply about the impact of different user scenarios on information value during training. As a result, the final trained MLP can more accurately extract the positional deviation score of different information based on the user's scenario, thereby further improving the effectiveness and reliability of model training.
[0093] Furthermore, based on the above S110-S140, in some possible embodiments, the training samples may include user feedback information corresponding to the target information. For example... Figure 3 As shown, the above S140 may specifically include the following steps:
[0094] S1401. Add the second score to the third score to get the fourth score;
[0095] S1402. Determine the loss value based on the first score, the fourth score, and user feedback.
[0096] S1403. Adjust the model parameters of the multi-objective network model and the multilayer perceptron based on the loss value until the multi-objective network model converges to obtain the ranking model.
[0097] Here, this embodiment of the application can also collect user feedback information when receiving target information by recording historical information logs. User feedback information can include positive feedback and negative feedback; positive feedback, for example, is that the user clicked to view the information, while negative feedback is that the user did not click to view the information.
[0098] In a specific example, taking the application recommendation information received by the notification bar of a user's electronic device as an example, after a message is displayed on the screen, three results will be generated based on the user's behavior, as shown in Table 5 below:
[0099] Table 5. User Behavior and Sample Type
[0100]
[0101] Thus, in this embodiment of the application, positive samples and negative samples can be constructed based on user feedback information as training samples.
[0102] For example, such as Figure 2 As shown, after obtaining three scores from the MMOE base model 45 and the MLP supplementary model 46 respectively, raw_logit can be added to the bias score 461 (bias_logit) output by the MLP supplementary model 46 to obtain the original score 455 (denoted as new_logit, with a value range of -inf to +inf), which is the fourth score. After obtaining these scores, they can be normalized. For example, performing a sigmoid operation on init_logit can transform it into the original probability value 453 (denoted as pCtr_init, with a value range of 0 to 1), and performing a sigmoid operation on new_logit can transform it into the original probability value 456 (denoted as pCtr_new, with a value range of 0 to 1). Then, using pCtr_init and pCtr_new, as well as the user feedback information in the training sample, the loss value can be calculated.
[0103] Specifically, when the user feedback is positive, the sample label can be set to 1. In this case, the parameters of the two models can be adjusted by calculating the loss value so that pCtr_init and pCtr_new approach 1 infinitely. When the user feedback is negative, the sample label can be set to 0. In this case, the parameters of the two models can be adjusted by calculating the loss value so that pCtr_init and pCtr_new approach 0 infinitely.
[0104] Furthermore, since the training structures of the two targets in the MMOE base model 45 are exactly the same, the summed score new_logit will be approximately equal to init_logit, that is, pCtr_init and pCtr_new are approximately equal.
[0105] In this way, by determining the loss value based on the first and fourth scores and user feedback, the model parameters of the multi-objective network model and the multilayer perceptron can be adjusted. The converged multi-objective network model can then be used as the final ranking model, enabling the ranking model to output a more accurate score after eliminating positional bias. This reduces the impact of positional bias when using the ranking model to rank information, thereby improving the accuracy of information ranking and ensuring that the information needed by the user is placed first.
[0106] In one alternative implementation, S1401 may specifically include:
[0107] The fourth score is determined based on the second score, the third score, and the influence parameter; the influence parameter is used to characterize the degree of influence of the third score on the fourth score.
[0108] In this embodiment, to control the impact of positional deviation score on the final score, an adjustable influence parameter (denoted as γ, with a value range of 0 to +inf) is introduced. The specific value can be adjusted in advance according to the actual situation. Specifically, the fourth score can be calculated using the following formula:
[0109] new_logit=raw_logit*[1+γ*sigmoid(bias_logit)]
[0110] Among them, new_logit is the fourth score, raw_logit is the second score, and bias_logit is the third score.
[0111] For example, such as Figure 4As shown, this embodiment of the application introduces an influence parameter γ to reduce the influence of the positional bias score to a level at most equal to γ. For example, when γ = 0.2, the influence of bias_logit can be reduced to 0.2. During the training of the neural network model, if the number of training samples is insufficient, it can easily lead to poor performance of the MLP supplementary model, i.e., the bias score bias_logit is inaccurate. In this case, if there is an influence parameter γ as a control, this adverse effect can be reduced, and the accuracy of the entire information ranking training process can be improved.
[0112] Thus, by introducing an influence parameter, the impact of the third score on the fourth score can be controlled. This reduces the influence of the MLP supplementary model output on the final result when the number of training samples is insufficient, thereby further improving the accuracy of the model training process.
[0113] To further reduce the impact of positional deviation on the prediction of future sorting positions, in an optional implementation, prior to S1402 above, the sorting method provided in this application embodiment may further include:
[0114] Obtain the fifth score value corresponding to the training sample; where the fifth score value is the posterior probability value of receiving positive feedback from the user when the target information is located in the historical ranking position;
[0115] Accordingly, the above S1402 may specifically include:
[0116] Add the first score to the fifth score to get the sixth score, and add the fourth score to the fifth score to get the seventh score;
[0117] The target loss value is determined based on the sixth and seventh score values, as well as user feedback.
[0118] Here, the posterior probability value of receiving positive user feedback when each piece of historical information is located in its corresponding historical ranking position can be obtained as the advantage score, which is also the fifth score.
[0119] For example, such as Figure 2 As shown, for both pCtr_init and pCtr_new, in order to further eliminate positional bias, they need to be added to the advantage score 471 (denoted as p_system_ctr, with a value range of 0 to 1) corresponding to the historical information in the current training sample. This is equivalent to introducing real-time positional bias statistics to participate in the model training, further eliminating the influence of positional bias in the model.
[0120] Thus, by introducing a fifth score to participate in the model training, the final output can further take into account the bias caused by the historical ranking position, thereby further eliminating the position bias-related factors in the ranking model during the training process.
[0121] In one optional implementation, obtaining the fifth score corresponding to the training sample includes:
[0122] An initial data table is established based on the information identifier, user identifier, user feedback information, location index value, and target attribute value corresponding to multiple pieces of information recorded in the historical information log; wherein, the target attribute value is one or more attribute values included in the scene features;
[0123] The data in the initial data table is aggregated based on the location index value and the target attribute value to obtain the aggregation result;
[0124] Based on the aggregation results, the information corresponding to different location index values and target attribute values is calculated to obtain the posterior probability value of positive user feedback, and the posterior attention rate data table is obtained.
[0125] The target information is obtained from the posterior attention rate data table. When the target information is located in the historical ranking position under the corresponding target attribute value, the posterior probability value of positive user feedback is obtained and used as the fifth score.
[0126] Here, the fifth score can be data obtained through a table lookup, based on which a posterior attention rate data table can be pre-built. The target attribute values can be, for example, the values of time and / or location attributes.
[0127] For example, historical information logs can be used to obtain the information ID encoding of all training samples, the corresponding user's IMEI encoding, the sorting position index, user feedback information after display, and the time and location of log recording. Storing this data table on a backend server allows for filtering of the required sample subset according to different rules. This subset is used to calculate the average click-through rate (PTR) of a notification message across all users on the network under different sorting position indices, i.e., the posterior probability value, under specific conditions. Specifically, the rule used in this embodiment can be: filtering the data in the initial data table corresponding to the historical information logs using the input features corresponding to the auxiliary bias model as the filtering condition.
[0128] In a specific example, taking the filtering criteria as the sorting position index value and the time value in the scene features, the initial data table can be as shown in Table 6 below:
[0129] Table 6. Initial Data Table
[0130] serial number Information ID User imei Click time Sort position 1 A a yes on Monday 9 2 B b no on Monday 2 3 A c yes on Monday 5 4 B d no Tuesday 3 5 A e yes Tuesday 9 6 A f no on Monday 9 7 B g yes Tuesday 3
[0131] As shown in Table 6, there are two pieces of information, A and B, which appeared in different sorting positions at different times and were interacted with by different users. If we need to calculate the average click-through rate of these two pieces of information, we first need to filter the corresponding data based on the input features of the auxiliary deviation model, that is, aggregate the data table according to material ID, time, and sorting position. The aggregation results are shown in Table 7.
[0132] Table 7. Aggregated Data Table
[0133]
[0134] Therefore, after statistically aggregating the data table, the click-through rates of the two historical information entries can be categorized into the following five types:
[0135] Information A, Monday, average click-through rate at position 5 = 1 / 1 = 1.0
[0136] Information A, Monday, average click-through rate at position 9 = 1 / 2 = 0.5
[0137] Information A, Tuesday, average click-through rate at position 9 = 1 / 1 = 1.0
[0138] Information B, Monday, average click-through rate at position 2 = 0 / 1 = 0.0
[0139] Information B, Tuesday, average click-through rate at position 3 = 1 / 2 = 0.5
[0140] As can be seen, the posterior attention rate data table added in this application embodiment is obtained by filtering, aggregating, and statistically analyzing the data table to obtain the posterior click-through rate of each historical information at different sorting positions, i.e., the advantage score (denoted as p_system_ctr, with a value range of 0 to 1). Similar to the bias score, the larger this value is, the greater the advantage of the information at that sorting position receiving positive feedback from users.
[0141] For example, if the training sample is message A pushed on Monday, and message A is currently ranked at position 9, then when using this training sample for model training, one can obtain information from... Figure 2 The advantage score 471 corresponding to the information is obtained from the posterior attention rate data table 47 shown, and is added to the original probability value 453 and the original probability value 456 corresponding to the information respectively. The loss value is then calculated using the summed value to adjust the model parameters.
[0142] Thus, by establishing a posterior attention rate data table, it is easy to query the average click-through rate of each piece of information under specific conditions and under different sorting positions, thereby further eliminating positional bias during the training process.
[0143] In summary, the embodiments of this application, through the following... Figure 2 The model training structure shown can decompose the original positional bias score init_logit into two parts: the positional bias-free score raw_logit and the positional bias score bias_logit. When it is necessary to sort information, such as sorting the notification bar information of electronic devices, it is only necessary to take out the positional bias-free score raw_logit and process it with sigmoid to obtain the positional bias-free probability 454 (denoted as pCtr_better, with a value range of 0 to 1). This probability value is more accurate than the original probability 453pCtr_init and can obtain the sorting result after eliminating positional bias.
[0144] Based on the ranking model trained using the above-described ranking model training method, this application also provides a ranking method. The executing entity of this ranking method can be a ranking device. This ranking device can be a server or a terminal device, and is not limited thereto. This application uses the execution of the ranking method by a ranking device as an example to illustrate the ranking method provided by this application. The following describes the ranking method in conjunction with... Figure 5 Please provide a detailed explanation.
[0145] Figure 5 This is a flowchart illustrating a sorting method according to an exemplary embodiment.
[0146] like Figure 5 As shown, the sorting method may include the following steps S510-S530, each of which is explained in detail below.
[0147] S510. Obtain N pieces of information corresponding to the first user, wherein the first user is the user corresponding to the terminal device receiving the N pieces of information.
[0148] Here, the N pieces of information can be multiple pieces of information received by the terminal device used by the first user, which may include previously received information and / or currently received information. N is a positive integer, and N≥2. For example... Figure 6 As shown, these N messages can be pushed to the notification bar of an electronic device by multiple applications. Users can swipe down to bring up the notification bar and see the received messages. Each time the terminal device used by the first user receives a new message, the unread messages on the terminal device can be sorted.
[0149] S520. Use a ranking model to eliminate the predicted ranking position deviation of N pieces of information and obtain the information score value corresponding to each piece of information. The ranking model is trained based on a multi-objective network model and a multilayer perceptron.
[0150] Here, the ranking model in this embodiment can be a trained multi-objective network model, such as an MMOE (Modeling Task Relationships in Multi-task Learning with Multi-gate Mixture-of-Experts) model. This ranking model can be trained using the ranking model training method described in the preceding embodiments; that is, a multilayer perceptron is used as an auxiliary training model to train the multi-objective network model. This ranking model can rank and score each piece of information based on its corresponding features, outputting a score value for each piece of information. This score value can, to some extent, reflect the probability that the information is of interest to the user.
[0151] Unlike traditional sorting models, the sorting model in this application embodiment can eliminate the predicted sorting position deviation corresponding to each piece of information. As a result, the output information score can include the score after removing the deviation score caused by the sorting position, so that the value of the score is the value of the information itself to the first user.
[0152] Additionally, it should be noted that in the embodiments of this application, the output of the ranking model can be multi-objective, for example, the output can be two-objective, that is, the score output by the ranking model can include two kinds of values.
[0153] Based on this, in some implementations, the above-mentioned information score may include the original score and the debiased score; wherein, the original score is the score for which the sorting has a predicted sorting position deviation, and the debiased score is the score for which the sorting does not have a predicted sorting position deviation.
[0154] Thus, in the final sorting process, the final information sorting process can be carried out based on the debiased score, or it can be carried out by combining the original score and the debiased score, without any limitation.
[0155] S530. Sort the N pieces of information according to the information score corresponding to each piece of information, and display the sorted N pieces of information.
[0156] In this embodiment of the application, the score output by the ranking model corresponding to each piece of information can be the value of predicting positive user feedback for that information. Usually, it is necessary to normalize the value, for example, by using the sigmoid function f(x) = 1 / (1+exp(-x)) to process the value so that it becomes a value between 0 and 1. At this time, the probability of positive user feedback predicted by the model can be obtained, which can be used as a reference value when ranking.
[0157] For example, N pieces of information can be sorted in descending order of their normalized scores, with the larger scores ranking higher and the smaller scores ranking lower, thus obtaining N sorted pieces of information, which can then be displayed to the user in this order.
[0158] In this way, by using a ranking model trained on a multi-objective network model and a multilayer perceptron, each piece of information out of N pieces of information is scored, thereby eliminating the prediction ranking position deviation corresponding to each piece of information. This eliminates the prediction deviation caused by the arrangement position of each piece of information, and obtains a more accurate score value after eliminating the deviation. Thus, the information arrangement order determined based on the score value can arrange the information that is useful to the user first, thereby reducing the cost for the user to obtain useful information and improving the user experience.
[0159] In some implementations, the above-mentioned S420 may specifically include:
[0160] Obtain the information features, first user features, and first scene features corresponding to N pieces of information respectively; wherein, the first user features are the user features of the first user, and the first scene features are the scene features of the scene in which the terminal device is located;
[0161] Each of the N information features is associated with the first user feature and the first scenario feature respectively, resulting in N associated features;
[0162] The N associated features are input into the ranking model, and the ranking model is used to eliminate the prediction ranking position deviation corresponding to each piece of information. The output is the information score value corresponding to each piece of information.
[0163] Here, the first user characteristic can be the user characteristic corresponding to the first user logged in on the terminal device. The first scenario characteristic can be the scenario characteristic of the scenario in which the terminal device is located when the resource sorting process is triggered. The specific contents included in each characteristic can be found in the relevant descriptions above, and will not be repeated here.
[0164] For example, each of the N information features can be combined with the first user feature and the first scenario feature to generate N associated features. Each associated feature is then used as an input feature to the ranking model. This ranking model comprehensively scores the value of each piece of information to the first user from multiple dimensions, including information content, user profile, and scenario, while eliminating potential biases in the predicted ranking position of each piece of information, thus obtaining the information score for each piece of information.
[0165] In this way, by using information features, user features, and scenario features as input features for the ranking model, the ranking model can score each piece of information from multiple feature dimensions, thereby improving the accuracy of the output information score values and obtaining a more accurate information arrangement order.
[0166] In some embodiments, where the information score includes both the original score and the debiased score, S530 may specifically include:
[0167] The original scores and the debiased scores are weighted and summed to obtain the weighted scores corresponding to each piece of information.
[0168] Based on the weighted score corresponding to each piece of information, sort the N pieces of information and display the sorted N pieces of information.
[0169] Here, before sorting the information, both the original scores and the debiased scores can be considered. Specifically, the original scores and the debiased scores can be weighted and summed according to the following formula:
[0170] P1_old=w1*pCtr_init+w2*pCtr_better
[0171] Wherein, P1_old is the weighted score, pCtr_init is the normalized original score, pCtr_better is the normalized debiased score, and w1 and w2 are the weights. The specific values of these two weights can be adjusted online according to the actual situation.
[0172] In this way, by taking into account both the original score and the debiased score when sorting information, the information sorting method used in related technologies can be smoothly transitioned from sorting based on the original score to sorting based on the debiased score. This avoids large fluctuations in the sorting results when using a sorting model based on the debiased score to replace a sorting model based on the original score, which would otherwise affect the user experience.
[0173] In one optional implementation, the above-mentioned weighted summation of the original score and the debiased score to obtain a weighted score corresponding to each piece of information includes:
[0174] The debiased score is used as the dominant score, and a weighted sum is performed with the original score to obtain the weighted score corresponding to each piece of information.
[0175] In this embodiment of the application, in order to increase the influence of the debiased score on the final calculated weighted score, the normalized debiased score can be taken as the dominant value and moved outside the parentheses in the linear weighted summation formula. Specifically, the weighted summation can be performed according to the following formula:
[0176] P1_new=pCtr_better*(w1+w2*pCtr_init)
[0177] Where P1_new is the weighted score.
[0178] In this way, by prioritizing the deviation score and placing it outside the parentheses in the linear weighted sum formula, outlier values can be brought back to normal levels, preventing the final ranking from being affected by extreme cases and thus improving the stability of the information ranking results. Furthermore, the deviation score better reflects the value of information to the user than the original score; therefore, considering the deviation score more when calculating weighted scores can also improve the accuracy of information ranking and avoid the influence of ranking position deviations.
[0179] Furthermore, in some implementations, the above-mentioned sorting of N pieces of information based on the weighted score corresponding to each piece of information, and displaying the sorted N pieces of information, includes:
[0180] The initial order of the N pieces of information is determined based on the weighted score corresponding to each piece of information.
[0181] Based on the initial arrangement order, determine the initial sorting position index value corresponding to each of the N pieces of information;
[0182] Based on the initial sorting position index value corresponding to each piece of information, obtain the posterior probability value corresponding to each piece of information from the posterior attention rate data table;
[0183] Subtract the posterior probability value from the weighted score to obtain the final score corresponding to each piece of information.
[0184] Sort the N pieces of information according to the final score corresponding to each piece of information, and display the sorted N pieces of information.
[0185] Here, in order to further eliminate the advantage score caused by positional bias during the use of the model, before sorting the information, the average click rate of information under the same conditions and the same sorting position can be obtained by querying the posterior attention rate data table. Then, this advantage score can be deducted from the weighted score, which is the final score of the information.
[0186] For example, the information can first be sorted according to its weighted score P1_new. This yields the sorting position index pos for each piece of information, which is a priori value. Then, the dominance score p_system_ctr is obtained by querying the posterior attention rate data table. Subtracting this dominance score from the former gives the final score for that information. The formula for calculating the final score is as follows:
[0187] P = P1_new - p_system_ctr(pos)
[0188] Where P is the final score, and p_system_ctr(pos) represents the advantage score. p_system_ctr is the value obtained by looking up the table based on the sort position index pos.
[0189] Thus, since the final score takes into account the original model probability pCtr_init, the location probability modeled separately pCtr_better, and the posterior probability p_system_ctr statistically obtained from the actual logs, it is possible to sort the information more reasonably.
[0190] Based on the same inventive concept, this application also provides a sorting model training device. The following is in conjunction with... Figure 7 The sorting model training device provided in the embodiments of this application will be described in detail.
[0191] Figure 7 This is a structural block diagram of a sorting model training device according to an exemplary embodiment.
[0192] like Figure 7 As shown, the ranking model training device 700 may include:
[0193] The sample generation module 701 is used to obtain target information and its corresponding historical sorting position to generate training samples.
[0194] The first determining module 702 is used to determine the first score and the second score corresponding to the training sample using a multi-objective network model, wherein the first score is the score corresponding to the sorting position deviation, and the second score is the score corresponding to the sorting position deviation not being present.
[0195] The second determining module 703 is used to determine the third score value corresponding to the training sample based on the historical sorting position using a multilayer perceptron, wherein the third score value is the score value corresponding to the sorting position deviation.
[0196] The model training module 704 is used to train the multi-objective network model based on the first score, the second score, and the third score to obtain a ranking model.
[0197] The ranking model training device 700 described above is explained in detail below:
[0198] In some embodiments, the training samples include information features, user features, and scene features corresponding to the target information;
[0199] The first determining module 702 includes:
[0200] The first output submodule is used to input the information features, the user features, and the scene features into the multi-objective network model, and output the first score and the second score corresponding to the training sample.
[0201] In some embodiments, the training samples further include a position index value corresponding to the historical sorting position;
[0202] The second determining module 703 includes:
[0203] The second output submodule is used to input the scene features and the location index value into the multilayer perceptron and output a third score value corresponding to the training sample.
[0204] In some embodiments, the training samples include user feedback information corresponding to the target information;
[0205] The model training module 704 includes:
[0206] The fraction addition submodule is used to add the second fraction value to the third fraction value to obtain the fourth fraction value;
[0207] The loss determination submodule is used to determine the loss value based on the first score, the fourth score, and the user feedback information.
[0208] The parameter adjustment submodule is used to adjust the model parameters of the multi-objective network model and the multilayer perceptron based on the loss value, until the multi-objective network model converges to obtain the ranking model.
[0209] In some embodiments, the model training module 704 further includes:
[0210] The score acquisition submodule is used to acquire the fifth score corresponding to the training sample before determining the loss value based on the first score value, the fourth score value, and the user feedback information; wherein, the fifth score value is the posterior probability value of obtaining positive user feedback when the target information is located in the historical ranking position;
[0211] The loss determination submodule includes:
[0212] The fraction addition unit is used to add the first fraction value to the fifth fraction value to obtain the sixth fraction value, and to add the fourth fraction value to the fifth fraction value to obtain the seventh fraction value;
[0213] The loss determination unit is used to determine the loss value based on the sixth score, the seventh score, and the user feedback information.
[0214] In some embodiments, the score acquisition submodule includes:
[0215] The data table creation unit is used to create an initial data table based on the information identifier, user identifier, user feedback information, location index value, and target attribute value corresponding to multiple pieces of information recorded in the historical information log; wherein, the target attribute value is one or more attribute values included in the scene features;
[0216] A data aggregation unit is used to aggregate the data in the initial data table based on the location index value and the target attribute value to obtain an aggregation result;
[0217] The probability calculation unit is used to calculate the information corresponding to different location index values and target attribute values under different aggregation results to obtain the posterior probability value of positive user feedback and obtain the posterior attention rate data table.
[0218] The score acquisition unit is used to obtain the posterior probability value of positive user feedback when the target information is located in the historical ranking position under the corresponding target attribute value condition from the posterior attention rate data table, and use it as the fifth score value.
[0219] In some embodiments, the fraction addition submodule includes:
[0220] The score determination unit is used to determine a fourth score based on the second score, the third score, and the influence parameter; wherein the influence parameter is used to characterize the degree of influence of the third score on the fourth score.
[0221] In this way, by using a multi-objective network model to determine the biased first score and the unbiased second score corresponding to the training samples, and using a multilayer perceptron to determine the biased third score, the multi-objective network model can more accurately determine the second score when training with the first, second, and third scores. This eliminates the bias caused by the historical arrangement of the target information, resulting in a more accurate second score after bias elimination. Therefore, the information arrangement order determined based on this second score prioritizes information valuable to the user. This allows the ranking model trained using the method provided in this application to accurately reflect the value of information to the user, effectively reducing the time cost for users to obtain valuable information and improving the user experience.
[0222] Based on the same inventive concept, this application also provides a sorting device. The following is in conjunction with... Figure 8 The sorting apparatus provided in the embodiments of this application will be described in detail.
[0223] Figure 8 This is a structural block diagram of a sorting device according to an exemplary embodiment.
[0224] like Figure 8 As shown, the sorting device 800 may include:
[0225] The information acquisition module 801 is used to acquire N pieces of information corresponding to a first user, wherein the first user is the user corresponding to the terminal device that receives the N pieces of information;
[0226] The bias elimination module 802 is used to eliminate the predicted ranking position bias of the N information using the ranking model, and obtain the information score value corresponding to each information respectively. The ranking model is trained based on a multi-objective network model and a multilayer perceptron.
[0227] The information sorting module 803 is used to sort the N pieces of information according to the information score value corresponding to each piece of information, and display the sorted N pieces of information;
[0228] Where N is a positive integer and N≥2.
[0229] The sorting device 800 described above will be explained in detail below:
[0230] In some embodiments, the deviation elimination module 802 includes:
[0231] The feature acquisition submodule is used to acquire information features, first user features, and first scene features corresponding to the N pieces of information respectively; wherein, the first user feature is the user feature of the first user, and the first scene feature is the scene feature of the scene in which the terminal device is located;
[0232] The feature association submodule is used to associate each of the N information features with the first user feature and the first scene feature respectively, to obtain N associated features;
[0233] The information scoring module is used to input the N associated features into the ranking model, use the ranking model to eliminate the prediction ranking position deviation corresponding to each piece of information, and output the information score value corresponding to each piece of information.
[0234] In some embodiments, the information score includes an original score and a debiased score; wherein, the original score is the score for sorting with the predicted sorting position deviation, and the debiased score is the score for sorting without the predicted sorting position deviation.
[0235] The information sorting module 803 includes:
[0236] The weighted summation submodule is used to perform a weighted summation on the original score value and the debiased score value to obtain a weighted score value corresponding to each piece of information.
[0237] The information sorting submodule is used to sort the N pieces of information according to the weighted score value corresponding to each piece of information, and display the sorted N pieces of information.
[0238] In some embodiments, the weighted summation submodule includes:
[0239] The dominant summation unit is used to take the debiased score as the dominant score and perform a weighted summation with the original score to obtain the weighted score corresponding to each piece of information.
[0240] In some embodiments, the information sorting submodule includes:
[0241] The sequence determination unit is used to determine the initial arrangement order of the N pieces of information based on the weighted score value corresponding to each piece of information.
[0242] An initial arrangement unit is used to determine the initial sorting position index value corresponding to each of the N pieces of information according to the initial arrangement order;
[0243] The probability query unit is used to obtain the posterior probability value corresponding to each piece of information from the posterior attention rate data table based on the initial sorting position index value corresponding to each piece of information.
[0244] The final determination unit is used to subtract the posterior probability value from the weighted score value to obtain the final score value corresponding to each piece of information.
[0245] The final sorting unit is used to sort the N pieces of information according to the final score value corresponding to each piece of information, and to display the sorted N pieces of information.
[0246] In this way, by using a ranking model trained on a multi-objective network model and a multilayer perceptron, each piece of information out of N pieces of information is scored, thereby eliminating the prediction ranking position deviation corresponding to each piece of information. This eliminates the prediction deviation caused by the arrangement position of each piece of information, and obtains a more accurate score value after eliminating the deviation. Thus, the information arrangement order determined based on the score value can arrange the information that is useful to the user first, thereby reducing the cost for the user to obtain useful information and improving the user experience.
[0247] The sorting model training device and sorting device in the embodiments of this application can be electronic devices or components in electronic devices, such as integrated circuits or chips. The electronic device can be a terminal or other devices besides a terminal. For example, the electronic device can be a mobile phone, tablet computer, laptop computer, handheld computer, in-vehicle electronic device, mobile internet device (MID), augmented reality (AR) / virtual reality (VR) device, robot, wearable device, ultra-mobile personal computer (UMPC), netbook or personal digital assistant (PDA), etc. It can also be a server, network attached storage (NAS), personal computer (PC), television (TV), ATM or self-service machine, etc. The embodiments of this application do not specifically limit the scope.
[0248] The ranking model training device and ranking device in the embodiments of this application can be devices with an operating system. The operating system can be Android, iOS, or other possible operating systems, and this application embodiment does not specifically limit them.
[0249] The sorting model training device and sorting device provided in this application embodiment can achieve Figures 1 to 6 The various processes implemented in the method implementation examples will not be described again here to avoid repetition.
[0250] Optionally, such as Figure 9As shown, this application embodiment also provides an electronic device 900, including a processor 901 and a memory 902. The memory 902 stores a program or instructions that can run on the processor 901. When the program or instructions are executed by the processor 901, they implement the various steps of the above-described sorting model training method or sorting method embodiment and can achieve the same technical effect. To avoid repetition, they will not be described again here.
[0251] It should be noted that the electronic devices in the embodiments of this application include the mobile electronic devices and non-mobile electronic devices described above.
[0252] Figure 10 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of this application.
[0253] The electronic device 1000 includes, but is not limited to, components such as: radio frequency unit 1001, network module 1002, audio output unit 1003, input unit 1004, sensor 1005, display unit 1006, user input unit 1007, interface unit 1008, memory 1009, and processor 1010.
[0254] Those skilled in the art will understand that the electronic device 1000 may also include a power supply (such as a battery) for supplying power to various components. The power supply may be logically connected to the processor 1010 through a power management system, thereby enabling functions such as managing charging, discharging, and power consumption through the power management system. Figure 10 The electronic device structure shown does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown, or combine certain components, or have different component arrangements, which will not be elaborated here.
[0255] In some embodiments of the ranking model training method provided in this application:
[0256] The processor 1010 is used to acquire target information and its corresponding historical ranking position, and generate training samples; determine a first score and a second score corresponding to the training samples using a multi-objective network model, wherein the first score is the score corresponding to the existence of a ranking position deviation, and the second score is the score corresponding to the absence of the ranking position deviation; determine a third score corresponding to the training samples based on the historical ranking position using a multilayer perceptron, wherein the third score is the score corresponding to the ranking position deviation; and train the multi-objective network model based on the first score, the second score, and the third score to obtain a ranking model.
[0257] In this way, by using a multi-objective network model to determine the biased first score and the unbiased second score corresponding to the training samples, and using a multilayer perceptron to determine the biased third score, the multi-objective network model can more accurately determine the second score when training with the first, second, and third scores. This eliminates the bias caused by the historical arrangement of the target information, resulting in a more accurate second score after bias elimination. Therefore, the information arrangement order determined based on this second score prioritizes information valuable to the user. This allows the ranking model trained using the method provided in this application to accurately reflect the value of information to the user, effectively reducing the time cost for users to obtain valuable information and improving the user experience.
[0258] Optionally, the processor 1010 is further configured to input the information features, the user features, and the scene features into the multi-objective network model, and output the first score and the second score corresponding to the training sample.
[0259] Optionally, the processor 1010 is further configured to input the scene features and the location index value into the multilayer perceptron and output a third score value corresponding to the training sample.
[0260] Optionally, the processor 1010 is further configured to add the second score to the third score to obtain a fourth score; determine a loss value based on the first score, the fourth score, and the user feedback information; and adjust the model parameters of the multi-objective network model and the multilayer perceptron based on the loss value until the multi-objective network model converges to obtain the ranking model.
[0261] Optionally, the processor 1010 is further configured to obtain a fifth score corresponding to the training sample; wherein the fifth score is the posterior probability value of obtaining positive user feedback when the target information is located at the historical ranking position; add the first score to the fifth score to obtain a sixth score, and add the fourth score to the fifth score to obtain a seventh score; and determine a loss value based on the sixth score and the seventh score, and the user feedback information.
[0262] Optionally, the processor 1010 is further configured to establish an initial data table based on information identifiers, user identifiers, user feedback information, location index values, and target attribute values corresponding to multiple pieces of information recorded in historical information logs; wherein the target attribute values are one or more attribute values included in the scene features; aggregate the data in the initial data table according to the location index values and the target attribute values to obtain an aggregation result; calculate the posterior probability value of positive user feedback under different conditions of the location index values and the target attribute values according to the aggregation result to obtain a posterior attention rate data table; and obtain the posterior probability value of positive user feedback when the target information is located at the historical sorting position under the corresponding target attribute value conditions from the posterior attention rate data table, as the fifth score value.
[0263] Optionally, the processor 1010 is further configured to determine a fourth score based on the second score, the third score, and the influence parameter; wherein the influence parameter is used to characterize the degree of influence of the third score on the fourth score.
[0264] Thus, by introducing an influence parameter, the impact of the MLP output value on the final result can be reduced, improving the accuracy of the model training process. Furthermore, by introducing a posterior attention rate data table, the fifth score can be retrieved and included in the model training, allowing the final output to further account for biases caused by historical ranking positions. This further eliminates position-biased factors in the ranking model during training, improving the accuracy of the model training process.
[0265] Furthermore, regarding the ranking model training method provided in the embodiments of this application, in some of the embodiments:
[0266] The processor 1010 is configured to acquire N pieces of information corresponding to a first user, wherein the first user is the user corresponding to the terminal device receiving the N pieces of information; eliminate the predicted sorting position deviation of the N pieces of information using a sorting model to obtain an information score value corresponding to each piece of information, wherein the sorting model is trained based on a multi-objective network model and a multilayer perceptron; sort the N pieces of information according to the information score value corresponding to each piece of information, and display the sorted N pieces of information; wherein N is a positive integer and N≥2.
[0267] In this way, by using a ranking model trained on a multi-objective network model and a multilayer perceptron, each piece of information out of N pieces of information is scored, thereby eliminating the prediction ranking position deviation corresponding to each piece of information. This eliminates the prediction deviation caused by the arrangement position of each piece of information, resulting in a more accurate score value after eliminating the deviation. Thus, the information arrangement order determined based on the score value can meet the user's personalized needs, placing the information that is truly useful to the user first, thereby reducing the cost for the user to obtain useful information and improving the user experience.
[0268] Optionally, the processor 1010 is further configured to acquire information features, a first user feature, and a first scene feature corresponding to the N pieces of information respectively; wherein, the first user feature is the user feature of the first user, and the first scene feature is the scene feature of the scene in which the terminal device is located; associate each of the N information features with the first user feature and the first scene feature respectively to obtain N associated features; input the N associated features into the ranking model respectively, use the ranking model to eliminate the predicted ranking position deviation corresponding to each piece of information, and output the information score value corresponding to each piece of information respectively.
[0269] Optionally, the processor 1010 is further configured to perform a weighted summation of the original score and the debiased score to obtain a weighted score corresponding to each piece of information; and to sort the N pieces of information according to the weighted score corresponding to each piece of information, and display the sorted N pieces of information.
[0270] Optionally, the processor 1010 is further configured to use the debiased score as the dominant score and perform a weighted summation with the original score to obtain the weighted score corresponding to each piece of information.
[0271] Optionally, the processor 1010 is further configured to: determine the initial arrangement order of the N pieces of information based on the weighted score value corresponding to each piece of information; determine the initial sorting position index value corresponding to each piece of information among the N pieces of information based on the initial arrangement order; obtain the posterior probability value corresponding to each piece of information from the posterior attention rate data table based on the initial sorting position index value corresponding to each piece of information; subtract the posterior probability value from the weighted score value to obtain the final score value corresponding to each piece of information; and sort the N pieces of information based on the final score value corresponding to each piece of information, and display the sorted N pieces of information.
[0272] In this way, by taking into account both the original score and the debiased score when sorting information, the current information sorting method can be smoothly transitioned from the traditional sorting method based on the original score to the new sorting method based on the debiased score. This avoids large fluctuations in the sorting results when using the new sorting model to replace the traditional sorting model, which would affect the user experience.
[0273] It should be understood that, in this embodiment, the input unit 1004 may include a graphics processing unit (GPU) 10041 and a microphone 10042. The GPU 10041 processes image data of still images or videos obtained by an image capture device (such as a camera) in video capture mode or image capture mode. The display unit 1006 may include a display panel 10061, which may be configured in the form of a liquid crystal display, an organic light-emitting diode, or the like. The user input unit 1007 includes a touch panel 10071 and at least one of other input devices 10072. The touch panel 10071 is also called a touch screen. The touch panel 10071 may include a touch detection device and a touch controller. Other input devices 10072 may include, but are not limited to, physical keyboards, function keys (such as volume control buttons, power buttons, etc.), trackballs, mice, and joysticks, which will not be described in detail here.
[0274] The memory 1009 can be used to store software programs and various data. The memory 1009 may primarily include a first storage area for storing programs or instructions and a second storage area for storing data. The first storage area may store the operating system, application programs or instructions required for at least one function (such as sound playback, image playback, etc.). Furthermore, the memory 1009 may include volatile memory or non-volatile memory, or both. The non-volatile memory may be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory can be random access memory (RAM), static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct memory bus RAM (DRRAM). The memory 1009 in this embodiment includes, but is not limited to, these and any other suitable types of memory.
[0275] The processor 1010 may include one or more processing units; optionally, the processor 1010 integrates an application processor and a modem processor, wherein the application processor mainly handles operations involving the operating system, user interface, and applications, and the modem processor mainly handles wireless communication signals, such as a baseband processor. It is understood that the aforementioned modem processor may also not be integrated into the processor 1010.
[0276] This application also provides a readable storage medium storing a program or instructions. When the program or instructions are executed by a processor, they implement the various processes of the above-described sorting model training method or sorting method embodiment and achieve the same technical effect. To avoid repetition, they will not be described again here.
[0277] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.
[0278] This application embodiment also provides a chip, which includes a processor and a communication interface. The communication interface is coupled to the processor. The processor is used to run programs or instructions to implement the various processes of the above-described sorting model training method or sorting method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be described again here.
[0279] It should be understood that the chip mentioned in the embodiments of this application may also be referred to as a system-on-a-chip, system chip, chip system, or system-on-a-chip, etc.
[0280] This application provides a computer program product, which is stored in a storage medium and executed by at least one processor to implement the various processes of the sorting model training method or sorting method embodiment described above, and can achieve the same technical effect. To avoid repetition, it will not be described again here.
[0281] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element. Furthermore, it should be noted that the scope of the methods and apparatuses in the embodiments of this application is not limited to performing functions in the order shown or discussed, but may also include performing functions substantially simultaneously or in the reverse order, depending on the functions involved. For example, the described methods may be performed in a different order than described, and various steps may be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.
[0282] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a computer software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of this application.
[0283] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.
Claims
1. A ranking model training method, characterized in that, The method comprises the following steps: obtaining target information and a corresponding historical ranking position, generating a training sample, the training sample comprising push information and an index value corresponding to a historical ranking position of the push information, the push information being a video, text or image; determining a first score value and a second score value corresponding to the training sample by using a multi-objective network model, wherein the first score value is a score value corresponding to a ranking position deviation, and the second score value is a score value corresponding to no ranking position deviation; determining a third score value corresponding to the training sample according to the historical ranking position by using a multi-layer perceptron, wherein the third score value is a score value corresponding to the ranking position deviation; training the multi-objective network model based on the first score value, the second score value and the third score value to obtain a ranking model; the training of the multi-objective network model based on the first score value, the second score value and the third score value to obtain a ranking model comprises: training the multi-objective network model based on the sum of the second score value and the third score value and the first score value to obtain a ranking model.
2. The method of claim 1, wherein, The training sample comprises information features, user features and scene features corresponding to the target information; the determination of the first score value and the second score value corresponding to the training sample by using a multi-objective network model comprises: inputting the information features, the user features and the scene features into the multi-objective network model to output the first score value and the second score value corresponding to the training sample.
3. The method of claim 2, wherein, The training sample further comprises a position index value corresponding to the historical ranking position; the determination of the third score value corresponding to the training sample according to the historical ranking position by using a multi-layer perceptron comprises: inputting the scene features and the position index value into the multi-layer perceptron to output the third score value corresponding to the training sample.
4. The method of claim 1, wherein, The training sample comprises user feedback information corresponding to the target information; the training of the multi-objective network model based on the first score value, the second score value and the third score value to obtain a ranking model comprises: adding the second score value and the third score value to obtain a fourth score value; determining a loss value according to the first score value and the fourth score value and the user feedback information; adjusting model parameters of the multi-objective network model and the multi-layer perceptron based on the loss value until the multi-objective network model converges to obtain the ranking model.
5. The method of claim 4, wherein, Before determining the loss value according to the first score value and the fourth score value and the user feedback information, the method further comprises: obtaining a fifth score value corresponding to the training sample; wherein the fifth score value is a posterior probability value of obtaining positive feedback from a user when the target information is in the historical ranking position; the determination of the loss value according to the first score value and the fourth score value and the user feedback information comprises: adding the first score value and the fifth score value to obtain a sixth score value, and adding the fourth score value and the fifth score value to obtain a seventh score value; determining a loss value according to the sixth score value and the seventh score value, and the user feedback information.
6. The method of claim 5, wherein, The fifth score value corresponding to the training sample is obtained by: establishing an initial data table based on information identifiers, user identifiers, user feedback information, position index values and target attribute values corresponding to a plurality of information recorded in a historical information log, wherein the target attribute value is one or more attribute values included in a scene feature; aggregating data in the initial data table according to the position index values and the target attribute values to obtain an aggregation result; calculating a posterior probability value of user positive feedback corresponding to the information under different conditions of the position index values and the target attribute values according to the aggregation result, to obtain a posterior attention rate data table; obtaining, from the posterior attention rate data table, the posterior probability value of user positive feedback when the target information is located at the historical ranking position under the condition of the corresponding target attribute value, as the fifth score value.
7. The method of claim 4, wherein, The fourth score value is obtained by adding the second score value and the third score value, comprising: determining a fourth score value according to the second score value, the third score value and an influence parameter, wherein the influence parameter is used to represent the influence degree of the third score value on the fourth score value.
8. A sorting method characterized by, comprising: obtaining N information corresponding to a first user, wherein the first user is a user corresponding to a terminal device receiving the N information, the N information is information pushed to a notification bar of an electronic device by a plurality of application programs, and the N information is video, text or image; eliminating prediction ranking position deviation of the N information by using a ranking model to obtain information score values corresponding to each information respectively, wherein the ranking model is trained based on a multi-target network model and a multi-layer perceptron in any one of claims 1-7; ranking the N information according to the information score values corresponding to each information respectively, and displaying the ranked N information; wherein N is a positive integer and N≥2.
9. The method of claim 8, wherein, The information score values corresponding to each information are obtained by eliminating prediction ranking position deviation of the N information by using a ranking model, comprising: obtaining information features, first user features and first scene features corresponding to the N information respectively, wherein the first user features are user features of the first user, and the first scene features are scene features of a scene in which the terminal device is located; associating each information feature of the information features of the N information with the first user features and the first scene features respectively to obtain N association features; inputting the N association features into the ranking model respectively, eliminating prediction ranking position deviation corresponding to each information by using the ranking model, and outputting to obtain information score values corresponding to each information respectively.
10. The method of claim 8, wherein, The information score values include original score values and debiased score values; wherein the original score values are score values of ranking with the predicted ranking position bias, and the debiased score values are score values of ranking without the predicted ranking position bias; The ranking of the N information according to the information score values corresponding to each information respectively, and the display of the ranked N information, include: The original score values and the debiased score values are weighted and summed to obtain weighted score values corresponding to each information respectively; The ranking of the N information according to the weighted score values corresponding to each information respectively, and the display of the ranked N information.
11. The method of claim 10, wherein, The weighted score values corresponding to each information respectively are obtained by weighting and summing the original score values and the debiased score values, including: The debiased score values are taken as dominant score values, and the weighted score values corresponding to each information respectively are obtained by weighting and summing the original score values.
12. The method according to claim 10 or 11, characterized in that, The ranking of the N information according to the weighted score values corresponding to each information respectively, and the display of the ranked N information, include: According to the weighted score values corresponding to each information respectively, the initial arrangement order of the N information is determined; According to the initial arrangement order, the initial ranking position index value corresponding to each information in the N information is determined; According to the initial ranking position index value corresponding to each information, the posterior probability value corresponding to each information is obtained from the posterior attention rate data table; The weighted score values are subtracted by the posterior probability values to obtain the final score values corresponding to each information respectively; The ranking of the N information according to the final score values corresponding to each information respectively, and the display of the ranked N information.
13. A ranking model training apparatus, characterized by comprising: Including: A sample generation module is configured to obtain target information and a corresponding historical ranking position, and generate a training sample, wherein the training sample includes a push information and an index value of a corresponding historical ranking position, and the push information is a video, a text or an image; A first determination module is configured to determine a first score value and a second score value corresponding to the training sample by using a multi-target network model, wherein the first score value is a score value corresponding to a ranking position bias, and the second score value is a score value corresponding to no ranking position bias; A second determination module is configured to determine a third score value corresponding to the training sample according to the historical ranking position by using a multi-layer perceptron, wherein the third score value is a score value corresponding to the ranking position bias; A model training module is configured to train the multi-target network model based on the first score value, the second score value and the third score value, and obtain a ranking model. The model training module is specifically configured to train the multi-target network model based on a sum value of the second score value and the third score value and the first score value, and obtain a ranking model.
14. The apparatus of claim 13, wherein, The training sample includes information features, user features and scene features corresponding to the target information; The first determination module includes: The first output sub-module is configured to input the information feature, the user feature, and the scene feature into the multi-objective network model, and output the first score value and the second score value corresponding to the training sample.
15. The apparatus of claim 14, wherein, The training sample further includes a position index value corresponding to the historical ranking position; The second determining module includes: The second output sub-module is configured to input the scene feature and the position index value into the multi-layer perceptron, and output a third score value corresponding to the training sample.
16. The apparatus of claim 13, wherein, The training sample includes user feedback information corresponding to the target information; The model training module includes: The score adding sub-module is configured to add the second score value and the third score value to obtain a fourth score value; The loss determining sub-module is configured to determine a loss value according to the first score value and the fourth score value, and the user feedback information; The parameter adjusting sub-module is configured to adjust model parameters of the multi-objective network model and the multi-layer perceptron based on the loss value, until the multi-objective network model converges, to obtain the ranking model.
17. The apparatus of claim 16, wherein, The score adding sub-module includes: The score determining unit is configured to determine a fourth score value according to the second score value, the third score value, and an influence parameter, wherein the influence parameter is used to represent an influence degree of the third score value on the fourth score value.
18. A sequencing device, characterized in that, It includes: An information acquisition module is configured to acquire N information corresponding to a first user, wherein the first user is a user corresponding to a terminal device receiving the N information, the N information is information pushed to a notification bar of an electronic device by a plurality of application programs, and the N information is video, text, or image; A bias elimination module is configured to eliminate a predicted ranking position bias of the N information by using a ranking model to obtain an information score value corresponding to each information, wherein the ranking model is trained based on a multi-objective network model and a multi-layer perceptron in any one of claims 13-17; An information ranking module is configured to rank the N information according to the information score value corresponding to each information, and display the ranked N information. N is a positive integer, and N≥2.
19. The apparatus of claim 18, wherein, The bias elimination module includes: A feature acquisition sub-module is configured to acquire information features, first user features, and first scene features corresponding to the N information, wherein the first user features are user features of the first user, and the first scene features are scene features of a scene in which the terminal device is located; A feature association sub-module is configured to associate each information feature of the information features of the N information with the first user features and the first scene features respectively to obtain N associated features; An information scoring module is configured to input the N associated features into the ranking model, eliminate a predicted ranking position bias corresponding to each information by using the ranking model, and output an information score value corresponding to each information.
20. An electronic device, comprising: A computer program product comprising a computer readable storage medium having stored thereon a program or instructions which, when executed by a processor, implement the steps of the ranking model training method of any one of claims 1-7 or the ranking method of any one of claims 8-12.
21. A readable storage medium, characterized by, A computer program product comprising a computer readable storage medium having stored thereon a program or instructions which, when executed by a processor, implement the steps of the ranking model training method of any one of claims 1-7 or the ranking method of any one of claims 8-12.
Citation Information
Patent Citations
Model training method and device, electronic equipment and readable storage medium
CN112487283A