Item recommendation method and device, computer device, storage medium and program product

CN117408758BActive Publication Date: 2026-09-22TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210782508.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-07-05
Publication Date
2026-09-22
Estimated Expiration
2042-07-05

AI Technical Summary

Benefits of technology

[0040]上述物品推荐方法、装置、计算机设备、存储介质和计算机程序产品中,通过获取与应用平台上的各个批次的物品样本分别对应的采样概率值,并基于各采样概率值,分别在对应批次的各物品样本中进行采样,获得对应批次的第一物品样本集。进而通过获取各批次的第一物品样本集中的各物品样本的样本稳定值,以实现根据样本稳定值,对采样方式进行自适应调整,达到对各批次的第一物品样本集的筛选,得到筛选后的各批次的第二样本集,通过样本稳定值对物品样本的筛选可增强负物品样本的采样精度。进一步基于各批次的第二物品样本集,分批次进行负采样,得到负样本集合,即可以同时采样到多个批次中第二样本集中的负物品样本,得到采样精度更高的负样本集合,而根据负样本集合和正样本集合,可进一步获得采样精度更高训练样本集合,进而利用训练样本集合对初始推荐模型进行训练,以得到训练好的物品推荐模型,再减少模型训练的偏差的同时,提升了对模型的训练效率。最终根据训练好的物品推荐模型,确定出精准度更高的目标推荐物品,在应用平台上对目标推荐物品进行推荐时,提升各目标推荐物品的点击率和转化率。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117408758B_ABST
    Figure CN117408758B_ABST
Patent Text Reader

Abstract

The application relates to an article recommendation method and device, a computer device, a storage medium and a program product. The method relates to big data and comprises the following steps: acquiring sampling probability values of batches of article samples on an application platform respectively, performing sampling on the corresponding batches based on the sampling probability values respectively, and obtaining first article sample sets. Sample stability values of the article samples in the first article sample sets are acquired, sample screening is performed on the first article sample sets based on the sample stability values, and second article sample sets after screening are obtained. Negative sampling is performed on the second article sample sets in batches to obtain a negative sample set, an initial recommendation model is trained according to a training sample set composed of the negative sample set and a positive sample set, a trained article recommendation model is obtained, and target recommended articles are determined according to the article recommendation model. The method can enhance the sampling accuracy of negative article samples, reduce the deviation of model training, and determine more accurate target recommended articles.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of big data technology, and in particular to a method, apparatus, computer equipment, storage medium, and program product for recommending items. Background Technology

[0002] With the development of big data technology and the widespread use of various applications and platforms, the massive amounts of business or product information often lead to information overload. Users cannot quickly and accurately obtain the business or products they need. As a result, tools such as recommendation models or recommendation systems have emerged to recommend information to users, such as recommending products, services, and advertisements, so that users can quickly obtain the information they need.

[0003] Traditionally, for products or services across different applications or platforms, the similarity between each user and each product (or service) is calculated to make product (or service) recommendations based on this similarity. However, due to the large number of users and products across different applications or platforms, the number of samples also increases significantly, resulting in massive amounts of training data that cannot be used to train the model. Therefore, training sample sampling is necessary. Since not every user has a corresponding historical query, access, or purchase record, the number of positive samples is usually small, while the number of negative samples (those that have never been queried, accessed, or purchased) is large. Accurate and comprehensive sampling of negative samples plays a particularly important role in training the recommendation model.

[0004] However, the inventors discovered that traditional negative sampling methods typically involve dividing training samples into different batches and then randomly negatively sampling from each batch to obtain the negative sample set. However, due to the memory limitations of GPUs (Graphics Processing Units), the size of each batch during negative sampling cannot exceed the GPU's memory limit. Therefore, traditional random negative sampling methods still suffer from problems such as a small batch size leading to a small number of negative samples, and a large discrepancy between the distribution of the sampled negative samples and the true distribution of negative samples. Inaccurate sample pairs collected can also affect the learning and training of the recommendation model, and the recommendation accuracy of the model still needs improvement. Summary of the Invention

[0005] Therefore, it is necessary to provide an item recommendation method, apparatus, computer equipment, computer-readable storage medium, and computer program product that can enhance the sampling accuracy of negative samples and improve the recommendation accuracy of the trained recommendation model, in order to address the above-mentioned technical problems.

[0006] Firstly, this application provides a method for recommending items. The method includes:

[0007] Obtain the sampling probability values ​​corresponding to each batch of item samples on the application platform;

[0008] Based on the sampling probability values, sampling is performed in each item sample of the corresponding batch to obtain the first item sample set of the corresponding batch;

[0009] Obtain the sample stability value of each item sample in the first item sample set for each batch;

[0010] Based on the sample stability value, the first item sample set of each batch is filtered to obtain the second item sample set of each batch.

[0011] Based on the second item sample set of each batch, negative sampling is performed in batches to obtain a negative sample set, and a training sample set is obtained based on the negative sample set and the positive sample set; the training sample set is used to train the initial recommendation model to obtain a trained item recommendation model.

[0012] Based on the trained item recommendation model, the target recommended item is determined.

[0013] Secondly, this application also provides an item recommendation device. The device includes:

[0014] The sampling probability value acquisition module is used to acquire the sampling probability values ​​corresponding to each batch of item samples on the application platform.

[0015] The first item sample set acquisition module is used to sample each item sample in the corresponding batch based on the sampling probability value to obtain the first item sample set of the corresponding batch.

[0016] The sample stability value acquisition module is used to acquire the sample stability value of each item sample in the first item sample set of each batch;

[0017] The second item sample set acquisition module is used to filter the first item sample set of each batch based on the sample stability value to obtain the second item sample set of each batch after filtering.

[0018] The training sample set acquisition module is used to perform negative sampling in batches based on the second item sample set in each batch to obtain a negative sample set, and to obtain a training sample set based on the negative sample set and the positive sample set; the training sample set is used to train the initial recommendation model to obtain a trained item recommendation model;

[0019] The target recommended item determination module is used to determine the target recommended item based on the trained item recommendation model.

[0020] Thirdly, this application also provides a computer device. The computer device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to perform the following steps:

[0021] Obtain the sampling probability values ​​corresponding to each batch of item samples on the application platform;

[0022] Based on the sampling probability values, sampling is performed in each item sample of the corresponding batch to obtain the first item sample set of the corresponding batch;

[0023] Obtain the sample stability value of each item sample in the first item sample set for each batch;

[0024] Based on the sample stability value, the first item sample set of each batch is filtered to obtain the second item sample set of each batch.

[0025] Based on the second item sample set of each batch, negative sampling is performed in batches to obtain a negative sample set, and a training sample set is obtained based on the negative sample set and the positive sample set; the training sample set is used to train the initial recommendation model to obtain a trained item recommendation model.

[0026] Based on the trained item recommendation model, the target recommended item is determined.

[0027] Fourthly, this application also provides a computer-readable storage medium. The computer-readable storage medium stores a computer program thereon, which, when executed by a processor, performs the following steps:

[0028] Obtain the sampling probability values ​​corresponding to each batch of item samples on the application platform;

[0029] Based on the sampling probability values, sampling is performed in each item sample of the corresponding batch to obtain the first item sample set of the corresponding batch;

[0030] Obtain the sample stability value of each item sample in the first item sample set for each batch;

[0031] Based on the sample stability value, the first item sample set of each batch is filtered to obtain the second item sample set of each batch.

[0032] Based on the second item sample set of each batch, negative sampling is performed in batches to obtain a negative sample set, and a training sample set is obtained based on the negative sample set and the positive sample set; the training sample set is used to train the initial recommendation model to obtain a trained item recommendation model.

[0033] Based on the trained item recommendation model, the target recommended item is determined.

[0034] Fifthly, this application also provides a computer program product. The computer program product includes a computer program that, when executed by a processor, performs the following steps: acquiring sampling probability values ​​corresponding to each batch of item samples on the application platform;

[0035] Based on the sampling probability values, sampling is performed in each item sample of the corresponding batch to obtain the first item sample set of the corresponding batch;

[0036] Obtain the sample stability value of each item sample in the first item sample set for each batch;

