CN117056585A - Recall method, training method, device and storage medium for content recommendation - Google Patents

Recall method, training method, device and storage medium for content recommendation Download PDF

Info

Publication number
CN117056585A
CN117056585A CN202210474522.XA CN202210474522A CN117056585A CN 117056585 A CN117056585 A CN 117056585A CN 202210474522 A CN202210474522 A CN 202210474522A CN 117056585 A CN117056585 A CN 117056585A
Authority
CN
China
Prior art keywords
content
feature
interest
features
training
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210474522.XA
Other languages
Chinese (zh)
Inventor
王琳
胥凯
叶璨
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Dajia Internet Information Technology Co Ltd
Original Assignee
Beijing Dajia Internet Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Dajia Internet Information Technology Co Ltd filed Critical Beijing Dajia Internet Information Technology Co Ltd
Priority to CN202210474522.XA priority Critical patent/CN117056585A/en
Publication of CN117056585A publication Critical patent/CN117056585A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9535Search customisation based on user profiles and personalisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/70Information retrieval; Database structures therefor; File system structures therefor of video data
    • G06F16/73Querying
    • G06F16/735Filtering based on additional data, e.g. user or group profiles
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/70Information retrieval; Database structures therefor; File system structures therefor of video data
    • G06F16/75Clustering; Classification
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • G06N3/084Backpropagation, e.g. using gradient descent

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Multimedia (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Evolutionary Computation (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The disclosure relates to a recall method, a training method, a device and a storage medium for content recommendation, and belongs to the technical field of Internet. The method comprises the following steps: acquiring content characteristics of historical interaction content of a target user account; clustering the content features to obtain K feature clusters, wherein K is used for representing the interest number of the target user account and is a positive integer greater than 2; generating K mutually independent interest features of the target user account based on the cluster center feature of each of the K feature clusters and the user attribute feature of the target user account; content recall for content recommendation is initiated for the target user account based on each of the K mutually independent interest-features. The method and the device generate a plurality of interest categories which are independent of each other, can improve the comprehensiveness of recall content, and are suitable for various content recommendation scenes. In addition, the value of K is determined based on the iterative process in the training process, so that the accuracy of the interest category is improved.

Description

Recall method, training method, device and storage medium for content recommendation
Technical Field
The disclosure relates to the technical field of internet, and in particular relates to a recall method, a training method, a device and a storage medium for content recommendation.
Background
Content recommendation systems typically include recall, coarse ranking, fine ranking, and reordering stages. The recall phase is used to introduce as much work of interest to the user to the recommendation system as possible under limited computing resources, typically determining the upper recommendation limit for the overall system. The coarse ranking stage utilizes a simple model to perform preliminary screening on recall content. The fine discharge stage performs fine scoring on the coarse discharged content and further filters. And the reordering stage reorders the content which is discharged and presents the content to the user.
In existing content recommendation systems (e.g., short video recommendation systems with a dual tower neural network architecture), the user interest features are not independent of each other (e.g., all user interest features are typically expressed using a common vector), and the recall content cannot cover all user interests.
Disclosure of Invention
The embodiment of the disclosure provides a recall method, a training method, a device and a storage medium for content recommendation, thereby improving the comprehensiveness of the content.
According to an aspect of an embodiment of the present disclosure, a recall method for content recommendation is provided. The method comprises the following steps:
Acquiring content characteristics of historical interaction content of a target user account;
clustering the content features to obtain K feature clusters, wherein K is used for representing the interest number of the target user account, and K is a positive integer greater than 2;
generating K mutually independent interest features of the target user account based on the cluster center features of each of the K feature clusters and the user attribute features of the target user account;
content recall for content recommendation is initiated for the target user account based on each of the K mutually independent interest-features.
In an exemplary embodiment, the obtaining the content features of the historical interaction content of the target user account includes: inputting the historical interaction content into a first neural network model; acquiring the content characteristics from the historical interaction content by using the first neural network model; generating K mutually independent interest features of the target user account based on the cluster center feature of each of the K feature clusters and the user attribute feature of the target user account, including: inputting a cluster center feature of each of the K feature clusters, and a user attribute feature of the target user account into a second neural network model; and combining the cluster center feature of each of the K feature clusters and the user attribute feature of the target user account into K mutually independent interest features of the target user account by using the second neural network model.
In an exemplary embodiment, the number of interests characterized by K is configured to: under the condition that the similarity between every two interest features is lower than a preset similarity threshold, the maximum interest number corresponding to the target user account is met; the recall method further comprises: performing an iterative process for determining K, the iterative process comprising: clustering the content features into T mutually independent interest features, wherein T is a preset initial value; determining the similarity between every two interesting features in the T interesting features which are independent of each other; increasing the T under the condition that the similarity between every two interesting features is not larger than a preset threshold value; and determining T after the iteration is finished as the K.
In an exemplary embodiment, the initiating a content recall for content recommendation for the target user account based on each of the K mutually independent interest-features comprises: determining the number of recall content corresponding to each interest feature based on the predetermined total number of recall content; determining the content matched with each interest feature for each interest feature, wherein the number of the content is equal to the number of recall content corresponding to the interest feature; and combining the content determined by each interest feature into the recall content for content recommendation.
In an exemplary embodiment, the determining the number of recall contents corresponding to each interest feature based on the predetermined total number of recall contents includes: based on the total number of the recall content, the number of the recall content is evenly distributed for each interest feature; or determining the number of the recall content corresponding to each interest feature based on the total number of the recall content and the preset weight of each interest feature.
In an exemplary embodiment, before the obtaining the content features of the historical interaction content of the target user account, the recall method further includes: acquiring a content browsing record of the target user account in a selected time period; and determining the browsed content in the content browsing record as the historical interaction content.
According to another aspect of the disclosed embodiments, a model training method is provided. The method comprises the following steps:
obtaining a training sample set, wherein each training sample in the training sample set comprises training content and marking content associated with the same user account and user attribute characteristics of the user account, and the marking content is marked with a marking state;
based on the training sample set, performing a training process of the neural network model, the training process comprising: for each of the training samples: acquiring first content features of the training content and second content features of the marking content by using the neural network model; clustering the first content features to obtain K feature clusters, wherein K is used for representing the interest number of the user account and is a positive integer greater than 2; and generating K mutually independent features of interest based on the cluster center feature of each of the K feature clusters and the user attribute feature; determining a loss function value of the neural network model based on a labeling state of each training sample, the interest feature and the second content feature obtained for each training sample; and configuring model parameters of the neural network model so that the loss function value is lower than a preset threshold.
In an exemplary embodiment, the number of interests characterized by K is configured to: under the condition that the similarity between every two interest features is lower than a preset similarity threshold, the maximum interest number corresponding to the user account is met;
the method further comprises performing an iterative process for determining K in the training process, the iterative process comprising: clustering the first content features into T mutually independent interest features, wherein T is a preset initial value; determining the similarity between every two interesting features in the T interesting features which are independent of each other; increasing the T under the condition that the similarity between every two interesting features is not larger than a preset threshold value; and determining T after the iteration is finished as the K.
In an exemplary embodiment, the determining the loss function value of the neural network model based on the labeling state of each of the training samples, the interest feature and the second content feature obtained for each of the training samples includes:
determining a single sample loss value for each of the training samples based on a marker state of each of the training samples, the interest feature obtained for each of the training samples, and the second content feature;
And determining an average value of the single-sample loss values of all training samples in the training sample set as the loss function value.
In an exemplary embodiment, the determining a single sample loss value for each of the training samples based on the marking status of each of the training samples, the interest feature obtained for each of the training samples, and the second content feature includes the steps of, for each of the training samples: selecting one of K independent interest features with the smallest distance from the second content feature; determining the single sample loss value based on the selected one of the features of interest and the marker state, wherein the marker state has a first state value in the case that the training sample is a positive sample and a second state value different from the first state value in the case that the training sample is a negative sample.
According to another aspect of the disclosed embodiments, a recall device for content recommendation is provided. The device comprises:
the acquisition module is configured to acquire content characteristics of historical interaction content of the target user account;
The clustering module is configured to perform clustering processing on the content features to obtain K feature clusters, wherein K is used for representing the interest number of the target user account and is a positive integer greater than 2;
a generation module configured to generate K mutually independent interest features of the target user account based on a cluster center feature of each of the K feature clusters and a user attribute feature of the target user account;
a recall module configured to initiate content recall for content recommendation for the target user account based on each of K of the interest-features independent of each other.
In an exemplary embodiment, the acquisition module is configured to: inputting the historical interaction content into a first neural network model, wherein the first neural network model comprises a first embedded layer; acquiring the content characteristics from the historical interaction content by utilizing the first embedded layer; the generation module is configured to: inputting a cluster center feature of each of the K feature clusters, and a user attribute feature of the target user account into a second neural network model, the second neural network model comprising a second embedded layer; and combining the cluster center feature of each of the K feature clusters and the user attribute feature of the target user account into K mutually independent interest features of the target user account by using the second embedding layer.
In an exemplary embodiment, the number of interests characterized by K is configured to: under the condition that the similarity between every two interest features is lower than a preset similarity threshold, the maximum interest number corresponding to the target user account is met; the clustering module is configured to perform an iterative process for determining K, the iterative process comprising: clustering the content features into T mutually independent interest features, wherein T is a preset initial value; determining the similarity between every two interesting features in the T interesting features which are independent of each other; increasing the T under the condition that the similarity between every two interesting features is not larger than a preset threshold value; and determining T after the iteration is finished as the K.
In an exemplary embodiment, the recall module is configured to: determining the number of recall content corresponding to each interest feature based on the predetermined total number of recall content; determining the content matched with each interest feature for each interest feature, wherein the number of the content is equal to the number of recall content corresponding to the interest feature; and combining the content determined by each interest feature into the recall content for content recommendation.
In an exemplary embodiment, the recall module is configured to: based on the total number of the recall content, the number of the recall content is evenly distributed for each interest feature; or determining the number of the recall content corresponding to each interest feature based on the total number of the recall content and the preset weight of each interest feature.
In an exemplary embodiment, the acquisition module is configured to: before acquiring content characteristics of historical interaction content of a target user account, acquiring a content browsing record of the target user account in a selected time period; and determining the browsed content in the content browsing record as the historical interaction content.
According to another aspect of the disclosed embodiments, a model training apparatus is provided. The model training apparatus includes:
an acquisition module configured to acquire a set of training samples, wherein each training sample in the set of training samples includes training content and marking content associated with a same user account, and user attribute characteristics of the user account, the marking content being marked with a marking status;
a training module configured to perform a training process of the neural network model based on the set of training samples, the training process comprising: for each of the training samples: acquiring first content features of the training content and second content features of the marking content by using the neural network model; clustering the first content features to obtain K feature clusters, wherein K is used for representing the interest number of the user account and is a positive integer greater than 2; and generating K mutually independent features of interest based on the cluster center feature of each of the K feature clusters and the user attribute feature; determining a loss function value of the neural network model based on a labeling state of each training sample, the interest feature and the second content feature obtained for each training sample; and configuring model parameters of the neural network model so that the loss function value is lower than a preset threshold.
In an exemplary embodiment, the number of interests characterized by K is configured to: under the condition that the similarity between every two interest features is lower than a preset similarity threshold, the maximum interest number corresponding to the user account is met; the training module is configured to perform an iterative process for determining K in the training process, the iterative process comprising: clustering the first content features into T mutually independent interest features, wherein T is a preset initial value; determining the similarity between every two interesting features in the T interesting features which are independent of each other; increasing the T under the condition that the similarity between every two interesting features is not larger than a preset threshold value; and determining T after the iteration is finished as the K.
In an exemplary embodiment, the training module is configured to: determining a single sample loss value for each of the training samples based on a marker state of each of the training samples, the interest feature obtained for each of the training samples, and the second content feature; and determining an average value of the single-sample loss values of all training samples in the training sample set as the loss function value.
In an exemplary embodiment, the training module is configured to: selecting one of K independent interest features with the smallest distance from the second content feature; determining the single sample loss value based on the selected one of the features of interest and the marker state, wherein the marker state has a first state value in the case that the training sample is a positive sample and a second state value different from the first state value in the case that the training sample is a negative sample.
According to another aspect of the disclosed embodiments, an electronic device is provided. The electronic device includes:
a processor;
a memory for storing the processor-executable instructions;
the processor is configured to read the executable instruction from the memory, and execute the executable instruction to implement the recall method or the model training method for content recommendation.
According to another aspect of the disclosed embodiments, there is provided a computer-readable storage medium having stored thereon computer instructions which, when executed by a processor, implement the recall method or model training method for content recommendation described above.
According to another aspect of the disclosed embodiments, there is provided a computer program product comprising a computer program which, when executed by a processor, implements the recall method or model training method for content recommendation described above.
The technical scheme provided by the embodiment of the disclosure at least can comprise the following beneficial effects: the method and the device generate a plurality of interest categories which are independent of each other, improve the coverage rate of the interest categories, improve the comprehensiveness of the determined content and are suitable for various content recommendation scenes. In addition, the method and the device determine the number of the clustering categories based on the training process of the neural network, and the number of the clustering categories is not statically designated any more, so that the accuracy of the interest categories is improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the disclosure and together with the description, serve to explain the principles of the disclosure and do not constitute an undue limitation on the disclosure.
FIG. 1 is an application environment diagram illustrating content recall according to an example embodiment;
FIG. 2 is a flowchart illustrating a recall method for content recommendation, according to an example embodiment;
FIG. 3 is a schematic diagram of a short video recall model shown in accordance with an exemplary embodiment;
FIG. 4 is a schematic diagram of a short video recall process shown in accordance with an exemplary embodiment;
FIG. 5 is a flowchart illustrating a model training method according to an exemplary embodiment;
FIG. 6 is a block diagram illustrating a recall device for content recommendation, according to an example embodiment;
FIG. 7 is a block diagram of a model training apparatus, according to an example embodiment;
FIG. 8 is a block diagram of an electronic device shown in accordance with an exemplary embodiment;
FIG. 9 is a block diagram illustrating a recall device or model training device for content recommendation, according to an example embodiment;
FIG. 10 is another block diagram illustrating a recall device or model training device for content recommendation, according to an example embodiment.
Detailed Description
In order to enable those skilled in the art to better understand the technical solutions of the present disclosure, the technical solutions of the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings.
It should be noted that the terms "first," "second," and the like in the description and claims of the present disclosure and in the foregoing figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the disclosure described herein may be capable of operation in sequences other than those illustrated or described herein. The implementations described in the following exemplary examples are not representative of all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with some aspects of the present disclosure as detailed in the accompanying claims.
The recall method for content recommendation provided by the present disclosure may be applied to an application environment as shown in fig. 1. Wherein at least one client 11 and a server 12 communicate via a network. The client 11 has at least one application (e.g., a short video program or a live program) for acquiring content running therein. The server 12 has the capability to recommend and provide content to the client 11. The client 11 may be, but is not limited to, various personal computers, notebook computers, smart phones, tablet computers, and the like. The server 12 may be implemented as a stand-alone server or as a server cluster formed by a plurality of servers.
FIG. 2 is a flowchart illustrating a recall method for content recommendation, according to an example embodiment. The method may be performed by the client 11 or the server 12 in the application environment shown in fig. 1.
As shown in fig. 2, the method includes:
step 101: content characteristics of historical interaction content of the target user account are obtained.
Here, a user account is a personal file and settings used to record a user's username and password, a group of membership, network resources that can be accessed, and a user. For example, the user account may be an account in a variety of internet applications such as short videos, instant messaging, social networking, and the like. The target user account is an account that needs to initiate a content recall.
The content may include text, images, audio, short or long video, and so forth. Historical interaction content for the target user account may be determined based on historical operational information for the target user account. For example, the historical operating information of the target user account may include content-related user behavior records, such as short video browsing history, short video collection records, image browsing history, image collection records, long video browsing history, long video collection records, and so forth.
In one exemplary embodiment, before acquiring the content characteristics of the historical interaction content of the target user account, the recall method further comprises: acquiring a content browsing record of a target user account in a selected time period; and determining browsed content in the content browsing record as historical interaction content. Thus, the present disclosure can control the diversity of content features in the time dimension by capturing historical interaction content over a selected period of time.
Preferably, after the historical interaction content of the target user account is acquired, the content characteristics of the historical interaction content can be characterized in a vector form. In one exemplary embodiment, the obtaining of the content characteristics of the historical interaction content of the target user account in step 101 includes: inputting the historical interaction content into a first neural network model; and acquiring content characteristics from the historical interaction content by using the first neural network model. In an exemplary embodiment, the first neural network model includes a first embedding (embedding) layer that may characterize the acquired content features as vector forms in an embedded vector manner. For example, determining a short video browsing history list within a predetermined time based on a short video browsing history of the target user account; the short video browsing history list is input into a first neural network comprising a first embedding layer to determine, by the first embedding layer, a feature vector of each short video in the short video browsing history list, i.e. a first vector adapted to characterize the features of each short video. In one exemplary embodiment, the first neural network may extract the underlying features (e.g., color features, gray features, texture features, etc.) of the short video and generate a first vector adapted to characterize the underlying features through the first embedding layer. In one exemplary embodiment, the first neural network may also extract high-level features (such as semantic features) of the short video and generate, through the first embedding layer, a first vector adapted to characterize the high-level features. Optionally, the first neural network may also extract high-level features (such as semantic features) and low-level features (such as color features, gray-scale features, texture features, etc.) of the short video, and generate, through the first embedding layer, a first vector adapted to characterize the high-level features and the low-level features.
The foregoing describes a manner of characterizing content features by way of example and is merely exemplary, and those skilled in the art will recognize that such description is not intended to limit the scope of embodiments of the present invention.
Step 102: and clustering the content features to obtain K feature clusters, wherein K is used for representing the interest number of the target user account, and K is a positive integer greater than 2.
Here, the content features may be clustered using a variety of clustering algorithms such as K-Means clustering algorithms, mean shift clustering algorithms, density-based clustering methods (DBSCAN), maximum Expectation (EM) clustering algorithms using Gaussian Mixture Models (GMM), hierarchical clustering, or graph group detection (Graph Community Detection), to obtain K feature clusters. Wherein the value of K may be pre-specified or automatically determined based on an algorithm.
When the clustering process is performed using the K-means algorithm, it is necessary to provide a clustering number K (i.e., the number of clustering centers) equivalent to the number of interest categories. If the clustering number K is too small, the comprehensiveness of the content is difficult to improve; if the number of clusters K is too large, the recalled videos overlap in large amounts, resulting in wasted resources. How the cluster number K is determined is particularly important.
In one exemplary embodiment, the number of clusters K in the K-Means clustering algorithm may be determined based on an iterative process. In the iterative process, a mode of gradually increasing the cluster number is adopted, each user starts with a plurality of (such as two) clusters, and then gradually increases the cluster number until the maximum similarity between interests reaches a preset threshold value. The iterative process may be performed during a model training process or a test process that includes the first neural network. Preferably, the iterative process is performed during the training process, thereby ensuring the real-time nature of the testing process. In order not to affect the model training efficiency, the process of increasing the number of clusters can be averaged over multiple training samples of the same user. In addition, model parameters in a first embedded layer of the first neural network are automatically updated through a gradient descent algorithm in the training process, so that first vectors participating in clustering are also automatically updated, and the clustering algorithm is more accurate.
In one exemplary embodiment, the number of interests characterized by K is configured to: and under the condition that the similarity between every two interest features is lower than a preset similarity threshold, the maximum interest number corresponding to the target user account is met. The recall method further comprises: performing an iterative process for determining K, the iterative process comprising: clustering the content features into T mutually independent interest features, wherein T is a preset initial value; determining the similarity between every two interesting features in the T interesting features which are independent of each other; increasing the T under the condition that the similarity between every two interesting features is not larger than a preset threshold value; and determining T after the iteration is finished as the K.
It is assumed that an iterative process is performed in the training process. For example, in the first iteration, the initial value of the number of clusters (i.e., the number of categories of the feature of interest) is set to 2, and the content feature vector extracted based on the training sample is referred to as a first training vector. Based on the first training vector, 2 categories may be clustered. Then, based on the center vector of each of the 2 categories and the user feature vector characterizing the user attribute feature (the user attribute feature is included in the training sample), an interest vector characterizing the corresponding interest category of the user account is generated, which is referred to as a second training vector, so that 2 second training vectors can be obtained.
Then, it is determined whether the similarity of the two second training vectors is greater than a predetermined threshold.
(1) And stopping iteration when the similarity of the two second training vectors is greater than a preset threshold value, and determining the value of K as the initial value (namely equal to 2) of the category parameter.
(2) When the similarity of the two second training vectors is not greater than (i.e., less than or equal to) the predetermined threshold value, then the initial value of the number of clusters is increased by a predetermined step (e.g., 2), such as to 4. Then, a second iteration is started. The second iteration specifically includes: the first training vectors are clustered into 4 categories. Then, 4 second training vectors are generated based on the center vector and the user feature vector of each of the 4 categories. Then, continuing to judge whether the two-by-two similarity between the 4 second training vectors is larger than a preset threshold value, stopping iteration if the two-by-two similarity is larger than the preset threshold value, and determining the latest value (namely 4) of the clustering number as the category number K in the clustering algorithm. If not, continuing to increase the initial value of the clustering number, and continuing the iterative process.
While the above exemplary description describes typical examples of determining K based on iterative operations, those skilled in the art will recognize that such descriptions are merely exemplary and are not intended to limit the scope of embodiments of the present invention.
Therefore, K is determined based on the iterative process, and K is not statically designated any more, so that the accuracy of the interest category is improved. In addition, K is determined based on an iteration process in the training process, so that the instantaneity of the testing process can be ensured.
Step 103: generating K mutually independent interest features of the target user account based on the cluster center features of each of the K feature clusters and the user attribute features of the target user account.
Here, the cluster center feature of each of the K feature clusters is combined with the user attribute features of the target user account to generate K mutually independent interest features of the target user account.
Preferably, K mutually independent features of interest can be characterized by vector form. In one exemplary embodiment, step 103 includes: inputting cluster center features of each of the K feature clusters and user attribute features of the target user account into a second neural network model; and combining the cluster center feature of each of the K feature clusters and the user attribute feature of the target user account into K mutually independent interest features of the target user account by using a second neural network model. For example, the second neural network includes a second embedded layer. The second embedding layer further characterizes the K mutually independent features of interest into K mutually independent vector forms using an embedding vector approach.
For example, a feature vector for the target user account may be determined based on the user attribute features of the target user account. The user attribute features include age, gender, device type, city, network connection mode and statistical features of related behaviors, etc. The second embedding layer combines the center vector of each feature cluster (i.e., the feature vector of the cluster center point) with the feature vector of the target user account to generate a second vector corresponding to the feature cluster. Since the class is K, K second vectors are generated. Each second vector is used for representing a corresponding interest category in the K interest categories of the target user account.
As can be seen, the present disclosure explicitly models multiple interests of a user as well, one interest category corresponding to one second vector, such that the multiple interests of the user are fully expressed.
Step 104: content recall for content recommendation is initiated for the target user account based on each of the K mutually independent interest-features.
Therefore, the embodiment of the invention recalls the content aiming at each interest feature, and the recalled content covers all user interests, so that the comprehensiveness of the content is improved.
In an exemplary embodiment, step 104 specifically includes: determining the number of recall content corresponding to each interest feature based on the predetermined total number of recall content; determining the content matched with each interest feature for each interest feature, wherein the number of the content is equal to the number of recall content corresponding to the interest feature; and combining the content determined by each interest feature into the recall content for content recommendation.
Therefore, the embodiment of the invention carries out integral control on the recall content through the total number of the recall content, and controls the recall content of each interest feature respectively through the number of the recall content of each interest feature, thereby realizing omnibearing recall content control and improving the control flexibility.
In one exemplary embodiment, determining the number of recall content corresponding to each feature of interest based on a predetermined total number of recall content comprises:
and (2) in the mode (1), based on the total number of the recall content, evenly distributing the number of the recall content to each interest feature.
In the mode (1), the difficulty in calculation of determining the number of contents for each feature of interest can be reduced.
For example, assume that in a short video recommendation application, the total number of contents that need to be recalled to the user (i.e., the total number of recalled contents) is 15. The value of K is 5, and the number of the impromptu categories is 5. Accordingly, the number of features of interest is 5. And determining that the content number corresponding to each interest feature is 15/5, namely 3. That is, the number of recall content for each category of interest is 3. When the total content number is not divided by the value of K, the content number corresponding to each interest feature can be determined based on the round-up function or the round-down function.
And (2) determining the number of the recall content corresponding to each interest feature based on the total number of the recall content and the preset weight of each interest feature.
In the mode (2), by introducing a weight factor for the feature of interest, the corresponding content number of each feature of interest can be affected.
Similarly, the number of contents corresponding to each feature of interest may be guaranteed to be an integer based on a round-up function or a round-down function.
For example, assume that in a short video recommendation application, the total number of contents that need to be recalled to the user (i.e., the total number of recalled contents) is 16. The value of K is 3, the number of the impromptu categories is 3. Accordingly, the number of interest features is 3, namely interest feature 1, interest feature 2 and interest feature 3. Assuming that the weight of the interest feature 1 is 0.5, the weight of the interest feature 2 is 0.25, and the weight of the interest feature 3 is 0.25. Then, the content number corresponding to the interest feature 1 is 16×0.5, i.e. 8; the content number corresponding to the interest feature 2 is 16 x 0.25, namely 4; the number of contents corresponding to the interest feature 3 is 16×0.25, i.e. 4.
While the foregoing exemplary description describes typical examples of determining the number of contents corresponding to each category of interest based on a predetermined total number of contents, those skilled in the art will recognize that this description is exemplary only and is not intended to limit the scope of the embodiments of the present invention.
The present disclosure also proposes a model training method. FIG. 3 is a flowchart illustrating a model training method according to an exemplary embodiment. The model training method comprises the following steps:
step 301: a set of training samples is obtained, wherein each training sample in the set of training samples includes training content and marking content associated with the same user account, and user attribute features of the user account, the marking content being marked with a marking status.
After step 301, a training process of the neural network model is performed based on the training sample set. The training process includes steps 302-304.
Step 302: for each of the training samples: acquiring first content features of the training content and second content features of the marking content by using the neural network model; clustering the first content features to obtain K feature clusters, wherein K is used for representing the interest number of the user account and is a positive integer greater than 2; and generating K mutually independent interest features based on the cluster center features of each of the K feature clusters and the user attribute features.
Step 303: a loss function value of the neural network model is determined based on the labeling state of each of the training samples, the interest feature obtained for each of the training samples, and the second content feature.
Step 304: and configuring model parameters of the neural network model so that the loss function value is lower than a preset threshold.
Therefore, the neural network model capable of generating K mutually independent interest features can be trained, the recall content comprehensiveness can be improved, and the neural network model is suitable for various content recommendation scenes.
In one exemplary embodiment, the number of interests characterized by K is configured to: under the condition that the similarity between every two interest features is lower than a preset similarity threshold, the maximum interest number corresponding to the user account is met; the method further comprises performing an iterative process for determining K in the training process, the iterative process comprising: clustering the first content features into T mutually independent interest features, wherein T is a preset initial value; determining the similarity between every two interesting features in the T interesting features which are independent of each other; increasing the T under the condition that the similarity between every two interesting features is not larger than a preset threshold value; and determining T after the iteration is finished as the K.
Therefore, the method and the device can determine the value of K based on the iterative process in the training process, improve the accuracy of the interest category, and improve the instantaneity of the testing process.
In an exemplary embodiment, the determining the loss function value of the neural network model based on the labeling state of each of the training samples, the interest feature and the second content feature obtained for each of the training samples includes: determining a single sample loss value for each of the training samples based on a marker state of each of the training samples, the interest feature obtained for each of the training samples, and the second content feature; and determining an average value of the single-sample loss values of all training samples in the training sample set as the loss function value.
Therefore, the loss function value is determined through the single sample loss values of the plurality of test samples, and the training efficiency of the neural network model is improved.
In an exemplary embodiment, the determining a single sample loss value for each of the training samples based on the marking status of each of the training samples, the interest feature obtained for each of the training samples, and the second content feature includes the steps of: selecting one of K independent interest features with the smallest distance from the second content feature; determining the single sample loss value based on the selected one of the features of interest and the marker state, wherein the marker state has a first state value in the case that the training sample is a positive sample and a second state value different from the first state value in the case that the training sample is a negative sample.
Therefore, the single sample loss value is determined through the marking states with different state values, and the accuracy of the single sample loss value is improved.
The detailed flow of the present disclosure is illustrated below with short video recommendations. In general, each time a short video acquisition request in short videos needs to recall N short videos from a video pool containing a large number of short videos and return the N short videos to a recommendation engine, and the recommendation engine finally provides M (M < < N) short videos to return to a user through coarse ranking, fine ranking, reordering and other stages.
The present disclosure may be used to recall N videos from a video pool that cover all of the user's interests.
Specifically, the number K of interest categories of a user is firstly determined, then clustering is carried out according to a feedback behavior history list of the user, independent modeling is carried out on videos meeting the same interest, K independent interest vectors are generated, K different interests of the user are represented, and then corresponding videos are recalled according to each interest vector and returned to a recommendation engine. It should be noted that the K value employed in the present disclosure may be determined based on a training process for the neural network, and may not be clustered using existing fixed embedded vectors. In fact, the clustering algorithm logic of the present disclosure may be combined with a training process of the neural network model, where the embedded vector and the K value used during each clustering are different, and the embedded vector and the K value may be used as training parameters of the neural network model, and are guided by an optimization target, and updated by a back propagation algorithm.
FIG. 4 is a schematic diagram of a short video recall model shown in accordance with an exemplary embodiment.
In fig. 4, the short video recall model 31 includes:
(1) Video feature vector extraction module 311: for converting video features into vectors for representation. Video features may include video identification, author identification, category tags to which they belong, and so forth. The video feature vector extraction module 311 has a general DNN network structure that includes two hidden layers. For example, video feature vector extraction module 311 may output a 64-dimensional video vector that characterizes the video feature.
(2) Clustering module 312: and carrying out K-means clustering on the video vector of the current user to obtain K clustering centers.
(3) User interest extraction module 313: and the method is used for combining each cluster center vector and the user feature vector to obtain K user interest vectors. The user interest extraction module 313 may contain a DNN network architecture. The user interest vector may be 64 dimensions. Each user interest vector is used to characterize one interest of the user. The user feature vector may include, among other things, age, gender, device type, city in which the user is located, network connectivity, and statistics of related behaviors.
Specifically, the training process of short video recall model 31 includes:
the first step: a training sample set is constructed that includes a plurality of training samples. The number of user accounts in the training sample set is typically multiple, and the number of user accounts in each training sample is one. Each training sample contains user attribute characteristics of a user account, training content associated with the user account, and tagging content, wherein the tagging content is tagged with a tagging status. Specifically, the training content includes: a video list clicked by the user account (the list comprises a clicked video ID, a clicked video author ID, a clicked video category label and the like); the marking content comprises: a list of information for the current video (e.g., the list includes an ID of the current video, an author ID of the current video, a category label of the current video, etc.) and a marking status for marking whether the user account has clicked the marked content (i.e., the current video). For example, 256 training samples can be taken as one batch, and the training samples can be distinguished to be positive samples or negative samples based on the marking content in each training sample, wherein the marking state marks the training sample of the user account after the user account clicks the marking content as the positive sample of the user account. Several samples can be randomly sampled from the batch as negative samples of the user account, and positive and negative samples of each user account are guaranteed not to overlap.
And a second step of: the training sample set is input into a short video recall model 31. The video feature vector extraction module 311 extracts a vector characterizing the content features of the training content and a vector characterizing the content features of the tag content.
And a third step of: the clustering module 312 determines K for each user account based on the iterative operation. The iterative process comprises the following steps: for each user account: clustering vectors of the user account, which characterize content features of training content (the content features may be extracted from a plurality of training samples), into T mutually independent interest features, wherein T is a preset initial value; determining the similarity between every two interest features in the T interest features which are independent of each other; increasing T under the condition that the similarity between every two interesting features is not greater than a preset threshold value; and determining the T after the iteration is finished as K of the user account. The clustering module 312 may obtain K for each user account through the iterative process described above. The K of each user account may be the same or different.
Fourth step: for each training sample, the clustering module 312 clusters the content features of the training content to obtain K feature clusters associated with the user account in the training sample.
Fifth step: for each training sample, video feature vector extraction module 311 generates K mutually independent interest vectors based on the cluster center feature of each of the K feature clusters associated with the user account in the training sample, and the user attribute features.
Sixth step: for each training sample, a vector distance (e.g., cosine distance) between each interest vector and a vector characterizing the content features of the marker content is calculated, and the interest vector closest to the training sample is selected as the output score of the short video recall model 31.
Seventh step: the cross entropy loss function is calculated from the output score of the short video recall model 31 and the labeled states in the training samples, counter-propagated and the network parameters of the short video recall model 31 are updated using a random gradient descent algorithm.
For example, assume that in the training samples: the vector of the content characteristic of the marked content is V, the interest vector of the user account is P, in particular I 0 、I 1 、I 2 ……I P The method comprises the steps of carrying out a first treatment on the surface of the Y is a marking state and indicates whether the user account clicks the marking content.
A cross entropy Loss value Loss for a single test sample may be determined, wherein:
Loss=-Y*logA-(1-Y)*logA;
A=sigmoid(max{dot(V,I 0 ),dot(V,I 1 ),dot(V,I 2 )…dot(V,I p )});
wherein: dot is a point multiplication function; max is a maximum function, such as max { dot (V, I) 0 ),dot(V,I 1 ),dot(V,I 2 )…dot(V,I p ) The output of (2) is dot (V, I) 0 ),dot(V,I 1 ),dot(V, I 2 )…dot(V,I p ) The maximum of these P; the sigmoid function is an activation function with the range of the value range limited between (0, 1); when the user has clicked on the mark content, the training sample is a positive sample, where Y has a first state value (e.g., +1); when the user does not click on the marker content, the training sample is a negative sample, at which time Y has a second state value (e.g., 0).
And determining the average value of the cross entropy Loss values Loss of all the single test samples in the training sample set as a Loss function value. For example, the cross entropy Loss values Loss of all training samples are summed, and the sum is divided by the total number of training samples to obtain the Loss function value. Then, a back propagation process of the short video recall model 31 is performed, in which model parameters of the neural network model are configured so that the loss function value is lower than a preset threshold value, thereby completing a training phase of the short video recall model 31.
After the training phase of the short video recall model 31 is completed, the prediction phase may be performed using the short video recall model 31.
Specifically, in the prediction phase:
the first step: test data is received, wherein the test data includes historical interaction content of the target user account and user attribute characteristics of the target user account.
And a second step of: the video feature vector extraction module 311 obtains a vector representation of all video features in the historical interaction content, which is called a video feature vector.
And a third step of: the clustering module 312 is utilized to cluster all the video feature vectors output by the video feature vector extraction module 311, and K feature clusters are extracted altogether, wherein K is associated with the target user account and is determined in the training process.
Fourth step: the user interest extraction module 313 merges the user attribute feature and each cluster center vector of the K feature clusters to obtain K interest vectors for the target user account.
Fifth step: the nearest N/K short videos for each interest vector are retrieved from the video pool 32 using a fast nearest neighbor (FAISS) algorithm with each interest vector and returned to the recommendation engine. That is, a total of the recommendation engine (N/k=n) is returned for short videos. The recommendation engine provides M (M < < N) short videos from N short videos and returns the M < < N > short videos to the target user account after the stages of coarse ranking, fine ranking, reordering and the like.
FIG. 5 is a schematic diagram illustrating a short video recall process, according to an example embodiment.
In fig. 5, the history content list 41 includes short videos previously browsed by the target user account. A list of interest categories 42 for the target user account may be determined based on the historical content list 41. Moreover, based on the interest category list 42, videos that are close to each interest category in the interest category list 42 may be determined from the video pool, and the videos determined by the respective interest categories may be collected as recall videos 43 of the target user account. The recall video 43 is then initially screened using a simple model using the coarse ranking stage. The fine ranking stage performs fine scoring on the coarse ranking content and further filters. And the reordering stage reorders the content which is discharged finely and presents the content to the target user account.
While embodiments of the present invention have been described above with reference to short video recalls, those skilled in the art will recognize that this description is exemplary only and is not intended to limit the scope of embodiments of the present invention.
FIG. 6 is a block diagram illustrating a recall device for content recommendation, according to an example embodiment. Recall apparatus 600 for content recommendation includes:
an acquisition module 601 configured to acquire content characteristics of historical interaction content of a target user account; the clustering module 602 is configured to perform clustering processing on the content features to obtain K feature clusters, wherein K is used for representing the interest number of the target user account, and K is a positive integer greater than 2; a generating module 603 configured to generate K mutually independent interest-features of the target user account based on the cluster center feature of each of the K feature clusters and the user attribute feature of the target user account; a recall module 604 configured to initiate content recalls for the content recommendation for the target user account based on each of the K mutually independent interest-features.
In an exemplary embodiment, the acquisition module 601 is configured to: inputting the historical interaction content into a first neural network model, wherein the first neural network model comprises a first embedded layer; acquiring content characteristics from the historical interaction content by using the first embedded layer; a generation module configured to: inputting the cluster center feature of each of the K feature clusters and the user attribute feature of the target user account into a second neural network model, wherein the second neural network model comprises a second embedding layer; and combining the cluster center feature of each of the K feature clusters and the user attribute feature of the target user account into K mutually independent interest features of the target user account by using the second embedding layer.
In one exemplary embodiment, the number of interests of the K-representation is configured to: under the condition that the similarity between every two interest features is lower than a preset similarity threshold, the maximum interest number corresponding to the target user account is met; a clustering module 602 configured to perform an iterative process for determining K, the iterative process comprising: clustering the content features into T mutually independent interest features, wherein T is a preset initial value; determining the similarity between every two interest features in the T interest features which are independent of each other; increasing T under the condition that the similarity between every two interesting features is not greater than a preset threshold value; and determining T after the iteration is finished as K.
In one exemplary embodiment, recall module 604 is configured to: determining the number of recall content corresponding to each interest feature based on the predetermined total number of recall content; for each interest feature, determining the content matched with the interest feature, wherein the number of the content is equal to the number of recall content corresponding to the interest feature; the content determined for each feature of interest is combined into recall content for content recommendation.
In one exemplary embodiment, recall module 604 is configured to: based on the total number of recall contents, the number of recall contents is evenly distributed for each interest feature; or determining the number of recall contents corresponding to each interest feature based on the total number of recall contents and the preset weight of each interest feature.
In an exemplary embodiment, the acquisition module 601 is configured to: before acquiring the content characteristics of the historical interaction content of the target user account, acquiring a content browsing record of the target user account in a selected time period; and determining browsed content in the content browsing record as historical interaction content.
FIG. 7 is a block diagram of a model training apparatus, according to an example embodiment. The model training apparatus 700 includes:
an obtaining module 701 configured to obtain a set of training samples, wherein each training sample in the set of training samples includes training content and marking content associated with a same user account, and user attribute features of the user account, the marking content being marked with a marking status;
training module 702 is configured to perform a training process of the neural network model based on the training sample set, the training process comprising: for each training sample: acquiring first content features of training content and second content features of marked content by using a neural network model; clustering the first content features to obtain K feature clusters, wherein K is used for representing the interest number of the user account and is a positive integer greater than 2; generating K mutually independent interest features based on the cluster center features of each of the K feature clusters and the user attribute features; determining a loss function value of the neural network model based on the marking state of each training sample, the interest feature and the second content feature obtained for each training sample; model parameters of the neural network model are configured such that the loss function value is below a preset threshold.
In one exemplary embodiment, the number of interests of the K-representation is configured to: under the condition that the similarity between every two interest features is lower than a preset similarity threshold, the maximum interest number corresponding to the user account is met; training module 702 is configured to perform an iterative process for determining K during a training process, the iterative process comprising: clustering the first content features into T mutually independent interest features, wherein T is a preset initial value; determining the similarity between every two interest features in the T interest features which are independent of each other; increasing T under the condition that the similarity between every two interesting features is not greater than a preset threshold value; and determining T after the iteration is finished as K.
In one exemplary embodiment, training module 702 is configured to: determining a single sample loss value for each training sample based on the marking status of each training sample, the interest feature obtained for each training sample, and the second content feature; and determining the average value of the single sample loss values of all training samples in the training sample set as a loss function value.
In one exemplary embodiment, training module 702 is configured to: selecting one with the smallest distance from the second content feature from the K mutually independent interest features; a single sample loss value is determined based on the selected one feature of interest and the signature status, wherein the signature status has a first status value in the case of a positive sample and a second status value different from the first status value in the case of a negative sample.
The embodiment of the disclosure also provides electronic equipment. Fig. 8 is a block diagram of an electronic device, according to an example embodiment. As shown in fig. 8, the electronic device 800 may include: a processor 801; a memory 802 for storing instructions executable by the processor 801; wherein the processor 801 is configured to: when executing executable instructions stored on memory 802, a recall method or model training method for content recommendation provided by embodiments of the present disclosure is implemented. It is understood that the electronic device 800 may be a server or a terminal device, which in particular applications may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, etc.
FIG. 9 is a block diagram illustrating a recall device or model training device for content recommendation, according to an example embodiment. For example, apparatus 900 may be: a smart phone, a tablet computer, a dynamic video expert compression standard audio layer 3 player (Moving Picture Experts Group Audio Layer III, MP 3), a dynamic video expert compression standard audio layer 4 (Moving Picture Experts Group Audio Layer IV, MP 4) player, a notebook computer, or a desktop computer. The apparatus 900 may also be referred to by other names of user equipment, portable terminals, laptop terminals, desktop terminals, etc.
Generally, the apparatus 900 includes: a processor 901 and a memory 902. The processor 901 is used to perform the recall method or model training method of content recommendation as described above. Processor 901 may include one or more processing cores, such as a 4-core processor, an 8-core processor, and the like. The processor 901 may be implemented in hardware in at least one of digital signal processing (Digital Signal Processing, DSP), field programmable gate array (Field-Programmable Gate Array, FPGA), programmable logic array (Programmable Logic Array, PLA). Processor 901 may also include a main processor, which is a processor for processing data in an awake state, also referred to as a central processor (Central Processing Unit, CPU), and a coprocessor; a coprocessor is a low-power processor for processing data in a standby state. In some embodiments, the processor 901 may integrate with an image processor (Graphics Processing Unit, GPU) for rendering and rendering of content required to be displayed by the display screen. In some embodiments, the processor 901 may also include an artificial intelligence (Artificial Intelligence, AI) processor for processing computing operations related to machine learning. The memory 902 may include one or more computer-readable storage media, which may be non-transitory. The memory 902 may also include high-speed random access memory, as well as non-volatile memory, such as one or more magnetic disk storage devices, flash memory storage devices.
In some embodiments, a non-transitory computer readable storage medium in memory 902 is used to store at least one instruction for execution by processor 901 to implement the methods of determining content provided by various embodiments in the present disclosure. In some embodiments, the apparatus 900 may further optionally include: a peripheral interface 903, and at least one peripheral. The processor 901, memory 902, and peripheral interface 903 may be connected by a bus or signal line. The individual peripheral devices may be connected to the peripheral device interface 903 via buses, signal lines, or circuit boards. Specifically, the peripheral device includes: at least one of radio frequency circuitry 904, a touch display 905, a camera assembly 906, audio circuitry 907, a positioning assembly 908, and a power source 909.
The peripheral interface 903 may be used to connect at least one Input/Output (I/O) related peripheral to the processor 901 and the memory 902. In some embodiments, the processor 901, memory 902, and peripheral interface 903 are integrated on the same chip or circuit board; in some other embodiments, either or both of the processor 901, the memory 902, and the peripheral interface 903 may be implemented on separate chips or circuit boards, which are not limited by the disclosed embodiments. The Radio Frequency circuit 904 is configured to receive and transmit Radio Frequency (RF) signals, also known as electromagnetic signals. The radio frequency circuit 904 communicates with a communication network and other communication devices via electromagnetic signals. The radio frequency circuit 904 converts an electrical signal into an electromagnetic signal for transmission, or converts a received electromagnetic signal into an electrical signal. Optionally, the radio frequency circuit 904 includes: antenna systems, RF transceivers, one or more amplifiers, tuners, oscillators, digital signal processors, codec chipsets, subscriber identity module cards, and so forth. The radio frequency circuit 904 may communicate with other terminals via at least one wireless communication protocol. The wireless communication protocol includes, but is not limited to: metropolitan area networks, various generations of mobile communication networks (2G, 3G, 4G, and 5G), wireless local area networks, and/or wireless fidelity (Wireless Fidelity, wiFi) networks. In some embodiments, the radio frequency circuitry 904 may also include near field communication (Near Field Communication, NFC) related circuitry, which is not limited by the disclosed embodiments.
The display 905 is used to display a User Interface (UI). The UI may include graphics, text, icons, video, and any combination thereof. When the display 905 is a touch display, the display 905 also has the ability to capture touch signals at or above the surface of the display 905. The touch signal may be input as a control signal to the processor 901 for processing. At this time, the display 905 may also be used to provide virtual buttons and/or a virtual keyboard, also referred to as soft buttons and/or a soft keyboard. In some embodiments, the display 905 may be one, providing the front panel of the device 900; in other embodiments, the display 905 may be at least two, respectively disposed on different surfaces of the device 900 or in a folded design; in some embodiments, the display 905 may be a flexible display disposed on a curved surface or a folded surface of the device 900. Even more, the display 905 may be arranged in an irregular pattern other than rectangular, i.e., a shaped screen. The display 905 may be made of a material such as a liquid crystal display (Liquid Crystal Display, LCD) or an Organic Light-Emitting Diode (OLED).
The camera assembly 906 is used to capture images or video. Optionally, the camera assembly 906 includes a front camera and a rear camera. Typically, the front camera is disposed on the front panel of the terminal and the rear camera is disposed on the rear surface of the terminal. In some embodiments, the at least two rear cameras are any one of a main camera, a depth camera, a wide-angle camera and a tele camera, so as to realize that the main camera and the depth camera are fused to realize a background blurring function, and the main camera and the wide-angle camera are fused to realize a panoramic shooting and Virtual Reality (VR) shooting function or other fusion shooting functions. In some embodiments, camera assembly 906 may also include a flash. The flash lamp can be a single-color temperature flash lamp or a double-color temperature flash lamp. The dual-color temperature flash lamp refers to a combination of a warm light flash lamp and a cold light flash lamp, and can be used for light compensation under different color temperatures.
The audio circuit 907 may include a microphone and a speaker. The microphone is used for collecting sound waves of users and the environment, converting the sound waves into electric signals, and inputting the electric signals to the processor 901 for processing, or inputting the electric signals to the radio frequency circuit 904 for voice communication. For purposes of stereo acquisition or noise reduction, the microphone may be multiple, each disposed at a different location of the device 900. The microphone may also be an array microphone or an omni-directional pickup microphone. The speaker is used to convert electrical signals from the processor 901 or the radio frequency circuit 904 into sound waves. The speaker may be a conventional thin film speaker or a piezoelectric ceramic speaker. When the speaker is a piezoelectric ceramic speaker, not only the electric signal can be converted into a sound wave audible to humans, but also the electric signal can be converted into a sound wave inaudible to humans for ranging and other purposes. In some embodiments, the audio circuit 907 may also include a headphone jack.
The location component 908 is used to locate the current geographic location of the device 900 to enable navigation or location-based services (Location Based Service, LBS). The positioning component 908 may be a positioning component based on the U.S. global positioning system (Global Positioning System, GPS), the beidou system of china, the russian glonass system, or the galileo system of the european union.
The power supply 909 is used to power the various components in the device 900. The power supply 909 may be an alternating current, a direct current, a disposable battery, or a rechargeable battery. When the power supply 909 includes a rechargeable battery, the rechargeable battery can support wired or wireless charging. The rechargeable battery may also support fast charge technology.
In some embodiments, the apparatus 900 further includes one or more sensors 910. The one or more sensors 910 include, but are not limited to: acceleration sensor 911, gyroscope sensor 912, pressure sensor 913, fingerprint sensor 914, optical sensor 915, and proximity sensor 916. The acceleration sensor 911 can detect the magnitudes of accelerations on three coordinate axes of the coordinate system established with the apparatus 900. For example, the acceleration sensor 911 may be used to detect components of gravitational acceleration in three coordinate axes. The processor 901 may control the touch display 905 to display a user interface in a landscape view or a portrait view according to the gravitational acceleration signal acquired by the acceleration sensor 911. The acceleration sensor 911 may also be used for the acquisition of motion data of a game or a user. The gyro sensor 912 may detect a body direction and a rotation angle of the device 900, and the gyro sensor 912 may collect a 3D motion of the user on the device 900 in cooperation with the acceleration sensor 911. The processor 901 may implement the following functions according to the data collected by the gyro sensor 912: motion sensing (e.g., changing UI according to a tilting operation by a user), image stabilization at shooting, game control, and inertial navigation. The pressure sensor 913 may be disposed on a side frame of the device 900 and/or on an underlying layer of the touch display 905. When the pressure sensor 913 is disposed on the side frame of the device 900, a holding signal of the device 900 by the user can be detected, and the processor 901 performs a left-right hand recognition or a shortcut operation according to the holding signal collected by the pressure sensor 913. When the pressure sensor 913 is disposed at the lower layer of the touch display 905, the processor 901 performs control of the operability control on the UI interface according to the pressure operation of the user on the touch display 905. The operability controls include at least one of a button control, a scroll bar control, an icon control, and a menu control.
The fingerprint sensor 914 is used for collecting the fingerprint of the user, and the processor 901 identifies the identity of the user according to the fingerprint collected by the fingerprint sensor 914, or the fingerprint sensor 914 identifies the identity of the user according to the collected fingerprint. Upon recognizing that the user's identity is a trusted identity, the processor 901 authorizes the user to perform relevant sensitive operations including unlocking the screen, viewing encrypted information, downloading software, paying for and changing settings, etc. The fingerprint sensor 914 may be provided on the front, back or side of the device 900. When a physical key or vendor Logo is provided on the device 900, the fingerprint sensor 914 may be integrated with the physical key or vendor Logo. The optical sensor 915 is used to collect the intensity of ambient light. In one embodiment, the processor 901 may control the display brightness of the touch display 905 based on the intensity of ambient light collected by the optical sensor 915. Specifically, when the ambient light intensity is high, the display brightness of the touch display 905 is turned up; when the ambient light intensity is low, the display brightness of the touch display panel 905 is turned down. In another embodiment, the processor 901 may also dynamically adjust the shooting parameters of the camera assembly 906 based on the ambient light intensity collected by the optical sensor 915. A proximity sensor 916, also referred to as a distance sensor, is typically provided on the front panel of the device 900. Proximity sensor 916 is used to capture the distance between the user and the front of device 900. In one embodiment, when the proximity sensor 916 detects that the distance between the user and the front face of the device 900 gradually decreases, the processor 901 controls the touch display 905 to switch from the bright screen state to the off screen state; when the proximity sensor 916 detects that the distance between the user and the front face of the device 900 gradually increases, the processor 901 controls the touch display 905 to switch from the off-screen state to the on-screen state. It will be appreciated by those skilled in the art that the foregoing structure is not limiting of the apparatus 900 and may include more or fewer components than shown, or may combine certain components, or may employ a different arrangement of components.
FIG. 10 is another block diagram illustrating a recall device or model training device for content recommendation, according to an example embodiment. For example, the apparatus 300 may be provided as a server. Referring to fig. 10, the apparatus 300 includes a processing component 301 that further includes one or more processors, and memory resources represented by a memory 302, for storing instructions, such as applications, executable by the processing component 301. The application program stored in the memory 302 may include one or more modules each corresponding to a set of instructions. Further, the processing component 301 is configured to execute instructions to perform the recall method or model training method described above for content recommendation.
The apparatus 300 may further comprise a power supply component 303 configured to perform power management of the apparatus 300, a wired or wireless network interface 804 configured to connect the apparatus 300 to a network, and an input output interface 305. The device 300 may operate based on an operating system stored in the memory 302, such as Windows Server, mac OS X, unix, linux, freeBSD, or the like.
In addition, the embodiment of the application also provides a non-transitory computer readable storage medium, when the instructions in the storage medium are executed by a processor of the electronic device, the electronic device can execute the steps of the recall method for content recommendation provided by the embodiment of the application. The computer-readable storage medium may include, but is not limited to: portable computer diskette, hard disk, random Access Memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), portable compact disc read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination of the foregoing, but are not intended to limit the scope of the application. In the disclosed embodiments, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
In addition, the embodiment of the application also provides a computer program product, and the instructions in the computer program product enable the electronic device to execute the steps of the recall method for content recommendation when the instructions in the computer program product are executed by the processor of the electronic device.
Other embodiments of the application will be apparent to those skilled in the art from consideration of the specification and practice of the application disclosed herein. This application is intended to cover any variations, uses, or adaptations of the application following, in general, the principles of the application and including such departures from the present disclosure as come within known or customary practice within the art to which the application pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the application being indicated by the following claims.
It is to be understood that the application is not limited to the precise arrangements and instrumentalities shown in the drawings, which have been described above, and that various modifications and changes may be effected without departing from the scope thereof. The scope of the application is limited only by the appended claims.

