CN116723234B - Push processing method, related device and medium - Google Patents

Push processing method, related device and medium Download PDF

Info

Publication number
CN116723234B
CN116723234B CN202310983164.XA CN202310983164A CN116723234B CN 116723234 B CN116723234 B CN 116723234B CN 202310983164 A CN202310983164 A CN 202310983164A CN 116723234 B CN116723234 B CN 116723234B
Authority
CN
China
Prior art keywords
task
sample
auxiliary
content
push
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202310983164.XA
Other languages
Chinese (zh)
Other versions
CN116723234A (en
Inventor
赵光耀
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN202310983164.XA priority Critical patent/CN116723234B/en
Publication of CN116723234A publication Critical patent/CN116723234A/en
Application granted granted Critical
Publication of CN116723234B publication Critical patent/CN116723234B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/55Push-based network services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/147Signalling methods or messages providing extensions to protocols defined by standardisation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • H04L67/62Establishing a time schedule for servicing the requests
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The disclosure provides a push processing method, a related device and a medium. The push processing method comprises the following steps: acquiring object characteristics of a target object and content characteristics to be pushed of content to be pushed; inputting the object characteristics and the characteristics of the content to be pushed into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks; determining the sorting score of the content to be pushed based on task completion probabilities of a plurality of tasks corresponding to the content characteristics to be pushed; ranking the plurality of content to be pushed based on ranking scores of the plurality of content to be pushed; the task completion probability prediction model is trained based on sample task completion probabilities, first auxiliary probabilities, and second auxiliary probabilities of the plurality of tasks. The embodiment of the disclosure pushes content to a target object with push accuracy. The embodiment of the disclosure is applied to big data, artificial intelligence and the like.

Description

Push processing method, related device and medium
Technical Field
The present disclosure relates to the field of artificial intelligence, and in particular, to a push processing method, related apparatus, and medium.
Background
On the content pushing platform, the probability that the object completes each task (praise, comment and the like) to the content to be pushed is predicted based on the object characteristics and the content characteristics of the content to be pushed by utilizing the pushing processing model, and the content to be pushed is matched for the object according to the probability. Therefore, it is important that the push processing model be able to accurately predict the probability that an object will complete each task with respect to the content to be pushed. The push processing model applied in the prior art scheme has lower prediction accuracy, and thus, when pushing content to an object, the push accuracy is lower.
Disclosure of Invention
The embodiment of the disclosure provides a pushing processing method, a related device and a medium, which can improve the accuracy of content pushing.
According to an aspect of the present disclosure, there is provided a push processing method, including:
acquiring object characteristics of a target object and content characteristics to be pushed of content to be pushed;
inputting the object characteristics and the to-be-pushed content characteristics into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks;
determining the sorting score of the content to be pushed based on the task completion probabilities of a plurality of tasks corresponding to the content characteristics to be pushed;
ranking the plurality of content to be pushed based on ranking scores of the plurality of content to be pushed;
the task completion probability prediction model is trained based on sample task completion probabilities of a plurality of tasks, a first auxiliary probability and a second auxiliary probability, wherein the sample task completion probability is predicted by the task completion probability prediction model based on sample object characteristics and sample push content characteristics, the first auxiliary probability is predicted by a first auxiliary model based on the sample object characteristics, the second auxiliary probability is predicted by a second auxiliary model based on the sample push content characteristics, and the first auxiliary model and the second auxiliary model are respectively connected with the task completion probability prediction model in parallel.
According to an aspect of the present disclosure, there is provided a push processing device, including:
the first acquisition unit is used for acquiring object characteristics of a target object and content characteristics to be pushed of content to be pushed;
the first input unit is used for inputting the object characteristics and the characteristics of the content to be pushed into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks;
the determining unit is used for determining the sorting score of the content to be pushed based on the task completion probabilities of the tasks corresponding to the content characteristics to be pushed;
the sorting unit is used for sorting the plurality of content to be pushed based on the sorting scores of the plurality of content to be pushed;
the task completion probability prediction model is trained based on sample task completion probabilities of a plurality of tasks, a first auxiliary probability and a second auxiliary probability, wherein the sample task completion probability is predicted by the task completion probability prediction model based on sample object characteristics and sample push content characteristics, the first auxiliary probability is predicted by a first auxiliary model based on the sample object characteristics, the second auxiliary probability is predicted by a second auxiliary model based on the sample push content characteristics, and the first auxiliary model and the second auxiliary model are respectively connected with the task completion probability prediction model in parallel.
Optionally, the determining unit is specifically configured to:
acquiring first task weights of a plurality of tasks;
and based on the first task weights of the tasks, weighting and summing the task completion probabilities of the tasks corresponding to the characteristics of the content to be pushed, and obtaining the sorting score of the content to be pushed.
Optionally, the push processing device further includes:
the second acquisition unit is used for acquiring scene characteristics of the target object;
the first input unit is specifically configured to: and inputting the object features, the scene features and the to-be-pushed content features into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks.
Optionally, the task completion probability prediction model is specifically trained by the following modes:
obtaining a push event sample, wherein the push event sample comprises the sample object characteristics and the sample push content characteristics;
inputting the sample object features and the sample push content features into the task completion probability prediction model to obtain the sample task completion probabilities of a plurality of tasks, inputting the sample object features into the first auxiliary model to obtain the first auxiliary probabilities of a plurality of tasks, and inputting the sample push content features into the second auxiliary model to obtain the second auxiliary probabilities of a plurality of tasks;
Determining a second task weight for the task based on the sample task completion probability, the first auxiliary probability, and the second auxiliary probability;
and carrying out weighted sum operation on the task completion probability prediction model, the first auxiliary model and the second auxiliary model aiming at a first loss function of the task by using the second task weight of each task to obtain a second loss function of the push event sample, and training the task completion probability prediction model, the first auxiliary model and the second auxiliary model based on the second loss function.
Optionally, the push event sample further includes a tag for a plurality of tasks, the tag indicating whether the sample object completes the task for the sample push content;
and performing weighted sum operation on the task completion probability prediction model, the first auxiliary model and the second auxiliary model by using the second task weight of each task for the first loss function of the task to obtain a second loss function of the push event sample, wherein the weighted sum operation comprises the following steps:
determining the first loss function for the task based on the label of the task, the sample task completion probability, the first auxiliary probability, and the second auxiliary probability;
And carrying out weighted sum operation on the first loss function of each task by using the second task weight of each task to obtain a second loss function of the pushing event sample.
Optionally, the determining the first loss function of the task based on the label of the task, the sample task completion probability, the first auxiliary probability, and the second auxiliary probability includes:
determining a first sub-loss function of the task completion probability prediction model for the task based on the label of the task and the sample task completion probability;
determining a second sub-loss function of the first auxiliary model for the task based on the label of the task and the first auxiliary probability;
determining a third sub-loss function of the second auxiliary model for the task based on the label of the task and the second auxiliary probability;
the first loss function is determined based on the first, second, and third sub-loss functions.
Optionally, the determining the second task weight of the task based on the sample task completion probability, the first auxiliary probability, and the second auxiliary probability includes:
Determining a first difference of the sample task completion probability and the first auxiliary probability;
determining a second difference of the sample task completion probability and the second auxiliary probability;
a second task weight for the task is determined based on the first difference and the second difference.
Optionally, the determining the second task weight of the task based on the first difference and the second difference includes:
obtaining a first parameter and a second parameter, wherein the first parameter indicates a side severity of an impact on the push content, and the second parameter indicates an amplification index of the impact of the task on the object and the push content;
the second task weight is determined based on the first difference, the second difference, the first parameter, and the second parameter.
Optionally, the determining the second task weight based on the first difference, the second difference, the first parameter, and the second parameter includes:
adding a predetermined constant to the first difference to obtain a first enhanced difference;
adding the predetermined constant to the second difference to obtain a second enhanced difference;
determining a sum of a product of the second enhancement difference and the first parameter and the first enhancement difference;
And taking the second parameter of the sum to the power as the second task weight.
Optionally, the push event sample is out of a push event sample set comprising a plurality of the push event samples;
the training the task completion probability prediction model, the first auxiliary model, and the second auxiliary model based on the second loss function, comprising:
determining a third loss function for the set of push event samples based on the second loss function for each of the push event samples in the set of push event samples;
training the task completion probability prediction model, the first auxiliary model, and the second auxiliary model based on the third loss function.
Optionally, the determining a third loss function of the push event sample set based on the second loss function of each of the push event samples in the push event sample set includes:
acquiring a sample weight of each push event sample in the push event sample set;
and based on the sample weight, carrying out weighted sum on the second loss function of each push event sample to obtain the third loss function.
Optionally, the inputting the sample object feature and the sample push content feature into the task completion probability prediction model to obtain the sample task completion probabilities of a plurality of tasks, inputting the sample object feature into the first auxiliary model to obtain the first auxiliary probabilities of a plurality of tasks, and inputting the sample push content feature into the second auxiliary model to obtain the second auxiliary probabilities of a plurality of tasks includes:
inputting the sample object features and the sample push content features into an embedding layer to obtain a first vector corresponding to the sample object features and a second vector corresponding to the sample push content features;
inputting the first vector and the second vector into the task completion probability prediction model to obtain the sample task completion probabilities of a plurality of tasks, inputting the first vector into the first auxiliary model to obtain the first auxiliary probabilities of a plurality of tasks, and inputting the second vector into the second auxiliary model to obtain the second auxiliary probabilities of a plurality of tasks;
the training the task completion probability prediction model, the first auxiliary model, and the second auxiliary model based on the third loss function, comprising:
Adjusting model node weights in the task completion probability prediction model, the first auxiliary model and the second auxiliary model according to a backward propagation algorithm of the gradient by utilizing the third loss function;
the gradient of first layer node weights of the first auxiliary model and the second auxiliary model is prevented from propagating towards the embedding layer.
Optionally, the inputting the sample object feature and the sample push content feature into an embedding layer, to obtain a first vector corresponding to the sample object feature and a second vector corresponding to the sample push content feature, includes:
inputting the sample object features and the sample push content features into an embedding layer to obtain a first initial vector corresponding to the sample object features and a second initial vector corresponding to the sample push content features;
acquiring a first vector length of the first vector and a second vector length of the second vector;
pooling the first initial vector based on the first vector length to obtain the first vector;
and based on the second vector length, pooling the second initial vector to obtain the second vector.
Optionally, the task completion probability prediction model includes a first cascade layer, a plurality of first expert sub-models, a plurality of first gating nodes corresponding to a plurality of the tasks, and a plurality of first prediction sub-models;
the step of inputting the sample object feature and the sample push content feature into the task completion probability prediction model to obtain the sample task completion probabilities of a plurality of tasks, comprises the following steps:
cascading a first vector corresponding to the sample object feature and a second vector corresponding to the sample push content feature into a first cascade vector through the first cascade layer;
inputting the first cascade vector into a plurality of the first expert sub-models;
the output of a plurality of first expert sub-models is weighted and summed through the first gating node corresponding to each task to obtain a first intermediate vector corresponding to the task;
and inputting a first intermediate vector corresponding to the task into the first predictor model corresponding to the task to obtain the sample task completion probability of the task.
Optionally, the step of obtaining a first intermediate vector corresponding to each task by performing weighted summation on the outputs of a plurality of first expert sub-models through the first gating node corresponding to the task includes:
Acquiring weight vectors of the first gating nodes, wherein the weight vectors indicate weights of a plurality of first expert sub-models;
and through the first gating node, the weighted sum is carried out on the outputs of the plurality of first expert sub-models by utilizing the weight vector, so that the first intermediate vector corresponding to the task is obtained.
Optionally, the obtaining the weight vector of the first gating node includes:
obtaining a first matrix, wherein the number of rows of the first matrix is the number of the first expert sub-models, and the number of columns is the dimension of the first cascade vector;
multiplying the first matrix with the transpose of the first cascade vector, and performing normalized index processing on the multiplication result to obtain the weight vector of the first gating node.
According to an aspect of the present disclosure, there is provided an electronic device including a memory storing a computer program and a processor implementing the push processing method as described above when executing the computer program.
According to an aspect of the present disclosure, there is provided a computer-readable storage medium storing a computer program which, when executed by a processor, implements the push processing method as described above.
According to an aspect of the present disclosure, there is provided a computer program product comprising a computer program, which is read and executed by a processor of a computer device, causing the computer device to perform the push processing method as described above.
In the embodiment of the disclosure, object characteristics of a target object and characteristics of content to be pushed are input into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks; determining the sorting score of the content to be pushed based on task completion probabilities of a plurality of tasks corresponding to the content characteristics to be pushed; and sorting the plurality of contents to be pushed according to the sorting score, and pushing the contents to be pushed to the target object according to the sorting. In order to train the task completion probability prediction model, a first auxiliary model and a second auxiliary model are constructed in parallel with the task completion probability prediction model. And inputting the sample object characteristics and the sample push content characteristics into a task completion probability prediction model to obtain the sample task completion probability of the predicted sample object on the sample push content completion task (praise, comment and the like). Only the sample object features are input into the first auxiliary model, and a first auxiliary probability is obtained, which is used for representing the average probability that the sample object completes tasks (praise and the like) on all contents. It may be natural that a sample object has a high average probability of completing a task (praise, etc.) for all content, which is little gained for distinguishing objects, if it has a high probability of pushing content to complete the task for that sample. Then, only the characteristics of the sample push content are input into a second auxiliary model, so that a second auxiliary probability is obtained, and the second auxiliary probability is used for representing the average probability that the sample push content is completed by the general public (praise and the like). If the average probability that the sample push content is completed by the general public (praise, etc.) is high, it may be natural that the sample object has completed a task on the sample push content that is of little gain to differentiate the push content. According to the embodiment of the disclosure, after the gains of different tasks on distinguishing objects and the gains of distinguishing pushing contents are comprehensively considered, the task completion probability prediction model is trained, so that the task completion probability prediction model can be combined with the task to determine the content pushed to the target object, the prediction accuracy of the task completion probability prediction model is improved, and the pushing accuracy of the content pushed to the target object is further improved.
Additional features and advantages of the disclosure will be set forth in the description which follows, and in part will be apparent from the description, or may be learned by practice of the disclosure. The objectives and other advantages of the disclosure will be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
Drawings
The accompanying drawings are included to provide a further understanding of the disclosed embodiments and are incorporated in and constitute a part of this specification, illustrate embodiments of the disclosure and together with the description serve to explain, without limitation, the disclosed embodiments.
FIG. 1 is a architectural diagram of a push processing method of an embodiment of the present disclosure;
FIG. 2A is a schematic diagram of an interface in which embodiments of the present disclosure are applied in a video content push scenario in an instant session application;
FIG. 2B is another interface schematic of an embodiment of the present disclosure as applied in a video content push scenario in an instant session application;
FIG. 3 is a flow chart of a push processing method according to one embodiment of the present disclosure;
FIG. 4 is a flow chart of the scene feature of FIG. 3 in which the acquisition target object is added;
FIG. 5 is a flow chart of a process for training a task completion probability prediction model;
FIG. 6 is a flow chart of step 520 of FIG. 5;
FIG. 7 is a flowchart of step 610 of FIG. 6 in which a first vector and a second vector are obtained;
fig. 8 is a schematic diagram of a first vector of the first initial vector Chi Huawei;
FIG. 9 is a flowchart of the task completion probability prediction model of step 520 of FIG. 5 for deriving sample task completion probabilities based on sample object features and sample push content features;
FIG. 10 is a schematic diagram of a task completion probability prediction model deriving sample task completion probabilities based on sample object features and sample push content features;
FIG. 11 is a flow chart of step 930 of FIG. 9;
FIG. 12 is a flow chart of step 1110 of FIG. 11;
FIG. 13 is a flowchart of the first assist model of step 520 of FIG. 5 deriving a first assist probability based on sample object features;
FIG. 14 is a flow chart of the second assist model of step 520 of FIG. 5 deriving a second assist probability based on sample push content characteristics;
FIG. 15 is an overall schematic of step 520 of FIG. 5;
FIG. 16 is a flow chart of determining a second task weight for the task in step 530 of FIG. 5;
FIG. 17 is a flow chart of step 1630 of FIG. 16;
FIG. 18 is a flow chart of step 1720 of FIG. 17;
FIG. 19 is a flow chart of determining a second loss function in step 540 of FIG. 5;
FIG. 20 is a flow chart of determining a first loss function in step 1910 of FIG. 19;
FIG. 21 is a flow chart of step 540 of FIG. 5;
FIG. 22 is a flow chart of determining a third loss function in step 2110 of FIG. 21;
FIG. 23 is a flow chart of step 540 of FIG. 5;
FIG. 24 is a schematic diagram of adjusting model node weights according to a backward propagation algorithm of gradients;
FIG. 25 is a flow chart of step 330 of FIG. 3;
FIG. 26 is a flow chart of step 2510 in FIG. 25;
FIG. 27 is a detailed view of one implementation of a push processing method of an embodiment of the present disclosure;
FIG. 28 is a block diagram of a push processing device of an embodiment of the present disclosure;
fig. 29 is a terminal structure diagram of the push processing method shown in fig. 3 according to an embodiment of the present disclosure;
fig. 30 is a server configuration diagram of the push processing method shown in fig. 3 according to an embodiment of the present disclosure.
Detailed Description
In order to make the objects, technical solutions and advantages of the present disclosure more apparent, the present disclosure will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present disclosure.
Before proceeding to further detailed description of the disclosed embodiments, the terms and terms involved in the disclosed embodiments are described, which are applicable to the following explanation:
deep neural network: is a multi-layer unsupervised neural network. The deep neural network takes the output characteristics of the upper layer as the input of the lower layer to perform characteristic learning, and after the layer-by-layer characteristic mapping, the characteristics of the existing space sample are mapped to another characteristic space, so that the existing input is learned to have better characteristic expression. The deep neural network has a plurality of non-linear mapped feature transformations that can fit highly complex functions.
Gradient descent algorithm: a loss function minimization method calculates a gradient of a current position of a loss function, and updates parameters toward a direction in which the gradient decreases to find an optimal solution so that a value of the loss function is minimized.
Back propagation algorithm: a training and learning method in deep learning is used for adjusting weights among nodes in a deep neural network so as to minimize a mean square error between a predicted value and an actual value of the deep neural network. This modification is done "backward", i.e. by the output layer, via each hidden layer, to the first hidden layer. The specific process comprises the following steps: calculating the error of each node of the output layer by using the predicted value and the actual value of the deep neural network; updating the weight of the output layer based on the error; transmitting the error of the output layer to the hidden layer; updating the weight of the hidden layer.
Normalized index (softmax function): one K-dimensional vector containing arbitrary real numbers is compressed into another K-dimensional vector such that each element ranges between (0, 1) and the sum of all elements is 1.
Cross entropy: the degree of difference between two different probability distributions in the same random variable is measured and expressed in machine learning as the difference between the true probability distribution and the predicted probability distribution. Two probability distributions p and q are provided, p represents the real distribution, q represents the model predicted distribution, and the definition of the cross entropy is as follows:
representing the probability of occurrence of the ith event in the real distribution,/->Representing the probability of occurrence of the ith event in the model predictive distribution. The smaller the value of the cross entropy, the better the model prediction effect. Therefore, cross entropy is often used as a loss function to guide the optimization of the model.
System architecture and scenario description applied to embodiments of the present disclosure
Fig. 1 is a system architecture diagram to which a push processing method according to an embodiment of the present disclosure is applied. It comprises the following steps: server 110, gateway 120, internet 130, and terminal 140.
Server 110 refers to a computer system that determines content pushed to a target object using a task completion probability prediction model. The stability, security, performance, etc. of the server 110 are all required to be higher than those of the terminal 140. The server 110 may be one high-performance computer in a network platform, a combination of a portion (e.g., virtual machine) of a plurality of high-performance computers, etc. The server 110 may also communicate with the internet 130 via wired or wireless means to exchange data.
Gateway 120 is also known as an intersubnetwork connector, protocol converter. Gateway 120 implements network interconnections at the transport layer, and is a computer system or device that acts as a translation. Gateway 120 is a translator between two systems that use different communication protocols, data formats, or languages, and even architectures that are quite different. At the same time, gateway 120 may also provide filtering and security functions. The message sent by the terminal 140 to the server 110 is to be sent to the corresponding server 110 through the gateway 120. A message sent by the server 110 to the terminal 140 is also sent to the corresponding terminal 140 through the gateway 120.
The terminal 140 is a device for pushing content so that an object views the pushed content. It includes desktop computers, laptops, PDAs (personal digital assistants), cell phones, car terminals, home theater terminals, dedicated terminals, etc. In addition, the device can be a single device or a set of a plurality of devices. For example, a plurality of devices are connected via a lan, and a display device is commonly used for cooperative operation, so as to form a terminal 140. The terminal 140 may also communicate with the internet 130 in a wired or wireless manner, exchanging data.
The disclosed embodiments may be applied in a variety of scenarios, such as the scenario shown in fig. 2A and 2B in which video content is pushed to an object in an instant session application, and the like.
As shown in the interface of the instant session application in the terminal 140 shown in fig. 2A, the instant session application may be used to communicate with contacts in real-time. After triggering the "Session" option in the lower function bar, a list of conversations with the plurality of contacts is displayed. Instant session applications may also be used to view video. After triggering the "video" option in the function bar, the object interfaces with the instant session application as shown in FIG. 2B.
In fig. 2B, the instant session application opens the video interface and plays the pushed video content. The interface also displays the praise, collection and comment number obtained by the current video content before the current time. The object may also perform praise, collection, comment, etc. operations on the current video content in the interface. If the object wants to watch other video, the next video can be switched by a specific operation (e.g., sliding the screen up). The video content pushed to the object is determined by the task completion probability prediction model running in the server 110, that is, the video content that the object may be interested in is predicted according to the prediction result of the task completion probability prediction model, and the video content is pushed to the instant session application of the object. Therefore, it is important that the task completion probability prediction model can accurately judge the preference of the object and accurately push video content for the object according to the preference. The embodiment of the disclosure can improve the accuracy of pushing video content.
General description of embodiments of the disclosure
According to one embodiment of the present disclosure, a push processing method is provided.
The push processing method is a process of pushing content of interest of the target object to the terminal 140 of the target object. The target object is an object to view the content to be pushed. The embodiment of the disclosure can be applied to pushing different types of content, and the content to be pushed can be various types of pictures, videos, articles, applications and the like. When the push content is determined, the completion condition of different tasks of the target object to the push content is considered, and the push content is determined based on the task completion condition. A task refers to an operation performed by a target object on push content, for example: praise, collection, comment, complete viewing, etc. Determining the task completion of the target object requires the use of a task completion probability prediction model.
The push processing method in the embodiment of the present disclosure is executed by the server 110, after the execution is completed, the determined push content is transmitted to the terminal 140 through the internet 130, and the terminal 140 displays the push content to the target object.
As shown in fig. 3, according to one embodiment of the present disclosure, a push processing method includes:
step 310, obtaining object characteristics of a target object and content characteristics to be pushed of content to be pushed;
Step 320, inputting the object features and the features of the content to be pushed into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks, wherein the task completion probability prediction model is trained based on sample task completion probabilities of the plurality of tasks, a first auxiliary probability and a second auxiliary probability, the sample task completion probability is predicted by the task completion probability prediction model based on the sample object features and the sample push content features, the first auxiliary probability is predicted by the first auxiliary model based on the sample object features, the second auxiliary probability is predicted by the second auxiliary model based on the sample push content features, and the first auxiliary model and the second auxiliary model are respectively connected with the task completion probability prediction model in parallel;
step 330, determining a ranking score of the content to be pushed based on task completion probabilities of a plurality of tasks corresponding to the content to be pushed;
step 340, sorting the plurality of content to be pushed based on the sorting scores of the plurality of content to be pushed.
Steps 310-340 are described in detail below.
Detailed description of step 310
In step 310, object features refer to features associated with a target object. The object features may be features of the target object itself, such as features of the target object's industry, education level, etc. The preference of the target object for push content may be different if the feature values are different for the same feature. For example, the push content of target object preferences may be different for different industries. Taking video content as an example, an object in the medical industry may be more concerned with related videos of health care classes, and an object in the news industry may be more concerned with related videos of hot events.
Note that, when the object feature of the target object is acquired, consent of the target object is solicited in advance. Moreover, the collection, use, and handling of these object features, etc., may comply with relevant laws and regulations and standards. When requesting the consent of the target object, the individual permission or individual consent of the target object can be obtained through a popup window or a jump to a confirmation page or the like.
The object features may also be object features of an object group (e.g., family, workgroup) in which the target object is located. This is because, in some cases, the preference of the target object for push content is affected by the group of objects in which it is located. For example, the target object itself likes to see video content related to music, but because there are objects in the target object's family group that engage in the news industry, the target object may also be interested in related videos of hot events. By considering the object characteristics of the object group where the target object is, the comprehensiveness of the characteristics in the pushing event sample can be improved, so that the accuracy of completing the probability prediction model by utilizing the pushing event training task is improved. Similarly, when the object characteristics of the object group (such as family and workgroup) where the target object is located are acquired, the consent of the members of the object group is also requested in advance, so that the description is omitted.
In one embodiment, object characteristics of the target object may be obtained through registration information. The registration information here may be registration information of the target object on the terminal 140, registration information in the push content application, or the like. The terminal 140 may require the target object to register when the target object uses the terminal 140 for the first time, and information such as industry needs to be filled in as registration information when registering. In this way, object features can be obtained from the terminal 140 used by the target object. The target object also needs to register when the push content application is first used, and may be required to fill in information such as industry and the like as registration information. Thus, the object feature can also be acquired using the registration information of the application. The advantage of obtaining object features through registration information is: convenient and fast, obtain efficient. When registration information of the target object is acquired, as described above, consent of the target object is also required in advance, which is not described here again.
In another embodiment, the object characteristics of the target object may be obtained from a target historical viewing log of the target object for a predetermined period of time prior to the current point in time. The target history viewing log refers to a related record of push content viewed by the target object for a predetermined period of time prior to the current point in time. The predetermined period of time may be one hour, one day, one week, one month, etc. The predetermined period of time may be determined based on the frequency with which the target object views the push content. If the frequency of viewing the push content by the target object is higher, the current object characteristics of the target object can be obtained through the viewing record in a shorter time period; if the frequency of targeted historical viewing of push content is low, then a longer period of viewing records need to be used to ensure that sufficient data can be used to obtain the object characteristics. The predetermined period of time may also be determined based on the type of push content. For example, if the push content is video content, a longer period of time may be used as the predetermined period of time to acquire long-term preference of the target object; if the push content is news content, since news is time-efficient, a shorter period of time needs to be used as the predetermined period of time. The target history view log of the target object is acquired, and consent of the target object is also solicited in advance.
In this embodiment, the target historical viewing log of the target object is input into the object feature extraction model, and the object feature extraction model may predict the object feature of the target object according to the data in the historical viewing log. For example, if the target object views more "music", "movie" types of content in the target history viewing log, the object feature extraction model predicts that the object feature of the target object may include "music preference", "movie preference", and the like.
The advantage of obtaining the object feature from the target historical viewing log of the target object within a predetermined period of time before the current point in time is: the interest degree of the target object for the watched content can be accurately acquired through the target historical watching log, the preference of the target object can be predicted based on the interest degree, and the accuracy of acquiring the object characteristics of the target object is improved.
The content characteristics are used to represent characteristics of aspects of the content to be pushed, such as content type, content length, content distribution time, and content keywords. The preference of the target object for push content may also be different if the feature values are different for the same content feature. For example, the content length of push content may be different for different object preferences. Taking video content as an example, some objects may like to watch short video content for less than 3 minutes, and some objects may like to watch long video content for more than 10 minutes.
Note that, when the content characteristics of the push content are acquired, the consent of the content publisher of the push content is solicited in advance. Moreover, the collection, use, handling, etc. of the content features of these pushed content may comply with relevant laws and regulations. The specific manner is the same as that of soliciting consent from the target object, and will not be described in detail here.
In one embodiment, obtaining a content to be pushed feature of the content to be pushed includes: and screening the screened content set from the content set to be screened, and taking the characteristic of each screened content in the screened content set as the characteristic of the content to be pushed in turn. The content set to be filtered refers to an unfiltered content set containing various types of content. The content set to be screened contains a plurality of content which is not interested by the target object, so that the content in the content set to be screened is subjected to preliminary screening to form a screened content set, the calculated amount of a task completion probability prediction model is reduced, and the pushing efficiency is improved.
Detailed description of step 320
In step 320, the object feature and the feature of the content to be pushed are input into a task completion probability prediction model, so as to obtain task completion probabilities of a plurality of tasks.
In one embodiment, as shown in fig. 4, before inputting the object feature and the feature of the content to be pushed into the task completion probability prediction model to obtain the task completion probabilities of the plurality of tasks, the push processing method further includes:
Step 315, obtaining scene characteristics of the target object;
inputting the object characteristics and the characteristics of the content to be pushed into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks, wherein the task completion probability prediction model comprises the following steps:
and step 325, inputting the object characteristics, the scene characteristics and the characteristics of the content to be pushed into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks.
Scene characteristics refer to characteristics of the current scene in which the target object is located when viewing the push content. The same object may also want to view different pushed content in different scenarios. For example, when an object is in a work scenario, it may want to view push content related to the work, if the push content is of interest to the object, the object may perform a task of collection on the push content so that it can be viewed at any time when needed; when an object is at home, it may be more desirable to view push content related to its own preferences, and the object may be more likely to perform praise tasks on push content of interest. The scene features include: the geographical region feature, time period feature, input day type feature (weekday, weekend, or holiday) etc. where the target object is located when viewing the sample push content.
When the scene feature of the target object is acquired, the agreement of the target object is obtained in advance, and similar to the above, the description is omitted here.
The geographic area characteristics refer to characteristics of the geographic area in which the target object is located. The geographical area may be an administrative geographical area, such as city a, city B, etc., or may be physically divided geographical areas on the map, such as a school XX area, a mall XX area, etc. The administrative geographical area is influential to the push content that the subject wants to view. For example, if the object is in city a, the push content may be a tourist attraction or a food culture associated with city a, etc. The geographical area divided by the entity is also influential for the push content that the object wants to view. For example, if the object is in the XX school zone, the push content may be educational related content; if the object is in the XX mall area, the push content may be activity information or featured items in the mall, etc.
The characteristics of the geographic region in which the target object is located may be obtained from the location information of the terminal 140 of the target object. The terminal 140 of the target object has a positioning device such as GPS and beidou, and the positioning device can continuously acquire the positioning information of the terminal 140. The geographic area in which the target object is located when viewing the push content can be determined as a geographic area feature according to the positioning information. For example, according to the GPS positioning information obtained by the positioning device, mapping the GPS positioning information to an electronic map, and finding that the GPS positioning information belongs to city a, obtaining the geographical area feature of the city a when viewing the push content.
The time period feature refers to the time period of the day that the target object is in when viewing the push content, e.g., 9:00-11:00,11:00-13:00,13:00-18:00, 18:00-22:00, etc. Since the object's activities within different time periods of the day may vary, the purpose of viewing the push content may also vary, and thus the push content may be affected by the time period characteristics. For example, at 9:00-11:00, the object may be working, and thus, the object viewing push content is likely to want to view content related to the work; at 18:00-22:00, the subject is often resting, at which time it is likely that he wants to view content related to his own interests.
The input day type feature refers to a feature of the type of day when the target object views the push content. It is divided into weekdays, weekends, holidays, etc. The type of push content that an object wants to view may be different on different types of days. For example, on weekdays (monday to friday), the subject is often working, and the push content that is desired to be viewed may be work-related; on weekends (Saturday and sunday), the subject may want to view the impression that is relevant to his own hobbies when he does not need to work; on a holiday, the subject may want to view push content related to the holiday culture.
The time period feature and the input day type feature may be obtained from the system time of the terminal 140 of the target object. The system time generally includes year, month, day of week, hour, minute, second information. The input time period characteristics can be determined from the hour, minute, and second information. For example, the current time is 13 points 52 minutes 26 seconds, it is determined that it belongs to 13:00-18:00, i.e., the input time period is characterized by 13:00-18:00. The date is 2023, 6, 20 days tuesday, then the current input day type is determined to be characterized as the workday.
The object features, the scene features and the features of the content to be pushed are input into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks, and the task completion probabilities at the moment represent the task completion probabilities of the target object in the current scene and the content to be pushed and related to the plurality of tasks.
The method for determining the task completion probability by utilizing the scene characteristics and the object characteristics and the content characteristics to be pushed has the advantages that: the influence of the scene on the delivery of the push content to the object is considered, and the push accuracy is improved.
The task completion probability prediction model is used for determining task completion probabilities of the target object on the push content according to the object characteristics of the target object and the content characteristics of the content to be pushed. The task completion probability refers to the probability that the target object performs the task on the content to be pushed, for example: probability of endorsing the push content, probability of commenting on the push content, and the like.
The task completion probability prediction model is trained based on sample task completion probabilities of a plurality of tasks, a first auxiliary probability and a second auxiliary probability, wherein the sample task completion probability is predicted by the task completion probability prediction model based on sample object characteristics and sample push content characteristics, the first auxiliary probability is predicted by the first auxiliary model based on the sample object characteristics, the second auxiliary probability is predicted by the second auxiliary model based on the sample push content characteristics, and the first auxiliary model and the second auxiliary model are respectively connected with the task completion probability prediction model in parallel.
In one embodiment, as shown in fig. 5, the task completion probability prediction model is specifically trained by:
step 510, obtaining a push event sample, wherein the push event sample comprises sample object characteristics and sample push content characteristics;
step 520, inputting the sample object features and the sample push content features into a task completion probability prediction model to obtain sample task completion probabilities of a plurality of tasks, inputting the sample object features into a first auxiliary model to obtain first auxiliary probabilities of the plurality of tasks, and inputting the sample push content features into a second auxiliary model to obtain second auxiliary probabilities of the plurality of tasks;
Step 530, determining a second task weight of the task based on the sample task completion probability, the first auxiliary probability, and the second auxiliary probability;
step 540, performing weighted sum operation on the task completion probability prediction model, the first auxiliary model and the second auxiliary model aiming at the first loss function of the task by using the second task weight of each task to obtain a second loss function of the pushing event sample, and training the task completion probability prediction model, the first auxiliary model and the second auxiliary model based on the second loss function.
In step 510, a push event sample indicates an event that delivers sample push content to a sample object. Taking object features of sample objects in the event as sample object features; taking the content characteristics of the sample push content as sample push content characteristics; the sample object features and the sample push content features form a push event sample. For example, if the content a is delivered to the object a, the push event sample includes the object feature of the object a and the content feature of the content a. The content of the sample object features is similar to the object features of the target object in the foregoing embodiment, and will not be described herein again; the sample push content features are similar to those of the content to be pushed in the foregoing embodiments, and will not be described herein.
In one embodiment, obtaining a push event sample includes: acquiring an application history record in a preset time period before a current time point in a push application; push event samples are extracted from the application history.
The application history refers to a plurality of viewing records of the push content viewed by the object within a predetermined period of time prior to the current point in time in the push content application. The predetermined period of time may be one hour, one day, one week, one month, etc.
Each view record in the application history record includes object characteristics (e.g., object industry, education level, hobbies, etc.) of the object and content characteristics (e.g., content type, content length, etc.) of the pushed content. For example, the application history in a day before the current point in time in a certain video delivery application shown in table 1.
TABLE 1
Through the application history record shown in table 1 in the video delivery application within the day before the current time point, a plurality of view logs can be obtained, and each view log can be used as a push event sample. For example, with the first view record in the historical view log as a push event sample, sample object features include: education, study, music, etc., sample push content features include: movies, 20 minutes, etc.
The push event sample is obtained through the application history record, the viewing record which truly occurs in the push application is used as a training sample, so that the trained task completion probability prediction model is more fit with content delivery in the push application, and the prediction accuracy of the task completion probability prediction model is improved.
In an embodiment, the pushing event sample further includes a sample scene feature, where the sample scene feature is a scene feature where the sample object is located when viewing the pushing content of the sample, where the sample scene feature is the same as the scene feature in the foregoing embodiment, and will not be described herein.
In step 520, the sample object features and the sample push content features are input into a task completion probability prediction model to obtain sample task completion probabilities for a plurality of tasks. The sample task completion probability represents the task completion probability for a plurality of tasks for sample push content by a sample object. And inputting the characteristics of the sample object into a first auxiliary model to obtain first auxiliary probabilities of a plurality of tasks. The first auxiliary probability represents the average probability that the sample object will complete a task for all content. And inputting the sample pushing content characteristics into a second auxiliary model to obtain second auxiliary probabilities of the tasks. The second auxiliary probability represents an average probability that the sample push content is completed by the general public.
Based on the foregoing embodiment, the sample scene feature is included in the push event sample, so in step 520, the sample object feature and the sample push content feature are input into the task completion probability prediction model to obtain task completion probabilities of a plurality of tasks, including: and inputting the sample object features, the sample scene features and the sample push content features into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks.
Since the sample scene features are features related to the sample object, the sample scene features can also be used to predict the average probability of completion of the sample object for all push content, for a task. Thus, inputting the sample object features into the first auxiliary model, resulting in a first auxiliary probability for the plurality of tasks, comprising: the sample object features and the sample scene features are input into a first auxiliary model to obtain first auxiliary probabilities of a plurality of tasks.
The first auxiliary probability at this time represents the average probability that the sample object completes the task for all push content in the sample scene.
In one embodiment, as shown in fig. 6, inputting a sample object feature and a sample push content feature into a task completion probability prediction model to obtain sample task completion probabilities of a plurality of tasks, inputting the sample object feature into a first auxiliary model to obtain first auxiliary probabilities of the plurality of tasks, and inputting the sample push content feature into a second auxiliary model to obtain second auxiliary probabilities of the plurality of tasks, including:
Step 610, inputting the sample object feature and the sample push content feature into an embedding layer to obtain a first vector corresponding to the sample object feature and a second vector corresponding to the sample push content feature;
step 620, inputting the first vector and the second vector into a task completion probability prediction model to obtain sample task completion probabilities of a plurality of tasks, inputting the first vector into a first auxiliary model to obtain first auxiliary probabilities of the plurality of tasks, and inputting the second vector into a second auxiliary model to obtain second auxiliary probabilities of the plurality of tasks.
Sample object features and sample push content features come in a variety of types, such as character-type features, or variable length sequence features. If the sample object features and the sample push content features are directly input into the model, the model cannot process the features. Thus, there is a need to translate sample object features and sample push content features into a model processable form. The purpose of the embedding layer is to convert the sample object features and sample push content features into a vector form.
The embedded layer should handle features of different feature types in different ways. The feature type may be a character type feature, such as an educational level feature in a sample object feature, or a content length feature in a sample push content feature, or the like. When the feature type is a character type feature, the feature is mapped to a vector representation using a vector conversion reference table in the embedded layer. For example, one example of a vector conversion reference table is shown in Table 2.
TABLE 2
Referring to table 2, when the education-level characteristic of the sample object is "family", the first vector corresponding to the education-level characteristic after passing through the embedded layer is "1010".
The feature type may also be an indefinite length sequence feature, such as an object custom signature feature in a sample object feature, or a content custom tag feature in a sample push content feature, or the like. Because the length of the features is uncertain, if the features are directly spliced after being converted into corresponding vectors one by one according to characters, the length of the obtained final result is also uncertain, which is unfavorable for model processing of the features of the sequence with the indefinite length. Thus, in one embodiment, as shown in fig. 7, inputting the sample object feature and the sample push content feature into the embedding layer, resulting in a first vector corresponding to the sample object feature and a second vector corresponding to the sample push content feature, comprising:
step 710, inputting the sample object feature and the sample push content feature into an embedding layer to obtain a first initial vector corresponding to the sample object feature and a second initial vector corresponding to the sample push content feature;
step 720, obtaining a first vector length of the first vector and a second vector length of the second vector;
Step 730, pooling the first initial vector based on the first vector length to obtain a first vector;
step 740, based on the second vector length, pooling the second initial vector to obtain a second vector.
And inputting the characteristics of the sample object with the indefinite length into an embedding layer, mapping each character in the characteristics into a corresponding vector according to a vector conversion reference table, and splicing the vectors corresponding to all the characters together to form a first initial vector. Similarly, the sample push content features of indefinite length are input into the embedded layer to form a second initial vector.
The first vector is a vector obtained by pooling the first initial vector, and the second vector is a vector obtained by pooling the second initial vector. The first vector length is a length of a preset first vector and the second vector length is a length of a preset second vector. And controlling the lengths of the input sample object features and the sample push content features by presetting the first vector length and the second vector length so that the model processes the corresponding features according to the fixed length.
The pooling process is a process of reducing the dimension of the high-dimension vector. Pooling the first initial vector based on the first vector length to obtain a first vector, comprising: determining a capacity of the neighborhood based on the length of the first initial vector and the length of the first vector; integrating a plurality of characteristic values in a neighboring area in the first initial vector into a new characteristic value; and combining the new characteristic values generated by all the neighborhoods in the first initial value to form a first vector.
And dividing the length of the first initial vector by the length of the first vector, and rounding up the division result to obtain the capacity of the neighborhood. For example, the length of the first initial vector is 23, the length of the first vector is 8, and the obtained neighborhood capacity is 3, that is, every 3 eigenvalues in the first initial vector are integrated into a new eigenvalue, only 2 eigenvalues in the last neighborhood are integrated into a new eigenvalue.
The integration method can be to take the average value of the characteristic values in a neighborhood as a new characteristic value. For example, as shown in fig. 8, the object custom signature feature of the sample object is converted into a first vector. The object custom signature is characterized as "like reading, … …", and the corresponding first initial vector is [0,1,0,0,0,1,1,1,1,1,0, 1,0,0,0,0,0,1,1,1,0,1,1,1]. The first vector length is 8, then the capacity of the neighborhood is 3, and the average value of 3 eigenvalues in each neighborhood is taken as a new eigenvalue corresponding to the neighborhood. The characteristic value of the neighborhood [0,1,0] is 0.33, the characteristic value of the neighborhood [0, 1] is 0.33, and the characteristic values of other neighborhood integration are obtained by the same method. And combining the feature values obtained by integrating all the neighborhoods to form a first vector with the length being the length of the first vector. For example, as shown in FIG. 8, the resulting first vector is [0.33,0.33,1,0.67,0, 0.33,0.67,1]. The integration mode can also be to take the sum of the characteristic values in a neighborhood as the characteristic value of the neighborhood, or input the characteristic value in the neighborhood into a sequence model, and take the output of the sequence model as the characteristic value of the neighborhood.
The process of obtaining the second vector is the same as the process of obtaining the first vector, and will not be described here.
The embodiment of steps 710-740 has the advantage that the feature of the indefinite length is pooled into the vector of the definite length, which is convenient for the model to calculate the dimension of the input vector, and improves the processing efficiency of the model to the vector.
After a first vector corresponding to the sample object feature and a second vector corresponding to the sample push content feature are obtained, the first vector and the second vector are input into the task completion probability prediction model, the first vector is input into the first auxiliary model, and the second vector is input into the second auxiliary model so as to carry out subsequent steps.
An advantage of the embodiments of steps 610-620 is that the sample object features and sample push content features are converted into vector forms that can be processed by the model through the embedding layer, which improves the accuracy of feature conversion vectors and the efficiency of model processing features.
The sample object features and the sample push content features are input into a task completion probability prediction model, namely a first vector corresponding to the sample object features and a second vector corresponding to the sample push content features are input into the task completion probability prediction model, so that sample task completion probabilities of a plurality of tasks are obtained, and the specific process can be represented by a formula 1:
(equation 1).
In the case of the formula 1 of the present invention,the task completion probability prediction model is referred to; />Refers to n vectors, including a first vector and a second vector; />Refers to the sample task completion probability for task t.
In one embodiment, the task completion probability prediction model includes a first cascade layer, a plurality of first expert sub-models, a plurality of first gating nodes corresponding to the plurality of tasks, and a plurality of first prediction sub-models. Thus, as shown in fig. 9, inputting the sample object feature and the sample push content feature into the task completion probability prediction model, obtaining sample task completion probabilities for a plurality of tasks, comprising:
step 910, cascading a first vector corresponding to the sample object feature and a second vector corresponding to the sample push content feature into a first cascade vector through a first cascade layer;
step 920, inputting the first cascade vector into a plurality of first expert sub-models;
step 930, performing weighted summation on the outputs of the plurality of first expert sub-models through first gating nodes corresponding to each task to obtain a first intermediate vector corresponding to the task;
step 940, inputting a first intermediate vector corresponding to the task into a first predictor model corresponding to the task to obtain a task completion probability of the task.
Steps 910-940 are described in detail below in conjunction with fig. 10.
As shown in the bottommost layer of fig. 10, inputting the sample object features into the embedding layer to obtain corresponding first vectors; and inputting the sample pushing content characteristics into the embedded layer to obtain a corresponding second vector. The first vector and the second vector are input into a first cascade layer in the task completion probability prediction model. The first cascade layer is used for cascading all the first vectors and the second vectors into one vector to generate a first cascade vector.
Concatenating the first vector with the second vector may be to concatenate the first vector with the second vector end to end in the order of input, as shown in formula 2:
(equation 2)
In the case of the formula 2 of the present invention,-/>refers to a first vector and a second vector arranged in the order of input to the first cascade layer. And connecting the first vector with the second vector in series to obtain a first cascade vector X. For example, the first vector includes: [1,0,1,1,0,1,1,0]、[0,0,1,0,1, 0,1,0]And [0,0,0,1,1,0,1,1 ]]The method comprises the steps of carrying out a first treatment on the surface of the The second vector includes: [0,1,1,1,1,0,0,1,0,1]And [0,1,1,1,0,0,1,1,1 ]]. Cascading the vectors to obtain a first cascade vector which is: [1,0,1,1,0,1,1,0,0,0,1,0,1,0,1,0,0,0,0,1,1,0,1, 1,0,1,1,1,1,0,0,1,0,1,0,1,1,1,0,0,1,1,1 ]。
The first cascade vector is input into a plurality of first expert sub-models, and the first expert sub-models are used for analyzing and calculating aiming at each dimension of the first cascade vector so as to balance sharing and mutual exclusion before multiplexing. Each task corresponds to one gating node, the gating node receives the outputs from the plurality of first expert sub-models, and the outputs of the plurality of first expert sub-models are weighted and summed to obtain a first intermediate vector corresponding to the task. For example, as shown in fig. 8, a first gating node a corresponding to a task a performs weighted summation on the outputs of a first expert sub-model a, a first expert sub-model B, and a first expert sub-model C to obtain a first intermediate vector a.
In one embodiment, as shown in fig. 11, by the first gating node corresponding to each task, weighting and summing the outputs of the plurality of first expert sub-models to obtain a first intermediate vector corresponding to the task, including:
step 1110, obtaining a weight vector of a first gating node, wherein the weight vector indicates weights of a plurality of first expert sub-models;
and 1120, carrying out weighted summation on the outputs of the plurality of first expert sub-models by using the weight vector through the first gating node to obtain a first intermediate vector corresponding to the task.
The weight vector refers to the weight of the output of the plurality of first expert sub-models for outputting the first intermediate vector corresponding to the task in one first gating node corresponding to the task. The weights of the outputs of the same first expert sub-model may be different in different first gating nodes. This is because different first gating nodes correspond to different tasks for which the contribution of the same first expert sub-model may be different.
In one embodiment, as shown in fig. 12, obtaining a weight vector of a first gating node includes:
step 1210, obtaining a first matrix;
step 1220, multiplying the first matrix with the transpose of the first cascade vector, and performing normalized exponential processing on the multiplication result to obtain a weight vector of the first gating node.
The first matrix is a trainable parameter matrix. The number of rows of the first matrix is the number of the first expert sub-models, and the number of columns is the dimension of the first cascade vector. The dimension of the first concatenated vector is the sum of the dimensions of all the first vectors and the second vectors. For example, the number of the first expert sub-models is 4, the dimension of the first cascade vector is 10, and then the number of rows of the first matrix is 4 and the number of columns is 10.
The transpose multiplication of the first matrix with the first cascade vector corresponds to the multiplication of a matrix with a column vector, the result being a column vector with a dimension of the number of expert sub-models.
For example, the first matrix isThus, it can be seen that the specialThe number of the family models is 3, and the dimension of the first feature vector is 4; the first feature vector is [0,1 ]]Then the result of the multiplication is:
each row in the multiplied result represents in turn the weight of one first expert sub-model in the first gating node in the order of the first expert sub-model in the task completion probability prediction model.
And carrying out normalized index processing on the multiplied result to obtain a weight vector of the first gating node. The normalization index process is to limit each value in the result of the multiplication operation to a specific range so that the values of the weights of different models are in the same range, with comparability. The normalized index processing uses a softmax function. The softmax function inputs the result of multiplication operation of the first matrix and the first cascade vector, and outputs the weight vector of the first gating node. Therefore, the process of calculating the weight vector is as shown in equation 3:
(equation 3).
In the case of the formula 3 of the present invention,designating a first matrix in a first gating node corresponding to a task +.>Refers to the first cascade vector of the first-order vector,refers to a weight vector of a first gating node corresponding to the task. Each row of weight vectors represents the weight of one first expert sub-model.
The advantage of obtaining the weight vector through the normalization index processing in this embodiment is that the first weights of the models are in the same numerical range, so that the influence of different expert sub-models on obtaining the first intermediate vector can be more effectively represented, and the accuracy of obtaining the first intermediate vector is improved.
In step 1120, in the first gating node, the weighted sum of the outputs of the plurality of first expert sub-models is performed by using the weight vector, so as to obtain a first intermediate vector corresponding to the task. The process of obtaining the first intermediate vector is shown in equation 4:
(equation 4).
In the case of the formula 4 of the present invention,a weight vector referring to the first gating node, m representing the mth first expert sub-model, thus,/->Representing the corresponding weight of the mth first expert sub-model in the weight vector, +.>Refers to the output of the mth first expert sub-model. Multiplying the output of the first expert sub-model with the corresponding weight, and adding K (the number of the first expert sub-models) multiplication results to obtain a first intermediate vector- >
An advantage of the embodiments of steps 1110-1120 is that the weighted sum of the outputs of the first expert sub-models based on the weight vectors embodies the different effects of different first expert sub-models on the task, improving the accuracy of determining the first intermediate vectors corresponding to the task.
As shown in fig. 10, after the first gating node outputs the first intermediate vector, the first intermediate vector is input into the first predictor model corresponding to the task, and the first predictor model outputs the sample push content of the sample object and the sample task completion probability about the corresponding task. For example, task a is whether a sample object will praise the sample push content with a task completion probability of 0.85, that is, a sample object has a 85% likelihood of praise the sample push content.
The process of obtaining the sample task completion probability of the corresponding task by the first predictor model is shown in formula 5:
(equation 5).
In the formula 5 of the present invention,representing a first intermediate vector output by a first gating node corresponding to the task; />Representing a first predictor model corresponding to the task, the first predictor model may be a deep neural network model; />The sample task completion probability obtained by the first predictor model is referred to.
In the embodiment of steps 910-940, vector operations are performed by using a plurality of first expert sub-models for different tasks, thereby saving computing resources; and the first gating node is utilized to calculate the weighted sum of the outputs of the plurality of first expert sub-models, so that the influence of different expert sub-models on the task is effectively reflected, and the accuracy of determining the task completion probability is improved.
The sample object feature is input into the first auxiliary model, namely a first vector corresponding to the sample object feature is input into the first auxiliary model, so as to obtain a first auxiliary probability of a plurality of tasks, and the specific process can be represented by a formula 6:
(equation 6)
In the case of the formula 6 of the present invention,refers to a first auxiliary model; />Refers to i first vectors; />Refers to the first auxiliary probability of task t.
In one embodiment, the first auxiliary model includes a second cascade layer, a plurality of second expert sub-models, a plurality of second gating nodes corresponding to the plurality of tasks, and a plurality of second predictor sub-models. Based on the task completion probability prediction model in the foregoing embodiment, the second expert sub-model has the same structure as the first expert sub-model, the second gating node has the same structure as the first gating node, and the second predictor model has the same structure as the first predictor model. Thus, as shown in FIG. 13, inputting sample object features into the first auxiliary model yields a first auxiliary probability for a plurality of tasks, including:
Step 1310, cascading the first vectors corresponding to the characteristics of each sample object into second cascading vectors through the second cascading layer;
step 1320, inputting a second cascade vector into a plurality of second expert sub-models;
step 1330, through the second gating node corresponding to each task, performing weighted summation on the outputs of the plurality of second expert sub-models to obtain a second intermediate vector corresponding to the task;
step 1340, inputting the second intermediate vector corresponding to the task into the second predictor model corresponding to the task, to obtain the first auxiliary probability of the task.
Since the structure in the first auxiliary model is the same as that of the task completion probability prediction model in the foregoing embodiment, the process of determining the first auxiliary probability of the task based on the first auxiliary model is the same as that of determining the task completion probability of the task based on the task completion probability prediction model, and will not be described here again.
The sample push content features are input into a second auxiliary model, namely, a second vector corresponding to the sample push content features is input into the second auxiliary model, so as to obtain second auxiliary probabilities of a plurality of tasks, and the specific process can be represented by a formula 7:
(equation 7)
In the formula 7 of the present invention, Refers to a second auxiliary model; />Refers to j second vectors; />Refers to the second auxiliary probability of task t.
In one embodiment, the second auxiliary model includes a third cascade layer, a plurality of third expert sub-models, a plurality of third gating nodes corresponding to the plurality of tasks, and a plurality of third predictor sub-models. Based on the task completion probability prediction model in the foregoing embodiment, the third cascade layer has the same structure as the first cascade layer, the third expert sub-model has the same structure as the first expert sub-model, the third gating node has the same structure as the first gating node, and the third predictor sub-model has the same structure as the first predictor sub-model. Thus, as shown in fig. 14, inputting the sample push content feature into the second auxiliary model yields a second auxiliary probability for the plurality of tasks, including:
step 1410, cascading the second vectors corresponding to the push content features of each sample into a third cascade vector through a third cascade layer;
step 1420, inputting a third cascade vector into a plurality of third expert sub-models;
step 1430, performing weighted summation on the outputs of the plurality of third expert sub-models through third gating nodes corresponding to each task to obtain a third intermediate vector corresponding to the task;
Step 1440, inputting the third intermediate vector corresponding to the task to the third predictor model corresponding to the task, to obtain the second auxiliary probability of the task.
Since the structure in the second auxiliary model is the same as that of the task completion probability prediction model in the foregoing embodiment, the process of determining the second auxiliary probability of the task based on the second auxiliary model is the same as that of determining the task completion probability of the task based on the task completion probability prediction model, and will not be described here again.
As shown in fig. 15, the process of step 520 is generally illustrated schematically. Firstly, inputting sample object features into an embedded layer to obtain a first vector, and inputting sample push content features into the embedded layer to obtain a second vector; inputting the first vector and the second vector into a task completion probability prediction model to obtain a plurality of sample task completion probabilities corresponding to a plurality of tasks; and simultaneously, inputting the first vector into a first auxiliary model to obtain first auxiliary probabilities corresponding to a plurality of tasks, and inputting the second vector into a second auxiliary model to obtain second auxiliary probabilities corresponding to a plurality of tasks. The task completion probability prediction model, the first auxiliary model and the second auxiliary model have the same hierarchical structure, and the structure of each layer is also the same. Thus, the three models are identical for the operation of the input vector. Because the number of the vectors received by the first auxiliary model and the second auxiliary model is smaller than the number of the vectors received by the task completion probability prediction model, parameters in the first auxiliary model and the second auxiliary model can be properly reduced, so that the calculation efficiency of the models is improved.
In step 530, the impact of different tasks on whether the object is interested in push content may be different. For example, if an object is accustomed to a viewed push content, then the effect of the task "whether to endorse" on the object's preference is relatively small; when the object sees the content of interest, the push content is commented, and the task of commenting whether to comment has little influence on the object preference. Therefore, when training the task completion probability prediction model, it is necessary to determine, for the pushing event sample, the degree of influence on the task whose sample object and sample pushing content are different, that is, the second task weight.
In one embodiment, as shown in fig. 16, determining the second task weight for the task based on the task completion probability, the first auxiliary probability, and the second auxiliary probability includes:
step 1610, determining a first difference between the task completion probability and the first assistance probability;
step 1620, determining a second difference between the task completion probability and a second auxiliary probability;
step 1630, determining a second task weight for the task based on the first difference and the second difference.
Since the first auxiliary model is used to determine the average probability that a sample object will complete a task for all content, the higher the first auxiliary probability for a task, the less impact that represents that task will have on determining the sample object's interest in sample push content, since the sample object is likely to complete the task even if facing push content that is not of interest. Thus, the higher the first auxiliary probability corresponding to a task, the smaller the first difference between the sample task completion probability and the first auxiliary probability corresponding to a task, indicating that the task has a smaller gain for distinguishing objects, and further indicating that the second task weight of the task should be lower based on only the first difference.
Similarly, since the second auxiliary model is used to determine the average probability that sample push content is being used by the general public to complete a task, the higher the second auxiliary probability for a task, the less impact that represents that task on determining the sample object's interest in sample push content, since it is likely that an object will complete the task even though it is not interested in sample push content. Thus, the higher the second auxiliary probability for a task, the less the second difference between the sample task completion probability for a task and the second auxiliary probability for that task, indicating that the task has less gain in distinguishing push content, and thus indicating that the second task weight for that task should be lower based on only the second difference. In summary, the second task weight determined based on the first and second differences considers the gain of the task for distinguishing the object from the push content. Thus, the second task weight may sufficiently reflect the effect of the task on the sample object preference.
In one embodiment, as shown in fig. 17, determining the second task weight for the task based on the first difference and the second difference includes:
step 1710, obtaining a first parameter and a second parameter;
step 1720, determining a second task weight based on the first difference, the second difference, the first parameter, and the second parameter.
The first parameter indicates a side weight that affects the push content. In practical applications, the degree of influence of the gain of the task for distinguishing the object and the gain of the task for distinguishing the push content on the second task weight is adjustable. Thus, the extent to which the gain of the task for differentiating the push content affects the second task weight may be represented by setting the first parameter. Similarly, the degree of influence of the gain of the task for distinguishing the object on the second task weight can also be expressed by setting a parameter. Two parameters for expressing the influence degree of the gain of the task for distinguishing the object on the second task weight and the influence degree of the gain for distinguishing the push content on the second task weight can be set simultaneously.
The advantage of setting the first parameter is that the side weight affecting the push content can be adjusted according to the actual application, which is beneficial to improving the flexibility of determining the second task weight.
The second parameter indicates an amplification factor of the effect of the task on the sample object and the sample push content. In practical applications, if the second task weight is determined directly by using the first difference and the second difference, the obtained result may be unfavorable for calculation in the subsequent step. For example, the value of the second task weight is too small or too large. Thus, the overall effect of the second task weight may be scaled by setting the second parameter. Because the second task weights of the tasks are calculated one by one, the second task weights of different tasks may have larger gaps for the same push event sample, so that the second task weights of different tasks are incomparable, and different influences of different tasks on the push event cannot be reflected. Therefore, the second parameter can also control the second task weight of different tasks within a preset interval by scaling the second task weight, so that the different tasks have comparability, and the influence of the different tasks on the pushing event is intuitively reflected.
The setting of the second parameter has the advantage that the overall effect of the second task weight can be adjusted according to the actual application scene, which is beneficial to improving the flexibility of determining the second task weight.
It should be noted that, since there is no relation between the first parameter and the second parameter, the same function is to increase flexibility in determining the second task weight. Thus, the first parameter and the second parameter may be used together to determine the second task weight together with the first difference and the second difference, or the second task weight may be determined separately together with the first difference and the second difference, respectively.
In one embodiment, as shown in fig. 18, determining the second task weight based on the first difference, the second difference, the first parameter, and the second parameter includes:
step 1810, adding a predetermined constant to the first difference to obtain a first enhanced difference;
step 1820, adding a predetermined constant to the second difference to obtain a second enhanced difference;
step 1830, determining a sum of the second enhancement difference and the first enhancement difference and a product of the second enhancement difference and the first parameter;
step 1840, exponentiating the second parameter of the sum as a second task weight.
The first difference is a difference between the sample task completion probability and the first auxiliary probability, and if the first auxiliary probability is greater than the sample task completion probability, the result of the first difference is less than 0, possibly resulting in a result of the second task weight also being less than 0. Since the second task weight must be a positive number, the purpose of increasing the predetermined constant is to avoid that the value of the first difference and the second difference is smaller than 0, resulting in a second task weight result also smaller than 0. Since the sample task completion probability, the first auxiliary probability, and the second auxiliary probability are all values greater than 0 and less than 1, the values of the first difference and the second difference are greater than-1 and less than 1. In order to ensure that the values of the first enhancement amount and the second enhancement amount are positive numbers, the predetermined constant needs to be 1 or more.
Since the first parameter indicates the severity of the impact on the push content, multiplying the first parameter by the second enhancement, adding the multiplied result to the first enhancement, the result obtained may already be indicative of the extent to which the task affects the object and the push content. Since the second parameter indicates scaling of the overall effect of the task on the object and push content, the addition result will be exponentially calculated, with the second parameter as a power, and the result of the exponent calculation as a second task weight.
In summary, the process of determining the second task weight based on the first difference, the second difference, the first parameter, and the second parameter can be expressed by equation 8:
(equation 8)
In equation 8, the predetermined constant is 1;representing a sample task completion probability; />Representing a first auxiliary probability; />Representing a second auxiliary probability; />Representing a first parameter; />Representing a second parameter. For example, if the sample task completion probability of a task is 0.78, the first auxiliary probability is 0.62, the second auxiliary probability is 0.88, the first parameter is 0.4, and the second parameter is 0.5, then the second task weight of the task is ∈>
The advantage of this embodiment is that by setting the predetermined constant to ensure that the value of the second task weight is greater than 0, the accuracy of determining the second task weight is improved.
The embodiment of steps 1710-1720 has the advantage that by setting the first parameter and the second parameter, the second task weight can be adjusted according to the actual application requirement, and the flexibility of determining the second task weight is improved.
In the embodiment of steps 1610-1630, the first difference embodies the gain effect of the task on distinguishing objects; the second difference represents the gain effect of the task on distinguishing push content; based on the first difference and the second difference, the influence degree of the task on the preference of the sample push content by the sample object is comprehensively considered, and the accuracy of determining the weight of the second task is improved.
In another embodiment, determining the second task weight for the task based on the sample task completion probability, the first auxiliary probability, and the second auxiliary probability may further comprise:
determining a first ratio of the sample task completion probability to the first auxiliary probability;
determining a second ratio of the sample task completion probability to a second auxiliary probability;
a second task weight for the task is determined based on the first ratio and the second ratio.
In this embodiment, the larger the value of the first ratio, the larger the gain of the task for distinguishing the object, and thus the higher the second task weight of the task should be based on only the first ratio. Similarly, when the value of the second ratio is greater, the higher the gain of the task for distinguishing push content is indicated, and the higher the second task weight of the task should be based on the second ratio alone.
The process of determining the second task weight of the task based on the first ratio and the second ratio, similar to the foregoing embodiment, may also set the first parameter and the second parameter to improve the flexibility of determining the second task weight, which is not described herein.
Since the value of the first ratio to the second ratio is necessarily greater than 0, in the present embodiment, the second task weight greater than 0 can be obtained even without setting the predetermined constant. The process of determining the second task weight of the task according to this embodiment can be expressed as formula 9:
(equation 9)
In the case of the formula 9 of the present invention,a first ratio representing a sample task completion probability to a first auxiliary probability; />A second ratio representing a sample task completion probability to a second auxiliary probability; />Representing a first parameter; />Representing a second parameter. For example, if the sample task completion probability of a task is 0.78, the first auxiliary probability is 0.62, the second auxiliary probability is 0.88, the first parameter is 0.4, and the second parameter is 0.5, then the second task weight of the task is ∈>
The embodiment is similar to the embodiment of determining the weight of the second task by using the difference value, and the gain effect of the task on the distinguishing object is reflected by using the first ratio; the gain effect of the task on distinguishing the push content is reflected by the second ratio; based on the first ratio and the second ratio, the influence degree of the task on the sample pushing content preference of the sample object is comprehensively considered. Therefore, the accuracy of determining the second task weight can also be improved. Above this, the present embodiment can obtain the correct second task weight larger than 0 without a predetermined constant, and therefore, the present embodiment can also save the calculation amount of determining the second task weight.
In step 540, first, the task completion probability prediction model, the first auxiliary model, and the second auxiliary model are weighted and calculated for the first loss function of the task by using the second task weight of each task, so as to obtain a second loss function of the push event sample. The first loss function is used for representing accuracy of sample task completion probability, first auxiliary probability and second auxiliary probability obtained for the task after the training event sample is input into the task completion probability prediction model, the first auxiliary model and the second auxiliary model. The larger the first loss function, the larger the difference between the three models and the true value of the pushing event sample for completing the task, and the lower the prediction accuracy of the models for the task.
Since the three models are used to evaluate task completion of multiple tasks, the first loss function of all tasks needs to be considered when evaluating the overall prediction accuracy of the model. And because different tasks have different second task weights, the second task weights are used for weighting and summing the first loss functions corresponding to the tasks to obtain the second loss functions. The second loss function is used for evaluating the task completion probability prediction model, the first auxiliary model and the prediction accuracy of the whole second auxiliary model.
In one embodiment, the push event sample further includes a plurality of task labels, the labels indicating whether the sample object has completed a task on the sample push content. Since the push event sample is data for training a model, the push event is an event that has occurred in the delivery application, it can be directly determined whether the sample object has completed a task on the sample push content. In the foregoing embodiment, the view record is obtained from the application history record of the push application as the push event sample, and then the task completion condition of the object on the push content is also recorded in the application history record. For example, for viewing record A, the task completion for the push content by the object is: { praise: yes, comment: is to store: no, … … }; for view record B, the task completion for the object for use in pushing is: { praise: yes, comment: and (3) if not, collecting: no, … …).
The tag may be used to represent the actual value of the push event sample to complete a task. Therefore, as shown in fig. 19, weighting and calculating the task completion probability prediction model, the first auxiliary model, and the second auxiliary model with respect to the first loss function of the task by using the second task weight of each task, to obtain a second loss function of the push event sample includes:
Step 1910, determining a first loss function of the task based on the label of the task, the sample task completion probability, the first auxiliary probability, and the second auxiliary probability;
step 1920, performing weighted sum operation on the first loss function of the task by using the second task weight of each task, so as to obtain a second loss function of the push event sample.
The label of a task may be represented by a value, if the task is complete, the label of the task is 1, whereas the label of the task is 0. Thus, in one embodiment, as shown in FIG. 20, determining a first penalty function for a task based on a label for the task, a sample task completion probability, a first auxiliary probability, and a second auxiliary probability, includes:
step 2010, determining a first sub-loss function of a task completion probability prediction model for a task based on a label of the task and a sample task completion probability;
step 2020, determining a second sub-loss function of the first auxiliary model for the task based on the label of the task and the first auxiliary probability;
step 2030, determining a third sub-loss function of the second auxiliary model for the task based on the label of the task and the second auxiliary probability;
step 2040, determining a first loss function based on the first sub-loss function, the second sub-loss function, and the third sub-loss function.
In one embodiment, determining an absolute value of a difference between a label and a sample task completion probability for a first sub-loss function of a task by a task completion probability prediction model; determining the absolute value of the difference value between the label and the first auxiliary probability of a second sub-loss function of the first auxiliary model aiming at the task through calculation; the third sub-loss function of the second auxiliary model for the task is determined by calculating the absolute value of the difference of the label and the second auxiliary probability. For example, the task tag is 0, the sample task completion probability is 0.23, the first auxiliary probability is 0.45, the second auxiliary probability is 0.52, and then the first sub-loss function is |0-0.23|=0.23; the second sub-loss function is |0-0.45|=0.45; the third sub-loss function is |0-0.52|=0.52. The advantage of calculating the first to third sub-loss functions using the absolute value of the difference is that the calculation speed is faster.
In another embodiment, determining a cross entropy of a task completion probability prediction model for a first sub-loss function of a task by calculating a label and a sample task completion probability; determining a cross entropy of a second sub-loss function of the first auxiliary model aiming at the task through calculating a label and a first auxiliary probability; and determining a third sub-loss function of the second auxiliary model for the task by calculating cross entropy of the label and the second auxiliary probability. For example, the task label is 0, the sample task completion probability is 0.23, the first auxiliary probability is 0.45, and the second auxiliary probability is 0.52, then the first sub-loss function is-0 log (0.23) - (1-0) ×log (1-0.23) =0.26; the second sub-loss function is-0 log (0.45) - (1-0) ×log (1-0.45) =0.6; the third sub-loss function is-0 log (0.52) - (1-0) ×log (1-0.52) =0.73. The advantage of calculating the first to third sub-loss functions using cross entropy is that the accuracy of calculating the first to third sub-loss functions is improved.
Determining the first loss function based on the first sub-loss function, the second sub-loss function, and the third sub-loss function may be by direct addition. Based on the foregoing embodiment of calculating the first to third sub-loss functions using cross entropy, the process of determining the first loss function is as shown in equation 10:
(equation 10)
In the formula 10 of the present invention,representing a first sub-loss function;
representing a second sub-loss function;representing a third sub-loss function. For example, a first sub-loss function of 0.23, a second sub-loss function of 0.45, and a third sub-loss function of 0.56 for a task, then the first of the taskThe loss function is 0.23+0.45+0.56=1.24.
The advantage of calculating the first loss function by adding is that the contributions of the task completion probability prediction model, the first auxiliary model and the second auxiliary model to the determination of the first loss function are the same, so that the fairness of determining the first loss function by using the three models is improved.
Determining the first loss function based on the first sub-loss function, the second sub-loss function, and the third sub-loss function may also be by calculating a weighted sum. A weight is set for each of the first, second, and third sub-loss functions to represent different contributions of different models to determining the first loss function. For example, based on the example in the above embodiment, the first sub-loss function is set to have a weight of 0.8, the second sub-loss function is set to have a weight of 0.6, and the third sub-loss function is set to have a weight of 0.5, so that the first loss function of the task is set to have a weight of 0.23×0.8+0.45×0.6+0.56×0.5=0.734.
The advantage of calculating the first loss function by means of the weighted sum is that different weights can be set for the first sub-loss function, the second sub-loss function and the third sub-loss function according to the actual application, which increases the flexibility of determining the first loss function.
An advantage of the embodiments of steps 2010-2040 is that after the sub-loss functions of each model are calculated separately, the first loss function corresponding to the task is determined, so that the sub-loss functions of different models are adjusted, and the flexibility and accuracy of determining the first loss function are improved.
After determining the first loss function of each task, a weighted sum is calculated for the first loss function of the task based on the second task weight of the task, and a task completion probability prediction model, a first auxiliary model, and a second loss function integral with the second auxiliary model are determined. For example, task A has a first loss function of 1.56 and a second task weight of 1.2; the first loss function of the task B is 0.98, and the second task weight is 1.1; the first loss function of task C is 1.34, and the second task weight is 0.8; the second loss function is 1.56×1.2+0.98×1.1+1.34×0.8=4.022.
The embodiment of steps 1910-1920 has the advantages that the labels of the samples are used as the true values, so that the accuracy of determining the first loss function corresponding to the task is improved; the first loss functions of different tasks are weighted and summed by the second task weight, so that the influence of different tasks on the pushing event sample is reflected, and the accuracy of determining the second loss function of the pushing event sample is improved.
After determining a second loss function of the push event sample, training a task completion probability prediction model, a first auxiliary model, and a second auxiliary model based on the second loss function.
The goal of training the task completion probability prediction model, the first auxiliary model and the second auxiliary model is to reduce the second loss function, which means that the difference between the prediction results and the true values of the three models is smaller, and the model prediction is more accurate. Thus, the training process is to update parameters in the task completion probability prediction model, the first auxiliary model, and the second auxiliary model such that the second loss function derived based on the updated model is reduced. Training the task completion probability model, the first auxiliary model, and the second auxiliary model based on the second loss function may employ a gradient descent method such that parameters of the three models may be updated in a direction in which the gradient of the second loss function descends.
In one embodiment, the push event samples are from a push event sample set containing a plurality of push event samples. That is, multiple push event samples may be utilized in one round of training the task completion probability prediction model, the first auxiliary model, and the second auxiliary model. Thus, as shown in fig. 21, training the task completion probability prediction model, the first auxiliary model, and the second auxiliary model based on the second loss function includes:
Step 2110, determining a third loss function of the push event sample set based on the second loss function of each push event sample in the push event sample set;
step 2120, training a task completion probability prediction model, a first auxiliary model, and a second auxiliary model based on the third loss function.
Each push event sample has a corresponding second loss function. The determining of the third loss function may be by summing the second loss functions corresponding to all push event samples in the set of push event samples. For example, there are 5 push event samples in the push event sample set, and the second loss functions are respectively: 5.31, 4.28, 4.71, 6.5, 3.11, then the third loss function for this push event sample set is: 5.31+4.28+4.71+6.5+3.11=23.91. The advantage of using direct addition to determine the third loss function is that each push event sample contributes equally to determining the training of the three models, improving the fairness of the training.
In another embodiment, as shown in fig. 22, determining a third loss function for a set of push event samples based on the second loss function for each push event sample in the set of push event samples, comprises:
Step 2210, obtaining a sample weight of each push event sample in the push event sample set;
step 2220, based on the sample weights, performs weighted summation on the second loss function of each push event sample, to obtain a third loss function.
In a push event sample set, the contribution of different push event samples to the training may be different. For example, the sample weight of a push event sample that occurs at a time close to the current time is higher, because the preference of the object for push content may not change significantly in a shorter time, and thus the push event sample closer in time to the current time should have a higher contribution for training. The sample weight of each push event sample may be obtained using a table of factors that determine the sample weight versus the sample weight. For example, the factor determining the sample weight is the event occurrence time, and table 3 is an example of a table of the comparison between the event occurrence time and the sample weight.
TABLE 3 Table 3
Referring to table 3, if the event occurrence time is 15 hours from the current time, the sample weight is 0.8.
If there are multiple factors that determine the sample weight, the sample weight may be obtained based on the corresponding weight in the look-up table for different factors that push the event samples. For example, the weights corresponding to different factors are added or weighted, and the sample weight of the push event sample is obtained. The factors determining the sample weight of the push event sample can be input into a sample weight determining model to obtain the sample weight of the push event sample.
And after the sample weight is acquired, weighting and summing the second loss function of each push event sample in the push event sample set by using the sample weight to obtain a third loss function. For example, there are 5 push event samples in the push event sample set, the second loss function of push event sample a is 3.25, and the sample weight is 0.6; the second loss function of push event B is 4.15, the sample weight is 0.8; the second loss function of push event C is 5.2, and the sample weight is 1; the second loss function of push event D is 2.36, the sample weight is 0.4; the second loss function of the push event E is 3.58 and the sample weight is 0.5, and then the third loss function of the push event sample set is 3.25×0.6+4.15×0.8+5.2×1+2.36×0.4+3.58×0.5= 13.204.
The advantage of calculating the third loss function by using the weighted sum in the embodiment is that different weights can be set for the pushing event samples according to actual application, so that the training process is more fit to an application scene, and the flexibility of determining the third loss function and the accuracy of a trained model are improved.
An advantage of the embodiments of steps 2110-2120 is that training a task completion probability prediction model, a first auxiliary model, and a second auxiliary model based on multiple push event samples in one push event sample set avoids model overfitting due to the training process being over-influenced by a single push event sample, and improves the accuracy of the training process.
In one embodiment, as shown in fig. 23, training the task completion probability prediction model, the first auxiliary model, and the second auxiliary model based on the third loss function includes:
2310, adjusting the model node weight in the task completion probability prediction model, the first auxiliary model and the second auxiliary model according to a backward propagation algorithm of the gradient by using a third loss function;
step 2320, preventing the gradient of the first layer node weights of the first auxiliary model and the second auxiliary model from propagating toward the embedded layer.
After the third loss function is determined, according to the order of the task completion probability prediction model based on the sample object characteristics and the sample push content characteristics, the node weights of all nodes in the task completion probability prediction model are adjusted layer by utilizing a backward propagation algorithm; according to the sequence of the first auxiliary model outputting the first auxiliary probability based on the sample object characteristics, adjusting the node weights of all nodes in the first auxiliary model layer by utilizing a backward propagation algorithm; and adjusting the node weights of all the nodes in the second auxiliary model layer by using a backward propagation algorithm according to the order of the second auxiliary model outputting the second auxiliary probability based on the sample push content characteristics. The model node weights are adjusted in such a way that the gradient of the third loss function decreases.
In the foregoing embodiment, the sample object feature and the sample push content feature are input into the embedding layer, so as to obtain a first vector corresponding to the sample object feature and a second vector corresponding to the sample push content feature. Inputting the first vector and the second vector into a task completion probability prediction model; inputting the first vector into a first auxiliary model; the second vector is input to a second auxiliary model. And after the node weights of the three models are adjusted layer by utilizing a backward propagation algorithm, propagating the gradient of the first layer node weight of the task completion probability prediction model to the embedded layer, and preventing the gradient of the first layer node weight of the first auxiliary model and the second auxiliary model from propagating to the embedded layer.
For example, as shown in fig. 24, in the foregoing embodiment, the task completion probability prediction model includes a first cascade layer, a plurality of first expert sub-models, a plurality of first gating nodes corresponding to the plurality of tasks, and a plurality of first predictor sub-models. The first auxiliary model includes a second cascade layer, a plurality of second expert sub-models, a plurality of second gating nodes corresponding to the plurality of tasks, and a plurality of second predictor sub-models. The second auxiliary model includes a third cascade layer, a plurality of third expert sub-models, a plurality of third gating nodes corresponding to the plurality of tasks, and a plurality of third predictor sub-models. The direction of the dashed arrow in fig. 24 represents the direction of the gradient traveling backward.
In the task completion probability prediction model, adjusting node weights layer by layer according to the sequence of a first predictor model, a first gating node, a first expert sub model and a first cascade layer; and then adjusting the node weight of the embedded layer by utilizing the gradient of the node weight of the first cascade layer. In the first auxiliary model, node weights are adjusted layer by layer in the order of the second predictor model, the second gating node, the second expert sub model, and the second cascade layer. The manner of adjusting the node weights in the second auxiliary model is the same as that of the first auxiliary model, and will not be described here again. The second and third cascaded layers no longer propagate toward the embedded layer.
The task completion probability of the push content for the task is predicted by using the task completion probability prediction model, and the first auxiliary model and the second auxiliary model only play an auxiliary role in the training process. Therefore, even if the embedded layer is a common layer that is used by all three models, its main task is to improve the prediction accuracy of the task completion probability prediction model. If the first layer of the first auxiliary model and the second auxiliary model is not prevented from being transmitted to the embedded layer, the embedded layer is also influenced by the first auxiliary model and the second auxiliary model, so that the prediction accuracy after the task completion probability prediction model is influenced. Therefore, the method and the device have the advantages that the influence of the training process of the first auxiliary model and the second auxiliary model on the optimization of the task completion probability prediction model is avoided, and the training accuracy of the task completion probability prediction model is improved.
In the embodiment of steps 510-540, a task weight for the task is determined based on the task completion probability, the first auxiliary probability, and the second auxiliary probability, the task weight reflecting a business gain of the task for distinguishing the object from the push content. The task weight is used for carrying out weighted sum on the loss functions of all tasks to obtain the loss functions of the samples, the loss functions are used for model training, and the prediction accuracy of the trained task completion probability prediction model is improved.
The task completion probability prediction model after training can obtain the task completion probability of the target object to the content to be pushed and aiming at a plurality of tasks according to the object characteristics of the target object and the content characteristics to be pushed of the content to be pushed. The process of obtaining the task completion probabilities of the plurality of tasks based on the object features and the content features to be pushed is the same as that of the previous embodiment, and the process of obtaining the sample task completion probabilities of the plurality of tasks by inputting the sample object features and the sample push content features into the task completion probability prediction model is not repeated here for saving the space.
Detailed description of step 330
In step 330, a ranking score of the content to be pushed is determined based on the task completion probabilities of the plurality of tasks corresponding to the content to be pushed features.
In one embodiment, determining the ranking score of the content to be pushed includes: and adding task completion probabilities of a plurality of tasks corresponding to the content features to be pushed to obtain the sorting score of the content to be pushed. For example, the task a of the content to be pushed has a task completion probability of 0.65, the task B has a task completion probability of 0.45, and the task C has a task completion probability of 0.22, so the ranking score of the content to be pushed is 0.65+0.45+0.22=1.32. The method has the advantages that the effect of all tasks on the push ordering of the content to be pushed is the same, the fairness of ordering is improved, and the calculation efficiency of determining the ordering score is also improved.
In another embodiment, as shown in fig. 25, determining the ranking score of the content to be pushed based on the task completion probabilities of the plurality of tasks corresponding to the content feature to be pushed includes:
step 2510, acquiring a first task weight of a plurality of tasks;
step 2520, based on the first task weights of the tasks, performing weighted summation on task completion probabilities of the tasks corresponding to the features of the content to be pushed, to obtain the ranking score of the content to be pushed.
In step 2510, the first task weight of the task indicates how well the task affects the target object's preference for push content.
In one embodiment, as shown in fig. 26, obtaining a first task weight of a plurality of tasks includes:
step 2610, inputting object features of the target object into the first auxiliary model to obtain a third auxiliary probability of the plurality of tasks;
step 2620, inputting the content to be pushed characteristics of the content to be pushed into the second auxiliary model to obtain a fourth auxiliary probability of the plurality of tasks;
step 2630, for each task, determining a first task weight for the task based on the task completion probability, the third auxiliary probability, and the fourth auxiliary probability.
The first auxiliary model and the second auxiliary model are trained in conjunction with the task completion probability prediction model in the foregoing embodiments. The third auxiliary probability is the average probability that the target object completes the task for all the content, and the higher the third auxiliary probability, the smaller the influence of the task on determining the interest degree of the target object to the content to be pushed. The fourth auxiliary probability is the average probability of determining that the content to be pushed is completed by the general public, and the higher the fourth auxiliary probability is, the smaller the influence of the task on the degree of interest of the target object in determining the content to be pushed is represented.
The process of obtaining the third auxiliary probability by the first auxiliary model based on the object characteristics of the target object is the same as the process of obtaining the first auxiliary probability based on the sample object characteristics in the foregoing process. The process of the second auxiliary model obtaining the fourth auxiliary probability based on the to-be-pushed content features is the same as the process based on the sample push content features in the previous process. And will not be described in detail herein.
The process of determining the first task weight of the task based on the task completion probability, the third auxiliary probability, and the fourth auxiliary probability is the same as that of determining the second task weight based on the sample task completion probability, the first auxiliary probability, and the second auxiliary probability in the foregoing embodiment, and is not described herein.
In this embodiment, the first task weight of the task is determined based on the task's service gain for distinguishing the target object and the content to be pushed, so that accuracy of acquiring the first task weight is improved.
In step 2520, the task completion probabilities for the plurality of tasks are weighted and summed using the first task weight for the task to obtain a ranking score. For example, task A has a first task weight of 0.96 and a task completion probability of 0.6; the first task weight of the task B is 1.1, and the task completion probability is 0.5; the first task weight of task C is 1.5, the task completion probability is 0.3, and the ranking score is: 0.96 x 0.6+1.1 x 0.5+0.5 x 0.3=1.276.
The method for determining the ranking score by using the first task weight has the advantages that the influence of different tasks on the interest degree of the target object on the content to be pushed is reflected by using the first task weight, and the accuracy of determining the ranking score is improved.
Detailed description of step 340
In step 340, the plurality of content to be pushed is ranked based on the ranking scores of the plurality of content to be pushed, and the content to be pushed is pushed to the target object according to the ranking. For example, the ranking score of the content to be pushed is { content to be pushed A:1.5, to push content B:1.34, content to be pushed C:1.8, to push content D:0.95}, then the ordering result is: to-be-pushed content C, to-be-pushed content A, to-be-pushed content B and to-be-pushed content D. And firstly pushing the content C to be pushed to the target object according to the sorting result, and pushing the content A to be pushed to the target object when the target object triggers the operation of checking the next content.
Implementation details of push processing method of embodiments of the present disclosure
The implementation details of the push processing method according to the embodiment of the present disclosure are described in detail below with reference to fig. 27.
In step 2710, object features of the target object, scene features in which the target object is located, and content features to be pushed of the content to be pushed are acquired.
In step 2720, the object feature and the feature of the content to be pushed are input into a task completion probability prediction model, so as to obtain task completion probabilities of a plurality of tasks.
Training details of the task completion probability prediction model include:
Step 2721, obtaining a push event sample, wherein the push event sample comprises sample object characteristics, sample scene characteristics and sample push content characteristics;
step 2722, inputting the sample object feature and the sample push content feature into an embedding layer to obtain a first vector corresponding to the sample object feature, a second vector corresponding to the sample push content feature and a third vector corresponding to the sample scene feature;
step 2723, inputting the first vector and the second vector into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks, inputting the first vector and the third vector into a first auxiliary model to obtain first auxiliary probabilities of the plurality of tasks, and inputting the second vector into a second auxiliary model to obtain second auxiliary probabilities of the plurality of tasks;
step 2724, determining a first difference between the task completion probability and the first auxiliary probability and a second difference between the task completion probability and the second auxiliary probability; obtaining a first parameter for indicating the side severity of the impact on the push content and a second parameter for indicating the magnification of the impact of the task on the object and the push content; adding a predetermined constant to the first difference to obtain a first enhanced difference; adding a predetermined constant to the second difference to obtain a second enhanced difference; determining a sum of a product of the second enhancement difference and the first parameter and the first enhancement difference; and taking the second parameter of the sum to the power as the task weight.
Step 2725, determining a first sub-loss function of a task completion probability prediction model for the task based on the label of the task and the task completion probability; determining a second sub-loss function of the first auxiliary model for the task based on the label of the task and the first auxiliary probability; a third sub-loss function for the task for the second auxiliary model is determined based on the label of the task and the second auxiliary probability.
Step 2726, determining a first loss function based on the first sub-loss function, the second sub-loss function, and the third sub-loss function;
step 2727, performing weighted sum operation on the first loss function of the task by using the task weight of each task to obtain a second loss function of the pushing event sample;
step 2728, obtaining a sample weight of each push event sample in the push event sample set; based on the sample weight, carrying out weighted sum on the second loss function of each pushing event sample to obtain a third loss function;
step 2729, adjusting the model node weight in the task completion probability prediction model, the first auxiliary model and the second auxiliary model according to a backward propagation algorithm of the gradient by using a third loss function; the gradient of the first layer node weights of the first auxiliary model and the second auxiliary model is prevented from propagating towards the embedding layer.
In step 2730, a first task weight of the plurality of tasks is obtained.
In step 2740, based on the first task weights of the tasks, the task completion probabilities of the tasks corresponding to the features of the content to be pushed are weighted and summed to obtain the ranking score of the content to be pushed.
In step 2750, the plurality of content to be pushed is ranked based on the ranking scores of the plurality of content to be pushed.
Apparatus and device descriptions of embodiments of the present disclosure
It will be appreciated that, although the steps in the various flowcharts described above are shown in succession in the order indicated by the arrows, the steps are not necessarily executed in the order indicated by the arrows. The steps are not strictly limited in order unless explicitly stated in the present embodiment, and may be performed in other orders. Moreover, at least some of the steps in the flowcharts described above may include a plurality of steps or stages that are not necessarily performed at the same time but may be performed at different times, and the order of execution of the steps or stages is not necessarily sequential, but may be performed in turn or alternately with at least a portion of the steps or stages in other steps or other steps.
In the embodiments of the present application, when related processing is performed according to data related to the characteristics of the target content, such as attribute information or attribute information set of the target content, permission or consent of the target content is obtained first, and the collection, use, processing, etc. of the data complies with related laws and regulations and standards. In addition, when the embodiment of the application needs to acquire the attribute information of the target content, the independent permission or independent consent of the target content is acquired through a popup window or a jump to a confirmation page or the like, and after the independent permission or independent consent of the target content is definitely acquired, the necessary related data of the target content for enabling the embodiment of the application to normally operate is acquired.
Fig. 28 is a schematic structural diagram of a push processing device 2800 provided in an embodiment of the present disclosure. The push processing device 2800 includes:
a first obtaining unit 2810, configured to obtain an object feature of a target object and a content feature to be pushed of the content to be pushed;
the first input unit 2820 is configured to input the object feature and the feature of the content to be pushed into a task completion probability prediction model, so as to obtain task completion probabilities of a plurality of tasks;
A determining unit 2830, configured to determine a ranking score of the content to be pushed based on task completion probabilities of a plurality of tasks corresponding to the feature of the content to be pushed;
the ranking unit 2840 is configured to rank the plurality of content to be pushed based on ranking scores of the plurality of content to be pushed.
The task completion probability prediction model is trained based on sample task completion probabilities of a plurality of tasks, a first auxiliary probability and a second auxiliary probability, wherein the sample task completion probability is predicted by the task completion probability prediction model based on sample object characteristics and sample push content characteristics, the first auxiliary probability is predicted by the first auxiliary model based on the sample object characteristics, the second auxiliary probability is predicted by the second auxiliary model based on the sample push content characteristics, and the first auxiliary model and the second auxiliary model are respectively connected with the task completion probability prediction model in parallel.
Optionally, the determining unit 2830 is specifically configured to:
acquiring first task weights of a plurality of tasks;
and based on the first task weight of the tasks, weighting and summing task completion probabilities of the tasks corresponding to the characteristics of the content to be pushed, and obtaining the sorting score of the content to be pushed.
Optionally, the push processing device 2800 further includes:
A second acquisition unit (not shown) for acquiring scene features in which the target object is located;
the first input unit 2820 specifically is used for:
and inputting the object characteristics, the scene characteristics and the characteristics of the content to be pushed into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks.
Optionally, the task completion probability prediction model is specifically trained by the following ways:
obtaining a push event sample, wherein the push event sample comprises sample object characteristics and sample push content characteristics;
inputting sample object features and sample push content features into a task completion probability prediction model to obtain sample task completion probabilities of a plurality of tasks, inputting the sample object features into a first auxiliary model to obtain first auxiliary probabilities of the plurality of tasks, and inputting the sample push content features into a second auxiliary model to obtain second auxiliary probabilities of the plurality of tasks;
determining a second task weight for the task based on the sample task completion probability, the first auxiliary probability, and the second auxiliary probability;
and carrying out weighted sum operation on the task completion probability prediction model, the first auxiliary model and the second auxiliary model aiming at the first loss function of the task by using the second task weight of each task to obtain a second loss function of the pushing event sample, and training the task completion probability prediction model, the first auxiliary model and the second auxiliary model based on the second loss function.
Optionally, the push event sample further comprises a label for a plurality of tasks, the label indicating whether the sample object completes a task on the sample push content;
and performing weighted sum operation on the task completion probability prediction model, the first auxiliary model and the second auxiliary model aiming at the first loss function of the task by using the second task weight of each task to obtain a second loss function of the pushing event sample, wherein the weighted sum operation comprises the following steps:
determining a first loss function of the task based on the label of the task, the sample task completion probability, the first auxiliary probability, and the second auxiliary probability;
and carrying out weighted sum operation on the first loss function of the task by using the second task weight of each task to obtain a second loss function of the push event sample.
Optionally, determining the first loss function of the task based on the label of the task, the sample task completion probability, the first auxiliary probability, and the second auxiliary probability includes:
determining a first sub-loss function of a task completion probability prediction model for the task based on the label of the task and the sample task completion probability;
determining a second sub-loss function of the first auxiliary model for the task based on the label of the task and the first auxiliary probability;
Determining a third sub-loss function of the second auxiliary model for the task based on the label of the task and the second auxiliary probability;
the first loss function is determined based on the first, second, and third sub-loss functions.
Optionally, determining the second task weight of the task based on the sample task completion probability, the first auxiliary probability, and the second auxiliary probability includes:
determining a first difference of the sample task completion probability and the first auxiliary probability;
determining a second difference of the sample task completion probability and a second auxiliary probability;
a second task weight for the task is determined based on the first difference and the second difference.
Optionally, determining a second task weight for the task based on the first difference and the second difference includes:
acquiring a first parameter and a second parameter, wherein the first parameter indicates the side weight of the influence on the push content, and the second parameter indicates the amplification index of the influence of the task on the object and the push content;
a second task weight is determined based on the first difference, the second difference, the first parameter, and the second parameter.
Optionally, determining the second task weight based on the first difference, the second difference, the first parameter, and the second parameter includes:
adding a predetermined constant to the first difference to obtain a first enhanced difference;
Adding a predetermined constant to the second difference to obtain a second enhanced difference;
determining a sum of a product of the second enhancement difference and the first parameter and the first enhancement difference;
and taking the second parameter of the sum to the power as a second task weight.
Optionally, the push event samples are from a push event sample set comprising a plurality of push event samples;
training the task completion probability prediction model, the first auxiliary model, and the second auxiliary model based on the second loss function, comprising:
determining a third loss function for the set of push event samples based on the second loss function for each push event sample in the set of push event samples;
the task completion probability prediction model, the first auxiliary model, and the second auxiliary model are trained based on the third loss function.
Optionally, determining a third loss function of the set of push event samples based on the second loss function of each push event sample in the set of push event samples comprises:
acquiring sample weight of each push event sample in the push event sample set;
and carrying out weighted summation on the second loss function of each pushing event sample based on the sample weight to obtain a third loss function.
Optionally, inputting the sample object feature and the sample push content feature into a task completion probability prediction model to obtain sample task completion probabilities of a plurality of tasks, inputting the sample object feature into a first auxiliary model to obtain first auxiliary probabilities of the plurality of tasks, and inputting the sample push content feature into a second auxiliary model to obtain second auxiliary probabilities of the plurality of tasks, including:
Inputting the sample object features and the sample push content features into an embedding layer to obtain a first vector corresponding to the sample object features and a second vector corresponding to the sample push content features;
inputting the first vector and the second vector into a task completion probability prediction model to obtain sample task completion probabilities of a plurality of tasks, inputting the first vector into a first auxiliary model to obtain first auxiliary probabilities of the plurality of tasks, and inputting the second vector into a second auxiliary model to obtain second auxiliary probabilities of the plurality of tasks;
training the task completion probability prediction model, the first auxiliary model, and the second auxiliary model based on the third loss function, comprising:
adjusting the model node weight in the task completion probability prediction model, the first auxiliary model and the second auxiliary model according to a backward propagation algorithm of the gradient by using a third loss function;
the gradient of the first layer node weights of the first auxiliary model and the second auxiliary model is prevented from propagating towards the embedding layer.
Optionally, inputting the sample object feature and the sample push content feature into the embedding layer to obtain a first vector corresponding to the sample object feature and a second vector corresponding to the sample push content feature, including:
Inputting the sample object features and the sample push content features into an embedding layer to obtain a first initial vector corresponding to the sample object features and a second initial vector corresponding to the sample push content features;
acquiring a first vector length of a first vector and a second vector length of a second vector;
pooling the first initial vector based on the first vector length to obtain a first vector;
and pooling the second initial vector based on the second vector length to obtain a second vector.
Optionally, the task completion probability prediction model includes a first cascade layer, a plurality of first expert sub-models, a plurality of first gating nodes corresponding to the plurality of tasks, and a plurality of first predictor sub-models;
inputting the sample object features and the sample push content features into a task completion probability prediction model to obtain sample task completion probabilities of a plurality of tasks, comprising:
cascading a first vector corresponding to the sample object feature and a second vector corresponding to the sample push content feature into a first cascade vector through a first cascade layer;
inputting the first cascade vector into a plurality of first expert sub-models;
the output of the plurality of first expert sub-models is weighted and summed through a first gating node corresponding to each task to obtain a first intermediate vector corresponding to the task;
And inputting the first intermediate vector corresponding to the task into a first predictor model corresponding to the task to obtain the sample task completion probability of the task.
Optionally, the weighted sum of the outputs of the plurality of first expert sub-models is performed through a first gating node corresponding to each task to obtain a first intermediate vector corresponding to the task, including:
acquiring weight vectors of the first gating nodes, wherein the weight vectors indicate weights of a plurality of first expert sub-models;
and through the first gating node, the outputs of the plurality of first expert sub-models are weighted and summed by using the weight vector to obtain a first intermediate vector corresponding to the task.
Optionally, obtaining a weight vector of the first gating node includes:
obtaining a first matrix, wherein the number of rows of the first matrix is the number of the first expert sub-models, and the number of columns is the dimension of a first cascade vector;
multiplying the first matrix by the transpose of the first cascade vector, and carrying out normalized index processing on the multiplication result to obtain a weight vector of the first gating node.
Referring to fig. 29, fig. 29 is a block diagram of a portion of a terminal 140 implementing a push processing method according to an embodiment of the present disclosure, where the terminal 140 includes: radio Frequency (RF) circuitry 2910, memory 2915, input unit 2930, display unit 2940, sensor 2950, audio circuitry 2960, wireless fidelity (wireless fidelity, wiFi) module 2970, processor 2980, and power supply 2990. It will be appreciated by those skilled in the art that the configuration of the terminal 140 shown in fig. 29 is not limiting of a cell phone or computer and may include more or fewer components than shown, or may combine certain components, or a different arrangement of components.
The RF circuit 2910 may be used for receiving and transmitting signals during a message or a call, and particularly, after receiving downlink information of a base station, the signal is processed by the processor 2980; in addition, the data of the design uplink is sent to the base station.
The memory 2915 may be used to store software programs and modules, and the processor 2980 executes the software programs and modules stored in the memory 2915 to perform various functional applications and data processing of the content terminal 140.
The input unit 2930 may be used to receive input numeric or character information and generate key signal inputs related to the setting and function control of the content terminal 140. In particular, the input unit 2930 may include a touch panel 2931 and other input devices 2932.
The display unit 2940 may be used to display input information or provided information and various menus of the content terminal 140. The display unit 2940 may include a display panel 2941.
Audio circuitry 2960, speaker 2961, and microphone 2962 may provide an audio interface.
In this embodiment, the processor 2980 included in the terminal 140 may perform the push processing method of the previous embodiment.
The terminal 140 of the embodiments of the present disclosure includes, but is not limited to, a mobile phone, a computer, an intelligent voice interaction device, an intelligent home appliance, a vehicle-mounted terminal, an aircraft, etc. Embodiments of the present invention may be applied to a variety of scenarios including, but not limited to, big data, artificial intelligence, etc.
Fig. 30 is a block diagram of a portion of a server 110 implementing a push processing method of an embodiment of the present disclosure. The server 110 may vary considerably in configuration or performance and may include one or more central processing units (Central Processing Units, simply CPU) 3022 (e.g., one or more processors) and memory 3032, one or more storage media 3030 (e.g., one or more mass storage devices) storing applications 3042 or data 3044. Wherein the memory 3032 and the storage medium 3030 may be transitory or persistent storage. The program stored in the storage medium 3030 may include one or more modules (not shown), each of which may include a series of instruction operations on the server 110. Still further, the central processor 3022 may be provided in communication with the storage medium 3030, executing a series of instruction operations in the storage medium 3030 on the server 110.
Server 110 may also include one or more power supplies 3026, one or more wired or wireless network interfaces 3050, one or more input/output interfaces 3058, and/or one or more operating systems 3041, such as Windows server (tm), mac OS XTM, unixTM, linuxTM, freeBSDTM, etc.
The central processor 3022 in the server 110 may be used to perform the push processing method of the embodiments of the present disclosure.
The embodiments of the present disclosure also provide a computer readable storage medium storing a program code for executing the push processing method of the foregoing embodiments.
The disclosed embodiments also provide a computer program product comprising a computer program. The processor of the computer device reads the computer program and executes the computer program, so that the computer device executes the push processing method.
The terms "first," "second," "third," "fourth," and the like in the description of the present disclosure and in the above-described figures, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the disclosure described herein may be capable of operation in sequences other than those illustrated or described herein, for example. Furthermore, the terms "comprises," "comprising," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed or inherent to such process, method, article, or apparatus.
It should be understood that in this disclosure, "at least one" means one or more, and "a plurality" means two or more. "and/or" for describing association relation of association contents, the representation may have three kinds of relations, for example, "a and/or B" may represent: only a, only B and both a and B are present, wherein a, B may be singular or plural. The character "/" generally indicates that the context of the association is an "or" relationship. "at least one of" or the like means any combination of these items, including any combination of single item(s) or plural items(s). For example, at least one (one) of a, b or c may represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", wherein a, b, c may be single or plural.
It should be understood that in the description of the embodiments of the present disclosure, the meaning of a plurality (or multiple) is two or more, and that greater than, less than, exceeding, etc. is understood to not include the present number, and that greater than, less than, within, etc. is understood to include the present number.
In the several embodiments provided in the present disclosure, it should be understood that the disclosed systems, devices, and methods may be implemented in other manners. For example, the apparatus embodiments described above are merely illustrative, e.g., the division of elements is merely a logical functional division, and there may be additional divisions of actual implementation, e.g., multiple elements or components may be combined or integrated into another system, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices or units, which may be in electrical, mechanical or other form.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed over a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in each embodiment of the present disclosure may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in software functional units.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present disclosure may be embodied in essence or a part contributing to the prior art or all or part of the technical solution in the form of a software product stored in a storage medium, including several instructions to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods of the various embodiments of the present disclosure. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
It should also be appreciated that the various implementations provided by the embodiments of the present disclosure may be arbitrarily combined to achieve different technical effects.
The above is a specific description of the embodiments of the present disclosure, but the present disclosure is not limited to the above embodiments, and various equivalent modifications and substitutions can be made by those skilled in the art without departing from the spirit of the present disclosure, and are included in the scope of the present disclosure as defined in the claims.

