CN112541122A - Recommendation model training method and device, electronic equipment and storage medium - Google Patents

Recommendation model training method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN112541122A
CN112541122A CN202011545736.9A CN202011545736A CN112541122A CN 112541122 A CN112541122 A CN 112541122A CN 202011545736 A CN202011545736 A CN 202011545736A CN 112541122 A CN112541122 A CN 112541122A
Authority
CN
China
Prior art keywords
sample
data
recommendation
representation vector
model
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.)
Pending
Application number
CN202011545736.9A
Other languages
Chinese (zh)
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.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and Technology 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 Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202011545736.9A priority Critical patent/CN112541122A/en
Publication of CN112541122A publication Critical patent/CN112541122A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9535Search customisation based on user profiles and personalisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods

Abstract

The application discloses a training method and device of a recommendation model, electronic equipment and a storage medium, and relates to the technical field of computers, in particular to the technical fields of artificial intelligence such as intelligent recommendation, user understanding, deep learning and big data processing. The specific implementation scheme is as follows: acquiring sample portrait data and sample recommendation data; generating an image representation vector corresponding to the sample image data; generating a feature representation vector corresponding to the sample recommendation data; the student model is trained according to the portrait representation vector, the feature representation vector and the prediction recommendation result of the teacher model, wherein the teacher model is obtained by training according to the sample behavior data, the sample portrait data and the sample recommendation data of the user to which the sample portrait data belongs, the student model can be trained only by using partial user features under the guidance of the teacher model, the student model can learn the generalization recommendation capability of the teacher model, and therefore the accuracy of personalized recommendation of the student model can be effectively improved.

Description

