Model training method, diversity score determination method, medium, device and equipment

By constructing user feature vectors and training target models, predicting user diversity scores, the problem of ignoring user diversity audio and video needs in the existing technology is solved, and the accuracy of user diversity analysis and personalized recommendations are improved.

CN114637885BActive Publication Date: 2025-02-07HANGZHOU NETEASE CLOUD MUSIC TECH CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202210176553.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-02-24
Publication Date
2025-02-07
Estimated Expiration
2042-02-24

AI Technical Summary

Technical Problem

When analyzing user's audio and video preferences, the prior art tends to ignore the user's potential demand for diverse audio and video, resulting in the inadequate personalized recommendations to meet the user's diverse needs.

Method used

By determining the interaction data between users and media objects in multiple feature dimensions, the user's feature vector is constructed, and the target model is trained based on these feature vectors and diversity score tags, predicting the user's diversity score.

Benefits of technology

It realizes quantitative analysis of the diversity of interaction between users and media objects, ensures the accuracy of the analysis, and provides users with more accurate data recommendations through diversity prediction ratings, improving user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114637885B_ABST
    Figure CN114637885B_ABST
Patent Text Reader

Abstract

The embodiments of the present disclosure provide a model training method, a diversity score determination method, a medium, a device and an apparatus, wherein the model training method includes: determining a user feature vector of a target user, wherein the user feature vector is obtained based on the interaction data between the target user and a media object under multiple feature dimensions; processing the user feature vector through a target model to obtain a diversity prediction score corresponding to the target user; and displaying the diversity prediction score to the target user. The method of the present disclosure implements a quantitative analysis of the diversity reflected in the interaction between the user and the media object through a model for predicting the diversity score of the user, and by displaying the diversity prediction score to the user, it is convenient for the user to understand the diversity of his or her interaction with the media object, thereby improving the user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present disclosure relate to the field of computer technology, and more specifically, the embodiments of the present disclosure relate to a model training method, a diversity score determination method, a medium, a device, and an apparatus. Background Art

[0002] This section is intended to provide a background or context to the embodiments of the disclosure that are recited in the claims. No description herein is admitted to be prior art by inclusion in this section.

[0003] With the development of big data technology, users' behavioral preferences can be analyzed based on massive data.

[0004] At present, when audio and video related applications analyze user preferences, they usually analyze user preferences based on the user's previous browsing history after the user's authorization. However, when a user habitually browses or plays audio and video of a certain style, the recommended audio and video for the user is always of this style, ignoring the possibility that the user prefers audio and video of other different styles, resulting in personalized content recommendations that cannot meet the user's diverse needs for audio and video. Summary of the invention

[0005] The present disclosure provides a model training method, a diversity score determination method, a medium, a device and an apparatus to implement analysis of the diversity of interactions between users and media objects.

[0006] In a first aspect of an embodiment of the present disclosure, a model training method is provided, comprising: determining training data, the training data comprising a plurality of user feature vectors and diversity score labels corresponding to the user feature vectors, the user feature vectors being obtained based on interaction data between a user and a media object under a plurality of feature dimensions; training a target model based on the training data to obtain a trained target model, the target model being used to predict a diversity score of the user.

[0007] In a second aspect of an embodiment of the present disclosure, a method for determining a diversity score is provided, including: determining a user feature vector of a target user, wherein the user feature vector is obtained based on interaction data between the target user and a media object under multiple feature dimensions; processing the user feature vector through a target model to obtain a diversity prediction score corresponding to the target user; and displaying the diversity prediction score to the target user.

[0008] In a third aspect of the embodiments of the present disclosure, a computer-readable storage medium is provided, in which computer-executable instructions are stored. When a processor executes the computer-executable instructions, the model training method provided in the first aspect is implemented, and / or the diversity score determination method provided in the second aspect is implemented.

[0009] In a fourth aspect of the embodiments of the present disclosure, a model training device is provided, comprising: a determination unit, for determining training data, the training data comprising a plurality of user feature vectors and diversity score labels corresponding to the user feature vectors, the user feature vectors being obtained based on interaction data between the user and the media object under a plurality of feature dimensions; a training unit, for training a target model based on the training data to obtain a trained target model, the target model being used to predict the diversity score of the user.

[0010] In a fifth aspect of the embodiments of the present disclosure, a diversity score determination device is provided, comprising: a determination unit, used to determine a user feature vector of a target user, wherein the user feature vector is obtained based on interaction data between the target user and a media object under multiple feature dimensions; a processing unit, used to process the user feature vector through a target model to obtain a diversity prediction score corresponding to the target user; and a display unit, used to display the diversity prediction score to the target user.

[0011] In a sixth aspect of an embodiment of the present disclosure, a computing device is provided, comprising: at least one processor and a memory; the memory stores computer-executable instructions; at least one processor executes the computer-executable instructions stored in the memory, so that at least one processor executes the model training method provided in the first aspect, and / or, so that at least one processor executes the diversity score determination method provided in the second aspect.

[0012] In the disclosed embodiment, a target model for predicting a user's diversity score is trained based on training data, wherein the training data includes user features and diversity score labels corresponding to the user features, and the user features are based on the interaction data between the user and the media object under multiple feature dimensions. Thus, by using the idea of ​​model training, a method for quantitatively analyzing the diversity of the interaction between the user and the media object is provided, which not only realizes the analysis of the user's diversity, but also ensures the accuracy of the analysis. Through the user's diversity prediction score, it is helpful for the user to have a clearer understanding of the diversity of the interaction between himself and the media object, and it is also helpful to provide more accurate data recommendations for the user and improve the user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0013] The above and other objects, features and advantages of the exemplary embodiments of the present disclosure will become readily understood by reading the detailed description below with reference to the accompanying drawings. In the accompanying drawings, several embodiments of the present disclosure are shown in an exemplary and non-limiting manner, in which:

[0014] Figure 1 The following schematically shows an application scenario diagram provided according to an embodiment of the present disclosure;

[0015] Figure 2The following schematically shows a flow chart of a model training method provided according to an embodiment of the present disclosure;

[0016] Figure 3 A schematic diagram of a flow chart of a model training method provided according to another embodiment of the present disclosure is schematically shown;

[0017] Figure 4 The following is a schematic diagram showing a process flow of a training process of a target model provided according to an embodiment of the present disclosure;

[0018] Figure 5 The schematic diagram shows a structure of a target model provided according to an embodiment of the present disclosure;

[0019] Figure 6 The flowchart of the diversity score determination method provided in accordance with an embodiment of the present disclosure is schematically shown;

[0020] Figure 7a The flowchart of a diversity score determination method provided in accordance with another embodiment of the present disclosure is schematically shown;

[0021] Figure 7b The structure diagram of the target model provided according to another embodiment of the present disclosure is schematically shown;

[0022] Figure 8 The structure diagram of a storage medium provided according to an embodiment of the present disclosure is schematically shown;

[0023] Fig. 9 The structure diagram of the model training device provided according to an embodiment of the present disclosure is schematically shown;

[0024] Fig.10 The structure diagram of a diversity score determination device provided according to an embodiment of the present disclosure is schematically shown;

[0025] Fig.11 The schematic diagram shows a structure of a computing device provided according to an embodiment of the present disclosure.

[0026] In the drawings, the same or corresponding reference numerals represent the same or corresponding parts. DETAILED DESCRIPTION

[0027] The principles and spirit of the present disclosure will be described below with reference to several exemplary embodiments. It should be understood that these embodiments are provided only to enable those skilled in the art to better understand and implement the present disclosure, and are not intended to limit the scope of the present disclosure in any way. On the contrary, these embodiments are provided to make the present disclosure more thorough and complete, and to fully convey the scope of the present disclosure to those skilled in the art.

[0028] Those skilled in the art will appreciate that the embodiments of the present disclosure may be implemented as a system, device, apparatus, method or computer program product. Therefore, the present disclosure may be specifically implemented in the following forms, namely: complete hardware, complete software (including firmware, resident software, microcode, etc.), or a combination of hardware and software.

[0029] According to an embodiment of the present disclosure, a diversity score determination method, medium, apparatus, and computing device are proposed.

[0030] In this article, it is important to understand that the terms and their meanings are as follows:

[0031] (1) Media object: It can be a single media object or a multimedia object.

[0032] Among them, a single media object refers to an object with a single media form (such as text, sound, or image), such as music without subtitles and cover; a multimedia object refers to an object that contains multiple media forms (such as at least two media forms of text, sound, and image); an object refers to an object that can interact with users, for example, music and videos that users can play and download.

[0033] (2) Behavior diversity: The diversity of the interaction between users and media objects can also be understood as the diversity of multimedia objects that users interact with. For example, the diverse behavior of users playing music of various styles is the diversity of the interaction between users and music, that is, the diversity of the music that users interact with.

[0034] (3) User interaction with a media object: refers to the user's interaction with a media object on an application related to the media object. Optionally, the user's interaction with a media object includes at least one of clicking, browsing, playing, collecting, commenting, downloading, uploading, and sharing.

[0035] (4) User feature vector: feature data related to the user and represented in vector form.

[0036] (5) Feature engineering method: a method that performs one or more data processing (such as standardization, normalization, and digitization) on data to make it meet the model input requirements.

[0037] (6) Multi-layer Perceptron (MLP): An artificial neural network (ANN) that contains at least one hidden layer.

[0038] Furthermore, any number of elements in the drawings is for illustrative purposes only and not limiting, and any naming is for distinction only and does not have any limiting meaning.

[0039] The principle and spirit of the present disclosure are explained in detail below with reference to several representative embodiments of the present disclosure. SUMMARY OF THE INVENTION

[0041] The inventors have discovered that in applications related to data resources such as music and videos, users' preferences for the style and content of these data resources are usually analyzed, while the diversity of users' behaviors is ignored.

[0042] The behavioral diversity of different users may be different, and the behavioral diversity of the same user may also be different at different time stages. For example, some users like to listen to a certain style of music all the time, while other users like to listen to multiple styles of music; users like to listen to one style of music in one time period, and like to listen to multiple styles of music in another time period. It can be seen that the behavioral diversity of users can be used to build a more complete user profile for users and to improve the accuracy of data resource recommendations for users. For example, more new music and more different styles of music can be recommended to users with more diverse behaviors.

[0043] Therefore, it is necessary to analyze the diversity of user behavior.

[0044] Based on the idea of ​​analyzing the behavioral diversity of users, in the embodiments of the present invention, a target model capable of predicting the diversity scores of users is trained based on user feature vectors and diversity score labels corresponding to the user feature vectors. Based on the target model, not only the behavioral diversity analysis of users is achieved and the accuracy of the behavioral diversity analysis is ensured, but also the behavioral diversity of users is quantified into a diversity score, and the behavioral diversity of users is accurately and clearly reflected through the diversity score.

[0045] After introducing the basic principles of the present disclosure, various non-limiting embodiments of the present disclosure are described in detail below.

[0046] Application Scenario Overview

[0047] The scenarios to which the embodiments of the present disclosure are applicable include model training scenarios and / or diversity scoring scenarios.

[0048] First reference Figure 1 , Figure 1 The application scenario diagram provided according to an embodiment of the present disclosure is schematically shown, and the devices involved in the application scenario include a server 101.