Claims (10)

1. A recall method for content recommendation, comprising:
acquiring content characteristics of historical interaction content of a target user account;
Clustering the content features to obtain K feature clusters, wherein K is used for representing the interest number of the target user account, and K is a positive integer greater than 2;
generating K mutually independent interest features of the target user account based on the cluster center features of each of the K feature clusters and the user attribute features of the target user account;
content recall for content recommendation is initiated for the target user account based on each of the K mutually independent interest-features.
2. The method of claim 1, wherein the obtaining content characteristics of the historical interaction content of the target user account comprises:
inputting the historical interaction content into a first neural network model;
acquiring the content characteristics from the historical interaction content by using the first neural network model;
generating K mutually independent interest features of the target user account based on the cluster center feature of each of the K feature clusters and the user attribute feature of the target user account, including:
inputting a cluster center feature of each of the K feature clusters, and a user attribute feature of the target user account into a second neural network model;
And combining the cluster center feature of each of the K feature clusters and the user attribute feature of the target user account into K mutually independent interest features of the target user account by using the second neural network model.
3. A method of model training, comprising:
obtaining a training sample set, wherein each training sample in the training sample set comprises training content and marking content associated with the same user account and user attribute characteristics of the user account, and the marking content is marked with a marking state;
based on the training sample set, performing a training process of the neural network model, the training process comprising:
for each of the training samples: acquiring first content features of the training content and second content features of the marking content by using the neural network model; clustering the first content features to obtain K feature clusters, wherein K is used for representing the interest number of the user account and is a positive integer greater than 2; and generating K mutually independent features of interest based on the cluster center feature of each of the K feature clusters and the user attribute feature;
Determining a loss function value of the neural network model based on a labeling state of each training sample, the interest feature and the second content feature obtained for each training sample;
and configuring model parameters of the neural network model so that the loss function value is lower than a preset threshold.
4. A method according to claim 3, wherein the number of interests of the K-representation is configured to: under the condition that the similarity between every two interest features is lower than a preset similarity threshold, the maximum interest number corresponding to the user account is met;
the method further comprises performing an iterative process for determining K in the training process, the iterative process comprising:
clustering the first content features into T mutually independent interest features, wherein T is a preset initial value;
determining the similarity between every two interesting features in the T interesting features which are independent of each other;
increasing the T under the condition that the similarity between every two interesting features is not larger than a preset threshold value;
and determining T after the iteration is finished as the K.
5. The method of claim 3, wherein the step of,
The determining a loss function value of the neural network model based on the labeling state of each training sample, the interest feature and the second content feature obtained for each training sample, includes:
determining a single sample loss value for each of the training samples based on a marker state of each of the training samples, the interest feature obtained for each of the training samples, and the second content feature;
and determining an average value of the single-sample loss values of all training samples in the training sample set as the loss function value.
6. A recall device for content recommendation, comprising:
the acquisition module is configured to acquire content characteristics of historical interaction content of the target user account;
the clustering module is configured to perform clustering processing on the content features to obtain K feature clusters, wherein K is used for representing the interest number of the target user account and is a positive integer greater than 2;
a generation module configured to generate K mutually independent interest features of the target user account based on a cluster center feature of each of the K feature clusters and a user attribute feature of the target user account;
A recall module configured to initiate content recall for content recommendation for the target user account based on each of K of the interest-features independent of each other.
7. A model training device, comprising:
an acquisition module configured to acquire a set of training samples, wherein each training sample in the set of training samples includes training content and marking content associated with a same user account, and user attribute characteristics of the user account, the marking content being marked with a marking status;
a training module configured to perform a training process of the neural network model based on the set of training samples, the training process comprising:
for each of the training samples: acquiring first content features of the training content and second content features of the marking content by using the neural network model; clustering the first content features to obtain K feature clusters, wherein K is used for representing the interest number of the user account and is a positive integer greater than 2; and generating K mutually independent features of interest based on the cluster center feature of each of the K feature clusters and the user attribute feature;
Determining a loss function value of the neural network model based on a labeling state of each training sample, the interest feature and the second content feature obtained for each training sample;
and configuring model parameters of the neural network model so that the loss function value is lower than a preset threshold.
8. An electronic device, comprising:
a processor;
a memory for storing the processor-executable instructions;
the processor configured to read the executable instructions from the memory and execute the executable instructions to implement the recall method for content recommendation of any one of claims 1-2 or the model training method of any one of claims 3-5.
9. A computer readable storage medium having stored thereon computer instructions, which when executed by a processor, implement the recall method for content recommendation of any one of claims 1-2 or the model training method of any one of claims 3-5.
10. A computer program product comprising a computer program which, when executed by a processor, implements the recall method for content recommendation of any one of claims 1-2 or the model training method of any one of claims 3-5.
CN202210474522.XA 2022-04-29 2022-04-29 Recall method, training method, device and storage medium for content recommendation Pending CN117056585A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210474522.XA CN117056585A (en) 2022-04-29 2022-04-29 Recall method, training method, device and storage medium for content recommendation

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210474522.XA CN117056585A (en) 2022-04-29 2022-04-29 Recall method, training method, device and storage medium for content recommendation