[0037] Based on the sample stability value, the first item sample set of each batch is filtered to obtain the second item sample set of each batch.

[0038] Based on the second item sample set of each batch, negative sampling is performed in batches to obtain a negative sample set, and a training sample set is obtained based on the negative sample set and the positive sample set; the training sample set is used to train the initial recommendation model to obtain a trained item recommendation model.

[0039] Based on the trained item recommendation model, the target recommended item is determined.

[0040] In the aforementioned item recommendation method, apparatus, computer equipment, storage medium, and computer program products, sampling probability values ​​corresponding to each batch of item samples on the application platform are obtained. Based on each sampling probability value, sampling is performed on each item sample in the corresponding batch to obtain a first item sample set for that batch. Then, by obtaining the sample stability value of each item sample in the first item sample set of each batch, the sampling method is adaptively adjusted according to the sample stability value, achieving the filtering of the first item sample set of each batch, resulting in a filtered second sample set for each batch. Filtering item samples using sample stability values ​​can enhance the sampling accuracy of negative item samples. Further, based on the second item sample set of each batch, negative sampling is performed in batches to obtain a negative sample set. This allows for the simultaneous sampling of negative item samples from the second sample set of multiple batches, resulting in a negative sample set with higher sampling accuracy. Based on the negative sample set and the positive sample set, a training sample set with even higher sampling accuracy can be obtained. This training sample set is then used to train the initial recommendation model to obtain a trained item recommendation model, reducing training bias and improving training efficiency. Finally, based on the trained item recommendation model, more accurate target recommended items are determined. When recommending target recommended items on the application platform, the click-through rate and conversion rate of each target recommended item are improved. Attached Figure Description

[0041] Figure 1 This is a diagram illustrating the application environment of the item recommendation method in one embodiment;

[0042] Figure 2 This is a flowchart illustrating an item recommendation method in one embodiment;

[0043] Figure 3 This is a flowchart illustrating the process of determining the sampling probability values ​​for each batch of item samples in one embodiment.

[0044] Figure 4 This is a flowchart illustrating the item recommendation method in another embodiment;

[0045] Figure 5 This is a flowchart illustrating the item recommendation method in yet another embodiment;

[0046] Figure 6 This is a structural block diagram of an item recommendation device in one embodiment;

[0047] Figure 7 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation

[0048] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0049] The item recommendation method provided in this application relates to cloud technology. Cloud technology refers to a hosting technology that unifies hardware, software, and network resources within a wide area network (WAN) or local area network (LAN) to achieve data computation, storage, processing, and sharing. Cloud technology encompasses network technology, information technology, integration technology, management platform technology, and application technology based on cloud computing business models. These technologies can form resource pools, providing flexible and convenient on-demand access. Since the backend services of different network systems require substantial computing and storage resources—such as video websites, image websites, and many portal websites—cloud computing technology will become a crucial support, providing the necessary resources for computation, storage, processing, and sharing. With the rapid development and application of the internet industry, each item may eventually possess its own identification mark, requiring transmission to a backend system for logical processing. Data at different levels will be processed separately; therefore, various industry data require robust system support, which can be achieved through cloud computing.

[0050] Big data refers to data sets that cannot be captured, managed, and processed within a certain timeframe using conventional software tools. It represents massive, rapidly growing, and diverse information assets that require new processing models to achieve stronger decision-making, insightful discovery, and process optimization capabilities. With the advent of the cloud era, big data has attracted increasing attention. Big data requires specialized technologies to effectively process large amounts of data within a tolerable timeframe. Technologies suitable for big data include massively parallel processing databases, data mining, distributed file systems, distributed databases, cloud computing platforms, the internet, and scalable storage systems.

[0051] The item recommendation method provided in this application specifically involves big data technology in cloud technology and can be applied to, for example... Figure 1 In the application environment shown, terminal 102 communicates with server 104 via a network. A data storage system can store the data that server 104 needs to process. This data storage system can be integrated onto server 104 or located in the cloud or on another network server. Server 104 obtains the sampling probability values ​​corresponding to each batch of item samples on the application platform, and based on these sampling probability values, samples from each item sample in the corresponding batch to obtain the first item sample set for that batch. The sampling probability values ​​corresponding to each batch of item samples can be stored in the local storage of terminal 102. When negative sampling is required, server 104 can retrieve the sampling probability values ​​corresponding to each batch of item samples from the local storage of terminal 102. Similarly, the sampling probability values ​​corresponding to each batch of item samples can also be stored in the data storage system or in the cloud storage service corresponding to server 104. Furthermore, server 104 obtains the sample stability values ​​of each item sample in the first item sample set of each batch, and filters the first item sample set of each batch based on the sample stability values ​​to obtain the filtered second item sample set of each batch. Based on the second item sample set of each batch, negative sampling is performed in batches to obtain a negative sample set. After obtaining the negative sample set, server 104 further obtains a training sample set based on the negative sample set and the positive sample set pre-determined based on the click operations of the action object. The initial recommendation model is then trained based on the training sample set to obtain a trained item recommendation model. Finally, the target recommended item can be determined based on the item recommendation model, and the target recommended item is fed back to the terminal 102 where the action object is located for display, thereby achieving the purpose of recommending items to each action object.

[0052] The terminal 102 can be, but is not limited to, various personal computers, laptops, smartphones, tablets, IoT devices, and portable wearable devices. IoT devices can include smart speakers, smart TVs, smart air conditioners, and smart in-vehicle devices. Portable wearable devices can include smartwatches, smart bracelets, and head-mounted devices. The server 104 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms. The terminal 102 and the server 104 can be directly or indirectly connected via wired or wireless communication; this application does not impose any restrictions on this connection.

[0053] This application's embodiments can be applied to various scenarios, including but not limited to cloud technology, artificial intelligence, smart transportation, and assisted driving. For example, taking the advertising push application scenario in an artificial intelligence context as an example, for different applications or application platforms, a recommendation model is typically used to determine highly relevant recommended advertisements to display to various users of the application or application platform. To ensure the recommendation effect of the model, i.e., to guarantee the click-through rate and conversion rate of the recommended advertisements, the model needs to be trained based on a large training sample set. Therefore, the distribution ratio of positive and negative item samples in the determined training sample set, as well as the accuracy of negative sample sampling, are particularly important. Traditional negative sample sampling methods typically involve dividing the training samples into different batches and then randomly sampling negative samples directly from each batch to obtain the negative sample set. However, random negative sampling is limited by the size of the batch sample size, making it impossible to perform more comprehensive sampling processing, resulting in a large difference between the collected sample distribution and the true negative sample distribution.

[0054] The item recommendation method of this application obtains the sampling probability values ​​corresponding to each batch of item samples on the application platform, and samples from each item sample in the corresponding batch based on each sampling probability value to obtain the first item sample set of the corresponding batch. Then, by obtaining the sample stability value of each item sample in the first item sample set of each batch, the sampling method is adaptively adjusted according to the sample stability value to achieve the filtering of the first item sample set of each batch, resulting in the filtered second item sample set of each batch. Filtering item samples through sample stability values ​​can enhance the sampling accuracy of negative item samples. Further, based on the second item sample set of each batch, negative sampling is performed in batches to obtain a negative sample set. That is, negative item samples from the second item sample set of multiple batches can be sampled simultaneously to obtain a negative sample set with higher sampling accuracy. After obtaining the negative sample set, a training sample set is obtained based on the negative sample set and the positive sample set determined in advance based on the click operation of the action object. The initial recommendation model is trained based on the training sample set to obtain a trained advertising recommendation model. This reduces the bias of model training while improving the training efficiency and recommendation effect of the model. Finally, recommended ads are determined based on the advertising recommendation model and displayed on the terminal where the action object is located, thereby achieving the goal of recommending ads to each action object. In particular, by improving the accuracy and sampling efficiency of negative sampling, the relevance between the determined recommended ads and each action object is improved, resulting in an overall increase in advertising revenue on the application platform or application.

[0055] In one embodiment, such as Figure 2 As shown, an item recommendation method is provided, which can be applied to... Figure 1 Taking the server in the example, the following steps are included:

[0056] Step S202: Obtain the sampling probability values ​​corresponding to each batch of item samples on the application platform.

[0057] For application platforms or applications that require sample collection, the sample can be divided into multiple batches, and the sampling probability value for each batch can be obtained. The sample set can then be obtained by sampling based on the sampling probability of each batch. The sampling probability determines the specific number of sample items to be collected from each batch. For example, if each batch contains 1000 sample items with a sampling probability of 5%, then 50 sample items need to be collected from that batch.

[0058] In this embodiment, the number of item samples in a batch and the sampling probability of item samples in each batch are not limited to certain specific values, but need to be determined according to the actual application scenario. The actual application scenario may correspond to different application platforms or applications, such as the advertising push scenario of a shopping platform (or shopping application), the business or product push scenario of a business platform (or business application), etc. The number of item samples in each batch and the determined sampling probability of each batch are different.

[0059] Specifically, by acquiring the item characteristics of each item sample in each batch on the application platform, and based on the object characteristics of the action object, the item characteristics of each item sample in each batch, and the item click frequency of each item sample, the sampling probability value for each batch of item samples is determined separately. That is, the sampling probability value is different for each batch.

[0060] One approach is to first divide each item sample into multiple batches and then obtain the item characteristics of each item sample in each batch. Another approach is to first obtain the item characteristics of each item sample and then divide the item characteristics into multiple batches, with each batch containing the item characteristics of multiple item samples.

[0061] Item characteristics refer to the relevant features of items pushed by different applications or application platforms. Items can be products, services, or advertisements, and the corresponding item characteristics can be the characteristics of products, services, or advertisements, such as product type, product function, product usage scenario, and product price, as well as service type, service scope, and service purpose, and advertisement format (such as text, images, videos, links, etc.), advertisement type, and advertisement duration.

[0062] An action object refers to a registered or user object in different applications or application platforms. It can click, access, and view push information on different pages in the application, including recommended products, recommended services, and recommended advertisements. The object characteristics of an action object include the object's personal information, pre-set preference information, and records of the object's historical clicks, views, accesses, purchases, and other behaviors.

[0063] Item click frequency represents the number of times an action object in an application or application platform clicks an item. Item click frequency is used to correct the sampling ratio of positive and negative item samples, ensuring that item samples with a low ratio are also collected. Similarly, for item samples with higher click frequencies, the sampling deviation correction coefficient determined based on the item click frequency is larger, that is, for item samples with higher click frequencies, the adjustment of their sampling ratio is more significant.

[0064] Furthermore, the item characteristics of each item sample in each batch, specifically including the item characteristics of positive item samples and negative item samples, are used to determine the first similarity value between each action object and each positive item sample in the corresponding batch, based on the object characteristics of the action object and the item characteristics of the positive item samples. The item click frequency is used to adjust the first similarity value to obtain the corresponding second similarity value. Then, based on the object characteristics of the action object and the item characteristics of the negative item samples, a third similarity value is determined between each action object and each negative item sample in the corresponding batch. Finally, based on the second and third similarity values ​​for each batch, the sampling probability value of the items in the corresponding batch can be determined.

[0065] Step S204: Based on each sampling probability value, sample each item in the corresponding batch to obtain the first item sample set of the corresponding batch.

[0066] Specifically, based on the sampling probability values ​​corresponding to each batch of items, sampling is performed on each item sample in the corresponding batch to obtain the first item sample set for that batch. The first item sample set for each batch includes positive and negative item samples. Further filtering and sampling are required on the first item sample set to obtain the filtered second item sample set. The second item sample set also includes positive and negative item samples. Negative sampling is then performed on the filtered second item sample set to obtain the negative sample set.

[0067] Step S206: Obtain the sample stability value of each item sample in the first item sample set of each batch.

[0068] Specifically, by determining at least two output embedding vector values ​​for each item sample in the first item sample set of each batch, and based on the at least two output embedding vector values ​​for each item sample in the first item sample set of each batch, the sample stability value of each item sample in the first item sample set of each batch is determined.

[0069] The sample stability value measures the stability of each batch of item samples. It can also be understood as the degree of influence of item samples on model parameters during model training; a smaller value indicates a more stable sample. More stable samples mean less influence on model parameters during training, and therefore less knowledge and performance the model can learn from stable samples. Thus, more stable samples have less impact on model training and should be removed during sample selection to retain only those that allow the model to learn more knowledge and performance for training.

[0070] Furthermore, since training a model based on a training sample set typically requires multiple rounds of training until the model's loss function value reaches a certain threshold, or the number of training rounds reaches a preset threshold, training stops to obtain a well-trained recommendation model. Therefore, for each item sample in the first item sample set of each batch, there are usually at least two rounds of model training. Correspondingly, each round of model training corresponds to the output embedding vector value of one item sample, that is, the output embedding vector value is the model output result obtained by processing the item sample during the corresponding round of model training.

[0071] In one embodiment, the sample stability value of each item sample in the first item sample set of each batch can be obtained by calculating the absolute difference between at least two output embedding vector values ​​of each item sample in the first item sample set of each batch.

[0072] If each item sample in the first item sample set of each batch has more than three output embedding vector values, then it is necessary to further determine two sets of output embedding vector values ​​that need to be calculated for absolute difference. For example, if item sample A in the first item sample set of a certain batch has 3 output embedding vector values, it means that for item sample A in this batch, the model was trained 3 times during the model training process. That is, the number of output embedding vector values ​​of each item sample corresponds to the total number of training rounds used for model training of that item sample.

[0073] To give a simple example, if item A in the first item sample set of a certain batch undergoes three rounds of model training, meaning that item A has three output embedding vector values, including vector value 1, vector value 2, and vector value 3, then when calculating the stability of item A, it is necessary to determine the target round based on the current round, such as the third round of training, and by randomly selecting a round before the current round, such as the first round of training.

[0074] In this embodiment, the current round is round 3, the randomly selected round is round 1, and the target round is 3-1=2, i.e., round 2 training. Specifically, the absolute difference between vector value 3 and vector value 2 is calculated. However, since the previously randomly selected round is not fixed, when the currently selected round is round 3, the previously randomly selected round could also be round 2 training. Therefore, the corresponding target round is 3-2=1, i.e., the target round could also be round 1. Accordingly, the absolute difference between vector value 3 and vector value 1 also needs to be calculated, and the obtained absolute differences are summed to finally obtain the sample stability value of item sample A.

[0075] The calculation method for the sample stability value of each item in the first item sample set of each batch is the same. There is no specific limit to the number of rounds of model training for each item in the first item sample set of each batch, such as reaching the model convergence requirement or meeting the model loss function value requirement.

[0076] Furthermore, the sample stability value D(V,t,Δt) of each item in the first item sample set is calculated using the following formula (1):

[0077]

[0078] Where D(V,t,Δt) is the sample stability value of the item sample. It is the sum of the absolute differences between the current round and each of the determined target rounds. For the t-th round of model training, the output embedding vector value of the item sample is... For the (t-Δt)th round of model training, the output embedding vector values ​​of the item samples are... This represents the model parameters during t rounds of training. This represents the model parameters during training rounds t-Δt, where t represents the current training round of each item sample in the first item sample set of a certain batch, and Δt represents a previous training round of each item sample in the first item sample set of a certain batch. t-Δt is used to determine the target round.

[0079] Step S208: Based on the sample stability value, the first item sample set of each batch is filtered to obtain the filtered second item sample set of each batch.

[0080] Specifically, by obtaining a pre-set stability threshold for the sample stability value, and based on the stability threshold, the first item sample set of each batch is filtered to obtain the filtered second item sample set of each batch. Where the sample stability value of each item in the second item sample set of each batch is greater than or equal to the stability threshold, it is necessary to filter out item samples in the first item sample set whose sample stability value is less than the stability threshold to obtain the filtered second item sample set of each batch.

[0081] When the sample stability value is less than the stability threshold, it indicates that these item samples have little impact on the model's parameters and performance during model training. In other words, the model cannot continue to learn new knowledge and performance through these item samples during training. Therefore, these item samples need to be filtered out to avoid the problem of increasing model training time due to invalid training.