[0049] When the application scenario is a model training scenario: the server 101 stores pre-collected training data and deploys a model to be trained, and the model can be trained based on the training data on the server 101.

[0050] When the application scenario is a diversity scoring scenario: the server 101 stores relevant data of users to be diversity scored and deploys a trained model. The diversity score of the user can be predicted on the server 101 based on the relevant data of the user and the trained model.

[0051] Optionally, the device involved in the application scenario also includes a terminal 102, and the server 101 and the terminal 102 can communicate through a network. In this case, the server 101 can be a product server of an application related to the media object, and the terminal 102 can be a client deployed with the application.

[0052] The user can open an application related to the media object on the terminal 102 and interact with the media object, for example, listening to a song on the application. With the user's authorization, the terminal 102 can record the user's interaction with the media object and send the recorded data to the server 101 for model training and / or analysis of the user's behavioral diversity.

[0053] Exemplary Methods

[0054] Combine the following Figure 1 For application scenarios, refer to Figure 2 -Figure 7 is used to describe the model training method and diversity score determination method provided according to the exemplary embodiment of the present disclosure. It should be noted that the above application scenarios are only shown to facilitate understanding of the spirit and principles of the present disclosure, and the embodiments of the present disclosure are not limited in this regard. On the contrary, the embodiments of the present disclosure can be applied to any applicable scenario.

[0055] It should be noted that the embodiments of the present disclosure may be applied to electronic devices, and the electronic devices may be terminals or servers, that is, the model training method and / or diversity score determination method provided by the exemplary embodiments of the present disclosure may be executed on the terminals or servers.

[0056] Among them, the terminal can be a personal digital assistant (PDA) device, a handheld device with wireless communication function (such as a smart phone, a tablet computer), a computing device (such as a personal computer (PC)), a vehicle-mounted device, a wearable device (such as a smart watch, a smart bracelet), a smart home device (such as a smart display device), etc.

[0057] Wherein, the server can be an integral server or a distributed server across multiple computers or computer data centers. The server can also be of various categories, such as but not limited to, a network server, an application server, or a database server, or a proxy server.

[0058] Optionally, the server may include hardware, software, or an embedded logic component or a combination of two or more such components for performing appropriate functions supported or implemented by the server. For example, the server may be a blade server, a cloud server, etc., or may be a server group consisting of multiple servers, including one or more of the above-mentioned categories of servers, etc.

[0059] It should be noted that the model training method provided according to the exemplary embodiment of the present disclosure and the model training method and diversity score determination method provided according to the exemplary embodiment of the present disclosure can be executed on the same device or on different devices.

[0060] Optionally, in an embodiment of the present disclosure, the media object is audio and / or video.

[0061] refer to Figure 2 , Figure 2 The flowchart of the model training method provided according to an embodiment of the present disclosure is schematically shown. Figure 2 As shown, the model training method includes:

[0062] S201. Determine training data, where the training data includes a plurality of user feature vectors and diversity score labels corresponding to the user feature vectors. The user feature vectors are obtained based on interaction data between a user and a media object in a plurality of feature dimensions.

[0063] In the training data, one user feature vector corresponds to one user, and the diversity score label corresponding to the user feature vector is the diversity score label of the user, and the diversity score label of the user is the real, actual or ideal diversity score of the user. Taking a music-related application as an example, the user may be a user in the music community constructed by the application.

[0064] Among them, the interaction data between users and media objects in multiple feature dimensions may include the features of the media objects that users interacted with in the past time in multiple feature dimensions. For example, the interaction data between users and music in multiple feature dimensions such as multiple languages ​​and styles include that the style of the music played, collected, and commented on by users is rock and the language is Chinese. Therefore, the interaction data between users and media objects in multiple feature dimensions can reflect the diversity of the media objects that users interact with in multiple feature dimensions, so the user feature vector obtained based on the interaction data can reflect the diversity of user behavior.

[0065] With user authorization, the interaction data between the user and the media object under multiple feature dimensions can be obtained from the user's historical behavior data. The user's historical behavior data may include the description text of the media object interacted by the user and / or the user's log file. The user's historical behavior data may record the interaction between the user and the media object, the values ​​of the media object under multiple feature dimensions, and the user ID and / or the ID of the media object interacted by the user.

[0066] Optionally, the multiple feature dimensions include at least two of the following: language, style, release time, author, collection of works, and creation equipment involved.

[0067] Optionally, when the media object is music, the multiple feature dimensions may include at least two of the following: language, style, release year, author, album, and accompaniment instrument.

[0068] Therefore, as an example, the following interaction data can be extracted from the user's music access log: the style of the music played, collected, and commented on by the user; the release year of the music played, collected, and commented on by the user; the author of the music played, collected, and commented on by the user; the album of the music played, collected, and commented on by the user; and the accompaniment instruments of the music played, collected, and commented on by the user.

[0069] In this embodiment, pre-made training data may be obtained. Alternatively, interaction data between a user and a media object in multiple feature dimensions may be obtained, and a user feature vector may be obtained based on the interaction data, and then training data may be obtained based on the user feature vector and the user's diversity score label.

[0070] S202: Train the target model according to the training data to obtain a trained target model, where the target model is used to predict the diversity score of the user.

[0071] The diversity score of a user reflects the degree of diversity of the user's behavior. For example, the greater the diversity score of a user, the higher the degree of diversity of the user's behavior.

[0072] In this embodiment, in the training data, the user feature vector is used as the input data of the target model, and the diversity score label corresponding to the user feature vector is used as the label data of the target model. The target model is supervised trained so that the diversity score predicted by the target model is close to the diversity score label corresponding to the user feature vector, thereby improving the accuracy of the diversity score prediction of the target model.

[0073] In the disclosed embodiment, a user feature vector is obtained based on interaction data between the user and the media object in multiple feature dimensions, a target model is trained based on training data of the user feature vector and diversity score labels corresponding to the user feature vector, and a quantitative analysis of the user's behavioral diversity is achieved based on the trained target model, thereby ensuring the accuracy of the user's diversity analysis.

[0074] refer to Figure 3 , Figure 3 The flowchart of the model training method provided according to another embodiment of the present disclosure is schematically shown. Figure 3 As shown, the model training method includes:

[0075] S301. Using a feature engineering method, feature processing is performed on the interaction data between the user and the media object in multiple feature dimensions to obtain a feature vector in each feature dimension.

[0076] Among them, one user may correspond to multiple feature vectors. The multiple feature vectors of the user include the feature vector of the user in each feature dimension. The feature vector of the user in each feature dimension is the distribution feature of the media object interacted by the user in each feature dimension, which is used to reflect the distribution of the media object interacted by the user in each feature dimension.

[0077] Optionally, when multiple feature dimensions include at least two of language, style, publication time, author, collection of works, and creative devices involved, the feature vector includes at least two of the following: feature vectors of the media objects with which the user interacts under at least two of the feature dimensions of language, style, publication time, author, collection of works, and creative devices involved.

[0078] In this embodiment, the interactive data between users and media objects in multiple feature dimensions may have the problem of inconsistent data forms, which may not meet the input requirements of the target model. For example, the interactive data includes the style of music A1 played by the user in the past time as rock and in Chinese, and the style of music A2 played by the user as light music in Chinese. Rock, light music, and Chinese cannot be directly input into the target model. Therefore, feature engineering methods can be used to perform feature processing on the interactive data between users and media objects in multiple feature dimensions to obtain feature vectors corresponding to the user in each feature dimension.

[0079] Optionally, there may be multiple feature vectors corresponding to a feature dimension of a user.

[0080] Optionally, for each feature dimension, multiple feature vectors of the user in the feature dimension can be obtained based on the interaction data between the user and the media object in the feature dimension in multiple time periods, wherein the interaction data in each time period in the feature dimension is used to obtain a feature vector.

[0081] Optionally, a possible implementation of S301 includes: according to the preset correspondence between multiple feature dimensions and feature engineering methods, for each feature dimension, using the feature engineering method corresponding to the feature dimension, performing feature processing on the interaction data between the user and the media object under the feature dimension, and obtaining the feature vector of the user under the feature dimension. Thus, by setting the correspondence between the feature dimension and the feature engineering method, a suitable feature engineering method is provided for the interaction data between the user and the media object under each feature dimension in a targeted manner, thereby improving the feature processing effect.

[0082] Optionally, the feature engineering method may include at least one of the following: a feature engineering method for performing feature processing on continuous data, and a feature engineering method for performing feature processing on discrete data. Thus, in the process of performing feature processing on interactive data, full consideration is given to the possibility that the interactive data may contain continuous data and / or discrete data, and a special feature engineering method is provided for continuous data and discrete data in a targeted manner to improve the feature processing effect.

[0083] Optionally, the preset correspondence between multiple feature dimensions and feature engineering methods may include at least one of the following: a correspondence between a feature dimension and a feature engineering method for feature processing continuous data, and a correspondence between a feature dimension and a feature engineering method for feature processing discrete data. For the sake of concise description, the feature dimension corresponding to the feature engineering method for feature processing continuous data will be referred to as the first feature dimension, and the feature dimension corresponding to the feature engineering method for feature processing discrete data will be referred to as the second feature dimension. Among them, the first feature dimension and the second feature dimension are different feature dimensions. Thus, by presetting the feature engineering method corresponding to the feature dimension, a suitable feature engineering method is provided for the interactive data under the feature dimension in a targeted manner, thereby improving the feature processing effect.

[0084] Based on this optional method, a possible implementation method of S301 includes: obtaining a numerical vector of the user in the first feature dimension based on the interaction data between the user and the media object in the first feature dimension; using a feature engineering method for performing feature processing on continuous data to perform feature processing on the numerical vector of the user in the first feature dimension to obtain a feature vector of the user in the first feature dimension; and / or using a feature engineering method for performing feature processing on discrete data to perform feature processing on the interaction data between the user and the media object in the second feature dimension to obtain a feature vector of the user in the second feature dimension.

[0085] In this implementation, the vector dimension of the numerical vector under the first feature dimension is the number of features under the first feature dimension, wherein, in the numerical vector, each vector dimension corresponds one-to-one to each feature under the first feature dimension, such as the first vector dimension of the numerical vector corresponds to the first feature under the first feature dimension. In the numerical vector, the element at the vector dimension represents the number of interactions between the user and the media object under the feature corresponding to the vector dimension. Therefore, based on the interaction data between the user and the media object under the first feature dimension, the number of interactions between the user and the media object under each feature under the first feature dimension can be obtained, and based on the number of interactions, the numerical vector of the user under the first feature dimension can be determined.

[0086] As an example, the first feature dimension is language, and there are 11 languages ​​for music, including Chinese and English (that is, the number of features under the feature dimension of language is 11). Therefore, it can be determined that the vector dimension of the numerical vector corresponding to the first feature dimension is 11. In the numerical vector, multiple languages ​​such as Chinese and English correspond to a vector dimension respectively. The elements at the vector dimension corresponding to Chinese represent the number of times the user plays, collects, and comments on music in Chinese, and the elements at the vector dimension corresponding to English represent the number of times the user plays, collects, and comments on music in English. Therefore, the number of interactions between users and music in multiple languages ​​such as Chinese and English can be statistically obtained from the interaction data between users and music under the feature dimension of language, and the numerical vector of the user under language can be obtained based on the number of interactions and the vector dimension.