Claims (18)

1. The pushing processing method is characterized by comprising the following steps of:
acquiring object characteristics of a target object and content characteristics to be pushed of content to be pushed;
inputting the object characteristics and the to-be-pushed content characteristics into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks;
determining the sorting score of the content to be pushed based on the task completion probabilities of a plurality of tasks corresponding to the content characteristics to be pushed;
ranking the plurality of content to be pushed based on ranking scores of the plurality of content to be pushed;
the task completion probability prediction model is trained by the following modes: obtaining a push event sample, wherein the push event sample comprises sample object characteristics and sample push content characteristics; inputting the sample object features and the sample push content features into the task completion probability prediction model to obtain sample task completion probabilities of a plurality of tasks, inputting the sample object features into a first auxiliary model to obtain first auxiliary probabilities of the plurality of tasks, and inputting the sample push content features into a second auxiliary model to obtain second auxiliary probabilities corresponding to the plurality of tasks; determining a second task weight for the task based on the sample task completion probability, the first auxiliary probability, and the second auxiliary probability; and carrying out weighted sum operation on the task completion probability prediction model, the first auxiliary model and the second auxiliary model aiming at a first loss function of the task by using the second task weight of each task to obtain a second loss function of the push event sample, and training the task completion probability prediction model, the first auxiliary model and the second auxiliary model based on the second loss function.
2. The push processing method of claim 1, wherein the determining the ranking score of the content to be pushed based on the task completion probabilities of the plurality of tasks corresponding to the content to be pushed features comprises:
acquiring first task weights of a plurality of tasks;
and based on the first task weights of the tasks, weighting and summing the task completion probabilities of the tasks corresponding to the characteristics of the content to be pushed, and obtaining the sorting score of the content to be pushed.
3. The push processing method according to claim 1, wherein before inputting the object feature and the feature of content to be pushed into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks, the push processing method further comprises: acquiring scene characteristics of the target object;
inputting the object features and the to-be-pushed content features into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks, wherein the method comprises the following steps: and inputting the object features, the scene features and the to-be-pushed content features into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks.
4. The push processing method of claim 1, wherein the push event samples further comprise a tag for a plurality of tasks, the tag indicating whether the sample object completes the task for the sample push content;
and performing weighted sum operation on the task completion probability prediction model, the first auxiliary model and the second auxiliary model by using the second task weight of each task for the first loss function of the task to obtain a second loss function of the push event sample, wherein the weighted sum operation comprises the following steps:
determining the first loss function for the task based on the label of the task, the sample task completion probability, the first auxiliary probability, and the second auxiliary probability;
and carrying out weighted sum operation on the first loss function of each task by using the second task weight of each task to obtain a second loss function of the pushing event sample.
5. The push processing method of claim 4, wherein the determining the first penalty function for the task based on the label for the task, the sample task completion probability, the first auxiliary probability, and the second auxiliary probability comprises:
Determining a first sub-loss function of the task completion probability prediction model for the task based on the label of the task and the sample task completion probability;
determining a second sub-loss function of the first auxiliary model for the task based on the label of the task and the first auxiliary probability;
determining a third sub-loss function of the second auxiliary model for the task based on the label of the task and the second auxiliary probability;
the first loss function is determined based on the first, second, and third sub-loss functions.
6. The push processing method of claim 1, wherein the determining the second task weight for the task based on the sample task completion probability, the first auxiliary probability, and the second auxiliary probability comprises:
determining a first difference of the sample task completion probability and the first auxiliary probability;
determining a second difference of the sample task completion probability and the second auxiliary probability;
a second task weight for the task is determined based on the first difference and the second difference.
7. The push processing method of claim 6, wherein the determining a second task weight for the task based on the first difference and the second difference comprises:
Obtaining a first parameter and a second parameter, wherein the first parameter indicates a side severity of an impact on sample push content, and the second parameter indicates an amplification index of the impact of the task on the object and the sample push content;
the second task weight is determined based on the first difference, the second difference, the first parameter, and the second parameter.
8. The push processing method of claim 7, wherein the determining the second task weight based on the first difference, the second difference, the first parameter, and the second parameter comprises:
adding a predetermined constant to the first difference to obtain a first enhanced difference;
adding the predetermined constant to the second difference to obtain a second enhanced difference;
determining a sum of a product of the second enhancement difference and the first parameter and the first enhancement difference;
and taking the second parameter of the sum to the power as a second task weight.
9. The push processing method of claim 1, wherein the push event samples are out of a push event sample set comprising a plurality of the push event samples;
the training the task completion probability prediction model, the first auxiliary model, and the second auxiliary model based on the second loss function, comprising:
Determining a third loss function for the set of push event samples based on the second loss function for each of the push event samples in the set of push event samples;
training the task completion probability prediction model, the first auxiliary model, and the second auxiliary model based on the third loss function.
10. The push processing method of claim 9, wherein the determining a third loss function for the set of push event samples based on the second loss function for each of the push event samples in the set of push event samples comprises:
acquiring a sample weight of each push event sample in the push event sample set;
and based on the sample weight, carrying out weighted sum on the second loss function of each push event sample to obtain the third loss function.
11. The push processing method of claim 9, wherein the inputting the sample object feature and the sample push content feature into the task completion probability prediction model to obtain the sample task completion probabilities for a plurality of tasks, inputting the sample object feature into the first auxiliary model to obtain the first auxiliary probabilities for a plurality of the tasks, and inputting the sample push content feature into the second auxiliary model to obtain the second auxiliary probabilities for a plurality of the tasks comprises:
Inputting the sample object features and the sample push content features into an embedding layer to obtain a first vector corresponding to the sample object features and a second vector corresponding to the sample push content features;
inputting the first vector and the second vector into the task completion probability prediction model to obtain the sample task completion probabilities of a plurality of tasks, inputting the first vector into the first auxiliary model to obtain the first auxiliary probabilities of a plurality of tasks, and inputting the second vector into the second auxiliary model to obtain the second auxiliary probabilities of a plurality of tasks;
the training the task completion probability prediction model, the first auxiliary model, and the second auxiliary model based on the third loss function, comprising:
adjusting model node weights in the task completion probability prediction model, the first auxiliary model and the second auxiliary model according to a backward propagation algorithm of the gradient by utilizing the third loss function;
the gradient of first layer node weights of the first auxiliary model and the second auxiliary model is prevented from propagating towards the embedding layer.
12. The push processing method of claim 11, wherein the inputting the sample object feature and the sample push content feature into an embedding layer, to obtain a first vector corresponding to the sample object feature and a second vector corresponding to the sample push content feature, comprises:
Inputting the sample object features and the sample push content features into an embedding layer to obtain a first initial vector corresponding to the sample object features and a second initial vector corresponding to the sample push content features;
acquiring a first vector length of the first vector and a second vector length of the second vector;
pooling the first initial vector based on the first vector length to obtain the first vector;
and based on the second vector length, pooling the second initial vector to obtain the second vector.
13. The push processing method of claim 1, wherein the task completion probability prediction model comprises a first cascade layer, a plurality of first expert sub-models, a plurality of first gating nodes corresponding to a plurality of the tasks, and a plurality of first predictor sub-models;
the step of inputting the sample object feature and the sample push content feature into the task completion probability prediction model to obtain the sample task completion probabilities of a plurality of tasks, comprises the following steps:
cascading a first vector corresponding to the sample object feature and a second vector corresponding to the sample push content feature into a first cascade vector through the first cascade layer;
Inputting the first cascade vector into a plurality of the first expert sub-models;
the output of a plurality of first expert sub-models is weighted and summed through the first gating node corresponding to each task to obtain a first intermediate vector corresponding to the task;
and inputting a first intermediate vector corresponding to the task into the first predictor model corresponding to the task to obtain the sample task completion probability of the task.
14. The push processing method of claim 13, wherein the weighting and summing the outputs of the plurality of first expert sub-models by the first gating node corresponding to each task to obtain a first intermediate vector corresponding to the task, includes:
acquiring weight vectors of the first gating nodes, wherein the weight vectors indicate weights of a plurality of first expert sub-models;
and through the first gating node, the weighted sum is carried out on the outputs of the plurality of first expert sub-models by utilizing the weight vector, so that the first intermediate vector corresponding to the task is obtained.
15. The push processing method of claim 14, wherein the obtaining the weight vector of the first gating node comprises:
Obtaining a first matrix, wherein the number of rows of the first matrix is the number of the first expert sub-models, and the number of columns is the dimension of the first cascade vector;
multiplying the first matrix with the transpose of the first cascade vector, and performing normalized index processing on the multiplication result to obtain the weight vector of the first gating node.
16. A push processing device is characterized in that,
the first acquisition unit is used for acquiring object characteristics of a target object and content characteristics to be pushed of content to be pushed;
the first input unit is used for inputting the object characteristics and the characteristics of the content to be pushed into a task completion probability prediction model to obtain task completion probabilities of a plurality of tasks;
the determining unit is used for determining the sorting score of the content to be pushed based on the task completion probabilities of the tasks corresponding to the content characteristics to be pushed;
the sorting unit is used for sorting the plurality of content to be pushed based on the sorting scores of the plurality of content to be pushed;
the task completion probability prediction model is trained by the following modes: obtaining a push event sample, wherein the push event sample comprises sample object characteristics and sample push content characteristics; inputting the sample object features and the sample push content features into the task completion probability prediction model to obtain sample task completion probabilities of a plurality of tasks, inputting the sample object features into a first auxiliary model to obtain first auxiliary probabilities of the plurality of tasks, and inputting the sample push content features into a second auxiliary model to obtain second auxiliary probabilities corresponding to the plurality of tasks; determining a second task weight for the task based on the sample task completion probability, the first auxiliary probability, and the second auxiliary probability; and carrying out weighted sum operation on the task completion probability prediction model, the first auxiliary model and the second auxiliary model aiming at a first loss function of the task by using the second task weight of each task to obtain a second loss function of the push event sample, and training the task completion probability prediction model, the first auxiliary model and the second auxiliary model based on the second loss function.
17. An electronic device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor implements the push processing method according to any of claims 1 to 15 when executing the computer program.
18. A computer-readable storage medium storing a computer program, characterized in that the computer program, when executed by a processor, implements the push processing method according to any one of claims 1 to 15.
CN202310983164.XA 2023-08-07 2023-08-07 Push processing method, related device and medium Active CN116723234B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310983164.XA CN116723234B (en) 2023-08-07 2023-08-07 Push processing method, related device and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310983164.XA CN116723234B (en) 2023-08-07 2023-08-07 Push processing method, related device and medium