Recommendation model training method and device, electronic equipment and storage medium
Technical Field
The application relates to the technical field of computers, in particular to the technical field of artificial intelligence such as intelligent recommendation, user understanding, deep learning and big data processing, and particularly relates to a training method and device of a recommendation model, electronic equipment and a storage medium.
Background
Artificial intelligence is the subject of research that makes computers simulate some human mental processes and intelligent behaviors (such as learning, reasoning, thinking, planning, etc.), both at the hardware level and at the software level. Artificial intelligence hardware technologies generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing, and the like; the artificial intelligence software technology mainly comprises a computer vision technology, a voice recognition technology, a natural language processing technology, machine learning/deep learning, a big data processing technology, a knowledge map technology and the like.
Cold starts are one of the important challenges for recommended systems, including user cold starts, item cold starts, and system cold starts. The user cold start means that the new user does not have behavior data related to the user when registering, so that the interest of the new user is difficult to predict, and personalized recommendation cannot be accurately made. According to the user data missing type, the user cold start can be divided into portrait data missing, behavior data missing and the like of the user.
Disclosure of Invention
A training method, device, electronic equipment, storage medium and computer program product of a recommendation model are provided.
According to a first aspect, there is provided a training method of a recommendation model, comprising: acquiring sample portrait data and sample recommendation data; generating a representation vector corresponding to the sample representation data; generating a feature representation vector corresponding to the sample recommendation data; and training a student model according to the portrait representation vector, the feature representation vector and a prediction recommendation result of a teacher model, wherein the teacher model is obtained by training according to sample behavior data of a user to which the sample portrait data belongs, the sample portrait data and the sample recommendation data.
According to a second aspect, there is provided a training apparatus for recommending a model, comprising: the acquisition module is used for acquiring sample portrait data and sample recommendation data; a generation module to generate a representation vector corresponding to the sample representation data and to generate a feature representation vector corresponding to the sample recommendation data; and the first training module is used for training a student model according to the portrait representation vector, the feature representation vector and a prediction recommendation result of a teacher model, wherein the teacher model is obtained by training according to sample behavior data of a user to which the sample portrait data belongs, the sample portrait data and the sample recommendation data.
According to a third aspect, there is provided an electronic device comprising: at least one processor; and a memory communicatively coupled to the at least one processor; the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the training method of the recommendation model of the embodiment of the application.
According to a fourth aspect, a non-transitory computer-readable storage medium is proposed, having stored thereon computer instructions for causing a computer to perform a training method of a recommendation model disclosed in embodiments of the present application.
According to a fifth aspect, a computer program product is presented, comprising a computer program which, when executed by a processor, implements a method of training a recommendation model as disclosed in embodiments of the present application.
It should be understood that the statements in this section do not necessarily identify key or critical features of the embodiments of the present application, nor do they limit the scope of the present application. Other features of the present application will become apparent from the following description.
Drawings
The drawings are included to provide a better understanding of the present solution and are not intended to limit the present application. Wherein:
FIG. 1 is a schematic diagram according to a first embodiment of the present application;
FIG. 2 is a schematic diagram of a student model and a teacher model in an embodiment of the present application;
FIG. 3 is a schematic diagram according to a second embodiment of the present application;
FIG. 4 is a schematic view of a student model service scenario in an embodiment of the present application;
FIG. 5 is a schematic illustration according to a third embodiment of the present application;
FIG. 6 is a schematic illustration according to a fourth embodiment of the present application;
FIG. 7 is a block diagram of an electronic device for implementing a training method for a recommendation model according to an embodiment of the present application.
Detailed Description
The following description of the exemplary embodiments of the present application, taken in conjunction with the accompanying drawings, includes various details of the embodiments of the application for the understanding of the same, which are to be considered exemplary only. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the present application. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Fig. 1 is a schematic diagram according to a first embodiment of the present application.
It should be noted that an execution subject of the training method for the recommendation model in this embodiment is a training device for the recommendation model, the device may be implemented in a software and/or hardware manner, the device may be configured in an electronic device, and the electronic device may include, but is not limited to, a terminal, a server, and the like.
The embodiment of the application relates to the technical field of artificial intelligence such as intelligent recommendation, user understanding, deep learning and big data processing.
Wherein, Artificial Intelligence (Artificial Intelligence), english is abbreviated as AI. The method is a new technical science for researching and developing theories, methods, technologies and application systems for simulating, extending and expanding human intelligence.
Deep learning is the intrinsic law and expression level of the learning sample data, and the information obtained in the learning process is very helpful for the interpretation of data such as characters, images and sounds. The final goal of deep learning is to make a machine capable of human-like analytical learning, and to recognize data such as characters, images, and sounds.
The intelligent recommendation is to provide real-time and accurate recommendation service for different scenes by deeply mining user behaviors and business characteristics, and to rapidly improve user activity and click conversion rate.
The user understanding is related to the sensing measurement, behavior understanding and emotion calculation of user data, and analysis and mining of various types of user data, such as user network searching behavior data, user sharing photos and annotation data and the like.
The big data processing refers to a process of analyzing and processing large-scale data in an artificial intelligence mode, and the big data can be summarized into 5V, and has large data Volume (Volume), high speed (Velocity), multiple types (Velocity), Value (Value) and authenticity (Veracity).
As shown in fig. 1, the training method of the recommendation model includes:
s101: sample portrait data and sample recommendation data are obtained.
The portrait data of the mass users for training the student model can be called sample portrait data, and the recommendation data of the mass users for training the student model can be called sample recommendation data.
Sample portrait data, e.g., attribute feature data of the user, such as gender, age, occupation, income, scholarly, etc., and sample recommendation data, e.g., content of a recommended article, recommended goods, recommended store, etc., that is a candidate to be recommended.
In the embodiment of the application, after the sample portrait data and the sample recommendation data are obtained, the obtained sample portrait data and the sample recommendation data can be used for training a student model, so that the student model can determine appropriate recommendation data only according to portrait data of a real user in an actual recommended application scene, and the method is not limited to this.
That is to say, in the process of training the student model, the embodiment of the present application adopts partial sample user features (i.e., sample portrait data) and sample recommendation data as training data.
The student model may be any one of artificial intelligence models, such as a machine learning model or a neural network model, and the like, without limitation.
S102: an image representation vector corresponding to the sample image data is generated.
After the sample portrait data and the sample recommendation data are obtained, the portrait representation vector corresponding to the sample portrait data can be directly generated, the portrait representation vector can be used for representing the feature expression of the sample portrait data in the vector dimension, and when the sample portrait data is converted into the corresponding portrait representation vector, the model fusion calculation in artificial intelligence can be conveniently carried out.
For example, any possible vector computation algorithm may be employed to compute an image representation vector corresponding to the sample image data.
S103: a feature representation vector corresponding to the sample recommendation data is generated.
After the sample portrait data and the sample recommendation data are obtained, the feature representation vector corresponding to the sample recommendation data can be directly generated, the feature representation vector can be used for representing feature representation of the sample recommendation data in vector dimensions, and when the sample recommendation data are converted into the corresponding feature representation vector, fusion calculation can be conveniently carried out with a model in artificial intelligence.
For example, any possible vector calculation algorithm may be used to calculate the feature representation vector corresponding to the sample recommendation data.
S104: and training the student model according to the portrait representation vector, the feature representation vector and the prediction recommendation result of the teacher model, wherein the teacher model is trained according to sample behavior data, sample portrait data and sample recommendation data of a user to which the sample portrait data belongs.
In the process of training the student model, not only the image representation vector and the feature representation vector are referred to, but also the prediction recommendation result of the teacher model, that is, the prediction recommendation result of the teacher model for the image representation vector and the feature representation vector is referred to, wherein the teacher model is trained according to the sample behavior data, the sample image data and the sample recommendation data of the user to which the sample image data belongs.
That is, the teacher model is trained by referring to the complete user characteristics (sample behavior data and sample portrait data) and the sample recommendation data, so that the accuracy of the prediction recommendation result of the teacher model is higher.
The behavior data of a large number of users for training the teacher model may be referred to as sample behavior data, and the sample behavior data specifically includes: user click history, user collection history, user browsing history of the last week, etc.
In the process of training the teacher model, behavior data belonging to the same or similar user as the sample portrait data may be used as sample behavior data, so that the recommendation result is more matched with the user or the users, and no limitation is imposed on the recommendation result.
The teacher model may be any one of artificial intelligence models, such as a machine learning model or a neural network model, and the like, without limitation.
In the embodiment of the application, the teacher model can have the same model structure as the student model, so that the student model can be better and more conveniently fitted with the prediction result of the teacher model.
In the embodiment of the application, the teacher model may be specifically trained before the student model is trained, or the teacher model may be trained while the student model is being trained, which is not limited to this.
Referring to fig. 2, fig. 2 is a schematic diagram of a student model and a teacher model in an embodiment of the present application, where the teacher model and the student model have the same model structure, and training data for training the student models includes: the representation vector of the portrait, the representation vector of the feature, and the prediction recommendation result of the teacher model (which can be expressed by distillation loss), and the training data for training the teacher model includes: an image representation vector, a feature representation vector, and a behavior representation vector.
Optionally, in some embodiments, after the sample portrait data and the sample recommendation data are obtained, a user identifier of a user to which the sample portrait data belongs may also be obtained, and behavior data corresponding to the user identifier is determined from a preset sample data set and is used as the sample behavior data.
The preset sample data set can be configured with massive sample data in advance, and the sample data set comprises sample portrait data corresponding to a sample user, behavior data of the sample user and sample recommendation data, and can also be configured with corresponding relations among a user identifier of the sample user, the sample portrait data, the behavior data and the sample recommendation data in advance.
Therefore, the user identification of the user to which the sample portrait data belongs can be directly obtained, the behavior data corresponding to the user identification is determined from the preset sample data set and is used as the sample behavior data, the sample behavior data of the user to which the sample portrait data belongs can be quickly obtained, the training efficiency of the model is improved in an auxiliary mode, and the obtained training data have good matching performance.
After the sample portrait data and the sample recommendation data are obtained, behavior representation vectors corresponding to the sample behavior data can be generated, and the portrait representation vectors, the feature representation vectors and the behavior representation vectors are input into the teacher model to obtain a prediction recommendation result output by the teacher model.
The behavior representation vector can be used for representing the characteristic expression of the sample behavior data in the vector dimension, and when the sample behavior data are converted into the corresponding behavior representation vector, the behavior representation vector can be conveniently fused with a model in artificial intelligence for calculation.
For example, any possible vector calculation algorithm may be used to calculate the behavior representation vector corresponding to the sample behavior data.
As can be seen from the above examples, the prediction recommendation result in the embodiment of the present application is obtained by predicting the teacher model according to the image representation vector, the feature representation vector, and the behavior representation vector, and the accuracy of the prediction recommendation result is higher due to the reference to the complete user feature.
In the embodiment, by obtaining sample portrait data and sample recommendation data, portrait representation vectors corresponding to the sample portrait data are generated, feature representation vectors corresponding to the sample recommendation data are generated, and a student model is trained according to the portrait representation vectors, the feature representation vectors and prediction recommendation results of a teacher model.
Fig. 3 is a schematic diagram according to a second embodiment of the present application.
As shown in fig. 3, the training method of the recommendation model includes:
s301: sample portrait data and sample recommendation data are obtained.
S302: a user identification of a user to whom the sample portrait data belongs is obtained.
S303: and determining behavior data corresponding to the user identification from the preset sample data set and using the behavior data as sample behavior data.
S304: a representation vector of the image corresponding to the sample image data is generated, a feature representation vector corresponding to the sample recommendation data is generated, and a behavior representation vector corresponding to the sample behavior data is generated.
For S301 to S304, reference may be made to the above embodiments, which are not described herein again.
S305: and inputting the image representation vector, the feature representation vector and the behavior representation vector into the teacher model to obtain a candidate recommendation result output by the teacher model.
Referring to fig. 2, in the embodiment of the present application, a transfer learning manner is adopted, a teacher model is trained by using the full-scale user characteristics of non-cold-start users, and then the trained teacher model is adopted to guide the training of a student model, wherein the student model is trained and predicted only by using user portrait data and is consistent with the on-line situation.
S306: a first loss value between the candidate recommendation and the calibrated recommendation is determined.
S307: and if the first loss value meets a first reference loss threshold, taking the candidate recommendation as a prediction recommendation.
The target function corresponding to the teacher model may be a loss function, and a loss value corresponding to the loss function when the teacher model converges may be referred to as a first reference loss threshold.
In the process of training the teacher model, a first loss value between the candidate recommendation result and a calibration recommendation result (the calibration recommendation result may be, for example, a real label of the content to be recommended) is determined, and if the first loss value satisfies a first reference loss threshold, the candidate recommendation result is taken as a prediction recommendation result.
S308: and inputting the portrait representation vector, the feature representation vector and the prediction recommendation result of the teacher model into the student model to obtain a target recommendation result output by the student model.
After the prediction recommendation result output by the teacher model is determined, the portrait representation vector, the feature representation vector and the prediction recommendation result of the teacher model are input into the student model to obtain a target recommendation result output by the student model.
S309: and training the student model according to the target recommendation result, the prediction recommendation result and the calibration recommendation result.
In the embodiment of the application, corresponding loss functions can be configured for the student models, and the loss functions of the student models can be configured to be obtained according to the fitting of the loss functions of the teacher model, so that the student models can be trained according to the target recommendation result, the prediction recommendation result and the calibration recommendation result.
In some embodiments, a second loss value between the target recommendation, the predicted recommendation, and the calibration recommendation is determined; if the second loss value satisfies a second reference loss threshold, the student model training is complete.
In the process of training the teacher model, a first loss value between the candidate recommendation result and a calibration recommendation result (the calibration recommendation result may be, for example, a real label of the content to be recommended) is determined, and if the first loss value satisfies a first reference loss threshold, the candidate recommendation result is taken as a prediction recommendation result.
For example, a corresponding loss function may be configured for the student model, and the loss function of the student model may also be configured to be obtained by fitting the loss function of the teacher model, so that the loss function corresponding to the student model may be as follows:
minWs(1-τ)*Ls(y,f(X;Ws))+τ*Ld(f(X*;Wt),f(X;Ws));
in the training process of the student model, besides the loss value between the prediction recommendation result and the real label, the prediction probability of the student model and the teacher model is fitted.
Therefore, in the embodiment of the present application, the learning goal of the student model is to minimize the prediction probability and the real label, and the weighted values of the prediction probability and the prediction probability of the teacher model, as shown in the above formula: tau is a hyper-parameter and is used for balancing self-learning capability of the student model and guiding capability of the teacher model, X is a sample data set (sample image data + sample recommended data) used for training the student model, X is a sample data set (sample image data + sample behavior data + object sample recommended data) used for training the teacher model, Ls is a loss function of the student model, Ws is a parameter of the student model, Ld is a loss function of the teacher model, Wt is a parameter of the teacher model, y represents a real label, f (X, Ws) represents a prediction probability of the student model, f (X, Wt) represents a prediction probability of the teacher model, and parameters of the teacher model are kept unchanged in the training process of the student model.
Inputting the portrait representation vector, the feature representation vector and the prediction recommendation result of the teacher model into the student model to obtain a target recommendation result output by the student model, and determining a second loss value between the target recommendation result, the prediction recommendation result and the calibration recommendation result; if the second loss value meets the second reference loss threshold value, training of the student model is completed, and the student model learns the generalization ability of the teacher model instead of overfitting training data, so that the student model learned based on feature distillation in the embodiment of the application can relieve the cold start problem of the user, effectively improve the generalization ability of the student model and improve the recommendation performance of the existing user.
After the student model is obtained through training, the student model can be used for providing recommendation service on line, referring to fig. 4, where fig. 4 is a schematic view of a service scenario of the student model in the embodiment of the present application. When the student model is used for recommending data on line, corresponding recommended data can be matched and identified according to the characteristics of part of users (user image data of real users).
In the embodiment, by obtaining sample portrait data and sample recommendation data, portrait representation vectors corresponding to the sample portrait data are generated, feature representation vectors corresponding to the sample recommendation data are generated, and a student model is trained according to the portrait representation vectors, the feature representation vectors and prediction recommendation results of a teacher model. Inputting the portrait representation vector, the feature representation vector and the prediction recommendation result of the teacher model into the student model to obtain a target recommendation result output by the student model, and determining a second loss value between the target recommendation result, the prediction recommendation result and the calibration recommendation result; if the second loss value satisfies the second reference loss threshold, then the training of the student model is completed, because the student model learns the generalization ability of the teacher model instead of over-fitting the training data, therefore, the student model learned based on the feature distillation in the embodiment can not only relieve the cold start problem of the user, but also effectively improve the generalization ability of the student model itself and improve the recommendation performance of the existing user.
Fig. 5 is a schematic diagram according to a third embodiment of the present application.
As shown in fig. 5, the training device 50 for the recommendation model includes:
an obtaining module 501, configured to obtain sample portrait data and sample recommendation data;
a generation module 502 for generating a representation vector corresponding to the sample representation data and generating a feature representation vector corresponding to the sample recommendation data;
the first training module 503 is configured to train the student model according to the portrait representation vector, the feature representation vector, and the prediction recommendation result of the teacher model, where the teacher model is trained according to the sample behavior data of the user to which the sample portrait data belongs, the sample portrait data, and the sample recommendation data. In some embodiments of the present application, wherein,
the obtaining module 501 is further configured to obtain a user identifier of a user to which the sample portrait data belongs, and determine behavior data corresponding to the user identifier from a preset sample data set and use the behavior data as sample behavior data.
In some embodiments of the present application, wherein,
a generating module 502, further configured to generate a behavior representation vector corresponding to the sample behavior data;
referring to fig. 6, fig. 6 is a schematic diagram of a training apparatus 60 for a recommended model according to a fourth embodiment of the present application, including: the obtaining module 601, the generating module 602, and the first training module 603 further include:
the second training module 604 is configured to input the image representation vector, the feature representation vector, and the behavior representation vector into the teacher model to obtain a prediction recommendation result output by the teacher model.
In some embodiments of the present application, the second training module 604 is specifically configured to:
inputting the image representation vector, the feature representation vector and the behavior representation vector into a teacher model to obtain a candidate recommendation result output by the teacher model;
determining a first loss value between the candidate recommendation result and the calibration recommendation result;
and if the first loss value meets a first reference loss threshold, taking the candidate recommendation as a prediction recommendation.
In some embodiments of the present application, the first training module 603 is specifically configured to:
inputting the portrait representation vector, the feature representation vector and the prediction recommendation result of the teacher model into the student model to obtain a target recommendation result output by the student model;
and training the student model according to the target recommendation result, the prediction recommendation result and the calibration recommendation result.
In some embodiments of the present application, the first training module 603 is further configured to:
determining a second loss value among the target recommendation result, the prediction recommendation result and the calibration recommendation result;
if the second loss value satisfies a second reference loss threshold, the student model training is complete.
It is understood that the training apparatus 60 of the recommendation model in fig. 6 of the present embodiment may have the same functions and structures as the training apparatus 50 of the recommendation model in the above embodiment, the obtaining module 601 may have the same functions and structures as the obtaining module 501 in the above embodiment, the generating module 602 may have the same structures as the generating module 502 in the above embodiment, and the first training module 603 may have the same structures as the first training module 503 in the above embodiment.
It should be noted that the foregoing explanation of the training method of the recommendation model is also applicable to the training apparatus of the recommendation model of the present embodiment, and is not repeated herein.
In the embodiment, by obtaining sample portrait data and sample recommendation data, portrait representation vectors corresponding to the sample portrait data are generated, feature representation vectors corresponding to the sample recommendation data are generated, and a student model is trained according to the portrait representation vectors, the feature representation vectors and prediction recommendation results of a teacher model.
There is also provided, in accordance with an embodiment of the present application, an electronic device, a readable storage medium, and a computer program product.
FIG. 7 is a block diagram of an electronic device for implementing a training method for a recommendation model according to an embodiment of the present application. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the present application that are described and/or claimed herein.
As shown in fig. 7, the device 700 comprises a computing unit 701, which may perform various suitable actions and processes according to a computer program stored in a Read Only Memory (ROM)702 or a computer program loaded from a storage unit 708 into a Random Access Memory (RAM) 703. In the RAM 703, various programs and data required for the operation of the device 700 can also be stored. The computing unit 701, the ROM 702, and the RAM 703 are connected to each other by a bus 704. An input/output (I/O) interface 705 is also connected to bus 704.
Various components in the device 700 are connected to the I/O interface 705, including: an input unit 706 such as a keyboard, a mouse, or the like; an output unit 707 such as various types of displays, speakers, and the like; a storage unit 708 such as a magnetic disk, optical disk, or the like; and a communication unit 709 such as a network card, modem, wireless communication transceiver, etc. The communication unit 709 allows the device 700 to exchange information/data with other devices via a computer network, such as the internet, and/or various telecommunication networks.
Computing unit 701 may be a variety of general purpose and/or special purpose processing components with processing and computing capabilities. Some examples of the computing unit 701 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various specialized Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, and so forth. The calculation unit 701 performs the respective methods and processes described above, for example, a training method of a recommendation model.
For example, in some embodiments, the training method of the recommendation model may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as storage unit 708. In some embodiments, part or all of a computer program may be loaded onto and/or installed onto device 700 via ROM 702 and/or communications unit 709. When the computer program is loaded into the RAM 703 and executed by the computing unit 701, one or more steps of the training method of the recommendation model described above may be performed. Alternatively, in other embodiments, the computing unit 701 may be configured by any other suitable means (e.g., by means of firmware) to perform the training method of the recommendation model.
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuitry, Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), system on a chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
The program code for implementing the training method of the recommendation model of the present application may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program codes, when executed by the processor or controller, cause the functions/operations specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of this application, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), the internet, and blockchain networks.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The Server can be a cloud Server, also called a cloud computing Server or a cloud host, and is a host product in a cloud computing service system, so as to solve the defects of high management difficulty and weak service expansibility in the traditional physical host and VPS service ("Virtual Private Server", or simply "VPS"). The server may also be a server of a distributed system, or a server incorporating a blockchain.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in the present disclosure may be executed in parallel, sequentially, or in different orders, and are not limited herein as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved.
The above-described embodiments should not be construed as limiting the scope of the present application. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made in accordance with design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims (15)