[0087] After obtaining the numerical vector, a feature engineering method for performing feature processing on continuous data is used to perform feature processing on the numerical vector, such as standardization, normalization, and digitization.

[0088] Optionally, among multiple feature dimensions, if the interaction data under the feature dimension is continuous data, then the feature dimension can be determined as the first feature dimension, for example, the number of interactions between a user and music in a certain language is continuous data; if the interaction data under the feature dimension is discrete data, then the feature dimension can be determined as the second feature dimension, such as the author of the music the user has listened to.

[0089] Optionally, when multiple feature dimensions include language, style, release time, author, collection of works, and creative equipment involved, the first feature dimension includes language, style, and release time, and the second feature dimension includes author, collection of works, and creative equipment involved.

[0090] Optionally, the feature engineering method for feature processing of continuous data may include a logistic regression (softmax) method, and / or the feature engineering method for feature processing of discrete data may include one-hot encoding and / or multi-hot encoding, so as to utilize the softmax method, one-hot encoding and / or multi-hot encoding to improve the feature processing effect. Among them, the softmax method is a method for standardizing numerical vectors, which can convert an original vector composed of arbitrary numerical values ​​into a new vector with the same dimension and elements between 0 and 1, and the elements in the new vector represent the probability distribution of each dimension in the original vector. Both one-hot encoding and multi-hot encoding can convert discrete data into corresponding numerical vectors.

[0091] Optionally, when the feature engineering method for feature processing of continuous data includes a softmax method, the softmax method can be used to process the numerical vector of the user in the first feature dimension to obtain the feature vector of the user in the first feature dimension.

[0092] Optionally, the formula for feature processing using the softmax method can be expressed as:

[0093]

[0094] Among them, z represents the numerical vector of the user in the first feature dimension, z j is the jth element of z, that is, the number of interactions between the user and the media object whose feature in the first feature dimension is the jth feature in the first feature dimension, and K1 represents the vector dimension of Z and the number of features in the first feature dimension. Finally, the processing result of each dimension σ(z) j The combination obtains the user's feature vector σ in the first feature dimension.

[0095] Taking the first feature dimension as language as an example, assuming there are 11 languages, such as Chinese, English, etc., then K1 is 11. Assuming z j For Chinese, z j Indicates the number of times the user interacted with the music in Chinese.

[0096] Optionally, when the feature engineering method for feature processing of discrete data includes one-hot encoding, one-hot encoding can be used to perform feature processing on the interaction data between the user and the media object in the second feature dimension to obtain a feature vector of the user in the second feature dimension.

[0097] In this optional method, the representation vector corresponding to each feature in the second feature dimension can be determined, wherein the vector dimension of the representation vector is the number of features in the second feature dimension, and each vector dimension of the representation vector corresponds one-to-one to each feature in the second feature dimension. In the representation vector corresponding to the feature, the element at the vector dimension corresponding to the feature is 1, and the elements at other vector dimensions are 0. In the interaction data between the user and the media object in the second feature dimension, if the user has interacted with the media object under the feature, it is determined that the feature vector of the user in the second feature dimension includes the representation vector corresponding to the feature.

[0098] Optionally, the formula for feature processing using one-hot encoding can be expressed as:

[0099]

[0100] Among them, f j represents the representation vector corresponding to the jth feature in the second feature dimension, K2 is the dimension of the representation vector and the number of features in the second feature dimension, in f j When k=j, v k =1, and the other elements are 0. If the media object with which the user interacts includes the feature in the second feature dimension as the jth feature in the second feature dimension, then the feature vector of the user in the second feature dimension includes f j .

[0101] Taking the feature dimension of author as an example, if there are 20,000 authors in total, the representation vector corresponding to each author in the second feature dimension is a 20,000-dimensional one-hot vector. If the user has listened to music by K3 authors, the user's feature vector in the second feature dimension includes the representation vectors corresponding to the K3 authors respectively, and the feature vector is a matrix of size K3×20,000.

[0102] Optionally, when the feature engineering method for feature processing of discrete data includes multi-hot encoding, multi-hot encoding can be used to perform feature processing on the interaction data between the user and the media object in the second feature dimension to obtain a feature vector of the user in the second feature dimension.

[0103] In this optional method, multi-hot encoding is a method of dimensionality reduction based on one-hot encoding. In the process of multi-hot encoding, one-hot encoding can be used to obtain the feature vector of the user in the second feature dimension. At this time, the feature vector of the user in the second feature dimension includes the representation vectors corresponding to multiple features in the second feature dimension. These representation vectors are summed up row by row and bit by bit to obtain a merged vector, and the feature vector of the user in the second feature dimension is determined to be the merged vector.

[0104] Optionally, the formula for feature processing using multi-hot encoding can be expressed as:

[0105] Among them, K4 is the number of features of the media objects that user u has interacted with in the second feature dimension (such as the number of styles of all the music listened to by user u), represents the representation vector of the i-th feature among the K4 features (features of the media objects that user u has interacted with in the second feature dimension) (the representation vector is obtained by one-hot encoding, which can be referred to above and will not be repeated here). F u Represents the feature vector of user u in the second feature dimension after multi-hot encoding.

[0106] As an example, taking the media object as music and the interaction between the user and the media object as listening to music, the feature processing using the feature engineering method can refer to Table 1:

[0107]

[0108]

[0109] For example, you can refer to the table above to set the correspondence between multiple feature dimensions and feature engineering methods.

[0110] Optionally, before performing feature processing on the interaction data between the user and the media object in multiple feature dimensions, data cleaning may be performed on the interaction data to remove abnormal data in the interaction data.

[0111] In this optional method, the statistical data corresponding to the user can be determined based on the interaction data between the user and the media object in multiple feature dimensions, and the interaction data between the user and the media object in multiple feature dimensions can be cleaned based on the statistical data corresponding to the user. In the data cleaning process, for each user, if the statistical data corresponding to the user meets the preset deletion conditions, the interaction data between the user and the media object in multiple feature dimensions can be deleted from all interaction data.

[0112] In this optional method, the statistical data may include at least one of the following: the number of media objects played by the user within a preset time period, the duration of the media objects played by the user within the preset time period, and the number of interactive behaviors of the user within the preset time period. Among them, the number of media objects played by the user within the preset time period refers to the total number of media objects played by the user within the preset time period, the duration of the media objects played by the user within the preset time period refers to the total duration of the media objects played by the user within the preset time period, and the number of interactive behaviors of the user within the preset time period refers to the total number of times the user interacts with the media objects within the preset time period. The user identifier can be used as an index to obtain statistical data from the interactive data.

[0113] In this optional method, the preset conditions may include at least one of the following: the number of media objects played by the user in the preset time period is greater than the number threshold; the duration of the media objects played by the user in the preset time period is greater than the first duration threshold; the duration of the media objects played by the user in the preset time period is greater than the second duration threshold and the number of interactive behaviors of the user in the preset time period is less than the number threshold. If the statistical data corresponding to the user meets any of the above preset conditions, it means that the confidence of the interactive data between the user and the media object in multiple feature dimensions is not high, which will affect the accuracy of the diversity analysis.

[0114] S302: Obtain a user feature vector according to the feature vector.

[0115] In this embodiment, after obtaining the feature vectors of the user in multiple feature dimensions, the feature vectors of the user in multiple feature dimensions may be combined to determine the corresponding user feature vector, thereby obtaining multiple user feature vectors. For example, vector operations, such as vector addition and multiplication, may be performed on the feature vectors of the user in multiple feature dimensions to obtain the user feature vector. For another example, the feature vectors of the user in each feature dimension may be concatenated to obtain the user feature vector.

[0116] S303: Determine training data according to the user feature vector and the diversity score label corresponding to the user.

[0117] In this embodiment, for each user, the diversity score label corresponding to the user is obtained, and the diversity score label corresponding to the user feature vector corresponding to the user is determined as the diversity score label corresponding to the user, and the data labeling of the user feature vector is completed. Based on multiple user feature vectors and the diversity score labels corresponding to the user feature vectors, training data is obtained. For example, the user feature vector x u The corresponding diversity score label is y u , so the final training data can be expressed as (X, Y) = {[x u ,y u]}, u=1~U, U represents the total number of users, that is, the total number of samples.

[0118] The diversity scoring labels corresponding to the users may be collected in advance, for example, by manual scoring to obtain the diversity scoring labels corresponding to the users.

[0119] As an example, taking the diversity score label as the listening diversity score, industry experts can manually give the corresponding listening diversity score to the user to be evaluated, and the listening diversity score range is [0, 100]. First, the interaction data of 2000 users can be randomly selected from the interaction data after data cleaning, that is, 2000 samples. These 2000 samples are randomly distributed to 100 music experts, each of whom is distributed 100 samples, and each expert gives a listening diversity score to these 100 samples. Assuming that each of these 2000 samples will receive 5 expert scores, in order to remove the error when the experts score, for each sample, after removing the highest score and the lowest score from all the expert scores, 3 expert scores can be retained, and the average of the 3 expert scores is determined as the listening diversity score of the user. Finally, the listening diversity scores of the 2000 samples can form a label vector Y.

[0120] S304: Train the target model according to the training data to obtain a trained target model.

[0121] The implementation principle and technical effects of S304 may refer to the aforementioned embodiments and will not be described in detail.

[0122] In the embodiment of the present disclosure, a feature engineering method is used to perform feature processing on the interaction data between users and media objects in multiple feature dimensions to obtain a feature vector, and a user feature vector is obtained based on the feature vector. Training data is obtained based on the user feature vector and the diversity score label corresponding to the user feature vector, so that the training data can be better processed by the target model, thereby improving the accuracy and efficiency of the target model for diversity analysis.

[0123] refer to Figure 4 , Figure 4 The flowchart of a training process of a target model provided according to an embodiment of the present disclosure is schematically shown. Figure 4 As shown in Figure 1, a training process of the target model includes:

[0124] S401: Input the user feature vector in the training data into the target model to obtain the diversity prediction score corresponding to the user feature vector.

[0125] In this embodiment, in each training, a preset number of user feature vectors and diversity score labels corresponding to the preset number of user feature vectors may be selected from the training data to complete a training of the target model based on the preset number of user feature vectors and the diversity score labels corresponding to the preset number of user feature vectors. The preset number is greater than or equal to 1.

[0126] In this embodiment, in one training, the user feature vector selected from the training data is input into the target model to obtain the output data of the target model. The output data of the target model may be the diversity prediction score corresponding to the user feature vector; or the output data of the target model may be a floating point value between 0 and 1, and the floating point value is multiplied by a fixed value to obtain the diversity prediction score corresponding to the user feature vector. For example, if the diversity prediction score is a ten-point system, the fixed value may be 10, and if the diversity prediction score is a hundred-point system, the fixed value may be 100.

[0127] Optionally, in the training data, a user feature vector includes feature vectors under various feature dimensions, and inputting the user feature vector into the target model is equivalent to inputting the feature vectors under various feature dimensions contained in the user feature vector into the target model to obtain a diversity prediction score corresponding to the user feature vector.