[0082] In one embodiment, after sampling the items in the corresponding batch based on each sampling probability value to obtain the first item sample set of the corresponding batch, it is also necessary to construct a batch cache queue M according to the sampling probability value of each batch and the corresponding first item sample set. Specifically, the cache queue M is represented by the following formula (2):

[0083]

[0084] Where M represents a batch buffer queue of length M, and x = 1 indicates that the batch buffer queue contains at least one batch of the first item sample set. That is, M can take different values ​​greater than 1. In this embodiment, M is not specifically limited; its specific value can be adjusted and modified according to actual needs. batch (V|U;θ) represents the sampling probability of sampling items in each batch, where V represents the object features of the action object, U represents the item features of the item sample, and θ represents the model parameters during model training. batch To represent the first item sample set generated after sampling each batch of item samples, the cache queue M includes the first item sample set generated after sampling M batches of item samples.

[0085] Furthermore, after filtering the first item sample set of each batch according to the stability threshold corresponding to the sample stability value, and obtaining the filtered second item sample set of each batch, the second item sample set of each batch is stored in the batch cache queue M, resulting in an updated cached batch queue. The updated batch cache queue M stores the filtered second item sample set of each batch. That is, the number of batches in the batch cache queue M remains unchanged, but by filtering the original first item sample set, the filtered second item sample set is obtained, meaning the number of item samples in each batch has changed. Due to the filtering process, the number of item samples in the second item sample set of each batch should typically be less than the number of item samples in the corresponding first item sample set.

[0086] Step S210: Based on the second item sample set of each batch, negative sampling is performed in batches to obtain a negative sample set. Then, based on the negative sample set and the positive sample set, a training sample set is obtained. The training sample set is used to train the initial recommendation model to obtain a trained item recommendation model.

[0087] Specifically, based on each item sample in any batch and each second item sample set in the updated cache queue, negative sampling is performed on the corresponding batch to obtain the negative item sample of the corresponding batch, and a negative sample set is obtained based on the negative item sample of each batch.

[0088] Specifically, for each batch of item samples that has not undergone sampling processing, one batch of item samples is randomly selected, and the union of all item samples in that batch with each second item sample set in the updated cache queue is performed to obtain the merged third item sample set. Based on the third item sample set, the negative sampling processing of the currently selected batch is performed to obtain the negative item sample of the currently selected batch.

[0089] Furthermore, for the item samples of other batches that have not undergone sampling processing, the same process is used: the union of the item samples of the selected batches and the second item sample sets in the updated cache queue is performed to obtain the corresponding merged third item sample sets. Based on each third item sample set, the corresponding batches are negatively sampled to obtain the negative item samples of each batch. Finally, based on the negative item samples of each batch, a negative sample set for model training is obtained.

[0090] Furthermore, after negative sampling is performed in batches based on the second item sample set of each batch to obtain the negative sample set, the process also includes:

[0091] A positive sample set is obtained based on each positive item sample, and a training sample set is obtained based on the positive sample set and the negative sample set; the training sample set is used to train the initial recommendation model to obtain a trained item recommendation model.

[0092] Specifically, by obtaining the items that have been clicked by the action object from the unsampled item samples, positive item samples are identified, and a positive sample set is obtained based on each positive item sample. Then, a training sample set for model training can be obtained based on the positive sample set and the negative sample set.

[0093] Furthermore, the initial recommendation model is trained based on the training sample set to obtain a trained item recommendation model. The initial recommendation model can be any model, such as a DNN (Deep Neural Networks), an RNN (Recurrent Neural Network), or a CNN (Convolutional Neural Network), etc. This application does not impose specific limitations; it only needs to implement similarity calculation and recommendation functions.

[0094] Step S212: Determine the target recommended item based on the trained item recommendation model.

[0095] Specifically, based on the trained item recommendation model, the target recommended item is determined from the candidate items, and the target recommended item is pushed to the target action object.

[0096] Furthermore, based on the trained item recommendation model, the similarity score between each candidate item and the target action object is calculated, and each candidate item is sorted according to the similarity score. A preset number of target recommended items are determined from each candidate item, and the target recommended items are pushed to the target action object.

[0097] Specifically, this can be achieved by calculating the dot product similarity score between each candidate item and the target action object, ranking the candidate items according to the magnitude of the dot product similarity score, and selecting the top N items as the target recommended items. The method for calculating the similarity score between each candidate item and the target action object is not specifically limited, as long as the similarity between each candidate item and the target action object can be calculated. The number of target recommended items (i.e., N) is also not specifically limited and can be adjusted and modified according to actual needs.

[0098] In one embodiment, the target recommended item can be of different types, such as recommended advertisements, recommended services, and recommended products from different applications or application platforms. The target recommended item varies depending on the type of application or application platform. For example, on an instant messaging application, the target recommended item could be a recommended advertisement; users of the instant messaging application can click on the recommended advertisement to be redirected to other applications for access. On a shopping platform, the target recommended item could be a recommended product; users of the shopping platform can click on the corresponding recommended product to view or purchase it. Similarly, on an audio / video application, the target recommended item could be a recommended service, such as a membership service; users of the audio / video application can click on the recommended service to view and subscribe to the corresponding service. The types of applications or application platforms can be diverse, and the corresponding recommended advertisements, recommended products, and recommended services are not specifically limited, allowing for item recommendation in various real-world scenarios.

[0099] In the aforementioned item recommendation method, sampling probability values ​​corresponding to each batch of item samples on the application platform are obtained. Based on these probability values, sampling is performed on each item sample within the corresponding batch to obtain the first item sample set for that batch. Then, by obtaining the sample stability value of each item sample in the first item sample set for each batch, the sampling method is adaptively adjusted based on the stability value, thus filtering the first item sample sets for each batch and obtaining the filtered second sample sets for each batch. Filtering item samples using the stability value enhances the sampling accuracy of negative item samples. Further, based on the second item sample sets for each batch, negative sampling is performed in batches to obtain a negative sample set. This allows for the simultaneous sampling of negative item samples from multiple batches' second sample sets, resulting in a negative sample set with higher sampling accuracy. Based on the negative sample set and the positive sample set, a training sample set with even higher sampling accuracy can be obtained. This training sample set is then used to train the initial recommendation model to obtain a trained item recommendation model, reducing training bias and improving training efficiency. Finally, based on the trained item recommendation model, more accurate target recommended items are determined. When recommending target recommended items on the application platform, the click-through rate and conversion rate of each target recommended item are improved.

[0100] In one embodiment, such as Figure 3 As shown, the steps for determining the sampling probability value of item samples in each batch are as follows: Based on the object characteristics of the action object, the item characteristics of each item sample in each batch, and the item click frequency of each item sample, the steps for determining the sampling probability value of item samples in each batch include:

[0101] Step S302: Based on the object characteristics of the action object and the item characteristics of each positive item sample in each batch, determine the first similarity value between each action object and each positive item sample in the corresponding batch.

[0102] In this context, "action object" refers to a registered or user object on different applications or application platforms. Object characteristics represent the action object's personal information, pre-set preferences, and records of its historical clicks, views, visits, and purchases, denoted by 'u'. "Item characteristics" represent the features of products, services, or advertisements pushed by different applications or application platforms, denoted by 'v'. Positive item samples are those clicked by the action object; the item characteristics of positive item samples are denoted by 'v'. + To express.

[0103] Furthermore, the following formula (3) is used to calculate the first similarity value s(u,v) between each action object and each positive item sample in the corresponding batch. + ):

[0104] s(u,v + )=u T v + (3)

[0105] Where u represents the action object feature, v + The characteristics of a positive item sample.

[0106] Step S304: Determine the sampling deviation correction parameters based on the item click frequency.

[0107] Specifically, the item click frequency is the number of times an item sample is clicked by an action object, denoted by q(V). The sampling bias correction parameter is determined based on q(V), specifically by taking the logarithm of the item click frequency q(V), i.e., logq(V) represents the sampling bias correction parameter.