1. A training method of a recommendation model comprises the following steps:
acquiring sample portrait data and sample recommendation data;
generating a representation vector corresponding to the sample representation data;
generating a feature representation vector corresponding to the sample recommendation data; and
and training a student model according to the portrait representation vector, the feature representation vector and a prediction recommendation result of a teacher model, wherein the teacher model is obtained by training according to sample behavior data of a user to which the sample portrait data belongs, the sample portrait data and the sample recommendation data.
2. The method of claim 1, after said obtaining sample portrait data and sample recommendation data, further comprising:
obtaining a user identification of a user to which the sample portrait data belongs;
and determining behavior data corresponding to the user identification from a preset sample data set and using the behavior data as the sample behavior data.
3. The method of claim 1, after said obtaining sample portrait data and sample recommendation data, further comprising:
generating a behavior representation vector corresponding to the sample behavior data;
inputting the portrait representation vector, the feature representation vector and the behavior representation vector into the teacher model to obtain the prediction recommendation result output by the teacher model.
4. The method of claim 3, wherein said inputting the representation vector of representations of images, the representation vector of features, and the representation vector of behaviors into the teacher model to obtain the predicted recommendation output by the teacher model comprises:
inputting the portrait representation vector, the feature representation vector and the behavior representation vector into the teacher model to obtain a candidate recommendation result output by the teacher model;
determining a first loss value between the candidate recommendation result and the calibration recommendation result;
and if the first loss value meets a first reference loss threshold, taking the candidate recommendation as the prediction recommendation.
5. The method of claim 1, wherein training a student model based on the representation of the features, and predicted recommendations of a teacher model comprises:
inputting the portrait representation vector, the feature representation vector and a prediction recommendation result of a teacher model into the student model to obtain a target recommendation result output by the student model;
and training the student model according to the target recommendation result, the prediction recommendation result and the calibration recommendation result.
6. The method of claim 5, wherein the training the student model based on the target recommendation, the predicted recommendation, and the calibration recommendation comprises:
determining a second loss value among the target recommendation result, the prediction recommendation result and the calibration recommendation result;
and if the second loss value meets a second reference loss threshold, finishing the training of the student model.
7. A training apparatus for recommending a model, comprising:
the acquisition module is used for acquiring sample portrait data and sample recommendation data;
a generation module to generate a representation vector corresponding to the sample representation data and to generate a feature representation vector corresponding to the sample recommendation data;
and the first training module is used for training a student model according to the portrait representation vector, the feature representation vector and a prediction recommendation result of a teacher model, wherein the teacher model is obtained by training according to sample behavior data of a user to which the sample portrait data belongs, the sample portrait data and the sample recommendation data.
8. The apparatus of claim 7, wherein,
the obtaining module is further configured to obtain a user identifier of a user to which the sample portrait data belongs, determine behavior data corresponding to the user identifier from a preset sample data set, and use the behavior data as the sample behavior data.
9. The apparatus of claim 7, wherein,
the generating module is further configured to generate a behavior representation vector corresponding to the sample behavior data;
further comprising:
and the second training module is used for inputting the portrait representation vector, the feature representation vector and the behavior representation vector into the teacher model so as to obtain the prediction recommendation result output by the teacher model.
10. The apparatus of claim 9, wherein the second training module is specifically configured to:
inputting the portrait representation vector, the feature representation vector and the behavior representation vector into the teacher model to obtain a candidate recommendation result output by the teacher model;
determining a first loss value between the candidate recommendation result and the calibration recommendation result;
and if the first loss value meets a first reference loss threshold, taking the candidate recommendation as the prediction recommendation.
11. The apparatus of claim 7, wherein the first training module is specifically configured to:
inputting the portrait representation vector, the feature representation vector and a prediction recommendation result of a teacher model into the student model to obtain a target recommendation result output by the student model;
and training the student model according to the target recommendation result, the prediction recommendation result and the calibration recommendation result.
12. The apparatus of claim 11, wherein the first training module is further configured to:
determining a second loss value among the target recommendation result, the prediction recommendation result and the calibration recommendation result;
and if the second loss value meets a second reference loss threshold, finishing the training of the student model.
13. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1-6.
14. A non-transitory computer readable storage medium having stored thereon computer instructions for causing the computer to perform the method of any one of claims 1-6.
15. A computer program product comprising a computer program which, when executed by a processor, implements the method of any one of claims 1-6.
CN202011545736.9A 2020-12-23 2020-12-23 Recommendation model training method and device, electronic equipment and storage medium Pending CN112541122A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011545736.9A CN112541122A (en) 2020-12-23 2020-12-23 Recommendation model training method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011545736.9A CN112541122A (en) 2020-12-23 2020-12-23 Recommendation model training method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN112541122A true CN112541122A (en) 2021-03-23