[0128] S402: Adjust the model parameters of the target model according to the diversity prediction score corresponding to the user feature vector, the diversity score label corresponding to the user feature vector, and the loss function.

[0129] In this embodiment, in one training, the function value of the loss function can be determined according to the difference between the diversity prediction score corresponding to the user feature vector and the diversity score label corresponding to the user feature vector. According to the function value of the loss function, the model parameters of the target model are adjusted.

[0130] In an optional model structure, the target model is a neural network model, and its model structure can adopt MLP.

[0131] refer to Figure 5 , Figure 5 The structure diagram of the target model provided according to an embodiment of the present disclosure is schematically shown as follows: Figure 5 As shown in , the target model is an MLP with one hidden layer. Figure 5In the target model, the target model includes an input layer, a hidden layer, and an output layer, wherein the input layer includes n nodes, the hidden layer includes m nodes, and the output layer includes 1 node. Each node represents a neuron, which represents the number of features. Therefore, the number of nodes n in the input layer is equal to the vector dimension of the user feature vector. In the target model, the output of each node in the hidden layer can be transformed by an activation function and then input to the output layer for processing. Finally, the nodes in the output layer can output a floating point value between 0 and 1.

[0132] Optional, based on Figure 5 The model structure shown, the target model can be expressed as:

[0133] H=σ(XW 1 +b 1 ), O=σ(HW 2 +b 2 )

[0134] Wherein, X represents the user feature vector input to the target model (i.e., x in the above embodiment u ), H represents the data obtained by processing the output data of the hidden layer using the activation function σ, O represents the output data of the target model (that is, the data obtained by processing the output data of the output layer using the activation function σ), W 1 , W 2 represents the weight parameter in the model parameters of the target model, b 1 、b 2 Represents the bias parameter in the model parameters of the target model.

[0135] Furthermore, in the target model, the activation function adopts a nonlinear activation function.

[0136] Furthermore, the nonlinear activation function is a sigmoid activation function. The function value of the sigmoid activation function ranges from 0 to 1, and its formula can be expressed as:

[0137]

[0138] Among them, x represents the input data of the activation function, such as XW in the above formula 1 b 1 , HW 2 +b 2 .

[0139] Another optional model structure, the target model is an artificial neural network (ANN), the target model includes an embedding layer, a feature cross layer and a multi-layer perceptron layer (hereinafter referred to as MLP layer), at this time, a possible implementation of S401 includes: in the embedding layer, embedding the feature vectors under each feature dimension to obtain the embedding vectors under each feature dimension; in the feature cross layer, using the attention mechanism to combine and cross-process the embedding vectors under each feature dimension to obtain a mixed vector; inputting the mixed vector into the MLP layer to obtain the diversity prediction score corresponding to the user feature vector. Therefore, the association between feature vectors under different feature dimensions can be learned in the target model, improving the feature learning ability of the target model, and then improving the accuracy of the target model in predicting the diversity score.

[0140] Among them, this optional model structure can be regarded as a refinement of the previous optional model structure: the embedding layer is equivalent to the structural refinement of the input layer, the feature cross layer is equivalent to the structural refinement of the hidden layer, and the MLP layer is equivalent to the structural refinement of the output layer. Through these structural refinements, the feature extraction effect of the target model is improved, thereby improving the accuracy of diversity score prediction.

[0141] The specific process in this optional manner may refer to the process of processing the user feature vector of the target user by using the target model in the diversity score determination method provided in the subsequent embodiments, and will not be described in detail again.

[0142] It should be noted that the target model in the model training method may be the same as or different from the target model in the diversity score determination method. In addition, the target model may also adopt other neural network model structures, which are not described one by one here.

[0143] Optionally, the optimization algorithm of the target model may adopt a back propagation (BP) algorithm, that is, the BP algorithm is used to adjust the model parameters to improve the model training effect.

[0144] In one possible implementation, Figure 4 As shown, S402 includes:

[0145] S4021. Determine a derivative of the loss function on the model parameters according to the diversity prediction score corresponding to the user feature vector, the diversity prediction score label corresponding to the user feature vector, and the loss function.

[0146] In this implementation, the difference between the diversity prediction score corresponding to the user feature vector and the diversity score label corresponding to the user feature vector is determined, and the function value of the loss function is determined based on the difference. The derivative of the function value of the loss function on the model parameters is then determined.

[0147] Alternatively, the loss function can be expressed as:

[0148]

[0149] Among them, L is the function value of the loss function, y represents the diversity score label corresponding to the user feature vector, and the diversity score label is converted into a floating point value between 0 and 1 through the activation function. Then, the difference between the converted diversity score label and the output data o (i.e., the diversity prediction score) of the target model is determined in the loss function, and finally L is calculated based on the difference.

[0150] Optionally, when determining the derivative of the loss function on the model parameters, the derivative of the loss function on the output data of multiple network layers of the target model can be calculated first, where the multiple network layers include hidden layers and output layers; based on the derivative of the loss function on the output data of multiple network layers of the target model, the derivative of the loss function on the model parameters of the target model is determined.

[0151] Further, based on Figure 5 The model structure shown in the figure, the above derivative calculation process can be expressed as:

[0152] (1) Calculate the derivative of the loss function on the output data z2 of the output layer:

[0153]

[0154] Among them, δ2 is the derivative of the loss function on the output data z2 of the output layer.

[0155] (2) Calculate the derivative of the loss function on the output data z1 of the hidden layer:

[0156]

[0157] Where T represents transposition and δ1 is the derivative of the loss function on the output data z1 of the hidden layer.

[0158] (3) According to the derivative of the loss function on z1 and z2, calculate the derivative of the loss function on the model parameters of each layer of the target model:

[0159]

[0160]

[0161]

[0162]

[0163] in, They represent the derivatives of the loss function on the weight parameter W2, bias parameter b2, weight parameter W1, and bias parameter b1 respectively.

[0164] S4022. Adjust the model parameters according to the derivative of the loss function on the model parameters.

[0165] In this embodiment, for each model parameter, the model parameter is updated based on the derivative of the loss function on the model parameter, for example, the derivative is added to or subtracted from the model parameter to obtain the updated model parameter. Finally, the model parameter after one training is obtained.

[0166] Optionally, multiple user feature vectors can be used in one training, that is, multiple samples are used, and each user feature vector is input into the target model for processing. After the loss function and the above derivation, the derivative of the loss function on each model parameter can be obtained under each user feature vector, that is, the derivative corresponding to each user feature vector. Therefore, in the process of adjusting the model parameters, for each model parameter, the model parameter can be adjusted based on the mean of the sum of all derivatives of the loss function under the model parameter in one training.

[0167] Optionally, the adjustment formula of the model parameters can be expressed as:

[0168]

[0169]

[0170]

[0171]

[0172] Where S represents the total number of user feature vectors in one training, and η is a preset parameter.

[0173] Optionally, the target model is trained multiple times until the training of the target model meets at least one of the following conditions: the number of training times is greater than a times threshold, and the function value of the loss function is less than a loss threshold.

[0174] In the disclosed embodiment, a target model is trained based on user feature vectors, diversity score labels corresponding to the user feature vectors, and a loss function to improve the training effect of the target model, thereby improving the accuracy of diversity analysis of the target model.

[0175] Subsequently, multiple embodiments of applying the target model to diversity scoring are provided.

[0176] refer to Figure 6 , Figure 6 The flowchart of the diversity score determination method provided in accordance with an embodiment of the present disclosure is schematically shown. Figure 6 As shown, the diversity score determination method includes:

[0177] S601: Determine a user feature vector of a target user, wherein the user feature vector is obtained based on interaction data between the target user and a media object in multiple feature dimensions.

[0178] The interaction data between the target user and the media object in multiple feature dimensions may include the features of the media object interacted by the target user in the past in multiple feature dimensions, for example, the interaction data between the target user and music in multiple feature dimensions such as multiple languages ​​and styles.

[0179] Among them, the characteristic dimensions can refer to the description of the above-mentioned embodiment and will not be repeated here.

[0180] With the authorization of the target user, the interaction data between the target user and the media object under multiple feature dimensions can be obtained from the historical behavior data of the target user. The historical behavior data of the target user may include the description text of the media object interacted by the target user and / or the log file of the target user. The historical behavior data of the target user may record the interaction between the target user and the media object, the values ​​of the media object under multiple feature dimensions, and the target user ID and / or the ID of the media object interacted by the target user.

[0181] In this embodiment, the user feature vector of the target user may be obtained from a database; or, the interaction data between the user and the media object in multiple feature dimensions may be obtained from the database, and the user feature vector of the target user may be obtained based on the interaction data.

[0182] Optionally, the user feature vector of the target user is determined every preset time period, so that the behavior diversity of the target user is analyzed periodically to improve the accuracy of the behavior diversity analysis.

[0183] Optionally, when a request for analyzing the behavior diversity of a target user is received, a user feature vector of the target user is determined, thereby satisfying the user's need for analyzing the behavior diversity and providing the user with a better service experience.

[0184] S602: Process the user feature vector of the target user through the target model to obtain a diversity prediction score corresponding to the target user.

[0185] The target model is obtained by training according to the model training method provided in any of the above embodiments, and the details can be referred to in the above embodiments, which will not be described in detail here. In addition, other model training methods can also be used to train the target model.

[0186] In this embodiment, the user feature vector of the target user can be input into the target model, and the target model analyzes the behavior diversity of the target user based on the user feature vector of the target user to obtain the behavior diversity score of the target user predicted by the target model. This is an indirect description, and herein, the behavior diversity score predicted by the target model is referred to as the behavior diversity prediction score.

[0187] The diversity score of the target user reflects the degree of behavioral diversity of the target user. For example, the greater the diversity score of the target user, the higher the degree of behavioral diversity of the target user.

[0188] S603: Display the diversity prediction score to the target user.

[0189] In this embodiment, the diversity prediction score can be displayed to the target user by pushing a reminder message to the target user, for example, sending the target user a reminder message such as "User XXX, after evaluation and analysis, your music diversity score is..."; and / or, the diversity prediction score can be displayed to the target user by displaying the target user's diversity prediction score on a display screen.

[0190] In this embodiment, if the current device is a server, the server may send the diversity prediction score of the target user to the terminal of the target user for display; if the current device is a terminal, the terminal may display the diversity score on its own display screen.

[0191] Optionally, in response to a target user's request to access the user center page, the diversity prediction score is displayed to the target user on the user center page, thereby facilitating the user to view his or her diversity prediction score in the personal center, improving the convenience of viewing the diversity prediction score, and providing a better experience for the user.

[0192] Optionally, the diversity prediction score is displayed to the target user by one or more combinations of preset patterns, texts, and audios, for example, displaying a music diversity badge to the user.

[0193] Optionally, based on the correspondence between the diversity score and the diversity level, the diversity level corresponding to the diversity prediction score of the target user may be determined, and the diversity level may be displayed to the target user. For example, the target user may be displayed that the target user has achieved a certain achievement related to diversity.

[0194] Optionally, the diversity prediction score can also be used to recommend data resources related to the media object to the target user. For example, when the media object is music, more music resources can be recommended to the target user based on the diversity prediction score of the target user. For example, when the diversity prediction score of the target user is high, more newly released music can be recommended to the target user.