[0108] Step S306: Adjust the first similarity value according to the sampling deviation correction parameter to obtain the second similarity value between each action object and each positive item sample in the corresponding batch.

[0109] Specifically, the first similarity value is adjusted according to the sampling deviation correction parameter to correct the proportion of positive and negative item samples, ensuring that samples with a low proportion are also collected. Similarly, for samples with higher item click frequency, the sampling deviation correction coefficient determined based on the item click frequency is larger.

[0110] Furthermore, specifically, the adjusted second similarity value is obtained by subtracting the sampling bias correction parameter from the first similarity value. The second similarity value s(u,v) between each action object and each positive item sample in the corresponding batch is calculated using the following formula (4). + ,q):

[0111] s(u,v + ,q)=s(u,v + )-logq(V)=u T v + -logq(V); (4)

[0112] Wherein, s(u,v + ) and u T v + Both can be used to represent the first similarity value between each action object and each positive item sample in the corresponding batch, and logq(V) is the sampling bias correction parameter.

[0113] Step S308: Based on the object characteristics and the item characteristics of each negative item sample in each batch, determine the third similarity value between each action object and each negative item sample in the corresponding batch.

[0114] Specifically, the third similarity value s(u,v) between each action object and each negative item sample in the corresponding batch is calculated using the following formula (5). - ):

[0115] s(u,v - )=u T v - (5)

[0116] Among them, v - Negative item samples are those that have not been clicked by the action object. Since the item click frequency q(V) represents the number of times an item sample is clicked by the action object, negative item samples have not been clicked by the action object, and therefore have no item click frequency. Thus, when calculating the third similarity value between each action object and each negative item sample in the corresponding batch, the item click frequency q(V) is not considered. The third similarity value can be calculated based on the object characteristics and the item characteristics of each negative item sample in each batch.

[0117] Step S310: Based on each second similarity value and each third similarity value, determine the sampling probability value for each batch of items.

[0118] Specifically, for each batch of items, since the distribution of positive and negative item samples in each batch is different, the corresponding sampling probability values ​​are different. Based on the second similarity value and the third similarity value corresponding to each batch of items, the sampling probability values ​​corresponding to each batch are calculated.

[0119] Specifically, the sampling probability value p corresponding to each batch of item samples is calculated using the following formula (6). batch (V|U;θ):

[0120]

[0121] in, The index score represents the second similarity value between the action object and each positive item sample in the corresponding batch. The index score, v, represents the third similarity value between each action object and each negative item sample in the corresponding batch. - Let B represent the negative item sample, and let v represent the all item samples. - ∈ B indicates that the negative item sample is determined from all item samples. This indicates that the exponential scores of the third similarity values ​​between all negative item samples and action objects in each batch need to be summed.

[0122] In this embodiment, a first similarity value is determined between each action object and each positive item sample in the corresponding batch based on the object characteristics of the action object and the item characteristics of each positive item sample in each batch. A sampling bias correction parameter is determined based on the item click frequency, and then the first similarity value is adjusted according to the sampling bias correction parameter to obtain a second similarity value between each action object and each positive item sample in the corresponding batch. Then, a third similarity value is determined between each action object and each negative item sample in the corresponding batch based on the object characteristics and the item characteristics of each negative item sample in each batch. Based on each second and third similarity value, a sampling probability value for each batch of item samples is determined. This achieves adjustment of the first similarity value according to the sampling bias correction parameter, thereby correcting the sampling ratio of positive and negative item samples and ensuring that samples with a low ratio are also collected. This makes the sampling probability values ​​determined based on the adjusted second and third similarity values ​​more accurate, improves sampling precision, reduces sampling bias, and further enhances the training effect of the model based on the training sample set obtained from subsequent sampling.

[0123] In one embodiment, such as Figure 4 As shown, an item recommendation method is provided, which includes the following steps:

[0124] Step S402: Obtain the sampling probability value corresponding to each batch of item samples on the application platform, and based on each sampling probability value, sample each item sample in the corresponding batch to obtain the first item sample set of the corresponding batch.

[0125] Specifically, by first dividing each item sample into multiple batches, then obtaining the item characteristics of each item sample in each batch, and then determining the sampling probability value of each batch of item samples based on the object characteristics of the action object, the item characteristics of each item sample in each batch, and the item click frequency of each item sample.

[0126] Alternatively, sampling can be achieved by first obtaining the item characteristics of each item sample, dividing each item characteristic into multiple batches, and then determining the sampling probability value of each batch of item samples based on the object characteristics of the action object, the item characteristics of each item sample in each batch, and the item click frequency of each item sample.

[0127] Furthermore, after determining the sampling probability value for each batch of item samples, sampling is performed in each item sample of the corresponding batch based on each sampling probability value to obtain the first item sample set of the corresponding batch.

[0128] Step S404: Construct a batch cache queue based on the sampling probability value of each batch and the corresponding first item sample set.

[0129] Specifically, after sampling from each item sample in the corresponding batch based on each sampling probability value to obtain the first item sample set of the corresponding batch, a batch cache queue is further constructed according to the sampling probability value of each batch and the corresponding first item sample set. The batch cache queue is a first-in-first-out cache queue used to store the first item sample set corresponding to each batch.

[0130] Step S406: Obtain the sample stability value of each item sample in the first item sample set of each batch.

[0131] Specifically, by determining at least two output embedding vector values ​​for each item sample in the first item sample set of each batch, and based on the at least two output embedding vector values ​​for each item sample in the first item sample set of each batch, the sample stability value of each item sample in the first item sample set of each batch is determined.

[0132] Further, specifically, the sample stability value of each item sample in the first item sample set of each batch can be obtained by calculating the absolute difference between at least two output embedding vector values ​​of each item sample in the first item sample set of each batch. Specifically, when each item sample in a batch has multiple output embedding vector values, multiple sets of two output embedding vector values ​​for which absolute difference calculation is required are first determined, and the absolute difference between the two output embedding vector values ​​in each set is calculated. These differences are then summed to obtain the sample stability value of each item sample in the first item sample set of each batch.

[0133] Step S408: Based on the stability threshold corresponding to the sample stability value, the first item sample set of each batch is filtered to obtain the second item sample set of each batch.

[0134] Specifically, the sample stability value of each item in the second item sample set of each batch is greater than or equal to the stability threshold. It can be understood that this is done by obtaining the stability threshold that is pre-set for the sample stability value, and by filtering the first item sample set of each batch according to the stability threshold, filtering out the item samples in the first item sample set whose sample stability value is less than the stability threshold, thus obtaining the filtered second item sample set of each batch.

[0135] Step S410: Store the second item sample set of each batch into the batch cache queue to obtain the updated cache batch queue.

[0136] Specifically, after filtering the first item sample set of each batch according to the stability threshold corresponding to the sample stability value, and obtaining the filtered second item sample set of each batch, the second item sample set of each batch is stored in the batch cache queue to obtain the updated cache batch queue.

[0137] Step S412: Based on each item sample in any batch and each second item sample set in the updated cache queue, perform negative sampling of the corresponding batch to obtain the negative item sample of the corresponding batch, and obtain the negative sample set according to the negative item sample of each batch.

[0138] Specifically, for each batch of item samples that have not undergone sampling processing, arbitrarily select each item sample from one batch, and perform a union operation on all item samples from that batch and each set of second item samples in the updated cache queue to obtain a merged third item sample set. Based on the third item sample set, perform negative sampling processing on the currently selected batch to obtain the negative item sample of the currently selected batch.

[0139] Specifically, for other batches of item samples that have not undergone sampling processing, the same negative sampling method is used to obtain the corresponding negative item samples for each batch. Then, based on the negative item samples of each batch, a set of negative samples for model training is obtained.