Publications (2)

Publication Number Publication Date
CN116723234A CN116723234A (en) 2023-09-08
CN116723234B true CN116723234B (en) 2023-11-14

Family

ID=87875502

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310983164.XA Active CN116723234B (en) 2023-08-07 2023-08-07 Push processing method, related device and medium

Country Status (1)

Country Link
CN (1) CN116723234B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106649774A (en) * 2016-12-27 2017-05-10 北京百度网讯科技有限公司 Artificial intelligence-based object pushing method and apparatus
CN111401963A (en) * 2020-03-20 2020-07-10 支付宝(杭州)信息技术有限公司 Method and device for training user behavior prediction model
CN112183818A (en) * 2020-09-02 2021-01-05 北京三快在线科技有限公司 Recommendation probability prediction method and device, electronic equipment and storage medium
CN113254792A (en) * 2021-07-15 2021-08-13 腾讯科技(深圳)有限公司 Method for training recommendation probability prediction model, recommendation probability prediction method and device
CN113641896A (en) * 2021-07-23 2021-11-12 北京三快在线科技有限公司 Model training and recommendation probability prediction method and device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8260846B2 (en) * 2008-07-25 2012-09-04 Liveperson, Inc. Method and system for providing targeted content to a surfer

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106649774A (en) * 2016-12-27 2017-05-10 北京百度网讯科技有限公司 Artificial intelligence-based object pushing method and apparatus
CN111401963A (en) * 2020-03-20 2020-07-10 支付宝(杭州)信息技术有限公司 Method and device for training user behavior prediction model
CN112183818A (en) * 2020-09-02 2021-01-05 北京三快在线科技有限公司 Recommendation probability prediction method and device, electronic equipment and storage medium
CN113254792A (en) * 2021-07-15 2021-08-13 腾讯科技(深圳)有限公司 Method for training recommendation probability prediction model, recommendation probability prediction method and device
CN113641896A (en) * 2021-07-23 2021-11-12 北京三快在线科技有限公司 Model training and recommendation probability prediction method and device