[0195] In the disclosed embodiment, based on the user feature vector of the target user and the pre-trained target model, the target user's behavior diversity is analyzed to obtain the target user's diversity prediction score, and the diversity prediction score is displayed to the target user. Thus, a quantitative analysis of the diversity of the user's interaction with the media object is achieved, and the accuracy of the behavior diversity analysis is improved. Through the user's diversity prediction score, the user can more clearly understand the diversity of his or her interaction with the media object.

[0196] refer to Figure 7a , Figure 7a The flowchart of the diversity score determination method provided in accordance with another embodiment of the present disclosure is schematically shown. Figure 7a As shown, the diversity score determination method includes:

[0197] S701. Using a feature engineering method, feature processing is performed on the interaction data between the target user and the media object in multiple feature dimensions to obtain a feature vector in each feature dimension.

[0198] In this embodiment, the feature vectors in each feature dimension are the feature vectors of the target user in each feature dimension.

[0199] Optionally, when multiple feature dimensions include at least two of language, style, publication time, author, collection of works, and creation devices involved, the feature vector includes at least two of the following: feature vectors of the media objects with which the target user interacts in at least two of the feature dimensions of language, style, publication time, author, collection of works, and creation devices involved.

[0200] In this embodiment, a feature engineering method may be used to perform feature processing on the interaction data between the target user and the media object in multiple feature dimensions to obtain a feature vector corresponding to the target user in each feature dimension.

[0201] Optionally, there may be multiple feature vectors corresponding to a target user in one feature dimension.

[0202] Optionally, for each feature dimension, multiple feature vectors of the target user in the feature dimension can be obtained based on the interaction data between the target user and the media object in the feature dimension in multiple time periods, wherein the interaction data in each time period in the feature dimension is used to obtain a feature vector.

[0203] Optionally, a possible implementation of S701 includes: according to the preset correspondence between multiple feature dimensions and feature engineering methods, for each feature dimension, using the feature engineering method corresponding to the feature dimension, performing feature processing on the interaction data between the target user and the media object under the feature dimension, and obtaining the feature vector of the target user under the feature dimension. Thus, by setting the correspondence between the feature dimension and the feature engineering method, a suitable feature engineering method is provided for the interaction data between the target user and the media object under each feature dimension in a targeted manner, thereby improving the feature processing effect.

[0204] Optionally, the feature engineering method includes at least one of the following: a feature engineering method for feature processing of continuous data, and a feature engineering method for feature processing of discrete data. Therefore, in the process of feature processing of interactive data, full consideration is given to the possibility that the interactive data may contain continuous data and / or discrete data, and a special feature engineering method is provided for continuous data and discrete data in a targeted manner to improve the feature processing effect.

[0205] Optionally, the preset correspondence between the multiple feature dimensions and the feature engineering method may include at least one of the following: a correspondence between the first feature dimension and the feature engineering method for feature processing of numerical data, and a correspondence between the second feature dimension and the feature engineering method for feature processing of discrete non-numerical data. The first feature dimension and the second feature dimension may refer to the description of the aforementioned embodiment.

[0206] Based on this optional method, another possible implementation method of S701 includes: obtaining a numerical vector of the target user in the first feature dimension based on the interaction data between the target user and the media object in the first feature dimension; using a feature engineering method for performing feature processing on continuous data to perform feature processing on the numerical vector of the target user in the first feature dimension to obtain a feature vector of the target user in the first feature dimension; and / or using a feature engineering method for performing feature processing on discrete data to perform feature processing on the interaction data between the target user and the media object in the second feature dimension to obtain a feature vector of the target user in the second feature dimension.

[0207] Among them, this implementation method can refer to the process provided by the aforementioned embodiment to process the interaction data between the user and the media object in the first feature dimension and the interaction data between the user and the media object in the second feature dimension during the training process to obtain the corresponding feature vector, which will not be repeated here.

[0208] Optionally, the feature engineering method for feature processing of continuous data may include a logistic regression (softmax) method, and / or the feature engineering method for feature processing of discrete data may include one-hot encoding and / or multi-hot encoding to improve the feature processing effect. The specific processing process may refer to the operation of using the softmax method, one-hot encoding and / or multi-hot encoding to process the interaction data between users and media objects in multiple feature dimensions during the training process provided in the aforementioned embodiment, which will not be repeated here.

[0209] Optionally, before performing feature processing on the interaction data between the target user and the media object in multiple feature dimensions, data cleaning may be performed on the interaction data between the target user and the media object in multiple feature dimensions to eliminate abnormal data in the interaction data.

[0210] In this optional method, the statistical data corresponding to the target user can be determined based on the interaction data between the target user and the media object in multiple feature dimensions, and the interaction data between the target user and the media object in multiple feature dimensions can be cleaned based on the statistical data corresponding to the target user. During the data cleaning process, if the statistical data corresponding to the target user meets the preset deletion conditions, the interaction data between the target user and the media object in multiple feature dimensions can be deleted from all interaction data, and then the interaction data between the target user and the media object in multiple feature dimensions can be recollected.

[0211] In this optional manner, the statistical data may include at least one of the following: the number of media objects played by the target user within a preset time period, the duration of the media objects played by the target user within the preset time period, and the number of interactive behaviors of the target user within the preset time period. Among them, the number of media objects played by the target user within the preset time period refers to the total number of media objects played by the target user within the preset time period, the duration of the media objects played by the target user within the preset time period refers to the total duration of the media objects played by the target user within the preset time period, and the number of interactive behaviors of the target user within the preset time period refers to the total number of times the target user interacts with the media objects within the preset time period.

[0212] In this optional method, the preset conditions may include at least one of the following: the number of media objects played by the target user in the preset time period is greater than the number threshold; the duration of the media objects played by the target user in the preset time period is greater than the first duration threshold; the duration of the media objects played by the target user in the preset time period is greater than the second duration threshold and the number of user interaction behaviors in the preset time period is less than the number threshold. If the statistical data corresponding to the target user meets any of the above preset conditions, it means that the confidence of the interaction data between the target user and the media object in multiple feature dimensions is not high, which will affect the accuracy of the diversity analysis, so the interaction data needs to be deleted.

[0213] S702: Obtain a user feature vector of the target user according to the feature vector.

[0214] In this embodiment, after the feature vectors of the target user in multiple feature dimensions are obtained, the feature vectors of the target user in multiple feature dimensions may be combined to determine the user feature vector of the target user. For example, vector operations such as vector addition and multiplication may be performed on the feature vectors of the target user in multiple feature dimensions to obtain the user feature vector of the target user. Another example is to concatenate the feature vectors of the target user in each feature dimension to obtain the user feature vector of the target user.

[0215] S703: Process the user feature vector of the target user through the target model to obtain a diversity prediction score corresponding to the target user.

[0216] In this embodiment, the user feature vector of the target user is input into the target model to obtain the output data of the target model. The output data of the target model can be the diversity prediction score of the target user; or the output data of the target model can also be a floating point value between 0 and 1, and the floating point value is multiplied by a fixed value to obtain the diversity prediction score of the target user.

[0217] Optionally, the user feature vector of the target user includes the feature vector of the target user in each feature dimension. At this time, the feature vector in each feature dimension is input into the target model to obtain the diversity prediction score corresponding to the target user.

[0218] In an optional model structure, the target model is a neural network model, and its model structure can adopt MLP. For details, please refer to Figure 5 The model training method provided in the above-mentioned embodiment will not be described in detail here.

[0219] In another optional model structure, the target model is ANN, such as Figure 7bAs shown in the figure, the target model includes an embedding layer, a feature cross layer and an MLP layer, which are connected in sequence. Thus, on the one hand, the quality of the data input to the feature cross layer is improved through the embedding layer; on the other hand, the interaction data between users and media objects in different feature dimensions are fully considered to be inextricably linked to each other. For example, users who usually listen to a high degree of diversity in music will try to listen to music of different styles, languages ​​and eras. The feature cross layer focuses on the relationship between feature vectors in different feature dimensions and their influence on each other, so as to improve the accuracy of diversity prediction scores.

[0220] Among them, this optional model structure can be regarded as a refinement of the previous optional model structure (i.e., MLP): the embedding layer is equivalent to the refined structure of the input layer, the feature cross layer is equivalent to the refined structure of the hidden layer, and the MLP layer is equivalent to the refined structure of the output layer. Through these structural refinements, the feature extraction effect of the target model is improved, thereby improving the accuracy of the diversity score prediction of the target model.

[0221] At this time, a possible implementation manner of S703 includes:

[0222] S7031. In the embedding layer, embedding processing is performed on the feature vectors in each feature dimension to obtain the embedding vectors in each feature dimension.

[0223] In this implementation, the feature vectors under each feature dimension can be input into the embedding layer, and the feature vectors under each feature dimension are embedded (i.e., embedded coding) in the embedding layer to obtain the embedded vectors under each feature dimension, so as to improve the data quality through embedding processing and further improve the subsequent feature extraction effect.

[0224] Among them, one feature dimension can correspond to one or more embedding vectors.

[0225] Optionally, in this implementation, for each feature dimension, a matrix transformation is performed on the feature vector under the feature dimension through a parameter vector corresponding to the feature dimension to obtain an embedding vector under the feature dimension. The dimensions of the embedding vectors under different feature dimensions are the same. Therefore, considering that the dimensions of the feature vectors under different feature dimensions may be different, the dimensions are unified by means of matrix transformation to improve the subsequent feature extraction effect.

[0226] The parameter vector can be a floating point matrix.

[0227] In this optional method, further, considering that the feature vectors under the same feature dimension have the same or similar semantics, for example, the feature vectors under the language dimension all reflect the language of the media object with which the user interacts, and the feature vectors under the same feature dimension have the same dimension, so different feature dimensions correspond to different parameter vectors, and the same feature dimension corresponds to the same parameter vector. On the one hand, the number of parameters can be reduced, and on the other hand, the semantic features can be better learned from the feature vectors accurately, thereby improving the generalization ability of the target model.

[0228] Furthermore, the formula for embedding processing can be expressed as: i =x i W i Among them, x i represents the i-th eigenvector, W i represents the parameter vector corresponding to the i-th eigenvector, f i Represents the embedding vector obtained based on the i-th feature vector.

[0229] like Figure 7b As shown in Table 1, there are 2 feature vectors under each of the 6 feature dimensions: language, style, author, song year, album, and accompaniment instrument. There are 12 feature vectors in total. These 12 feature vectors are input into the embedding layer. Assume that x i The dimension is M, W i If it is a matrix with M rows and 128 columns, then after the embedding layer processing, the 12 embedded vectors obtained are all 128-dimensional. Assume that the feature vector under the language is 11-dimensional and the feature vector under the song age is 51-dimensional. After the above embedding processing, they are all converted into 128-dimensional embedding vectors.

[0230] S7032. In the feature cross layer, the attention mechanism is used to combine and cross-process the embedded vectors under each feature dimension to obtain a mixed vector.