[0140] In this embodiment, sampling probability values ​​corresponding to multiple batches of item samples are obtained, and sampling is performed on the corresponding batches of item samples based on each sampling probability value to obtain the first item sample set of the corresponding batch. Then, a batch cache queue is constructed based on the sampling probability values ​​of each batch and the corresponding first item sample set. By obtaining the sample stability value of each item sample in the first item sample set of each batch, and according to the stability threshold corresponding to the sample stability value, the first item sample set of each batch is filtered to obtain the filtered second item sample set of each batch. Further, by storing the second item sample set of each batch in the batch cache queue, an updated cache batch queue is obtained. Based on each item sample in any batch and each second item sample set in the updated cache queue, negative sampling of the corresponding batch is performed to obtain the negative item sample of the corresponding batch, and a negative sample set is obtained based on the negative item sample of each batch. This achieves a higher sampling accuracy negative sample set by simultaneously sampling the negative item samples in the second item sample sets of multiple batches in the cache queue based on the batch cache queue, thereby reducing the bias of model training and improving the training efficiency of the model.

[0141] In one embodiment, such as Figure 5 As shown, an item recommendation method is provided, which includes the following steps:

[0142] Step S501: Obtain the item characteristics of each item sample in each batch on the application platform.

[0143] Step S502: Based on the object characteristics of the action object and the item characteristics of each positive item sample in each batch, determine the first similarity value between each action object and each positive item sample in the corresponding batch.

[0144] Step S503: Determine the sampling deviation correction parameters based on the item click frequency.

[0145] Step S504: Adjust the first similarity value according to the sampling deviation correction parameter to obtain the second similarity value between each action object and each positive item sample in the corresponding batch.

[0146] Step S505: Based on the object characteristics and the item characteristics of each negative item sample in each batch, determine the third similarity value between each action object and each negative item sample in the corresponding batch.

[0147] Step S506: Based on each second similarity value and each third similarity value, determine the sampling probability value for each batch of item samples.

[0148] Step S507: Based on each sampling probability value, samples are taken from each item in the corresponding batch to obtain the first item sample set of the corresponding batch.

[0149] Step S508: Construct a batch cache queue based on the sampling probability value of each batch and the corresponding first item sample set.

[0150] Step S509: Determine at least two output embedding vector values ​​for each item sample in the first item sample set of each batch. The output embedding vector values ​​are the model output results obtained by processing the item samples during the model training process of the corresponding round.

[0151] Step S510: Determine the absolute difference between at least two output embedding vector values ​​of each item sample in the first item sample set of each batch.

[0152] Step S511: Based on the absolute difference, obtain the sample stability value of each item sample in the first item sample set of each batch.

[0153] Step S512: Based on the stability threshold corresponding to the sample stability value, the first item sample set of each batch is filtered to obtain the second item sample set of each batch. The sample stability value of each item sample in the second item sample set of each batch is greater than or equal to the stability threshold.

[0154] Step S513: Store the second item sample set of each batch into the batch cache queue to obtain the updated cache batch queue.

[0155] Step S514: Based on each item sample in any batch and each second item sample set in the updated cache queue, perform negative sampling of the corresponding batch to obtain the negative item sample of the corresponding batch.

[0156] Step S515: Based on the negative item samples of each batch, obtain the negative sample set, and based on the negative sample set and the positive sample set, obtain the training sample set. The training sample set is used to train the initial recommendation model to obtain the trained item recommendation model.

[0157] Step S516: Determine the target recommended item based on the trained item recommendation model.

[0158] In one embodiment, during model training, the log-likelihood loss function is used to achieve model convergence. Specifically, the model loss function L during model training is represented by the following formula (7). CE :

[0159]

[0160] Where i represents the i-th item sample in the item sample set, B1 represents one of the item sample sets used for sampling, and p(V i |U i ;θ) represents the sampling probability value for item sample i. For the initial recommendation model training process, p(V) represents the sampling probability value for each item sample in the same item sample set. i |U i ;θ) are the same, logp(V i |U i ;θ) represents taking the logarithm of the sampling probability of the sample, ∑ i∈|B| logp(V i |U i ;θ) represents the summation of the logarithmic values ​​of the sampling probabilities of all samples.

[0161] Furthermore, the sampling probability value p(V) of each item sample in the same item sample set is calculated using the following formula (8). i |U i ;θ):

[0162]

[0163] Where all item samples in the same item sample set have the same sampling probability, then solving for the sampling probability value of an item sample is equivalent to solving for the sampling probability value of the entire item sample set, where v represents a positive item sample. - Let N represent negative item samples, N represent the set of negative item samples in the entire item sample set, and u represent the action object features. The index score represents the first similarity value between the action object and positive item samples in the item sample set. The index score represents the third similarity value between the action object and negative item samples in the item sample set. This indicates that the exponential scores of the third similarity values ​​between all negative item samples and action objects need to be summed.

[0164] In this embodiment, sampling probability values ​​corresponding to each batch of item samples on the application platform are obtained. Based on each sampling probability value, sampling is performed on each item sample in the corresponding batch to obtain the first item sample set of the corresponding batch. Then, a batch cache queue is constructed based on the sampling probability values ​​of each batch and the corresponding first item sample set. By obtaining the sample stability value of each item sample in the first item sample set of each batch, the sampling method can be adaptively adjusted according to the sample stability value to achieve the filtering of the first item sample set of each batch, obtaining the filtered second sample set of each batch. By storing the second item sample set of each batch in the batch cache queue, an updated cache batch queue is obtained. Based on each item sample in any batch and each second item sample set in the updated cache queue, negative sampling of the corresponding batch is performed to obtain the negative item sample of the corresponding batch. Based on the negative item sample of each batch, a negative sample set is obtained. This achieves the goal of obtaining a negative sample set with higher sampling accuracy based on the batch cache queue and simultaneously sampling the negative item samples in the second item sample sets of multiple batches in the cache queue. By combining the negative and positive sample sets, a training sample set with higher sampling precision can be obtained. This training sample set is then used to train the initial recommendation model, resulting in a well-trained item recommendation model. This reduces training bias and improves training efficiency. Finally, based on the trained item recommendation model, more accurate target recommended items are identified. When these target recommended items are recommended on the application platform, the click-through rate and conversion rate of each target recommended item are improved.

[0165] In one embodiment, an item recommendation method is provided, which specifically includes the following parts:

[0166] P1, Constructing model features:

[0167] Obtain the item characteristics of each item sample in multiple batches, as well as the object characteristics of each action object.

[0168] Each batch of item samples includes positive item samples and negative item samples. The corresponding item features include the item features of positive item samples and the item features of negative item samples. Positive item samples are items that have been clicked by the action object, while negative item samples are items that have not been clicked by the action object.

[0169] P2, calculate the sampling formula for each batch:

[0170] The process of calculating the sampling formula for each batch can also be understood as the process of determining the sampling probability value corresponding to each batch of item samples.

[0171] First, based on the object characteristics of the action object and the item characteristics of each positive item sample in each batch, the first similarity value between each action object and each positive item sample in the corresponding batch is determined.

[0172] Secondly, the click frequency of the positive item samples is obtained, and the sampling deviation correction parameter is determined based on the click frequency. Then, the first similarity value is adjusted according to the sampling deviation correction parameter to obtain the second similarity value between each action object and each positive item sample in the corresponding batch.

[0173] Furthermore, based on the object characteristics and the item characteristics of each negative item sample in each batch, a third similarity value is determined between each action object and each negative item sample in the corresponding batch. Based on each second similarity value and each third similarity value, the sampling probability value of the item samples in each batch is determined respectively.

[0174] After determining the sampling probability value corresponding to each batch of item samples, sampling is performed in the corresponding batch of item samples according to the sampling probability value corresponding to each batch to obtain the first item sample set of the corresponding batch.

[0175] P3, the formula for calculating the stability of the embedding of each item sample in the first item sample set of each batch in different training rounds:

[0176] The process of calculating the stability formula of the embedding of each item sample in the first item sample set of each batch in different training rounds can be understood as calculating the stability value between the output embedding vector values ​​of each item sample in the first item sample set of each batch in different training rounds.

[0177] First, at least two output embedding vector values ​​are determined for each item sample in the first item sample set of each batch. The output embedding vector values ​​are the model output results obtained by processing the item samples during the model training process of the corresponding round.

[0178] Secondly, by determining the absolute difference between at least two output embedding vector values ​​of each item sample in the first item sample set of each batch, and based on the absolute difference, the sample stability value of each item sample in the first item sample set of each batch is obtained.

