Poster recommendation method and device, electronic equipment and storage medium
By using the sorting model in poster recommendation combined with user and poster features, calculating the sorting score and selecting posters with high similarity, the problem of inability to personalize recommendations in the prior art is solved, and more accurate and efficient poster recommendations are achieved.
Patent Information
- Application Number
- CN202510416194.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-03
- Publication Date
- 2025-08-08
AI Technical Summary
The existing poster recommendation method fails to consider the differences in interests of different users in posters, resulting in the inability to achieve personalized recommendations and the accurate recommendation effect cannot be achieved.
By inputting user features, context features, video features and poster features into the pre-trained sorting model, calculating the sorting score, determining the target recommended video, and selecting the target poster for recommendation based on the similarity between the user feature vector and the poster feature vector.
It realizes personalized poster recommendations based on user interests, improves the accuracy and efficiency of recommendations, and reduces the consumption of computing resources.
Smart Images

Figure CN120448586A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing, and in particular to a poster recommendation method, device, electronic device and storage medium. Background Art
[0002] Posters can convey video information to viewers directly and quickly. Most users will decide whether to click on a video based on the video poster.
[0003] In related technologies, when recommending posters, a server uses a multi-armed bandit (MAB) algorithm to tentatively select a poster from N posters corresponding to the video to be recommended. Specifically, the server first randomly selects a poster from the N posters to recommend to the user, calculates the click-through rate of different posters, and finally selects the poster with the highest click-through rate to recommend to the user.
[0004] However, this poster recommendation method only considers the click-through rate of the poster, but does not take into account the different interests of different users in posters. In other words, this method cannot recommend posters to users in a personalized way and cannot achieve the effect of accurate recommendation. Summary of the Invention
[0005] The purpose of the embodiments of the present invention is to provide a poster recommendation method, device, electronic device, and storage medium to implement personalized poster recommendation for users. The specific technical solution is as follows:
[0006] In a first aspect of the present invention, a poster recommendation method is provided, comprising:
[0007] Inputting the target user's user features, context features, video features of the video to be recommended, and poster features of the poster corresponding to the video to be recommended into a pre-trained ranking model, obtaining a user feature vector obtained after the ranking model processes the user features and an output result of the ranking model; wherein the context features represent attribute information of the current scene where the target user is located; the ranking model is trained based on sample user features, sample context features, sample video features of sample videos, and sample poster features of sample posters corresponding to the sample videos;
[0008] Calculating a ranking score for the video to be recommended based on the output result, wherein the output result represents a probability that the user will operate on the video to be recommended, the ranking score is proportional to the probability that the user will operate on the video to be recommended, and the ranking score is used to represent the user's interest in the recommended video;
[0009] Determining a first number of target recommended videos with the largest ranking scores from the videos to be recommended;
[0010] Determining a target poster feature vector of a poster corresponding to each target recommended video based on the ranking model and the video identifier of the target recommended video;
[0011] Determining a target poster corresponding to each target recommended video from posters corresponding to each target recommended video based on a similarity between the user feature vector and the target poster feature vector;
[0012] Recommend the target poster corresponding to each target recommended video to the target user.
[0013] In one embodiment of the present invention, the step of recommending a target poster corresponding to each target recommended video to the target user includes:
[0014] Recommend each target recommended video and the target poster corresponding to each target recommended video to the target user.
[0015] In one embodiment of the present invention, determining a target poster corresponding to each target recommended video from posters corresponding to each target recommended video based on the similarity between the user feature vector and the target poster feature vector includes:
[0016] For each target recommended video, calculating the cosine similarity between the user feature vector and the target poster feature vector corresponding to the target recommended video;
[0017] The poster corresponding to the target poster feature vector with the highest cosine similarity is determined as the target poster corresponding to the target video.
[0018] In one embodiment of the present invention, determining a target poster feature vector of a poster corresponding to each target recommended video based on the ranking model and the video identifier of the target recommended video includes:
[0019] Inputting a first poster feature into the ranking model, obtaining and storing a poster feature vector obtained after the ranking model processes the first poster feature, where the first poster feature is a poster feature of a poster corresponding to the video to be recommended;
[0020] According to the video identifier of the target recommended video, a target poster feature vector of the poster corresponding to each target recommended video is determined from pre-stored poster feature vectors.
[0021] In one embodiment of the present invention, inputting the first poster feature into the ranking model, and obtaining and storing a poster feature vector obtained after the ranking model processes the first poster feature, includes:
[0022] The second poster feature is input into the sorting model, and a poster feature vector obtained after the sorting model processes the second poster feature is obtained and stored, where the second poster feature is at least one poster attribute information in the first poster feature, and the first poster feature includes a plurality of attribute information for describing poster attributes.
[0023] In one embodiment of the present invention, after determining a first number of target recommended videos with the largest ranking scores from the videos to be recommended, the method further includes:
[0024] The target recommended video is processed in at least one of the following ways:
[0025] If there are multiple duplicate videos, retain one of the multiple duplicate videos as the target recommended video, where the duplicate video is a video whose content similarity with the target recommended video is higher than a first preset threshold;
[0026] Removing videos whose video clarity is lower than a second preset threshold from the target recommended videos;
[0027] Set the display areas of target recommended videos of the same type to non-adjacent areas.
[0028] In a second aspect of the present invention, a poster recommendation device is provided, comprising:
[0029] A feature input module is configured to input user features, context features, video features of the target user, and poster features of the poster corresponding to the target video into a pre-trained ranking model, thereby obtaining a user feature vector obtained by processing the user features by the ranking model, and an output result of the ranking model; wherein the context features represent attribute information of the current scene in which the target user is located; and the ranking model is trained based on sample user features, sample context features, sample video features of sample videos, and sample poster features of sample posters corresponding to the sample videos;
[0030] a ranking score calculation module, configured to calculate a ranking score for the video to be recommended based on the output result; wherein the output result represents a probability that the user will operate on the video to be recommended, the ranking score is proportional to the probability that the user will operate on the video to be recommended, and the ranking score is used to represent the user's interest in the recommended video;
[0031] a target recommended video determination module, configured to determine a first number of target recommended videos having the largest ranking scores from the videos to be recommended;
[0032] a target poster feature vector determination module, configured to determine a target poster feature vector of a poster corresponding to each target recommended video based on the ranking model and the video identifier of the target recommended video;
[0033] a target poster selection module, configured to determine a target poster corresponding to each target recommended video from posters corresponding to each target recommended video based on a similarity between the user feature vector and the target poster feature vector;
[0034] The poster recommendation module is used to recommend the target poster corresponding to each target recommended video to the target user.
[0035] In another aspect of the embodiments of the present invention, an electronic device is provided, including a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other via the communication bus;
[0036] Memory for storing computer programs;
[0037] The processor is configured to implement any of the above-mentioned poster recommendation methods when executing the program stored in the memory.
[0038] In another aspect of the present invention, a computer-readable storage medium is provided, wherein a computer program is stored in the computer-readable storage medium. When the computer program is executed by a processor, any of the above-mentioned poster recommendation methods is implemented.
[0039] In another aspect of the present invention, a computer program product comprising instructions is provided. When the computer program product is run on a computer, the computer is enabled to execute any one of the above poster recommendation methods.
[0040] In the technical solution provided by the embodiment of the present invention, when recommending posters to users, the target recommended video is first determined based on the ranking model, and the poster features are added when determining the target recommended video. In this way, when determining the target recommended video based on the ranking model, both the user's interest in the video itself and the user's interest in the poster are taken into account, and the target recommended video that the user is interested in is determined from multi-dimensional features. Furthermore, based on the user feature vector produced by the ranking model and the similarity of the target poster feature vector of the poster corresponding to each target recommended video, the target poster recommended to the user is determined. That is, when making poster recommendations, the different interests of different users in different posters are taken into account, and the target poster corresponding to each target recommended video is determined based on the similarity between the user feature vector and the poster feature vector. The target poster determined is more likely to be of interest to the user, thereby achieving personalized poster recommendation for the user. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for describing the embodiments or the prior art.
[0042] Figure 1 A schematic diagram of an application scenario provided by an embodiment of the present invention;
[0043] Figure 2 A schematic flow chart of a first poster recommendation method provided by an embodiment of the present invention;
[0044] Figure 3 A schematic flow chart of a second poster recommendation method provided by an embodiment of the present invention;
[0045] Figure 4 A schematic diagram of a flow chart of a third poster recommendation method provided by an embodiment of the present invention;
[0046] Figure 5 A schematic diagram of the framework of the first poster recommendation method provided by an embodiment of the present invention;
[0047] Figure 6 A schematic diagram of a framework of a second poster recommendation method provided by an embodiment of the present invention;
[0048] Figure 7 A schematic structural diagram of a poster recommendation device provided by an embodiment of the present invention;
[0049] Figure 8 A schematic structural diagram of an electronic device provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0050] The technical solutions in the embodiments of the present invention will be described below with reference to the accompanying drawings in the embodiments of the present invention.
[0051] Posters can convey video information to viewers directly and quickly. Most users will decide whether to click on a video based on the video poster.
[0052] In related technologies, when recommending posters, a server uses the MAB algorithm to tentatively select a poster from N posters corresponding to the video to be recommended. Specifically, the server first randomly selects a poster from the N posters to recommend to the user, calculates the click-through rate of different posters, and finally selects the poster with the highest click-through rate to recommend to the user.
[0053] However, this poster recommendation method only considers the click-through rate of the poster, but does not take into account the different interests of different users in posters. In other words, this method cannot recommend posters to users in a personalized way and cannot achieve the effect of accurate recommendation.
[0054] In order to solve the above technical problems, embodiments of the present invention provide a poster recommendation method, device, electronic device, and storage medium.
[0055] First, a brief introduction to the application scenarios to which the technical solutions of the embodiments of the present invention can be applied is given. It should be noted that the application scenarios described below are only for illustrating the embodiments of the present invention and are not limiting. In specific implementation, the technical solutions provided by the embodiments of the present invention can be flexibly applied according to actual needs.
[0056] See also Figure 1 , which is a schematic diagram of an application scenario provided by an embodiment of the present invention. The scenario includes a terminal device 101 and a server 102. Terminal device 101 can be a smartphone, tablet computer, computer, various wearable devices, in-vehicle equipment, or other terminal devices. Server 102 can be a single server, a server cluster consisting of multiple servers, or a cloud computing center. Terminal device 101 communicates with server 102 via a network, which can be any communication network, such as a local area network, a wide area network, or the mobile internet.
[0057] The terminal device 101 may be installed with an application (Application, APP) with a video playback function, for example, the application may be a video application, a browser application, etc. For example, if the application is a video application, the recommended poster may be directly displayed on the display page of the video application. When the recommended poster is selected by the user, the video may be jumped to and played through the display page of the video application based on the one-to-one correspondence between the poster and the video. Alternatively, the application may be a browser, and a page of a video website may be opened in the browser to display the recommended poster on the display page.
[0058] The user can operate the terminal device 101 to send a poster recommendation request to the server 102. Furthermore, the server 102 can use the poster recommendation method in the embodiment of the present invention to recommend posters to the terminal device 101 for the user to view.
[0059] In another application scenario, the user can operate the terminal device 101 to send a poster and video recommendation request to the server 102. Furthermore, the server 102 can use the poster recommendation method in the embodiment of the present invention to recommend the poster to the terminal device 101 while recommending the video corresponding to the poster to the user for the user to watch.
[0060] It should be noted that the application scenarios mentioned above are merely exemplary illustrations for facilitating understanding of the embodiments of the present invention and are not limiting. On the contrary, the embodiments of the present invention can be applied to any applicable poster recommendation scenario, or a scenario where both posters and videos are recommended.
[0061] To further illustrate the technical solution provided by the embodiment of the present invention, it is described in detail below with reference to the accompanying drawings and specific implementation methods.
[0062] See also Figure 2 , which is a flowchart illustrating a first poster recommendation method according to an embodiment of the present invention. This method can be applied to any electronic device, such as a mobile terminal or a server. For ease of description, the following description uses a server as the execution entity, which is not intended to be limiting. The poster recommendation method includes the following steps.
[0063] S21, input the user features, context features, video features of the target user, and poster features of the poster corresponding to the video to be recommended into the pre-trained sorting model, and obtain the user feature vector obtained after the sorting model processes the user features and the output result of the sorting model.
[0064] Among them, the contextual features represent the attribute information of the current scene where the target user is located; the ranking model is trained based on sample user features, sample contextual features, sample video features of the sample video, and sample poster features of the sample poster corresponding to the sample video.
[0065] S22: Calculate the ranking score of the video to be recommended based on the output result.
[0066] The output result represents the probability that the user will take an action on the recommended video. The ranking score is proportional to the probability that the user will take an action on the recommended video. The ranking score is used to represent the user's interest in the recommended video.
[0067] S23: Determine a first number of target recommended videos with the largest ranking scores from the videos to be recommended.
[0068] S24, based on the ranking model and the video identifier of the target recommended video, determining the target poster feature vector of the poster corresponding to each target recommended video.
[0069] S25 , based on the similarity between the user feature vector and the target poster feature vector, determining a target poster corresponding to each target recommended video from the posters corresponding to each target recommended video.
[0070] S26, recommending the target poster corresponding to each target recommended video to the target user.
[0071] In the technical solution provided by the embodiment of the present invention, when recommending posters to users, the target recommended video is first determined based on the ranking model, and the poster features are added when determining the target recommended video. In this way, when determining the target recommended video based on the ranking model, both the user's interest in the video itself and the user's interest in the poster are taken into account, and the target recommended video that the user is interested in is determined from multi-dimensional features. Furthermore, based on the user feature vector produced by the ranking model and the similarity of the target poster feature vector of the poster corresponding to each target recommended video, the target poster recommended to the user is determined. That is, when making poster recommendations, the different interests of different users in different posters are taken into account, and the target poster corresponding to each target recommended video is determined based on the similarity between the user feature vector and the poster feature vector. The target poster determined is more likely to be of interest to the user, thereby achieving personalized poster recommendation for the user.
[0072] Next, the above steps S21 to S26 will be described in detail.
[0073] In step S21, the target user is the user to whom the server recommends a poster. The server determines the target recommended video from the videos to be recommended, which can be the video obtained by the server after the rough video sorting stage. Each video has a corresponding poster, and accordingly, each video to be recommended also has a corresponding poster. For example, one video to be recommended may have 10 posters corresponding to it.
[0074] Specifically, in existing video recommendation systems, there are generally four steps: recall, rough ranking, fine ranking, and re-ranking. Recall means that the server quickly retrieves the second number of videos from the first number of videos in the video pool based on the recall channel. Rough ranking means that the server calls a smaller machine learning model to score the second number of videos one by one, sorts and truncates them according to the scores, and retains the third number of videos with the highest scores. These third number of videos can be used as the videos to be recommended as mentioned above. Here, the scores of the rough ranking can roughly reflect the user's interest in the video. Fine ranking means that the server calls a large-scale deep neural network to score the third number of videos one by one. The scores of the fine ranking can more accurately reflect the user's interest in the video. After the fine ranking, re-ranking can be performed, or no other operations can be performed. Re-ranking is the last step. Here, the fourth number of videos are obtained based on the fine ranking scores, and then the display areas of videos with similar content are set to non-adjacent display areas, and advertisements and operational content are inserted to display them to users. The first number is greater than the second number, the second number is greater than the third number, and the third number is greater than the fourth number. For example, the first number may be 100 million, the second number may be 1,000, the third number may be 100, and the fourth number may be 10. The goal of a video recommendation system is to select dozens of videos that a user is interested in from a large video pool and recommend them to the user.
[0075] The above-mentioned user characteristics can represent the basic attributes of the user. Specifically, the user characteristics may include: user identification (ID), user's gender, age, video types that the user is interested in, director, user account information, such as whether the user is a new user or an old user. Specifically, the user can be determined to be a new user or an old user based on whether the length of time the user has registered the account is greater than a preset length of time. For example, a user whose registration time exceeds one month is determined to be an old user, and a user whose registration time does not exceed one month is determined to be a new user, and the user's daily activity level, etc. In addition, the user characteristics may also include statistical characteristics of the user, such as the number of clicks, likes, and favorites of the user on the video within the preset length of time. Of course, the specific content of the user characteristics may also include other content, and the embodiments of the present invention do not specifically limit this.
[0076] The above-mentioned contextual features, also known as scene features, can represent attribute information of the current scene. Specifically, the contextual features may include: the user's geographic location, the user's mobile phone brand, model, operating system, current time, current date (i.e., whether it is a weekend or a holiday), etc. Of course, the specific content of the contextual features may also include other content, which is not specifically limited in the embodiments of the present invention.
[0077] The above-mentioned video features can represent the basic attributes of the video. Specifically, the video features may include: video ID, video release time, video shooting location, video title, type (such as variety show, movie, TV series, etc.), keywords, director, actor, screenwriter, photography, and video clarity. In addition, the above-mentioned video features may also include statistical features of the video, such as the video's exposure, number of clicks, number of likes, and number of favorites within a preset duration. Of course, the specific content of the video features may also include other content, and the embodiments of the present invention do not specifically limit this.
[0078] The above-mentioned poster features can represent the basic attributes of the poster. Specifically, the poster features may include: poster ID, poster size, theme, protagonist, resolution, poster description, etc. Furthermore, the above-mentioned poster features may also include statistical features of the poster, such as the number of impressions, clicks, likes, and favorites within a preset time period. Of course, the specific content of the poster features may also include other content, which is not specifically limited in this embodiment of the present invention.
[0079] The aforementioned user features, contextual features, video features, and poster features can be further divided into static features and dynamic features. Static features are features that do not change over time. Static features can be pre-stored to reduce the time and computing resources required to acquire features in real time. For example, the user's gender and video type mentioned above are static features. Dynamic features are features that change. The aforementioned contextual features, including the current time, user statistics, video statistics, and poster statistics, are all dynamic features and require real-time acquisition.
[0080] In an embodiment of the present invention, after receiving a recommendation request from a target user, the server can obtain the target user's user characteristics, contextual characteristics, video characteristics of the video to be recommended, and poster characteristics of the poster corresponding to the video to be recommended. For static features among these characteristics, the server can obtain them from a database storing these static features. For dynamic features among these characteristics, the user's terminal can obtain these dynamic features in real time and include them in the recommendation request. After receiving the recommendation request, the server extracts the dynamic features from the recommendation request and compiles statistics on the dynamic features of different users to obtain dynamic features used for poster recommendation. Alternatively, the server can obtain these dynamic features in real time.
[0081] The ranking model can be a large-scale deep learning network. In this embodiment of the present invention, sample poster features are incorporated into the ranking model training process. Accordingly, when the server calls the ranking model, the poster features are also incorporated into the ranking model input. This allows the recommendation model to consider both the user's interest in the video itself and the user's interest in the poster when recommending videos to the user. This allows the model to more accurately identify videos that the user is interested in, providing a basis for subsequently recommending posters of interest to the user.
[0082] In this embodiment of the present invention, the server inputs the acquired user features, context features, video features, and poster features into a pre-trained ranking model. Since the ranking model can process vectorized data, the intermediate network layer of the ranking model performs vectorized encoding on the input feature data to obtain a feature vector (embedding), which is then input into a deeper network layer for subsequent processing. Specifically, the intermediate network layer may be an embedding layer, which is not specifically limited in this embodiment of the present invention.
[0083] In the embodiment of the present invention, the server may obtain the user feature vector obtained after the middle layer of the ranking model processes the user features, so as to be used in the subsequent determination of the target poster corresponding to the target recommended video.
[0084] In one embodiment of the present invention, the ranking model can be a multi-objective fusion ranking model. Specifically, the output layer of the ranking model can output estimated values for a click-through rate (indicating the likelihood of a user clicking on a video), a like rate (indicating the likelihood of a user liking a video), a favorite rate (indicating the likelihood of a user adding a video to a favorite), and a forwarding rate (indicating the likelihood of a user forwarding a video). These four estimated values can be real numbers between zero and one. The ranking model primarily relies on these four estimated values to reflect the user's level of interest in the video. The server can obtain the output results of the recommendation model's output layer, namely the four estimated values, to facilitate subsequent calculation of the ranking score of the recommended video based on these four estimated values.
[0085] In another embodiment of the present invention, the ranking model may be a click-through-rate (CTR) model. Specifically, the output layer of the ranking model outputs a CTR estimate, which indicates the likelihood of a user clicking on a video. This estimate can reflect the probability of a user clicking on the video. The server can obtain the output of the recommendation model's output layer, namely the CTR estimate, to facilitate subsequent calculation of the ranking score of the recommended video based on the CTR estimate.
[0086] In step S22, the ranking score may indicate the likelihood of the user performing an action on the recommended video. Specifically, the action performed on the recommended video may include at least one of the following: clicking on the video, forwarding the video, liking the video, or adding the video to favorites.
[0087] In one embodiment of the present invention, if the output result of the output layer of the recommendation model obtained by the server is: estimated values of click rate, like rate, collection rate, and forwarding rate, the server can perform weighted operations on these four estimated values to obtain a ranking score for each video to be recommended. The weights of these four estimated values can be set according to specific needs.
[0088] In another embodiment of the present invention, if the output result of the recommendation model output layer obtained by the server is: an estimated value of the click-through rate, the server can perform a normalization operation on the estimated value so as to convert the estimated click-through rate into a ranking score to obtain a ranking score for each video to be recommended.
[0089] In the above step S23, since the ranking score can indicate the possibility of the user performing an operation on the recommended video, that is, the larger the ranking score of a video, the greater the probability that the target user will perform an operation on the video, which also indicates that the target user is more interested in the video.
[0090] The first number can be set according to actual needs. In one embodiment of the present invention, the first number can be set to the number of videos ultimately recommended to the user. For example, if the number of videos ultimately recommended to the user is 10, the server can determine the top 10 videos with the highest ranking scores from the videos to be recommended as the target recommended videos.
[0091] In another embodiment of the present invention, after determining a first number of target recommended videos with the highest ranking scores, the server needs to further re-rank these target recommended videos. Therefore, the first number can be set to a value greater than the number of videos ultimately recommended to the user. For example, if the number of videos ultimately recommended to the user is 10, the server can determine the top 20 videos with the highest ranking scores from the videos to be recommended as target recommended videos.
[0092] In step S24, the target poster feature vector is the poster feature vector of the poster corresponding to the target recommended video. For example, if a target recommended video A has three posters corresponding to it: Poster 1, Poster 2, and Poster 3, then the poster feature vectors corresponding to Poster 1, Poster 2, and Poster 3 are the target poster feature vectors of the poster corresponding to target recommended video A.
[0093] In an embodiment of the present invention, a target recommended video may correspond to multiple posters, but different users have different levels of interest in different posters. Therefore, it is necessary to determine the target poster feature vector of the poster corresponding to each target recommended video, and then subsequently determine the target poster that the user is most interested in based on the target poster feature vector. Specifically, the video identifier of the target recommended video and the poster identifier of the poster corresponding to the target recommended video have a corresponding relationship. The server can determine the poster feature vector of the poster corresponding to the video to be recommended based on the ranking model, and then determine the target poster feature vector of the poster corresponding to each target recommended video from the poster feature vector of the poster corresponding to the video to be recommended based on the video identifier of the target recommended video.
[0094] In one embodiment of the present invention, since the poster features input by the server when calling the sorting model are the poster features of the poster corresponding to the video to be recommended, the server can obtain the user feature vector obtained after the middle layer of the sorting model processes the user features, and at the same time obtain the poster feature vector obtained after the middle layer of the sorting model processes the poster features. These poster feature vectors are the poster feature vectors of the poster corresponding to the video to be recommended. Then, the server can determine the target poster feature vector of the poster corresponding to each target recommended video from these poster feature vectors based on the target recommended video identifier and the correspondence between the video identifier of the target recommended video and the poster identifier of the poster corresponding to the target recommended video.
[0095] In another embodiment of the present invention, poster feature vectors corresponding to different posters may be pre-stored, and the server may determine a target poster feature vector for each target recommended video from the pre-stored poster feature vectors. The specific implementation process of this embodiment is described below.
[0096] In step S25, the target poster, i.e., the poster corresponding to the target recommended video, is the one that the user is most interested in. A target recommended video may correspond to multiple posters, but different users may have different levels of interest in different posters. For example, a movie has three posters, with stars A, B, and C printed on posters 1, 2, and 3, respectively. If user A likes star A, user A will be more interested in poster A, so poster 1 is recommended to user A, and the probability of user A clicking on it will be higher. If user B likes star B, user B will be more interested in poster 2, so poster 2 is recommended to user B, and the probability of user B clicking on it will be higher.
[0097] The similarity between the user feature vector and the target poster feature vector can reflect the degree of user interest in these posters. Therefore, the server can determine the target poster corresponding to each target recommended video from the posters corresponding to each target recommended video based on the similarity between the user feature vector and the target poster feature vector.
[0098] In addition, due to the massive number of videos, each video corresponds to multiple posters, that is, the order of magnitude of the posters is large. Correspondingly, the order of magnitude of the poster feature vectors corresponding to the posters is also large. Determining the poster feature vectors of large order of magnitude and calculating the similarity between the user feature vector and the poster feature vectors of large order of magnitude will inevitably consume more computing resources. Therefore, in an embodiment of the present invention, the server first determines the target recommended video, then determines the poster feature vector of the poster corresponding to the target recommended video, and calculates the similarity between the user feature vector and the poster feature vector of the poster corresponding to the target recommended video. This significantly reduces the amount of calculation and saves computing resources.
[0099] In one embodiment of the present invention, for each target recommended video, the server may calculate the Euclidean distance between the user feature vector and the target poster feature vector, and determine the poster corresponding to the target poster feature vector closest to the user feature vector as the target poster corresponding to the target video.
[0100] In another embodiment of the present invention, the server may calculate the similarity between the user feature vector and the target poster feature vector, and determine the target poster corresponding to each target recommended video from the posters corresponding to each target recommended video, as described below for details.
[0101] It should be noted that, in the embodiment of the present invention, the method based on the similarity between the user feature vector and the target poster feature vector is not specifically limited.
[0102] In the above step S26, after determining the target poster corresponding to each target recommended video, the server recommends the target poster corresponding to each target recommended video to the target user, and then the target user can watch the target poster corresponding to each target recommended video based on the corresponding application on the terminal device.
[0103] Since there is a unique correspondence between the poster and the video, that is, the video corresponding to the poster can be uniquely determined based on the poster. Therefore, when a user browses and clicks a poster on the video app, the video app can also jump to the video corresponding to the poster based on the unique correspondence between the poster and the video for the user to watch.
[0104] See also Figure 3, which is a flow chart of a second poster recommendation method provided by an embodiment of the present invention, the method includes steps S31 to S36, wherein step S36 is a refinement of the above-mentioned step S26, and steps S31 to S35 are the same as the above-mentioned steps S21 to S25.
[0105] S36, recommending each target recommended video and the target poster corresponding to each target recommended video to the target user.
[0106] In the related art, when recommending both posters and videos, the server needs to call two independent services to complete the poster and video recommendations. The first service call involves the server invoking the recommendation model and determining the top N videos of high user interest based on the model's output. The second service call involves the server selecting a poster from the M corresponding posters based on the MAB algorithm for a tentative recommendation of any of the N videos. However, using this poster and video recommendation method, the server needs to call two independent services to complete the poster and video recommendations, resulting in a long processing time.
[0107] Therefore, in an embodiment of the present invention, after determining the target recommended videos and the target posters corresponding to each target recommended video, the server can recommend each target recommended video and the target posters corresponding to each target recommended video to the target user. The target user can then watch the target recommended videos and target posters based on the corresponding APP application on the terminal device. Specifically, the target recommended videos and the posters corresponding to the target recommended videos can be displayed to the user in a stacked manner, that is, after the user clicks on the target poster, they can jump to the corresponding target recommended video page.
[0108] As can be seen from the above embodiments, in the technical solution provided by the embodiment of the present invention, while determining the target recommended video based on the output result of the ranking model, the user features are processed based on the ranking model to obtain the user feature vector, and then based on the user feature vector and the target poster feature vector of the poster corresponding to each target recommended video, the target poster corresponding to the target recommended video is obtained. Since the user's feature vector and the target poster feature vector are by-products of the ranking model output, there is no need to re-call another service to obtain them. Therefore, in the technical solution provided by the embodiment of the present invention, in an independent service, not only the target recommended video can be determined, but also the target recommended poster corresponding to the target recommended video can be determined, and then each target recommended video and the target poster corresponding to each target recommended video can be recommended to the target user at the same time, realizing the simultaneous recommendation of videos and posters in one service. Compared with calling two independent services to recommend videos and posters in the related art, the time consumption and computing resources of video and poster recommendations are reduced.
[0109] In one embodiment of the present invention, the above step S25 can be implemented based on the following steps A and B.
[0110] Step A: For each target recommended video, calculate the cosine similarity between the user feature vector and the target poster feature vector corresponding to the target recommended video.
[0111] Step B: Determine the poster corresponding to the target poster feature vector with the highest cosine similarity as the target poster corresponding to the target video.
[0112] For each target recommended video, the server can calculate the cosine similarity between the user feature vector and the target poster feature vector corresponding to the target recommended video, and determine the poster corresponding to the target poster feature vector with the highest cosine similarity as the target poster corresponding to the target video. The highest cosine similarity between a user feature vector and a target poster feature vector indicates that the closer the distance between the target poster feature vector and the user feature vector in space, the higher the similarity between the target poster feature vector and the user feature vector, and the greater the probability that the poster corresponding to the target poster feature vector is the poster that the user is interested in. Since the method for calculating cosine similarity is relatively well known, it will not be repeated here.
[0113] It can be seen from the above embodiments that in the embodiments of the present invention, the poster corresponding to the target poster feature vector with the highest cosine similarity is determined as the target poster corresponding to the target video. The cosine similarity can represent the degree of similarity between the two feature vectors, and then the poster corresponding to the target poster feature vector with the highest cosine similarity is determined as the target poster corresponding to the target video. The probability that the target poster is the poster that the user is interested in is higher, and the target poster is recommended to the target user, which means that personalized poster recommendation to the user is achieved.
[0114] See also Figure 4 , which is a flow chart of a third poster recommendation method provided by an embodiment of the present invention, the method includes steps S41 to S47, wherein steps S44 to S45 are refinements of the above-mentioned step S24, steps S41 to S43 are the same as the above-mentioned steps S21 to S23, and steps S46 to S47 are the same as the above-mentioned steps S25 to S26.
[0115] S44 , inputting the first poster feature into the ranking model, obtaining and storing a poster feature vector obtained after the ranking model processes the first poster feature.
[0116] Among them, the first poster feature is the poster feature of the poster corresponding to the video to be recommended.
[0117] Each time the server determines the target poster for a target user, it only uses one user feature vector, but it may require hundreds or even thousands of poster feature vectors. The computational complexity of obtaining one user feature vector in real time based on the sorting model is not large. However, if the sorting model is used to obtain thousands of poster feature vectors in real time, the computational complexity is still relatively large. Considering that most poster features are static features and will not change over a period of time, correspondingly, the poster feature vectors rarely change. Therefore, in an embodiment of the present invention, the server can input the poster features of the poster corresponding to the video to be recommended into the sorting model before the sorting model goes online, and obtain and store the poster feature vectors of the poster corresponding to the video to be recommended by the sorting model offline.
[0118] Specifically, after the ranking model is trained, the server can store poster feature vectors offline. The number of videos to be recommended is large, and the number of posters corresponding to the videos to be recommended is even larger. Before the ranking model is used online, the server can pre-input the poster features of the posters corresponding to the videos to be recommended into the ranking model, and obtain the poster feature vectors obtained after the intermediate layer of the ranking model processes the poster features of the video corresponding posters. Furthermore, after obtaining a large number of poster feature vectors, the server can store the poster ID and poster feature vector as a binary tuple in the database to facilitate the subsequent server to determine the target poster.
[0119] Since new videos to be recommended are constantly generated, correspondingly, the new videos to be recommended will also correspond to newly added posters, or new posters will be added to previous videos. Therefore, in order to be able to obtain the newly added poster feature vectors in a timely manner, in an embodiment of the present invention, the server can obtain the poster features of the newly added posters according to a preset period, and input the poster features of the newly added posters into the trained sorting model, and obtain the newly added poster feature vectors obtained after the middle layer of the sorting model processes the poster features of the newly added posters. Here, the preset period can be set according to actual needs, such as setting it to 1 day, and the newly added posters can include posters corresponding to the newly generated videos, as well as newly added posters for the previous videos. This ensures the richness of the pre-stored poster feature vectors and provides a basis for determining the target poster corresponding to each target video recommendation.
[0120] S45 , determining a target poster feature vector of a poster corresponding to each target recommended video from pre-stored poster feature vectors according to the video identifier of the target recommended video.
[0121] The video identifier of the target recommended video has a corresponding relationship with the poster identifier of the poster corresponding to the target recommended video. The server can use the video identifier of the target recommended video to determine the target poster feature vector of the poster corresponding to each target recommended video from the pre-stored poster feature vector, thereby reducing the computational complexity of the sorting model and improving the efficiency of poster recommendation.
[0122] It can be seen from the above embodiments that in the embodiments of the present invention, before the sorting model is put online, the poster feature vectors of the posters corresponding to the videos to be recommended are obtained and stored offline. Based on the identification of the target video, the target poster feature vectors of the posters corresponding to each target recommended video are determined from the stored poster feature vectors. Compared with obtaining the poster feature vectors in real time, the computational complexity of the sorting model is reduced and the efficiency of poster recommendation is improved.
[0123] In one embodiment of the present invention, in order to further save computing resources of the sorting model, the above step S45 can be implemented based on step three.
[0124] Step three: input the second poster feature into the ranking model, and obtain and store a poster feature vector obtained after the ranking model processes the second poster feature.
[0125] The second poster feature is at least one poster attribute information in the first poster feature. The first poster feature includes multiple attribute information used to describe the poster's attributes. A poster feature may include multiple attribute information used to describe the poster's attributes. For example, a poster's poster features may include: poster ID, poster size, theme, protagonist, resolution, poster description, etc., all of which are attribute information describing the poster's attributes.
[0126] In an embodiment of the present invention, to further conserve the computing resources of the ranking model, for any poster corresponding to any video to be recommended, the server may not input every attribute information in the poster features of the poster into the ranking model to obtain a poster feature vector. Instead, the server may input only some attribute information in the poster features into the ranking model to obtain a poster feature vector. For example, the server may input only the poster ID into the ranking model, and then process the poster ID based on the intermediate layer of the ranking model to obtain a poster ID feature vector. The obtained poster ID feature vector can be used as the poster feature vector described above.
[0127] As can be seen from the above embodiments, in the embodiments of the present invention, the server may input only part of the attribute information in the poster features into the ranking model to obtain the poster feature vector, thereby further reducing the computational complexity of the ranking model and improving the efficiency of poster recommendation.
[0128] In one embodiment of the present invention, to improve user experience, after determining a first number of target recommended videos with the largest ranking scores, the server may process the target recommended videos in at least one of the following ways before recommending the target recommended videos to the target user:
[0129] Method 1: If there are multiple duplicate videos, one of the multiple duplicate videos is retained as the target recommended video.
[0130] The duplicate videos are videos whose content similarity with the target recommended videos exceeds a first preset threshold. The first preset threshold can be set based on actual needs, for example, the first preset threshold can be set to 100%. If the content similarity of multiple videos is too high, recommending all videos with such high content similarity to the user will result in a poor viewing experience. Therefore, in an embodiment of the present invention, if there are duplicate videos with content repetition exceeding the first preset threshold, the server will only retain one of the multiple duplicate videos as the target recommended video to enhance the user's viewing experience.
[0131] In one embodiment of the present invention, the server may extract video features from different videos and calculate the similarity between these video features. If the similarity between the video features of two videos exceeds a preset similarity threshold, the two videos may be considered duplicate videos. Of course, other methods may also be used to determine duplicate videos, and the embodiment of the present invention does not specifically limit the method for determining duplicate videos.
[0132] Method 2: remove videos whose video clarity is lower than a second preset threshold from the target recommended videos.
[0133] The second preset threshold can be set based on actual needs, for example, the second preset threshold can be set to 360P. If the clarity of a video is too low, to ensure the quality of the video recommended to the user, in an embodiment of the present invention, the server can remove videos with a clarity lower than the second preset threshold from the target videos, thereby recommending videos with higher clarity from the target recommended videos to the user, thereby improving the user's user experience.
[0134] Method three: setting the display areas of target recommended videos of the same type to non-adjacent areas.
[0135] When recommending videos to users, placing the display areas for videos of the same type in adjacent areas can make users feel that the videos are too homogeneous, reducing their interest in watching videos and giving them a poor viewing experience. For example, according to the ranking and rating above, the top five videos are all anime-themed. If these five videos of the same type are placed in adjacent areas and displayed to the user, even if the user is anime-enthusiast, they will not want to see homogeneous content. Therefore, in an embodiment of the present invention, the display areas for target recommended videos of the same type are set to non-adjacent areas to improve the user's viewing experience.
[0136] As can be seen from the above embodiments, in the embodiments of the present invention, after obtaining the first number of target recommended videos with the largest ranking scores, the server performs at least one of the following processing on the target recommended videos: deleting duplicate videos, removing low-definition videos, and homogenizing video dispersion, thereby improving the user's viewing experience.
[0137] To further understand the poster recommendation method provided by the embodiment of the present invention, Figure 5 The method is further explained.
[0138] See also Figure 5 , which is a schematic diagram of the framework of the first poster recommendation method provided by an embodiment of the present invention. When the ranking model training is completed, the server obtains poster feature vectors of a large number of posters offline based on the ranking model and stores the poster feature vectors and poster IDs in a database as tuples.
[0139] After the sorting model is launched, the server (engine service) calls the sorting model online, and inputs the user features and context features of the target user, the video features of the video to be recommended, and the poster features of the poster corresponding to the video to be recommended into the sorting model. Then, the first number of target recommended videos to be recommended to the user and the by-product of the sorting model, namely the user feature vector, can be determined.
[0140] After determining the target recommended video, the server obtains the target poster feature vector of the poster corresponding to each target recommended video from the database. For each target recommended video, the server calculates the user feature vector and the target poster feature vector and cosine similarity under each target recommended video, and takes the target poster feature vector with the largest cosine similarity as the target poster of the target recommended video.
[0141] After determining the target recommended videos and the target posters corresponding to each target recommended video, the server recommends the target posters corresponding to each target recommended video to the terminal device used by the target user.
[0142] Alternatively, the server pushes each target recommended video and the target poster corresponding to each target recommended video to the terminal device used by the target user.
[0143] It can be seen from the above embodiments that the technical solution provided by the embodiments of the present invention is that after the sorting model training is completed, the server obtains the feature vectors of each poster offline based on the sorting model and stores them in advance, which reduces the time and computing resources in determining the target poster, and thus reduces the time and computing resources in personalized recommendation of videos and posters to users.
[0144] The poster recommendation method provided by the embodiment of the present invention is described below in conjunction with specific usage scenarios.
[0145] See also Figure 6 , which is a schematic diagram of the framework of the second poster recommendation method provided by an embodiment of the present invention.
[0146] like Figure 6The right half of the dashed line shows the training process for the ranking model. The server (engine service) can collect user behaviors from numerous sample users based on the terminal, such as a sample user's actions on a sample video and its corresponding sample poster at a specific moment. Labels are then constructed based on these user behaviors. Labels here can be understood as prediction targets for the ranking model, such as the click-through rate of the sample video and sample poster. Based on sample user features, sample context features, sample video features, sample poster features of the sample video's corresponding sample poster, and the constructed labels, corresponding training samples are constructed. The ranking model is then trained based on these training samples.
[0147] like Figure 6 The middle part of the dotted line shows the process of determining the target recommended video and target poster based on the sorting model. After the sorting model training is completed, the server loads the sorting model, estimates the poster feature vector offline and stores it in the database (filling library). After receiving the recommendation request of the target user, the server obtains the user features, context features of the target user, the video features of the video to be recommended and the poster features of the poster corresponding to the video to be recommended based on the recommendation request and the feature library that stores static features, and inputs them into the pre-trained sorting model. The server obtains the first number of target recommended videos based on the output result of the output layer of the sorting model, and obtains the user feature vector based on the intermediate layer of the sorting model, and then determines the target poster corresponding to each target recommended video according to the similarity between the user feature vector and the target feature vector pre-stored in the database.
[0148] like Figure 6 The left side of the dashed line shows the process of the server pushing the target poster (and target recommended video) to the target user. The target user sends a recommendation request to the server via a terminal device, and the server responds to the target user's recommendation request by returning the target poster (and target recommended video) to the target user.
[0149] In the technical solution provided by the embodiment of the present invention, when recommending posters to a user, the target poster to be recommended to the user is determined based on the similarity between the user's feature vector and the target poster's feature vector. In other words, when making poster recommendations, the user's interest in the poster is taken into account, and the probability that the target poster determined is of interest to the user is higher, thereby achieving personalized poster recommendations for the user. In addition, in the technical solution provided by the embodiment of the present invention, when determining the target recommended video based on the recommendation model, the poster features are incorporated. In this way, when recommending videos to the user based on the recommendation model, both the user's interest in the video itself and the user's interest in the poster are taken into account, further achieving personalized video recommendations for the user.
[0150] In addition, in the technical solution provided by the embodiment of the present invention, while determining the target recommended video based on the output of the ranking model, the user features are processed based on the intermediate layer of the ranking model to obtain a user feature vector, and then based on the user feature vector and the target poster vector of the poster corresponding to each target recommended video, the target poster corresponding to the target video is obtained. Since the user's feature vector is a by-product of the ranking model output, there is no need to call another service to obtain it. Therefore, in the technical solution provided by the embodiment of the present invention, in the video recommendation service, not only the target recommended video can be determined, but also the target recommended poster corresponding to the target recommended video can be determined, realizing the simultaneous recommendation of videos and posters in one service. Compared with calling two independent services to recommend videos and posters in the related art, the time consumption and computing resources of video and poster recommendations are reduced.
[0151] Based on the same inventive concept, the embodiment of the present invention also provides a poster recommendation device. Figure 7 , is a schematic structural diagram of a poster recommendation device provided by an embodiment of the present invention, the recommendation device comprising:
[0152] Feature input module 71 is used to input the user features, context features, video features of the video to be recommended, and poster features of the poster corresponding to the video to be recommended into a pre-trained ranking model, and obtain a user feature vector obtained after the ranking model processes the user features and the output result of the ranking model; wherein the context features represent attribute information of the current scene where the target user is located; the ranking model is trained based on sample user features, sample context features, sample video features of sample videos, and sample poster features of sample posters corresponding to the sample videos;
[0153] A ranking score calculation module 72 is configured to calculate a ranking score for the video to be recommended based on the output result; wherein the output result represents the probability that the user will operate on the video to be recommended, the ranking score is proportional to the probability that the user will operate on the video to be recommended, and the ranking score is used to represent the user's interest in the recommended video;
[0154] A target recommended video determination module 73 is configured to determine a first number of target recommended videos with the largest ranking scores from the videos to be recommended;
[0155] A target poster feature vector determination module 74 is configured to determine a target poster feature vector of a poster corresponding to each target recommended video based on the ranking model and the video identifier of the target recommended video;
[0156] a target poster selection module 75 for determining a target poster corresponding to each target recommended video from posters corresponding to each target recommended video based on the similarity between the user feature vector and the target poster feature vector;
[0157] The poster recommendation module 76 is used to recommend the target poster corresponding to each target recommended video to the target user.
[0158] In one embodiment of the present invention, the poster recommendation module 76 is specifically configured to:
[0159] Recommend each target recommended video and the target poster corresponding to each target recommended video to the target user.
[0160] In one embodiment of the present invention, the target poster selection module 75 is specifically configured to:
[0161] For each target recommended video, calculating the cosine similarity between the user feature vector and the target poster feature vector corresponding to the target recommended video;
[0162] The poster corresponding to the target poster feature vector with the highest cosine similarity is determined as the target poster corresponding to the target video.
[0163] In one embodiment of the present invention, the target poster feature vector determination module 74 includes:
[0164] A first poster feature input submodule, configured to input a first poster feature into the ranking model, and obtain and store a poster feature vector obtained after the ranking model processes the first poster feature, where the first poster feature is a poster feature of the poster corresponding to the video to be recommended;
[0165] The target poster feature vector determination submodule is used to determine the target poster feature vector of the poster corresponding to each target recommended video from the pre-stored poster feature vectors according to the video identifier of the target recommended video.
[0166] In one embodiment of the present invention, the first poster feature input submodule is specifically configured to:
[0167] The second poster feature is input into the sorting model, and a poster feature vector obtained after the sorting model processes the second poster feature is obtained and stored, where the second poster feature is at least one poster attribute information in the first poster feature, and the first poster feature includes a plurality of attribute information for describing poster attributes.
[0168] In one embodiment of the present invention, the apparatus further includes a target recommended video processing module configured to, after determining a first number of target recommended videos with the largest ranking scores from the videos to be recommended, process the target recommended videos in at least one of the following ways:
[0169] If there are multiple duplicate videos, retain one of the multiple duplicate videos as the target recommended video, where the duplicate video is a video whose content similarity with the target recommended video is higher than a first preset threshold;
[0170] Removing videos whose video clarity is lower than a second preset threshold from the target recommended videos;
[0171] Set the display areas of target recommended videos of the same type to non-adjacent areas.
[0172] In the technical solution provided by the embodiment of the present invention, when recommending posters to users, the target recommended video is first determined based on the recommendation model, and the poster features are added when determining the target recommended video. In this way, when determining the target recommended video based on the recommendation model, both the user's interest in the video itself and the user's interest in the poster are taken into account, and the target recommended video that the user is interested in is determined from multi-dimensional features. Furthermore, based on the user feature vector produced by the ranking model and the similarity of the target poster feature vector of the poster corresponding to each target recommended video, the target poster recommended to the user is determined. That is, when making poster recommendations, the different interests of different users in different posters are taken into account, and the target poster corresponding to each target recommended video is determined based on the similarity between the user feature vector and the poster feature vector. The target poster determined is more likely to be of interest to the user, thereby achieving personalized poster recommendation for the user.
[0173] The embodiment of the present invention further provides an electronic device, such as Figure 8 As shown, it includes a processor 81, a communication interface 82, a memory 83 and a communication bus 84, wherein the processor 81, the communication interface 82, and the memory 83 communicate with each other through the communication bus 84.
[0174] Memory 83, for storing computer programs;
[0175] The processor 81 is configured to implement any of the poster recommendation methods described in the above embodiments when executing the program stored in the memory 83 .
[0176] The communication bus mentioned in the terminal can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. This communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is used in the figure, but this does not mean that there is only one bus or only one type of bus.
[0177] The communication interface is used for communication between the above terminal and other devices.
[0178] The memory may include random access memory (RAM) or non-volatile memory, such as at least one disk storage. Alternatively, the memory may be at least one storage device located away from the processor.
[0179] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, and discrete hardware components.
[0180] In another embodiment of the present invention, a computer-readable storage medium is provided, wherein a computer program is stored in the computer-readable storage medium. When the computer program is executed by a processor, the poster recommendation method described in any one of the above embodiments is implemented.
[0181] In another embodiment of the present invention, a computer program product including instructions is provided. When the computer program product is executed on a computer, the computer is enabled to execute the poster recommendation method described in any one of the above embodiments.
[0182] In the above embodiments, all or part of the embodiments can be implemented by software, hardware, firmware, or any combination thereof. When implemented using software, all or part of the embodiments can be implemented in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of the present invention are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via a wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) method. The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server or data center that includes one or more available media. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state drive (SSD)).
[0183] It should be noted that, in this document, relational terms such as first and second, etc., are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply the existence of any such actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article, or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or device. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, method, article, or device comprising the element.
[0184] Each embodiment in this specification is described in a related manner. Similar portions between the various embodiments can be referenced to each other. Each embodiment focuses on the differences between the other embodiments. In particular, since the apparatus embodiments, electronic device embodiments, and computer storage medium embodiments are generally similar to the method embodiments, their descriptions are relatively simple. For related portions, reference can be made to the descriptions of the method embodiments.
[0185] The above description is only a preferred embodiment of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention are included in the scope of protection of the present invention.
Claims
1. A poster recommendation method, characterized in that: The method comprises: Inputting the target user's user features, context features, video features of the video to be recommended, and poster features of the poster corresponding to the video to be recommended into a pre-trained ranking model, obtaining a user feature vector obtained after the ranking model processes the user features and an output result of the ranking model; wherein the context features represent attribute information of the current scene where the target user is located; the ranking model is trained based on sample user features, sample context features, sample video features of sample videos, and sample poster features of sample posters corresponding to the sample videos; Calculating a ranking score for the video to be recommended based on the output result, wherein the output result represents a probability that the user will operate on the video to be recommended, the ranking score is proportional to the probability that the user will operate on the video to be recommended, and the ranking score is used to represent the user's interest in the recommended video; Determining a first number of target recommended videos with the largest ranking scores from the videos to be recommended; Determining a target poster feature vector of a poster corresponding to each target recommended video based on the ranking model and the video identifier of the target recommended video; Determining a target poster corresponding to each target recommended video from posters corresponding to each target recommended video based on a similarity between the user feature vector and the target poster feature vector; Recommend the target poster corresponding to each target recommended video to the target user.
2. The method according to claim 1, characterized in that The step of recommending a target poster corresponding to each target recommended video to the target user includes: Recommend each target recommended video and the target poster corresponding to each target recommended video to the target user.
3. The method according to claim 1, characterized in that The determining, based on the similarity between the user feature vector and the target poster feature vector, a target poster corresponding to each target recommended video from posters corresponding to each target recommended video, includes: For each target recommended video, calculating the cosine similarity between the user feature vector and the target poster feature vector corresponding to the target recommended video; The poster corresponding to the target poster feature vector with the highest cosine similarity is determined as the target poster corresponding to the target video.
4. The method according to claim 1, wherein The step of determining a target poster feature vector of a poster corresponding to each target recommended video based on the ranking model and the video identifier of the target recommended video includes: Inputting a first poster feature into the ranking model, obtaining and storing a poster feature vector obtained after the ranking model processes the first poster feature, where the first poster feature is a poster feature of a poster corresponding to the video to be recommended; According to the video identifier of the target recommended video, a target poster feature vector of the poster corresponding to each target recommended video is determined from pre-stored poster feature vectors.
5. The method according to claim 4, characterized in that Inputting the first poster feature into the ranking model, and obtaining and storing a poster feature vector obtained after the ranking model processes the first poster feature, includes: The second poster feature is input into the sorting model, and a poster feature vector obtained after the sorting model processes the second poster feature is obtained and stored, where the second poster feature is at least one poster attribute information in the first poster feature, and the first poster feature includes a plurality of attribute information for describing poster attributes.
6. The method according to any one of claims 1 to 5, characterized in that After determining a first number of target recommended videos with the largest ranking scores from the videos to be recommended, the method further includes: The target recommended video is processed in at least one of the following ways: If there are multiple duplicate videos, retain one of the multiple duplicate videos as the target recommended video, where the duplicate video is a video whose content similarity with the target recommended video is higher than a first preset threshold; Removing videos whose video clarity is lower than a second preset threshold from the target recommended videos; Set the display areas of target recommended videos of the same type to non-adjacent areas.
7. A poster recommendation device, characterized in that: The device comprises: A feature input module is configured to input user features, context features, video features of the target user, and poster features of the poster corresponding to the target video into a pre-trained ranking model, thereby obtaining a user feature vector obtained by processing the user features by the ranking model, and an output result of the ranking model; wherein the context features represent attribute information of the current scene in which the target user is located; and the ranking model is trained based on sample user features, sample context features, sample video features of sample videos, and sample poster features of sample posters corresponding to the sample videos; a ranking score calculation module, configured to calculate a ranking score for the video to be recommended based on the output result; wherein the output result represents a probability that the user will operate on the video to be recommended, the ranking score is proportional to the probability that the user will operate on the video to be recommended, and the ranking score is used to represent the user's interest in the recommended video; a target recommended video determination module, configured to determine a first number of target recommended videos having the largest ranking scores from the videos to be recommended; a target poster feature vector determination module, configured to determine a target poster feature vector of a poster corresponding to each target recommended video based on the ranking model and the video identifier of the target recommended video; a target poster selection module, configured to determine a target poster corresponding to each target recommended video from posters corresponding to each target recommended video based on a similarity between the user feature vector and the target poster feature vector; The poster recommendation module is used to recommend the target poster corresponding to each target recommended video to the target user.
8. The device according to claim 7, characterized in that The poster recommendation module is specifically used to recommend each target recommended video and the target poster corresponding to each target recommended video to the target user.
9. An electronic device, characterized in that: It includes a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus; Memory for storing computer programs; A processor, configured to implement the method steps described in any one of claims 1 to 6 when executing a program stored in a memory.
10. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method steps of any one of claims 1 to 6 are implemented.