[0231] In this implementation, the embedding vectors under each feature dimension are input into the feature cross layer, and different embedding vectors are cross-combined in the feature cross layer. The features and weights of the cross-combined embedding vectors are learned using the attention mechanism, and each embedding vector is adjusted by the learned features and weights to achieve the mixing of multiple embedding vectors, and obtain the mixed vector output by the feature-poor layer. Among them, the weight and feature learning process of adjusting each embedding vector by the learned features and weights is the attention mechanism (for example, the query vector V, key vector K and value vector Q of each embedding vector are learned by cross-combination, and then the embedding vector is weighted by these vectors), which is not limited here.

[0232] Optionally, the feature cross-layer includes multiple attention heads, that is, the attention mechanism adopted by the feature embedding layer is a multi-head attention mechanism, wherein each attention head includes a first residual block and a second residual block. Figure 7b As shown (where Figure 7b , taking 1 attention head as an example), the first residual block includes a multi-head attention network and a normalization layer, and the second residual block includes a forward network and a normalization network. Based on this, S7032 includes: for each attention head, feature processing is performed on the embedded vector under each feature dimension through the multi-head attention network and the normalization network in the first residual block to obtain the output vector of the first residual block; for each attention head, feature processing is performed on the output vector of the first residual block through the forward network and the normalization network in the second residual block to obtain the output vector of the second residual block; according to the output vector of the second residual block in each attention head, a mixed vector is obtained.

[0233] In this optional method, in the first residual block, the embedding vectors under each feature dimension (for example, 12 embedding vectors) can be input into the multi-head attention network of the first residual block, and the multi-head attention mechanism is used in the multi-head attention network to learn the features and weights of the cross-combination of the embedding vectors under each feature dimension to obtain the output vector of the multi-head attention network, wherein one embedding vector can correspond to one output vector of the multi-head attention network. Then, the output vector of the multi-head attention network and the embedding vector under each feature dimension are fused, and the fused vector is input into the normalization network in the first residual block for normalization to obtain the output vector of the first residual block.

[0234] Among them, in the process of fusing the output vector of the multi-head attention network and the embedding vector under each feature dimension, since the output vector of the multi-head attention network has the same dimension as the embedding vector under each feature dimension, for example, the 12 output vectors of the multi-head attention network can form a 12*128-dimensional matrix, and there are 12 embedding vectors under each feature dimension of the 6 feature dimensions, and the 12 embedding vectors can form a 12*128-dimensional matrix, so the output vector of the multi-head attention network and the embedding vector under each feature dimension can be bit-wise added or averaged in the matrix to improve the fusion processing effect.

[0235] In this optional manner, in the second residual block, the output vector of the first residual block can be input into the forward network to obtain the output vector of the forward network, the output vector of the forward network is fused with the output vector of the first residual block, and the fused vector is input into the normalization network in the second residual block for normalization to obtain the output vector of the second residual block. The forward network is a feedforward neural network (Feedforward).

[0236] Among them, the dimension of the output vector of the forward network is the same as the dimension of the output vector of the first residual block. The output vector of the forward network and the output vector of the first residual block can be fused by performing bit-wise addition or averaging of the output vector of the forward network and the output vector of the first residual block in a matrix.

[0237] In this optional method, after obtaining the output vector of the second residual block in each attention head, the output vector of the second residual block in each attention head can be fused to obtain a mixed vector. Thus, the feature vectors of different feature dimensions are cross-mixed based on multiple attention heads, and the outputs of multiple attention heads are combined to obtain the final mixed vector, which effectively improves the feature extraction capability of the target model, thereby improving the accuracy of diversity prediction.

[0238] Furthermore, since the dimensions of the output vectors of the second residual block in each attention head are consistent, the output vectors of the second residual block in each attention head can be bitwise summed or bitwise averaged to obtain a mixed vector. For example, there are 8 attention heads in total, and 8 output vectors from the second residual block are obtained. The dimension of the output vector is a 12*128-dimensional matrix. These 8 matrices are bitwise summed or bitwise averaged to finally obtain a 12*128-dimensional matrix.

[0239] S7033. Input the mixed vector into the MLP layer to obtain the diversity prediction score corresponding to the target user.

[0240] Among them, the MLP layer is used to perform diversity scoring based on the feature cross layer.

[0241] In this implementation, the mixed vector is input into the MLP layer, and the features of the mixed vector are processed by multiple network layers in the MLP to obtain the diversity prediction score corresponding to the target user.

[0242] Optional, such as Figure 7b As shown, MLP includes at least one fully connected layer and an output layer. Based on this, after the mixed vector is input into the MLP layer, the mixed vector can be reshaped, that is, the dimension of the mixed vector is changed. The reshaped mixed vector is input into the fully connected layer to obtain the output data of the neuron node in the last fully connected layer, and the output data is input into the output layer. In the output layer, the output data can be processed by a nonlinear activation function to obtain a floating point number between 0 and 1. The floating point number is the output data of the target model. Based on the floating point data, the diversity prediction score of the target user can be finally obtained.

[0243] Among them, the nonlinear activation function in the output layer can be a sigmoid function.

[0244] It should be noted that, in this embodiment, the connection relationship between the network layers can be a direct connection or an indirect connection, for example, the embedding layer is directly connected to the feature cross layer, or other network layers are connected between the embedding layer and the feature cross layer.

[0245] S704: Display the diversity prediction score to the target user.

[0246] The implementation principle and technical effects of S704 may refer to the aforementioned embodiments and will not be described in detail.

[0247] In the disclosed embodiment, a feature engineering method is used to process the interaction data between the target user and the media object in multiple feature dimensions, and the feature vector of the target user in each feature dimension is obtained. Based on the feature vector of the target user in each feature dimension, the user feature vector of the target user is obtained, and finally, based on the user feature vector and the target model, the diversity prediction score of the target user is obtained through analysis. Thus, the processing effect of the interaction data between the target user and the media object is improved, and the accuracy of the diversity prediction score obtained based on the target model analysis is further improved.

[0248] Exemplary Media

[0249] After introducing the method of the exemplary embodiment of the present disclosure, next, refer to Figure 8 A storage medium according to an exemplary embodiment of the present disclosure is described.

[0250] refer to Figure 8 As shown, a program product 80 for implementing the above method according to an embodiment of the present disclosure is described, which can adopt a portable compact disk read-only memory (CD-ROM) and include program code, and can be run on a terminal device, such as a personal computer. However, the program product of the present disclosure is not limited thereto. When the processor executes the program product of the present disclosure, the model training method provided in any of the aforementioned embodiments and / or the diversity score determination method provided in any of the aforementioned embodiments are implemented.

[0251] The program product may use any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, 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 disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.

[0252] The readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, wherein the readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. The readable signal medium may also be any readable medium other than a readable storage medium.

[0253] Program code for performing the operations of the present disclosure may be written in any combination of one or more programming languages, including object-oriented programming languages ​​such as Java, C++, etc., and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, partially on a remote computing device, or entirely on a remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN).

[0254] Exemplary Devices

[0255] After introducing the medium of the exemplary embodiment of the present disclosure, next, reference is made to Figure 9-10 The model training device and the diversity score determination device of the exemplary embodiment of the present disclosure are explained, wherein the model training device is used to implement the model training method provided by any of the above method embodiments, and the diversity score determination device is used to implement the diversity score determination method provided by any of the above method embodiments. The implementation principles and technical effects are similar and will not be repeated here.

[0256] refer to Fig. 9 , Fig. 9 This is a schematic diagram of the structure of a model training device provided by an embodiment of the present disclosure. Fig. 9 As shown, the model training device includes:

[0257] A determination unit 901 is used to determine training data, where the training data includes a plurality of user feature vectors and diversity score labels corresponding to the user feature vectors, where the user feature vectors are obtained based on interaction data between the user and the media object in a plurality of feature dimensions;

[0258] The training unit 902 is used to train the target model according to the training data to obtain a trained target model, and the target model is used to predict the diversity score of the user.

[0259] In one embodiment of the present disclosure, a user feature vector is obtained based on interaction data between a user and a media object in multiple feature dimensions, including: using a feature engineering method to perform feature processing on the interaction data to obtain a feature vector in each feature dimension, wherein the feature engineering method includes at least one of the following: a feature engineering method for performing feature processing on continuous data, a feature engineering method for performing feature processing on discrete data; and obtaining a user feature vector based on the feature vector in each feature dimension.

[0260] In another embodiment of the present disclosure, a feature engineering method is used to perform feature processing on the interaction data to obtain feature vectors under each feature dimension, including: according to a preset correspondence between multiple feature dimensions and the feature engineering method, for each feature dimension, a feature engineering method corresponding to the feature dimension is used to perform feature processing on the interaction data under the feature dimension to obtain a feature vector under the feature dimension.

[0261] In another embodiment of the present disclosure, feature engineering methods are used to perform feature processing on the interaction data to obtain feature vectors under various feature dimensions, and the method further includes: determining statistical data corresponding to the user based on the interaction data, the statistical data including at least one of the following: the number of media objects played by the user within a preset time period, the duration of the media objects played by the user within the preset time period, and the number of interactive behaviors of the user within the preset time period; and performing data cleaning on the interaction data based on the statistical data.

[0262] In another embodiment of the present disclosure, the user feature vector includes feature vectors under various feature dimensions, and the training process of the target model includes: inputting the feature vectors under various feature dimensions into the target model to obtain a diversity prediction score corresponding to the user feature vector; and adjusting the model parameters of the target model according to the diversity prediction score, the diversity score label and the loss function.

[0263] In another embodiment of the present disclosure, the target model includes an embedding layer, a feature cross layer and a multi-layer perceptron, and the feature vectors under each feature dimension are input into the target model to obtain a diversity prediction score corresponding to the user feature vector, including: in the embedding layer, embedding the feature vectors under each feature dimension to obtain the embedding vectors under each feature dimension; in the feature cross layer, using an attention mechanism to combine and cross-process the embedding vectors under each feature dimension to obtain a mixed vector; and inputting the mixed vector into the multi-layer perceptron layer to obtain a diversity prediction score corresponding to the user feature vector.

[0264] In another embodiment of the present disclosure, model parameters of a target model are adjusted according to diversity prediction scores, diversity score labels, and a loss function, including: determining derivatives of the loss function on model parameters of each layer of the target model according to the diversity prediction scores, diversity prediction score labels, and the loss function; and adjusting the model parameters according to the derivatives.

[0265] refer to Fig.10 , Fig.10 This is a schematic diagram of the structure of a diversity score determination device provided by an embodiment of the present disclosure. Fig.10 As shown, the diversity score determination device includes:

[0266] A determination unit 1001 is used to determine a user feature vector of a target user, wherein the user feature vector is obtained based on interaction data between the target user and a media object in multiple feature dimensions;

[0267] The processing unit 1002 is used to process the user feature vector through the target model to obtain a diversity prediction score corresponding to the target user;

[0268] Display unit 1003, used to display the diversity prediction score to the target user

[0269] In one embodiment of the present disclosure, a user feature vector is obtained based on interaction data between a target user and a media object in multiple feature dimensions, including: using a feature engineering method to perform feature processing on the interaction data to obtain a feature vector in each feature dimension, wherein the feature engineering method includes at least one of the following: a feature engineering method for performing feature processing on continuous data, a feature engineering method for performing feature processing on discrete data; and obtaining a user feature vector based on the feature vector in each feature dimension.