Publications (1)

Publication Number Publication Date
CN117056585A true CN117056585A (en) 2023-11-14

Family

ID=88652279

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210474522.XA Pending CN117056585A (en) 2022-04-29 2022-04-29 Recall method, training method, device and storage medium for content recommendation

Country Status (1)

Country Link
CN (1) CN117056585A (en)

Similar Documents

Publication Publication Date Title
CN110134804B (en) Image retrieval method, device and storage medium
CN110222789B (en) Image recognition method and storage medium
CN109284445B (en) Network resource recommendation method and device, server and storage medium
CN111897996B (en) Topic label recommendation method, device, equipment and storage medium
CN111104980B (en) Method, device, equipment and storage medium for determining classification result
CN111291200B (en) Multimedia resource display method and device, computer equipment and storage medium
CN110162604B (en) Statement generation method, device, equipment and storage medium
CN111506758A (en) Method and device for determining article name, computer equipment and storage medium
CN112131473B (en) Information recommendation method, device, equipment and storage medium
CN113032587B (en) Multimedia information recommendation method, system, device, terminal and server
CN113987326B (en) Resource recommendation method and device, computer equipment and medium
CN111782950B (en) Sample data set acquisition method, device, equipment and storage medium
CN112053360B (en) Image segmentation method, device, computer equipment and storage medium
CN111611414B (en) Vehicle searching method, device and storage medium
CN111563201A (en) Content pushing method, device, server and storage medium
CN114817709A (en) Sorting method, device, equipment and computer readable storage medium
CN110928913B (en) User display method, device, computer equipment and computer readable storage medium
CN112560472B (en) Method and device for identifying sensitive information
CN115905374A (en) Application function display method and device, terminal and storage medium
CN112418295A (en) Image processing method, device, equipment and storage medium
CN117056585A (en) Recall method, training method, device and storage medium for content recommendation
CN111597823A (en) Method, device and equipment for extracting central word and storage medium
CN111259252A (en) User identification recognition method and device, computer equipment and storage medium
CN111581481B (en) Search term recommendation method and device, electronic equipment and storage medium
CN111753154B (en) User data processing method, device, server and computer readable storage medium

Legal Events

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