Also Published As

Publication number Publication date
CN116723234A (en) 2023-09-08

Similar Documents

Publication Publication Date Title
US8856229B2 (en) System and method for social networking
US20170372351A1 (en) Dynamic state-space modeling based on contextual and behavioral factors
US10565525B2 (en) Collaborative filtering method, apparatus, server and storage medium in combination with time factor
Wang A market-oriented approach to accomplish product positioning and product recommendation for smart phones and wearable devices
EP2779057A1 (en) Computing system with relationship model mechanism and method of operation thereof
US20120233229A1 (en) Method of Generating Statistical Opinion Data
CN102696028A (en) Method and apparatus for dynamically grouping items in applications
CN113204577A (en) Information pushing method and device, electronic equipment and computer readable medium
CN111797320A (en) Data processing method, device, equipment and storage medium
CN115712657A (en) User demand mining method and system based on meta universe
Burkhard et al. Extracting regular mobility patterns from sparse CDR data without a priori assumptions
CN110555749A (en) credit behavior prediction method and device based on neural network
CN113723995A (en) Method and device for determining marketing task
CN117435819A (en) Method, system and storage medium for recommending interest points through space-time dynamic perception
CN116723234B (en) Push processing method, related device and medium
CN112381236A (en) Data processing method, device, equipment and storage medium for federal transfer learning
Dessens et al. Patterns and trends in occupational attainment of first jobs in the Netherlands, 1930–1995: ordinary least squares regression versus conditional multinomial logistic regression
CN115017362A (en) Data processing method, electronic device and storage medium
CN112418442A (en) Data processing method, device, equipment and storage medium for federal transfer learning
KR101462858B1 (en) Methods for competency assessment of corporation for global business
CN111951011A (en) Monitoring system threshold determination method and device
CN117349791A (en) Push processing method, related device and medium
CN117395303A (en) Push processing method, related device and medium
CN116796076B (en) Service recommendation method, device, equipment and storage medium
CN113905070B (en) Service providing method and system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant