| CPC G06F 16/9535 (2019.01) [G06N 5/04 (2013.01); G06N 20/00 (2019.01)] | 20 Claims |

|
1. A method comprising:
selecting a positive sample in a sample set, wherein the sample set comprises the positive sample and negative samples, wherein each of the positive sample and the negative samples comprises n sample features, wherein n>1, and wherein a first feature of each of the n sample features indicates whether a corresponding sample is the positive sample or one of the negative samples;
adding the positive sample to a training set;
calculating sampling probabilities of the negative samples using a preset algorithm based on a first rule, a second rule, or a third rule, wherein the first rule indicates that a sampling probability is negatively correlated with a score difference, wherein the score difference is between a first estimated score of the positive sample and a second estimated score of a current negative sample, wherein the first estimated score represents a positive tendency of the positive sample, and wherein the second estimated score represents a negative tendency of the negative sample, wherein the second rule indicates that the sampling probability is negatively correlated with a vector distance, wherein the vector distance is between a first eigenvector of the positive sample and a second eigenvector of the negative sample, and wherein the first eigenvector is an n-dimensional vector comprising the n sample features of the positive sample, wherein the third rule indicates that the sampling probability is positively correlated with a variation of an indicator, wherein the variation is based on exchanging a first ranking of the positive sample and a second ranking of the negative sample, wherein the first ranking and the second ranking are based on the first estimated score and the second estimated score, and wherein the indicator is a ranking indicator of the positive sample and the negative sample;
selecting a negative sample from the negative samples based on the sampling probabilities by:
dividing the sampling probabilities by a reference value to obtain corrected sampling probabilities of the negative samples, wherein the reference value is a maximum value in the sampling probabilities; and
successively comparing the corrected sampling probabilities with a random number ranging from 0 to 1;
adding the negative sample comprising a corrected sampling probability greater than the random number to the training set;
performing training using the training set to obtain a first recommendation model;
obtaining a recommendation result using the first recommendation model; and
providing, using an input/output (I/O) interface, the recommendation result to a client device for presenting the recommendation result to a user.
|