[0270] In another embodiment of the present disclosure, a feature engineering method is used to perform feature processing on the interaction data to obtain feature vectors under each feature dimension, including: according to a preset correspondence between multiple feature dimensions and the feature engineering method, for each feature dimension, a feature engineering method corresponding to the feature dimension is used to perform feature processing on the interaction data under the feature dimension to obtain a feature vector under the feature dimension.

[0271] In another embodiment of the present disclosure, feature engineering methods are used to perform feature processing on the interaction data to obtain feature vectors under various feature dimensions, and the method further includes: determining statistical data corresponding to the target user based on the interaction data, the statistical data including at least one of the following: the number of media objects played by the target user within a preset time period, the duration of the media objects played by the target user within the preset time period, and the number of interactive behaviors of the target user within the preset time period; and performing data cleaning on the interaction data based on the statistical data.

[0272] In another embodiment of the present disclosure, the user feature vector includes feature vectors under each feature dimension, the target model includes an embedding layer, a feature cross layer and a multi-layer perceptron, and the processing unit is specifically used to: in the embedding layer, embedding the feature vectors under each feature dimension to obtain the embedding vectors under each feature dimension; in the feature cross layer, using an attention mechanism to combine and cross-process the embedding vectors under each feature dimension to obtain a mixed vector; and input the mixed vector into the multi-layer perceptron layer to obtain a diversity prediction score corresponding to the target user.

[0273] In another embodiment of the present disclosure, the processing unit is specifically used to: for each feature dimension, perform a matrix transformation on the feature vector under the feature dimension through a parameter vector corresponding to the feature dimension to obtain an embedding vector under the feature dimension; wherein different feature dimensions correspond to different parameter vectors, and the dimensions of the embedding vectors under different feature dimensions are the same.

[0274] In another embodiment of the present disclosure, the feature cross layer includes multiple attention heads, each attention head includes a first residual block and a second residual block, the first residual block includes a multi-head self-attention network and a normalization network, the second residual block includes a forward network and a normalization network, and the processing unit is specifically used to: for each attention head, perform feature processing on the embedded vector under each feature dimension through the multi-head attention network and the normalization network in the first residual block to obtain the output vector of the first residual block; for each attention head, perform feature processing on the output vector of the first residual block through the forward network and the normalization network in the second residual block to obtain the output vector of the second residual block; according to the output vector of the second residual block in each attention head, obtain a mixed vector.

[0275] In another embodiment of the present disclosure, the processing unit is specifically used to: in the first residual block, input the embedding vector under each feature dimension into the multi-head attention network to obtain the output vector of the multi-head attention network; fuse the output vector of the multi-head attention network and the embedding vector under each feature dimension, and input the fused vector into the normalization network in the first residual block to obtain the output vector of the first residual block.

[0276] In another embodiment of the present disclosure, the processing unit is specifically used to: in the second residual block, input the output vector of the first residual block into the forward network to obtain the output vector of the forward network; fuse the output vector of the forward network with the output vector of the first residual block, and input the fused vector into the normalization network in the second residual block to obtain the output vector of the second residual block.

[0277] In another embodiment of the present disclosure, the processing unit is specifically used to: perform bit-wise matrix summation or bit-wise averaging on the output vectors of the second residual blocks in each attention head to obtain a mixed vector.

[0278] Exemplary Computing Devices

[0279] After introducing the method, medium and apparatus of the exemplary embodiments of the present disclosure, next, reference is made to Fig.11 A computing device according to an exemplary embodiment of the present disclosure is described.

[0280] Fig.11 The computing device 110 shown is only an example and should not bring any limitation to the functionality and scope of use of the embodiments of the present disclosure.

[0281] like Fig.11 As shown, the computing device 110 is in the form of a general computing device. The components of the computing device 110 may include, but are not limited to: the at least one processing unit 1101 mentioned above, the at least one storage unit 1102 mentioned above, and a bus 1103 connecting different system components (including the processing unit 1101 and the storage unit 1102). Among them, at least one storage unit 1102 stores computer-executable instructions, and at least one processor 1101 executes the computer-executable instructions stored in at least one memory 11102, so that at least one processor 1101 executes the model training method provided in any of the aforementioned embodiments, and / or, so that at least one processor 1101 executes the diversity score determination method provided in any of the aforementioned embodiments.

[0282] The bus 1103 includes a data bus, a control bus, and an address bus.

[0283] The storage unit 1102 may include a readable medium in the form of a volatile memory, such as a random access memory (RAM) 11021 and / or a cache memory 11022 , and may further include a readable medium in the form of a non-volatile memory, such as a read-only memory (ROM) 11023 .

[0284] The storage unit 1102 may also include a program / utility 11025 having a set (at least one) of program modules 11024, such program modules 11024 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.

[0285] The computing device 110 may also communicate with one or more external devices 1104 (e.g., keyboards, pointing devices, etc.). Such communication may be performed via an input / output (I / O) interface 1105. In addition, the computing device 110 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) via a network adapter 1106. Fig.11 As shown, the network adapter 406 communicates with other modules of the computing device 110 via the bus 1103. It should be understood that, although not shown in the figure, other hardware and / or software modules can be used in conjunction with the computing device 110, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.

[0286] It should be noted that although several units / modules or sub-units / modules of the model training device and the diversity score determination device are mentioned in the above detailed description, this division is merely exemplary and not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of two or more units / modules described above can be embodied in one unit / module. Conversely, the features and functions of one unit / module described above can be further divided to be embodied by multiple units / modules.

[0287] In addition, although the operations of the disclosed method are described in a specific order in the drawings, this does not require or imply that the operations must be performed in this specific order, or that all the operations shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps.

[0288] Although the spirit and principle of the present disclosure have been described with reference to several specific embodiments, it should be understood that the present disclosure is not limited to the disclosed specific embodiments, and the division of various aspects does not mean that the features in these aspects cannot be combined to benefit, and such division is only for the convenience of expression. The present disclosure is intended to cover various modifications and equivalent arrangements included in the spirit and scope of the attached claims.

Claims

1. A model training method, comprising: Determine training data, the training data including a plurality of user feature vectors and diversity score labels corresponding to the user feature vectors, the user feature vectors being obtained based on interaction data between the user and the media object in a plurality of feature dimensions; According to the training data, a target model is trained to obtain a trained target model, wherein the target model is used to predict a diversity score of a user; wherein the diversity score of a user represents a degree of diversity of the user's behavior; The method further comprises: Determine statistical data corresponding to the user according to the interaction data, the statistical data including at least one of the following: the number of media objects played by the user in a preset time period, the duration of the media objects played by the user in the preset time period, and the number of interactive behaviors of the user in the preset time period; According to the statistical data, delete the interaction data that meets the preset deletion conditions in the statistical data; the preset deletion conditions include at least one of the following: the number of media objects played by the user in the preset time period is greater than the number threshold; the duration of the media objects played by the user in the preset time period is greater than the first duration threshold; the duration of the media objects played by the user in the preset time period is greater than the second duration threshold and the number of interaction behaviors of the user in the preset time period is less than the number threshold.

2. According to the model training method of claim 1, the user feature vector is obtained based on the interaction data between the user and the media object in multiple feature dimensions, including: Using a feature engineering method, feature processing is performed on the interaction data to obtain feature vectors under various feature dimensions, wherein the feature engineering method includes at least one of the following: a feature engineering method for feature processing of continuous data and a feature engineering method for feature processing of discrete data; The user feature vector is obtained according to the feature vectors under the respective feature dimensions.

3. According to the model training method of claim 2, the method of using a feature engineering method to perform feature processing on the interaction data to obtain feature vectors under each feature dimension includes: According to the preset correspondence between the multiple feature dimensions and the feature engineering method, for each feature dimension, the feature engineering method corresponding to the feature dimension is adopted to perform feature processing on the interaction data under the feature dimension to obtain the feature vector under the feature dimension.

4. According to the model training method of claim 2 or 3, the user feature vector includes the feature vectors under each feature dimension, and the training process of the target model includes: Inputting the feature vectors under each feature dimension into the target model to obtain the diversity prediction score corresponding to the user feature vector; The model parameters of the target model are adjusted according to the diversity prediction score, the diversity score label and the loss function.

5. The model training method according to claim 4, wherein the target model comprises an embedding layer, a feature cross layer and a multi-layer perceptron, and the step of inputting the feature vectors under each feature dimension into the target model to obtain the diversity prediction score corresponding to the user feature vector comprises: In the embedding layer, embedding processing is performed on the feature vectors in each feature dimension to obtain the embedding vectors in each feature dimension; In the feature cross layer, an attention mechanism is used to perform combined cross processing on the embedding vectors under each feature dimension to obtain a mixed vector; The mixed vector is input into the multi-layer perceptron layer to obtain the diversity prediction score corresponding to the user feature vector.

6. The model training method according to claim 4, wherein adjusting the model parameters of the target model according to the diversity prediction score, the diversity score label and the loss function comprises: Determining, according to the diversity prediction score, the diversity prediction score label, and the loss function, a derivative of the loss function on the model parameters of each layer of the target model; Based on the derivatives, the model parameters are adjusted.

7. A method for determining a diversity score, comprising: Determining a user feature vector of a target user, wherein the user feature vector is obtained based on interaction data between the target user and a media object in multiple feature dimensions; The user feature vector is processed by a target model to obtain a diversity prediction score corresponding to the target user; wherein the user's diversity score represents the degree of user behavior diversity; Displaying the diversity prediction score to the target user; The method further comprises: Determine statistical data corresponding to the user according to the interaction data, the statistical data including at least one of the following: the number of media objects played by the user in a preset time period, the duration of the media objects played by the user in the preset time period, and the number of interactive behaviors of the user in the preset time period; According to the statistical data, delete the interaction data that meets the preset deletion conditions in the statistical data; the preset deletion conditions include at least one of the following: the number of media objects played by the user in the preset time period is greater than the number threshold; the duration of the media objects played by the user in the preset time period is greater than the first duration threshold; the duration of the media objects played by the user in the preset time period is greater than the second duration threshold and the number of interaction behaviors of the user in the preset time period is less than the number threshold.

8. The diversity score determination method according to claim 7, wherein the user feature vector is obtained based on interaction data between the target user and the media object in multiple feature dimensions, including: Using a feature engineering method, feature processing is performed on the interaction data to obtain feature vectors under various feature dimensions, wherein the feature engineering method includes at least one of the following: a feature engineering method for feature processing of continuous data and a feature engineering method for feature processing of discrete data; The user feature vector is obtained according to the feature vectors under the respective feature dimensions.

9. The diversity score determination method according to claim 8, wherein the feature engineering method is used to perform feature processing on the interaction data to obtain feature vectors under each feature dimension, including: According to the preset correspondence between the multiple feature dimensions and the feature engineering method, for each feature dimension, the feature engineering method corresponding to the feature dimension is adopted to perform feature processing on the interaction data under the feature dimension to obtain the feature vector under the feature dimension.