[0179] P4, based on the sampling formula for each batch and the sample stability values ​​of each item sample in the first item sample set of each batch, generates the updated batch cache queue:

[0180] The process of generating an updated batch cache queue based on the sampling formula for each batch and the sample stability value of each item sample in the first item sample set of each batch can be understood as sampling according to the sampling formula for each batch to obtain the first item sample set of each batch, storing the first item sample set in the constructed batch cache queue, further filtering each item sample in the first item sample set according to the sample stability value to obtain the filtered second item sample set, and storing the second item sample set in the batch cache queue, overwriting the previously stored first item sample set, thus realizing the process of updating the batch cache queue.

[0181] P5, based on the sample of each item in any batch and the sample set of each second item in the updated cache queue, performs negative sampling on the corresponding batch to obtain the negative item sample of the corresponding batch:

[0182] In this process, after obtaining negative item samples from each batch, a negative sample set is obtained based on the negative item samples from each batch. Then, based on the negative sample set and the positive sample set clicked by the object being acted upon, a training sample set for model training is obtained.

[0183] P6, the item recommendation model was trained:

[0184] Specifically, the initial recommendation model is trained based on the training sample set to obtain a trained item recommendation model.

[0185] P7. Based on the trained item recommendation model, determine the target recommended item:

[0186] Specifically, based on the trained item recommendation model, the similarity score between each candidate item and the target action object is calculated, and the candidate items are sorted according to the similarity score. A preset number of target recommended items are determined from the candidate items, and the target recommended items are pushed to the target action object.

[0187] The aforementioned item recommendation method corrects the proportion of positive and negative item samples based on sampling bias correction parameters, ensuring that samples with low proportions are also collected. Simultaneously, based on sample stability values, it adaptively adjusts the sampling method, enhancing the sampling accuracy of negative item samples and reducing sample bias. This further improves the training effect of the model based on the training sample set obtained from subsequent sampling, thereby improving the recommendation performance of the trained item recommendation model.

[0188] It should be understood that although the steps in the flowcharts of the above embodiments are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the above embodiments may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0189] Based on the same inventive concept, this application also provides an item recommendation device for implementing the item recommendation method described above. The solution provided by this device is similar to the solution described in the above method; therefore, the specific limitations of the one or more negative sampling devices and recommended product determination devices provided below can be found in the limitations of the item recommendation method described above, and will not be repeated here.

[0190] In one embodiment, such as Figure 6 As shown, an item recommendation device is provided, including: a sampling probability value acquisition module 602, a first item sample set acquisition module 604, a sample stability value acquisition module 606, a second item sample set acquisition module 608, a training sample set acquisition module 610, and a target recommended item determination module 612, wherein:

[0191] The sampling probability value acquisition module 602 is used to acquire the sampling probability values ​​corresponding to each batch of item samples on the application platform.

[0192] The first item sample set acquisition module 604 is used to sample each item sample in the corresponding batch based on each sampling probability value to obtain the first item sample set of the corresponding batch.

[0193] The sample stability value acquisition module 606 is used to acquire the sample stability value of each item sample in the first item sample set of each batch.

[0194] The second item sample set acquisition module 608 is used to filter the first item sample set of each batch based on the sample stability value to obtain the filtered second item sample set of each batch.

[0195] The training sample set acquisition module 610 is used to perform negative sampling in batches based on the second item sample set of each batch to obtain a negative sample set, and to obtain a training sample set based on the negative sample set and the positive sample set; the training sample set is used to train the initial recommendation model to obtain a trained item recommendation model;

[0196] The target recommended item determination module 612 is used to determine the target recommended item based on the trained item recommendation model.

[0197] In the aforementioned item recommendation device, sampling probability values ​​corresponding to each batch of item samples on the application platform are obtained. Based on these probability values, sampling is performed on each item sample in the corresponding batch to obtain a first item sample set for that batch. Then, by obtaining the sample stability value of each item sample in the first item sample set for each batch, the sampling method is adaptively adjusted based on the stability value, achieving filtering of the first item sample sets for each batch, resulting in a second sample set for each batch. Filtering item samples using the stability value enhances the sampling accuracy of negative item samples. Further, based on the second item sample sets for each batch, negative sampling is performed in batches to obtain a negative sample set. This allows for the simultaneous sampling of negative item samples from the second sample sets in multiple batches, resulting in a negative sample set with higher sampling accuracy. Based on the negative sample set and the positive sample set, a training sample set with even higher sampling accuracy can be obtained. This training sample set is then used to train the initial recommendation model to obtain a trained item recommendation model, reducing training bias and improving training efficiency. Finally, based on the trained item recommendation model, more accurate target recommended items are determined. When recommending target recommended items on the application platform, the click-through rate and conversion rate of each target recommended item are improved.

[0198] In one embodiment, the sampling probability value acquisition module is further configured to: acquire the item characteristics of each item sample in each batch on the application platform; and determine the sampling probability value of each batch of item samples based on the object characteristics of the action object, the item characteristics of each item sample in each batch, and the item click frequency of each item sample.

[0199] In one embodiment, the sampling probability value acquisition module is further configured to: determine a first similarity value between each action object and each positive item sample in the corresponding batch based on the object characteristics of the action object and the item characteristics of each positive item sample in each batch; positive item samples are item samples that have been clicked by the action object; determine a sampling deviation correction parameter based on the item click frequency; adjust the first similarity value according to the sampling deviation correction parameter to obtain a second similarity value between each action object and each positive item sample in the corresponding batch after adjustment; determine a third similarity value between each action object and each negative item sample in the corresponding batch based on the object characteristics and the item characteristics of each negative item sample in each batch; negative item samples are item samples that have not been clicked by the action object; and determine the sampling probability value for each batch of item samples based on each second similarity value and each third similarity value.

[0200] In one embodiment, the sample stability value acquisition module is further configured to: determine at least two output embedding vector values ​​for each item sample in the first item sample set of each batch, wherein the output embedding vector values ​​are the model output results obtained by processing the item samples during the model training process of the corresponding round; and determine the sample stability value of each item sample in the first item sample set of each batch based on the at least two output embedding vector values ​​for each item sample in the first item sample set of each batch.

[0201] In one embodiment, the sample stability value acquisition module is further configured to: determine the absolute difference between at least two output embedding vector values ​​of each item sample in the first item sample set of each batch; and obtain the sample stability value of each item sample in the first item sample set of each batch based on the absolute difference.

[0202] In one embodiment, an item recommendation device is provided, which further includes a cache queue construction module for: constructing a batch cache queue based on the sampling probability value of each batch and the corresponding first item sample set;

[0203] The second item sample set acquisition module is further configured to: filter the first item sample set of each batch according to the stability threshold corresponding to the sample stability value, and obtain the second item sample set of each batch after filtering, wherein the sample stability value of each item sample in the second item sample set of each batch is greater than or equal to the stability threshold; and store the second item sample set of each batch into the batch cache queue to obtain the updated cache batch queue.

[0204] In one embodiment, the negative sampling module is further configured to: perform negative sampling of the corresponding batch based on each item sample in any batch and each second item sample set in the updated cache queue, to obtain negative item samples for the corresponding batch; and obtain a negative sample set based on the negative item samples of each batch. Each module in the above-mentioned item recommendation device can be implemented entirely or partially through software, hardware, or a combination thereof. Each module can be embedded in or independent of the processor in a computer device in hardware form, or stored in the memory of a computer device in software form, so that the processor can call and execute the operations corresponding to each module.

[0205] In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 7 As shown, the computer device includes a processor, memory, input / output (I / O) interfaces, and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operating system and computer programs in the non-volatile storage media. The database stores data such as batches of item samples, sampling probability values ​​corresponding to each batch of item samples, a first item sample set, sample stability values ​​of each item sample in the first item sample set, a second item sample set, a negative sample set, a positive sample set, a training sample set, an initial recommendation model, a trained item recommendation model, and target recommended items. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communicating with external terminals via a network. When the computer program is executed by the processor, it implements an item recommendation method.