Family

ID=75017893

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011545736.9A Pending CN112541122A (en) 2020-12-23 2020-12-23 Recommendation model training method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112541122A (en)

Cited By (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113160009A (en) * 2021-03-31 2021-07-23 北京大米科技有限公司 Information pushing method, related device and computer medium
CN113313314A (en) * 2021-06-11 2021-08-27 北京沃东天骏信息技术有限公司 Model training method, device, equipment and storage medium
CN113361572A (en) * 2021-05-25 2021-09-07 北京百度网讯科技有限公司 Training method and device of image processing model, electronic equipment and storage medium
CN113360770A (en) * 2021-06-30 2021-09-07 北京百度网讯科技有限公司 Content recommendation method, device, equipment and storage medium
CN113360777A (en) * 2021-08-06 2021-09-07 北京达佳互联信息技术有限公司 Content recommendation model training method, content recommendation method and related equipment
CN113722594A (en) * 2021-09-01 2021-11-30 北京百度网讯科技有限公司 Recommendation model training method, recommendation device, electronic equipment and medium
CN113742572A (en) * 2021-08-03 2021-12-03 杭州网易云音乐科技有限公司 Data recommendation method and device, electronic equipment and storage medium
CN113806632A (en) * 2021-08-26 2021-12-17 上海交通大学 Personalized recommendation method based on dual consistency self-ensemble learning
CN114595323A (en) * 2022-03-04 2022-06-07 北京百度网讯科技有限公司 Portrait construction, recommendation, model training method, apparatus, device and storage medium
CN116486195A (en) * 2023-03-22 2023-07-25 北京百度网讯科技有限公司 Training method of video recommendation model, video recommendation method and device
CN117407571A (en) * 2023-12-14 2024-01-16 天津畅玩网络科技有限公司 Information technology consultation service method and system based on correlation analysis

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180268292A1 (en) * 2017-03-17 2018-09-20 Nec Laboratories America, Inc. Learning efficient object detection models with knowledge distillation
CN110070183A (en) * 2019-03-11 2019-07-30 中国科学院信息工程研究所 A kind of the neural network model training method and device of weak labeled data
US20200034702A1 (en) * 2018-07-27 2020-01-30 International Business Machines Corporation Training of student neural network with switched teacher neural networks
US20200065645A1 (en) * 2018-08-27 2020-02-27 International Business Machines Corporation Facilitating extraction of individual customer level rationales utilizing deep learning neural networks coupled with interpretability-oriented feature engineering and post-processing
CN111242297A (en) * 2019-12-19 2020-06-05 北京迈格威科技有限公司 Knowledge distillation-based model training method, image processing method and device
CN111598216A (en) * 2020-04-16 2020-08-28 北京百度网讯科技有限公司 Method, device and equipment for generating student network model and storage medium
CN111598213A (en) * 2020-04-01 2020-08-28 北京迈格威科技有限公司 Network training method, data identification method, device, equipment and medium
CN111950302A (en) * 2020-08-20 2020-11-17 上海携旅信息技术有限公司 Knowledge distillation-based machine translation model training method, device, equipment and medium
CN112070226A (en) * 2020-09-02 2020-12-11 北京百度网讯科技有限公司 Training method, device and equipment of online prediction model and storage medium

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180268292A1 (en) * 2017-03-17 2018-09-20 Nec Laboratories America, Inc. Learning efficient object detection models with knowledge distillation
US20200034702A1 (en) * 2018-07-27 2020-01-30 International Business Machines Corporation Training of student neural network with switched teacher neural networks
US20200065645A1 (en) * 2018-08-27 2020-02-27 International Business Machines Corporation Facilitating extraction of individual customer level rationales utilizing deep learning neural networks coupled with interpretability-oriented feature engineering and post-processing
CN110070183A (en) * 2019-03-11 2019-07-30 中国科学院信息工程研究所 A kind of the neural network model training method and device of weak labeled data
CN111242297A (en) * 2019-12-19 2020-06-05 北京迈格威科技有限公司 Knowledge distillation-based model training method, image processing method and device
CN111598213A (en) * 2020-04-01 2020-08-28 北京迈格威科技有限公司 Network training method, data identification method, device, equipment and medium
CN111598216A (en) * 2020-04-16 2020-08-28 北京百度网讯科技有限公司 Method, device and equipment for generating student network model and storage medium
CN111950302A (en) * 2020-08-20 2020-11-17 上海携旅信息技术有限公司 Knowledge distillation-based machine translation model training method, device, equipment and medium
CN112070226A (en) * 2020-09-02 2020-12-11 北京百度网讯科技有限公司 Training method, device and equipment of online prediction model and storage medium

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
KANG, SEONGKU等: "DE-RRD: A Knowledge Distillation Framework for Recommender System", 《CIKM \'20: PROCEEDINGS OF THE 29TH ACM INTERNATIONAL CONFERENCE ON INFORMATION & KNOWLEDGE MANAGEMENT》, pages 605 *
XU, CHEN等: "Privileged Features Distillation at Taobao Recommendations", 《KDD \'20: PROCEEDINGS OF THE 26TH ACM SIGKDD INTERNATIONAL CONFERENCE ON KNOWLEDGE DISCOVERY & DATA MINING》, pages 2590 - 2598 *
刘金环: "基于神经网络的服装兼容性建模方法研究", 《中国博士学位论文全文数据库工程科技Ⅰ辑》, pages 025 - 1 *
张俊林: "知识蒸馏在推荐系统的应用", Retrieved from the Internet <URL:https://zhuanlan.zhihu.com/p/143155437> *

Cited By (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113160009A (en) * 2021-03-31 2021-07-23 北京大米科技有限公司 Information pushing method, related device and computer medium
CN113361572B (en) * 2021-05-25 2023-06-27 北京百度网讯科技有限公司 Training method and device for image processing model, electronic equipment and storage medium
CN113361572A (en) * 2021-05-25 2021-09-07 北京百度网讯科技有限公司 Training method and device of image processing model, electronic equipment and storage medium
CN113313314A (en) * 2021-06-11 2021-08-27 北京沃东天骏信息技术有限公司 Model training method, device, equipment and storage medium
CN113360770A (en) * 2021-06-30 2021-09-07 北京百度网讯科技有限公司 Content recommendation method, device, equipment and storage medium
CN113360770B (en) * 2021-06-30 2024-04-12 北京百度网讯科技有限公司 Content recommendation method, device, equipment and storage medium
CN113742572A (en) * 2021-08-03 2021-12-03 杭州网易云音乐科技有限公司 Data recommendation method and device, electronic equipment and storage medium
CN113360777A (en) * 2021-08-06 2021-09-07 北京达佳互联信息技术有限公司 Content recommendation model training method, content recommendation method and related equipment
CN113360777B (en) * 2021-08-06 2021-12-07 北京达佳互联信息技术有限公司 Content recommendation model training method, content recommendation method and related equipment
CN113806632A (en) * 2021-08-26 2021-12-17 上海交通大学 Personalized recommendation method based on dual consistency self-ensemble learning
CN113722594B (en) * 2021-09-01 2024-01-09 北京百度网讯科技有限公司 Training method and device of recommendation model, electronic equipment and medium
CN113722594A (en) * 2021-09-01 2021-11-30 北京百度网讯科技有限公司 Recommendation model training method, recommendation device, electronic equipment and medium
CN114595323B (en) * 2022-03-04 2023-03-10 北京百度网讯科技有限公司 Portrait construction, recommendation, model training method, apparatus, device and storage medium
CN114595323A (en) * 2022-03-04 2022-06-07 北京百度网讯科技有限公司 Portrait construction, recommendation, model training method, apparatus, device and storage medium
CN116486195A (en) * 2023-03-22 2023-07-25 北京百度网讯科技有限公司 Training method of video recommendation model, video recommendation method and device
CN116486195B (en) * 2023-03-22 2024-04-16 北京百度网讯科技有限公司 Training method of video recommendation model, video recommendation method and device
CN117407571A (en) * 2023-12-14 2024-01-16 天津畅玩网络科技有限公司 Information technology consultation service method and system based on correlation analysis
CN117407571B (en) * 2023-12-14 2024-02-09 天津畅玩网络科技有限公司 Information technology consultation service method and system based on correlation analysis

Similar Documents

Publication Publication Date Title
CN112541122A (en) Recommendation model training method and device, electronic equipment and storage medium
CN112507040B (en) Training method and device for multivariate relation generation model, electronic equipment and medium
CN113033622B (en) Training method, device, equipment and storage medium for cross-modal retrieval model
CN112633380A (en) Interest point feature extraction method and device, electronic equipment and storage medium
CN113642431B (en) Training method and device of target detection model, electronic equipment and storage medium
CN112579727B (en) Document content extraction method and device, electronic equipment and storage medium
CN113722493B (en) Text classification data processing method, apparatus and storage medium
CN112580733B (en) Classification model training method, device, equipment and storage medium
CN112818227B (en) Content recommendation method and device, electronic equipment and storage medium
CN115082920A (en) Deep learning model training method, image processing method and device
CN113221565A (en) Entity recognition model training method and device, electronic equipment and storage medium
CN115829058A (en) Training sample processing method, cross-modal matching method, device, equipment and medium
CN112949433B (en) Method, device and equipment for generating video classification model and storage medium
CN113158030B (en) Recommendation method and device for remote interest points, electronic equipment and storage medium
CN114792097B (en) Method and device for determining prompt vector of pre-training model and electronic equipment
CN112541557B (en) Training method and device for generating countermeasure network and electronic equipment
CN113392920B (en) Method, apparatus, device, medium, and program product for generating cheating prediction model
CN114817476A (en) Language model training method and device, electronic equipment and storage medium
CN114037052A (en) Training method and device for detection model, electronic equipment and storage medium
CN113886543A (en) Method, apparatus, medium, and program product for generating an intent recognition model
CN114973279B (en) Training method and device for handwritten text image generation model and storage medium
CN115131709B (en) Video category prediction method, training method and device for video category prediction model
CN116416500B (en) Image recognition model training method, image recognition device and electronic equipment
US20240094018A1 (en) Method and device for acquiring point of interest representation information, and method for training spatial relationship perception model for points of interest
CN116150502A (en) Information recommendation method, device, equipment and medium

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