10. The diversity score determination method according to claim 8 or 9, wherein the user feature vector includes feature vectors under each feature dimension, the target model includes an embedding layer, a feature cross layer and a multi-layer perceptron, and the user feature vector is processed by the target model to obtain a diversity prediction score corresponding to the target user, comprising: In the embedding layer, embedding processing is performed on the feature vectors in each feature dimension to obtain the embedding vectors in each feature dimension; In the feature cross layer, an attention mechanism is used to perform combined cross processing on the embedding vectors under each feature dimension to obtain a mixed vector; The mixed vector is input into the multi-layer perceptron layer to obtain the diversity prediction score corresponding to the target user.

11. The diversity score determination method according to claim 10, wherein in the embedding layer, embedding the feature vectors in each feature dimension to obtain the embedding vectors in each feature dimension comprises: For each feature dimension, a matrix transformation is performed on the feature vector under the feature dimension by using a parameter vector corresponding to the feature dimension to obtain an embedding vector under the feature dimension; Among them, different feature dimensions correspond to different parameter vectors, and the dimensions of the embedding vectors under different feature dimensions are the same.

12. According to the diversity score determination method of claim 10, the feature cross layer includes multiple attention heads, each attention head includes a first residual block and a second residual block, the first residual block includes a multi-head self-attention network and a normalization network, and the second residual block includes a forward network and a normalization network. In the feature cross layer, the attention mechanism is used to combine and cross-process the embedded vectors under each feature dimension to obtain a mixed vector, including: For each attention head, feature processing is performed on the embedding vector under each feature dimension through the multi-head attention network and the normalization network in the first residual block to obtain an output vector of the first residual block; For each attention head, feature processing is performed on the output vector of the first residual block through the forward network and the normalization network in the second residual block to obtain the output vector of the second residual block; The mixed vector is obtained according to the output vector of the second residual block in each attention head.

13. The diversity score determination method according to claim 12, wherein for each attention head, the embedding vector under each feature dimension is subjected to feature processing by a multi-head attention network and a normalization network in the first residual block to obtain an output vector of the first residual block, comprising: In the first residual block, the embedding vectors under each feature dimension are input into the multi-head attention network to obtain the output vector of the multi-head attention network; The output vector of the multi-head attention network and the embedding vector under each feature dimension are fused, and the fused vector is input into the normalization network in the first residual block to obtain the output vector of the first residual block.

14. The diversity score determination method according to claim 12, wherein for each attention head, the output vector of the first residual block is subjected to feature processing by a forward network and a normalization network in the second residual block to obtain the output vector of the second residual block, comprising: In the second residual block, inputting the output vector of the first residual block into the forward network to obtain the output vector of the forward network; The output vector of the forward network is fused with the output vector of the first residual block, and the fused vector is input into the normalization network in the second residual block to obtain the output vector of the second residual block.

15. The method for determining a diversity score according to claim 12, wherein the step of obtaining the mixed vector according to the output vector of the second residual block in each attention head comprises: The output vectors of the second residual blocks in each of the attention heads are summed or averaged in a matrix to obtain the mixed vector.

16. A computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions. When a processor executes the computer-executable instructions, the model training method as described in any one of claims 1 to 6 is implemented, and / or the diversity score determination method as described in any one of claims 7 to 15 is implemented.

17. A model training device, comprising: A determination unit, configured to determine training data, wherein the training data includes a plurality of user feature vectors and diversity score labels corresponding to the user feature vectors, wherein the user feature vectors are obtained based on interaction data between the user and the media object in a plurality of feature dimensions; A training unit, used to train a target model according to the training data to obtain a trained target model, wherein the target model is used to predict a diversity score of a user; wherein the diversity score of a user represents a degree of diversity of the user's behavior; The determination unit is further configured to determine statistical data corresponding to the user based on the interaction data, wherein the statistical data includes at least one of the following: the number of media objects played by the user within a preset time period, the duration of the media objects played by the user within the preset time period, and the number of interactive behaviors of the user within the preset time period; According to the statistical data, delete the interaction data that meets the preset deletion conditions in the statistical data; the preset deletion conditions include at least one of the following: the number of media objects played by the user in the preset time period is greater than the number threshold; the duration of the media objects played by the user in the preset time period is greater than the first duration threshold; the duration of the media objects played by the user in the preset time period is greater than the second duration threshold and the number of interaction behaviors of the user in the preset time period is less than the number threshold.

18. The model training device according to claim 17, wherein the user feature vector is obtained based on interaction data between the user and the media object in multiple feature dimensions, including: Using a feature engineering method, feature processing is performed on the interaction data to obtain feature vectors under various feature dimensions, wherein the feature engineering method includes at least one of the following: a feature engineering method for feature processing of continuous data and a feature engineering method for feature processing of discrete data; The user feature vector is obtained according to the feature vectors under the respective feature dimensions.

19. The model training device according to claim 18, wherein the feature engineering method is used to perform feature processing on the interaction data to obtain feature vectors under each feature dimension, including: According to the preset correspondence between the multiple feature dimensions and the feature engineering method, for each feature dimension, the feature engineering method corresponding to the feature dimension is adopted to perform feature processing on the interaction data under the feature dimension to obtain the feature vector under the feature dimension.

20. According to the model training device of claim 18 or 19, the user feature vector includes feature vectors under each feature dimension, and the training process of the target model includes: Inputting the feature vectors under each feature dimension into the target model to obtain the diversity prediction score corresponding to the user feature vector; The model parameters of the target model are adjusted according to the diversity prediction score, the diversity score label and the loss function.

21. The model training device according to claim 20, wherein the target model comprises an embedding layer, a feature cross layer and a multi-layer perceptron, and the step of inputting the feature vectors under each feature dimension into the target model to obtain the diversity prediction score corresponding to the user feature vector comprises: In the embedding layer, embedding processing is performed on the feature vectors in each feature dimension to obtain the embedding vectors in each feature dimension; In the feature cross layer, an attention mechanism is used to perform combined cross processing on the embedding vectors under each feature dimension to obtain a mixed vector; The mixed vector is input into the multi-layer perceptron layer to obtain the diversity prediction score corresponding to the user feature vector.

22. The model training device according to claim 20, wherein adjusting the model parameters of the target model according to the diversity prediction score, the diversity score label and the loss function comprises: Determining, according to the diversity prediction score, the diversity prediction score label, and the loss function, a derivative of the loss function on the model parameters of each layer of the target model; Based on the derivatives, the model parameters are adjusted.

23. A diversity score determination device, comprising: A determination unit, configured to determine a user feature vector of a target user, wherein the user feature vector is obtained based on interaction data between the target user and a media object in multiple feature dimensions; A processing unit, configured to process the user feature vector through a target model to obtain a diversity prediction score corresponding to the target user; wherein the user's diversity score represents the degree of the user's behavior diversity; A display unit, used to display the diversity prediction score to the target user; The determination unit is further configured to determine statistical data corresponding to the user based on the interaction data, wherein the statistical data includes at least one of the following: the number of media objects played by the user within a preset time period, the duration of the media objects played by the user within the preset time period, and the number of interactive behaviors of the user within the preset time period; According to the statistical data, delete the interaction data that meets the preset deletion conditions in the statistical data; the preset deletion conditions include at least one of the following: the number of media objects played by the user in the preset time period is greater than the number threshold; the duration of the media objects played by the user in the preset time period is greater than the first duration threshold; the duration of the media objects played by the user in the preset time period is greater than the second duration threshold and the number of interaction behaviors of the user in the preset time period is less than the number threshold.

24. The diversity score determination device according to claim 23, wherein the user feature vector is obtained based on interaction data between the target user and the media object in multiple feature dimensions, including: Using a feature engineering method, feature processing is performed on the interaction data to obtain feature vectors under various feature dimensions, wherein the feature engineering method includes at least one of the following: a feature engineering method for feature processing of continuous data and a feature engineering method for feature processing of discrete data; The user feature vector is obtained according to the feature vectors under the respective feature dimensions.

25. The diversity score determination device according to claim 23, wherein the feature engineering method is used to perform feature processing on the interaction data to obtain feature vectors under each feature dimension, including: According to the preset correspondence between the multiple feature dimensions and the feature engineering method, for each feature dimension, the feature engineering method corresponding to the feature dimension is adopted to perform feature processing on the interaction data under the feature dimension to obtain the feature vector under the feature dimension.

26. The diversity score determination device according to claim 24 or 25, wherein the user feature vector comprises feature vectors under each feature dimension, the target model comprises an embedding layer, a feature cross layer and a multi-layer perceptron, and the processing unit is specifically configured to: In the embedding layer, embedding processing is performed on the feature vectors in each feature dimension to obtain the embedding vectors in each feature dimension; In the feature cross layer, an attention mechanism is used to perform combined cross processing on the embedding vectors under each feature dimension to obtain a mixed vector; The mixed vector is input into the multi-layer perceptron layer to obtain the diversity prediction score corresponding to the target user.

27. The diversity score determination device according to claim 26, wherein the processing unit is specifically configured to: For each feature dimension, a matrix transformation is performed on the feature vector under the feature dimension by using a parameter vector corresponding to the feature dimension to obtain an embedding vector under the feature dimension; in, Different feature dimensions correspond to different parameter vectors, and the dimensions of the embedding vectors under different feature dimensions are the same.

28. The diversity score determination device according to claim 26, wherein the feature cross layer comprises a plurality of attention heads, each of the attention heads comprises a first residual block and a second residual block, the first residual block comprises a multi-head self-attention network and a normalization network, the second residual block comprises a forward network and a normalization network, and the processing unit is specifically configured to: For each attention head, feature processing is performed on the embedding vector under each feature dimension through the multi-head attention network and the normalization network in the first residual block to obtain an output vector of the first residual block; For each attention head, feature processing is performed on the output vector of the first residual block through the forward network and the normalization network in the second residual block to obtain the output vector of the second residual block; The mixed vector is obtained according to the output vector of the second residual block in each attention head.

29. The diversity score determination device according to claim 28, wherein the processing unit is specifically configured to: In the first residual block, the embedding vectors under each feature dimension are input into the multi-head attention network to obtain the output vector of the multi-head attention network; The output vector of the multi-head attention network and the embedding vector under each feature dimension are fused, and the fused vector is input into the normalization network in the first residual block to obtain the output vector of the first residual block.

30. The diversity score determination device according to claim 28, wherein the processing unit is specifically configured to: In the second residual block, inputting the output vector of the first residual block into the forward network to obtain the output vector of the forward network; The output vector of the forward network is fused with the output vector of the first residual block, and the fused vector is input into the normalization network in the second residual block to obtain the output vector of the second residual block.

31. The diversity score determination device according to claim 28, wherein the processing unit is specifically configured to: The output vectors of the second residual blocks in each of the attention heads are summed or averaged in a matrix to obtain the mixed vector.

32. A computing device comprising: at least one processor and memory; The memory stores computer-executable instructions; The at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the model training method as described in any one of claims 1 to 6, and / or, so that the at least one processor executes the diversity score determination method as described in any one of claims 7-15.

Citation Information

Patent Citations

  • CliqueNet flight delay prediction method based on attention mechanism

    CN110956342A

  • Intelligent recommendation method for access control initialization

    CN112804080A

  • Method and system for obtaining social media user portrait

    CN113672818A

  • Recommendation method based on self-attention mechanism

    CN113822742A