[0206] Those skilled in the art will understand that Figure 7 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0207] In one embodiment, a computer device is also provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in the above method embodiments.

[0208] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon that, when executed by a processor, implements the steps in the above method embodiments.

[0209] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in the above method embodiments.

[0210] It should be noted that the object information (including but not limited to object device information, object personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the object or fully authorized by all parties, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions. Specifically, the objects involved can refuse or conveniently refuse advertisements pushed by different applications or application platforms.

[0211] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, etc., and are not limited to these.

[0212] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0213] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A method for recommending items, characterized in that, The method includes: The item characteristics of each item sample in each batch on the application platform are obtained respectively. Based on the object characteristics of the action object, the item characteristics of each item sample in each batch, and the item click frequency of each item sample, the sampling probability value of each batch of item samples is determined respectively. Based on the sampling probability values, sampling is performed in each item sample of the corresponding batch to obtain the first item sample set of the corresponding batch; Obtain the sample stability value of each item sample in the first item sample set for each batch; the sample stability value is used to measure the stability of the item samples in each batch and is determined based on at least two output embedding vector values ​​of each item sample in the first item sample set for each batch. Based on the sample stability value, the first item sample set of each batch is filtered to obtain the second item sample set of each batch. Based on the second item sample set in each batch, negative sampling is performed in batches to obtain a negative sample set. Based on the item samples that have been clicked by the action object in each unsampled item sample, a positive sample set is constructed. Based on the negative sample set and the positive sample set, a training sample set is obtained. The training sample set is used to train the initial recommendation model to obtain a trained item recommendation model. Based on the trained item recommendation model, the target recommended item is determined.

2. The method according to claim 1, characterized in that, The step of determining the sampling probability value for each batch of item samples based on the object characteristics of the action object, the item characteristics of each item sample in each batch, and the item click frequency of each item sample includes: Based on the object characteristics of the action object and the item characteristics of each positive item sample in each batch, a first similarity value is determined between each action object and each positive item sample in the corresponding batch; the positive item sample is the item sample that has been clicked by the action object. Based on the click frequency of the item, determine the sampling deviation correction parameters; The first similarity value is adjusted according to the sampling deviation correction parameter to obtain the second similarity value between each of the action objects and each of the positive item samples in the corresponding batch; Based on the object characteristics and the item characteristics of each negative item sample in each batch, a third similarity value is determined between each action object and each negative item sample in the corresponding batch; the negative item sample is an item sample that has not been clicked by the action object. Based on each of the second similarity values ​​and each of the third similarity values, the sampling probability value for each batch of item samples is determined.

3. The method according to claim 1 or 2, characterized in that, The step of obtaining the sample stability value of each item sample in the first item sample set for each batch includes: Determine at least two output embedding vector values ​​for each item sample in the first item sample set for each batch, wherein the output embedding vector values ​​are the model output results obtained by processing the item samples during the model training process of the corresponding round; Based on at least two output embedding vector values ​​of each item sample in the first item sample set of each batch, determine the sample stability value of each item sample in the first item sample set of each batch.

4. The method according to claim 3, characterized in that, The step of determining the sample stability value of each item sample in the first item sample set for each batch based on at least two output embedding vector values ​​of each item sample in the first item sample set for each batch includes: Determine the absolute difference between at least two output embedding vector values ​​for each item sample in the first item sample set for each batch; Based on the absolute difference, the sample stability value of each item sample in the first item sample set of each batch is obtained.

5. The method according to claim 1 or 2, characterized in that, After sampling in each item sample of the corresponding batch based on the sampling probability value to obtain the first item sample set of the corresponding batch, the method further includes: constructing a batch cache queue according to the sampling probability value of each batch and the corresponding first item sample set; The step of filtering the first item sample set for each batch based on the sample stability value to obtain the filtered second item sample set for each batch includes: Based on the stability threshold corresponding to the sample stability value, the first item sample set of each batch is filtered to obtain the second item sample set of each batch after filtering. The sample stability value of each item sample in the second item sample set of each batch is greater than or equal to the stability threshold. The second item sample set of each batch is stored in the batch cache queue to obtain the updated cache batch queue.

6. The method according to claim 5, characterized in that, The second item sample set, based on each batch, is negatively sampled in batches to obtain a negative sample set, including: Based on each item sample in any batch and each second item sample set in the updated cache queue, negative sampling is performed on the corresponding batch to obtain the negative item sample of the corresponding batch. Based on the negative item samples from each batch, a negative sample set is obtained.

7. An item recommendation device, characterized in that, The device includes: The sampling probability value acquisition module is used to acquire the item characteristics of each item sample in each batch on the application platform, and determine the sampling probability value of each batch of item samples based on the object characteristics of the action object, the item characteristics of each item sample in each batch, and the item click frequency of each item sample. The first item sample set acquisition module is used to sample each item sample in the corresponding batch based on the sampling probability value to obtain the first item sample set of the corresponding batch. The sample stability value acquisition module is used to acquire the sample stability value of each item sample in the first item sample set of each batch; the sample stability value is used to measure the stability of each batch of item samples and is determined based on at least two output embedding vector values ​​of each item sample in the first item sample set of each batch. The second item sample set acquisition module is used to filter the first item sample set of each batch based on the sample stability value to obtain the second item sample set of each batch after filtering. The training sample set acquisition module is used to perform negative sampling in batches based on the second item sample set in each batch to obtain a negative sample set, construct a positive sample set based on the item samples clicked by the action object in each unsampled item sample, and obtain a training sample set based on the negative sample set and the positive sample set; the training sample set is used to train the initial recommendation model to obtain a trained item recommendation model; The target recommended item determination module is used to determine the target recommended item based on the trained item recommendation model.

8. The apparatus according to claim 7, characterized in that, The sampling probability value acquisition module is also used for: Based on the object characteristics of the action object and the item characteristics of each positive item sample in each batch, a first similarity value is determined between each action object and each positive item sample in the corresponding batch. The positive item samples are those clicked by the action object; a sampling bias correction parameter is determined based on the item click frequency; the first similarity value is adjusted according to the sampling bias correction parameter to obtain the adjusted second similarity value between each action object and each positive item sample in the corresponding batch; a third similarity value is determined between each action object and each negative item sample in the corresponding batch based on the object characteristics and the item characteristics of each negative item sample in each batch; the negative item samples are those not clicked by the action object; the sampling probability value for each batch of item samples is determined based on each second similarity value and each third similarity value.

9. The apparatus according to claim 7 or 8, characterized in that, The sample stability value acquisition module is also used for: Determine at least two output embedding vector values ​​for each item sample in the first item sample set of each batch, wherein the output embedding vector values ​​are the model output results obtained by processing the item samples during the model training process of the corresponding round; and determine the sample stability value of each item sample in the first item sample set of each batch based on the at least two output embedding vector values ​​for each item sample in the first item sample set of each batch.

10. The apparatus according to claim 9, characterized in that, The sample stability value acquisition module is also used for: Determine the absolute difference between at least two output embedding vector values ​​of each item sample in the first item sample set for each batch; based on the absolute difference, obtain the sample stability value of each item sample in the first item sample set for each batch.

11. The apparatus according to claim 7 or 8, characterized in that, The device also includes a cache queue construction module, used to construct a batch cache queue based on the sampling probability value of each batch and the corresponding first item sample set; The second item sample set acquisition module is further configured to: filter the first item sample set of each batch according to the stability threshold corresponding to the sample stability value, to obtain the second item sample set of each batch after filtering, wherein the sample stability value of each item sample in the second item sample set of each batch is greater than or equal to the stability threshold; and store the second item sample set of each batch in the batch cache queue to obtain the updated cache batch queue.

12. The apparatus according to claim 11, characterized in that, The negative sampling module is also used for: Based on each item sample in any batch and each second item sample set in the updated cache queue, negative sampling is performed on the corresponding batch to obtain the negative item sample of the corresponding batch; based on the negative item samples of each batch, a negative sample set is obtained.

13. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.

14. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.

15. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Recommendation model training method and device, and recommendation method and device

    CN110046952A

  • Material recommendation method and device, equipment and storage medium

    CN113204703A