Media diversity recommendation method and device, computer device and storage medium
By cross-processing the neighbor node representation vectors of media and objects in the network node graph and determining the diversity index, the problems of insufficient media recommendation accuracy and diversity in traditional recommendation schemes are solved, and the interaction rate between objects and media is improved.
Patent Information
- Application Number
- CN202210707062.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-21
- Publication Date
- 2025-10-10
- Estimated Expiration
- 2042-06-21
AI Technical Summary
Traditional media recommendation solutions are accuracy-oriented, which leads to excessive recommendations of similar media and affects the interaction rate between the subject and the media.
The neighbor nodes of media nodes and object nodes are extracted from the network node graph, and their representation vectors are cross-processed to determine the diversity index of the target object. Based on this index, different media types are selected from the candidate media for recommendation.
It improves the accuracy and diversity of media recommendations and enhances the interaction rate between target objects and recommended media, such as click-through rate and play rate.
Smart Images

Figure CN117312646B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of artificial intelligence technology, and in particular to a method, apparatus, computer device, storage medium, and computer program product for recommending media diversity. Background Art
[0002] With the rapid increase in the amount of information, in order to avoid the difficulty of finding the required media in the massive media, recommendation technology is used to predict the media that the target object may be interested in and then make recommendations.
[0003] Traditional recommendation schemes primarily employ graph neural network-based recommendation systems, constructing media and objects into a graph structure and representing them with embedding vectors. Through interactive supervised learning, optimized embedding vectors are learned. These systems then predict media that the target subject may be interested in from uninteracted candidate media. However, these recommendation schemes prioritize media accuracy, resulting in a high number of recommended similar media and a reduced interaction rate between the subject and the media. Summary of the Invention
[0004] Based on this, it is necessary to provide a media diversity recommendation method, apparatus, computer device, computer-readable storage medium and computer program product to address the above technical issues, which can increase the interaction rate between the object and the recommended media.
[0005] In a first aspect, the present application provides a method for recommending media diversity. The method comprises:
[0006] Extracting neighbor nodes of each order corresponding to the media node and the object node in the first network node graph; the object node and the media node are nodes corresponding to the target object and the candidate media respectively;
[0007] Cross-processing the representation vectors corresponding to the neighboring nodes of each order of the media node with the representation vectors corresponding to the neighboring nodes of each order of the object node to obtain a cross-vector;
[0008] Determining a diversity index of the target object based on a media set with which the target object has interacted;
[0009] Among the candidate media, media of different media types are selected for recommendation based on the diversity index and the cross vector.
[0010] In a second aspect, the present application further provides a media diversity recommendation device. The device comprises:
[0011] An extraction module is configured to extract neighbor nodes of various orders corresponding to the media node and the object node in the first network node graph; the object node and the media node are nodes corresponding to the target object and the candidate media respectively;
[0012] A crossover module, configured to cross-process the representation vectors corresponding to the neighboring nodes of each order of the media node with the representation vectors corresponding to the neighboring nodes of each order of the object node to obtain a crossover vector;
[0013] a determination module, configured to determine a diversity index of the target object based on a set of media with which the target object has interacted;
[0014] A recommendation module is configured to select media of different media types from the candidate media for recommendation based on the diversity index and the cross vector.
[0015] In one embodiment, the cross module is further used to aggregate neighbor nodes of each order of the media node to obtain a first neighbor aggregation node; aggregate neighbor nodes of each order of the object node to obtain a second neighbor aggregation node; and cross-process the representation vector of the first neighbor aggregation node with the representation vector of the second neighbor aggregation node to obtain a cross vector.
[0016] In one embodiment, the neighbor nodes of each order include neighbor nodes of each neighbor level;
[0017] The crossover module is also used to aggregate the neighbor nodes of the media node that belong to the same neighbor class to obtain the first neighbor aggregation node of each neighbor class of the media node; and to aggregate the neighbor nodes of the object node that belong to the same neighbor class to obtain the second neighbor aggregation node of each neighbor class of the object node.
[0018] In one embodiment, the crossover module is further used to cross-process the representation vector of the first neighbor aggregation node of the first neighbor level with the representation vector of the second neighbor aggregation node of each neighbor level in sequence, until the representation vector of the first neighbor aggregation node of the last neighbor level is cross-processed with the representation vector of the second neighbor aggregation node of each neighbor level in sequence, to obtain a crossover sub-vector whose vector number is the number of neighbor orders; and each of the crossover sub-vectors is vector-splicing to obtain the crossover vector.
[0019] In one embodiment, the determination module is further used to obtain the media set with which the target object has interacted; construct a second network node graph with the object node of the target object and the media in the media set as nodes; in the second network node graph, extract the neighbor nodes of each order corresponding to the media in the media set; based on the attention coefficient and the representation vector of the neighbor nodes of each order corresponding to the media in the media set, determine the aggregate sub-vector between every two neighbor nodes of the media set; and determine the diversity index of the target object based on the aggregate sub-vector.
[0020] In one embodiment, the determination module is further used to perform vector splicing on the aggregated sub-vectors between every two order neighbor nodes to obtain a spliced vector; perform mapping processing on the spliced vector based on a multi-layer perceptron, and normalize the result obtained by the mapping processing according to the objective function to obtain a normalized result; and determine the diversity index of the target object based on the normalized result.
[0021] In one embodiment, the recommendation module is further used to determine the first interaction score of the target object for the candidate media based on the cross vector; among the candidate media, media of different media types are selected for recommendation based on the diversity index and the first interaction score.
[0022] In one embodiment, the recommendation module is further used to determine the first similarity between each media in the candidate media based on the cross vector; based on the diversity index and the first interaction score, determine the correlation between the target object and the i-th media in the candidate media in turn, and determine the adjustment parameters of the i-th media; based on the correlation and the adjustment parameters, determine the score value of each first media; when the score value reaches the preset recommendation condition, add the i-th media to the recommended media set, and increment i, and return to execute the determination of the correlation between the target object and the i-th media in the candidate media based on the diversity index and the first interaction score, until the k-th i-th media that meets the preset recommendation condition is added to the recommended media set; wherein k is the preset number of media recommendations; and recommend each media in the recommended media set to the target object.
[0023] In one embodiment, the recommendation module is further configured to determine an adjustment parameter of the i-th media based on the diversity index and the first similarity between the i-th media and the j-th media when the first similarity between the j-th media in the candidate media reaches a preset similarity condition; wherein i≠j.
[0024] In one embodiment, the media diversity recommendation method is applied to a graph neural network, and the apparatus further includes:
[0025] The extraction module is further configured to extract, from a third network node graph, training neighbor nodes of each order corresponding to sample media nodes and sample object nodes, respectively, using the graph neural network; the third network node graph is generated based on an interaction matrix between sample objects and sample media; the sample media includes positive sample media that have interacted with the sample objects and negative sample media that have not interacted with the sample objects;
[0026] The crossover module is further configured to cross-process the representation vectors corresponding to the neighboring nodes of each order of the sample media node with the representation vectors corresponding to the neighboring nodes of each order of the sample object node to obtain a training crossover vector;
[0027] The determination module is further configured to determine a diversity index of the target object based on the positive sample media;
[0028] A first selection module is configured to select media of different media types from the sample media as recommended media based on the diversity index and the training cross vector;
[0029] An optimization module is used to determine a loss value based on the recommended media and the corresponding media tags, and to optimize the parameters of the graph neural network based on the loss value.
[0030] In one embodiment, the device further comprises:
[0031] The determination module is further configured to determine, based on the training cross vector, a second interaction score of the sample object with respect to the sample media, and a second similarity between each medium in the sample media; sequentially determine, based on the diversity index and the second interaction score, a correlation between the sample object and each medium in the sample media, and determine an adjustment parameter for each medium in the sample media; and determine a score for each medium in the sample media based on the currently determined correlation and the adjustment parameter.
[0032] The optimization module is further configured to determine a loss value based on the score value and the recommended media and the corresponding media tag.
[0033] In one embodiment, the candidate media includes at least one of a live broadcast room, video, animation, music or image.
[0034] In one embodiment, the diversity index includes recommendation indexes corresponding to different media types; and the apparatus further includes:
[0035] A second receiving module is configured to receive live broadcast room interaction information sent by the client when the recommended media is a live broadcast room;
[0036] The determination module is further configured to determine a target live broadcast room for interaction of the target object based on the live broadcast room interaction information;
[0037] The weighting module is used to weight the recommendation index corresponding to the media type of the target live broadcast room based on the weighting coefficient when the residence time of the target live broadcast room meets the preset conditions, so as to obtain the weighted recommendation index; the weighted recommendation index is used for the next live broadcast room recommendation.
[0038] In one embodiment, the device further comprises:
[0039] A first receiving module is configured to receive a playback request for a target video sent by a client when the recommended media is a video; the target video is one of the recommended videos;
[0040] An acquisition module is used to obtain the bullet text and text playback time of the target video;
[0041] The determining module is further configured to determine the number of barrage texts in the barrage text belonging to each video period of the target video according to the text playback time;
[0042] The second selection module is used to select a target video period in which the number of the barrage texts meets the quantity condition from the video period;
[0043] The recommendation module is further configured to recommend the target video time period as a time period of popular video clips to the client.
[0044] In one embodiment, the recommendation module is further used to determine an information implantation area in the video segment corresponding to the target video time period; obtain product recommendation information, and implant the product recommendation information into the information implantation area; and recommend the video segment implanted with the product recommendation information to the client.
[0045] In one embodiment, the device further comprises:
[0046] a third receiving module, configured to, when the recommended media is music, receive a resource sharing message and a resource to be shared generated based on the music and sent by the first client;
[0047] A sending module, configured to send the resource sharing message to at least one second client;
[0048] The determining module is further configured to, upon receiving a resource acquisition request uploaded by a target client in the second client, determine a third similarity between the music and the performance music carried in the resource acquisition request; the performance music is obtained based on the music;
[0049] A transfer module is configured to transfer at least a portion of the to-be-shared resources to the resource account of the target object when the third similarity satisfies a preset similarity condition.
[0050] In a third aspect, the present application further provides a computer device. The computer device includes a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the following steps are performed:
[0051] Extracting neighbor nodes of each order corresponding to the media node and the object node in the first network node graph; the object node and the media node are nodes corresponding to the target object and the candidate media respectively;
[0052] Cross-processing the representation vectors corresponding to the neighboring nodes of each order of the media node with the representation vectors corresponding to the neighboring nodes of each order of the object node to obtain a cross-vector;
[0053] Determining a diversity index of the target object based on a media set with which the target object has interacted;
[0054] Among the candidate media, media of different media types are selected for recommendation based on the diversity index and the cross vector.
[0055] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the following steps:
[0056] Extracting neighbor nodes of each order corresponding to the media node and the object node in the first network node graph; the object node and the media node are nodes corresponding to the target object and the candidate media respectively;
[0057] Cross-processing the representation vectors corresponding to the neighboring nodes of each order of the media node with the representation vectors corresponding to the neighboring nodes of each order of the object node to obtain a cross-vector;
[0058] Determining a diversity index of the target object based on a media set with which the target object has interacted;
[0059] Among the candidate media, media of different media types are selected for recommendation based on the diversity index and the cross vector.
[0060] In a fifth aspect, the present application further provides a computer program product. The computer program product includes a computer program that, when executed by a processor, implements the following steps:
[0061] Extracting neighbor nodes of each order corresponding to the media node and the object node in the first network node graph; the object node and the media node are nodes corresponding to the target object and the candidate media respectively;
[0062] Cross-processing the representation vectors corresponding to the neighboring nodes of each order of the media node with the representation vectors corresponding to the neighboring nodes of each order of the object node to obtain a cross-vector;
[0063] Determining a diversity index of the target object based on a media set with which the target object has interacted;
[0064] Among the candidate media, media of different media types are selected for recommendation based on the diversity index and the cross vector.
[0065] The above-mentioned media diversity recommendation method, apparatus, computer device, storage medium, and computer program product extract the neighbor nodes of each order corresponding to each media node and object node in a first network node graph, thereby improving the distinguishability of the nodes to a certain extent and facilitating the accuracy of media recommendations. The representation vectors corresponding to the neighbor nodes of each order of the media node are cross-processed with the representation vectors corresponding to the neighbor nodes of each order of the object node, thereby obtaining a cross-vector containing a large amount of information. The diversity index of the target object is determined based on the set of media with which the target object has interacted. Among the candidate media, media of different media types are selected for recommendation based on the diversity index and cross-vector. This not only improves the accuracy of media recommendations but also increases the diversity of the recommended media, which is conducive to increasing the interaction rate between the target object and the recommended media, such as improving the click-through rate and play rate of the media. BRIEF DESCRIPTION OF THE DRAWINGS
[0066] Figure 1 A diagram illustrating an application environment of a media diversity recommendation method according to an embodiment;
[0067] Figure 2 1 is a flow chart of a method for recommending media diversity in one embodiment;
[0068] Figure 3 is a schematic diagram of a network node diagram in one embodiment;
[0069] Figure 4 This is a schematic diagram of a video recommendation page in one embodiment;
[0070] Figure 5 1 is a schematic diagram of a process for training a graph neural network in one embodiment;
[0071] Figure 6 is a schematic diagram of a network node diagram in another embodiment;
[0072] Figure 7 A schematic diagram of a process for recommending a person video clip of a target video in one embodiment;
[0073] Figure 8 FIG. 1 is a flow chart of resource transfer using recommended references in one embodiment;
[0074] Figure 9 is a structural block diagram of a media diversity recommendation device in one embodiment;
[0075] Figure 10 Figure 1 is a diagram of an internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0076] In order to make the purposes, technical solutions and advantages of the present application clearer, the present application is further described in detail below with reference to the drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and not used to limit the present application.
[0077] Before the embodiments of the present application are described, the technologies involved in the present application are briefly introduced as follows.
[0078] Artificial intelligence (AI) is the use of digital computers or digital computer-controlled machines to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology of computer science, which attempts to understand the essence of intelligence and produce a new intelligent machine that can react in a similar way to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines, so that machines have the functions of perception, reasoning and decision-making.
[0079] Artificial intelligence technology is a comprehensive discipline, involving a wide range of fields, both hardware and software technologies. Artificial intelligence basic technologies generally include technologies such as sensors, special artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction system, mechatronics, etc. Artificial intelligence software technology mainly includes computer vision technology, speech processing technology, natural language processing technology, and machine learning / deep learning, automatic driving, intelligent transportation, etc.
[0080] Machine learning (ML) is a multi-disciplinary subject, involving probability theory, statistics, approximation theory, convex analysis, algorithm complexity theory, etc. It is a subject that studies how computers simulate or implement human learning behavior to acquire new knowledge or skills, and reorganize existing knowledge structure to continuously improve their performance. Machine learning is the core of artificial intelligence and the fundamental approach to making computers intelligent, and its applications are widespread in various fields of artificial intelligence. Machine learning and deep learning usually include artificial neural networks, belief networks, reinforcement learning, transfer learning, inductive learning, and inductive learning.
[0081] The media diversity recommendation method provided by the embodiments of the present application can be applied to, for example, Figure 1In the application environment shown, the terminal 102 communicates with the server 104 via a network. The data storage system can store data that the server 104 needs to process. The data storage system can be integrated on the server 104 or placed on the cloud or other network servers.
[0082] The server 104 extracts the neighbor nodes of each order corresponding to the media node and the object node in the first network node graph; the object node and the media node are the nodes corresponding to the target object and the candidate media respectively; the representation vectors corresponding to the neighbor nodes of each order of the media node are cross-processed with the representation vectors corresponding to the neighbor nodes of each order of the object node to obtain a cross-vector; the diversity index of the target object is determined based on the media set with which the target object has interacted; among the candidate media, media of different media types are selected based on the diversity index and the cross-vector for recommendation to the terminal 102.
[0083] The terminal 102 may be a smartphone, tablet computer, laptop computer, desktop computer, smart speaker, smart watch, IoT device, or portable wearable device. IoT device may be a smart speaker, smart TV, smart air conditioner, or smart car device. Portable wearable device may be a smart watch, smart bracelet, or head-mounted device.
[0084] The server 104 may be an independent physical server or a service node in a blockchain system. A peer-to-peer (P2P) network is formed between the service nodes in the blockchain system. The P2P protocol is an application layer protocol running on top of the Transmission Control Protocol (TCP).
[0085] In addition, server 104 can also be a server cluster composed of multiple physical servers, and can be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms.
[0086] The terminal 102 and the server 104 may be connected via Bluetooth, USB (Universal Serial Bus), or a network, and this application does not impose any limitation thereto.
[0087] In one embodiment, Figure 2 As shown, a media diversity recommendation method is provided, which is applied to Figure 1 Taking the server 104 in the example as an example, the following steps are included:
[0088] S202, in the first network node graph, extract respective neighbor nodes of each order corresponding to the media nodes and the object nodes; the object nodes and the media nodes are nodes corresponding to the target object and the candidate media respectively.
[0089] The first network node graph can include object nodes corresponding to target objects and media nodes corresponding to candidate media. In addition, the first network node graph can also include object nodes corresponding to other objects and media nodes corresponding to other media. For details, please refer to Figure 3 The candidate media can be diversified media, i.e., media of various media types.
[0090] It should be noted that the object nodes corresponding to the other objects and the media nodes corresponding to the candidate media are connected by edges, and the edges between the object nodes and the media nodes represent that there is an interaction between the other objects and the candidate media, such as when the other objects play or enter the candidate media, the candidate media can be clicked to play. The media nodes corresponding to the other media and the object nodes corresponding to the target object are connected by edges, and the edges between the object nodes and the media nodes represent that there is an interaction between the target object and the other media, such as when the target object plays or enters the other media, the other media is clicked to play. The other object can refer to an object other than the target object, and the other media can refer to media other than the candidate media and interacting with the target object. The target object can refer to a user object that needs media recommendation, such as an object that has opened a video client, so that the server recommends videos to it through a recommendation system.
[0091] The object nodes and the media nodes are nodes corresponding to the target object and the candidate media respectively. The object node is a node in the first network node graph for representing the target object and the other object, and the object node has corresponding attribute information such as object identifier, interest information, and other information representing the target object. The media node is a node in the first network node graph for representing the candidate media and the other media, and the media node also has corresponding attribute information such as media identifier, media data size, release time, media type, and other information representing the candidate media. In actual application, the candidate media can be at least one of a live room, a video, an animation, music, or an image.
[0092] In one embodiment, the neighbor nodes of each order are neighbor nodes of each preset neighbor order; specifically, the server extracts neighbor nodes of each preset neighbor order corresponding to the media nodes and the object nodes in the first network node graph through a graph neural network. The preset neighbor order can be a preset neighbor layer number, such as a preset 1-L neighbor layer number, which can be controlled by a hyperparameter.
[0093] For example, for the object node u of the target object, the first-order neighbor nodes, second-order neighbor nodes, ..., L-order neighbor nodes of the object node are extracted in the first network node graph and recorded as For the media node v of the candidate media, extract the first-order neighbor nodes, second-order neighbor nodes, ..., L-order neighbor nodes of the media node in the first network node graph, and record them as
[0094] In one embodiment, the server obtains object information of the target object, object information of other objects, media information of candidate media and media information of other media, as well as interaction information between other objects and candidate media, other media, and interaction information between the target object and other media; converts the above interaction information into an interaction matrix, and constructs a first network node graph based on each interaction matrix, media information and object information.
[0095] For example, Figure 3 As shown in , the target object has previously clicked on other media 1 and other media 2, so the object node corresponding to the target object is connected to the media nodes corresponding to other media 1 and other media 2 by edges; and other object 1 has previously clicked on candidate media 1 and other media 1, so the object node corresponding to other object 1 is connected to the media nodes corresponding to candidate media 1 and other media 1 by edges, and so on, thus obtaining the following: Figure 3 It should be noted that the target object previously clicked on other media 1 and other media 2, indicating that other media 1 and other media 2 have been played, but has not clicked on candidate media 1 to 5. The solution of this application can select a variety of media from candidate media 1 to 5 for recommendation.
[0096] S204 , cross-processing the representation vectors corresponding to the neighboring nodes of each order of the media node with the representation vectors corresponding to the neighboring nodes of each order of the object node to obtain a cross-vector.
[0097] The cross processing may be an inner product process or a concatenation process. The cross vector may be a vector used to characterize the characteristics of the target object and the candidate media. The number of cross vectors may be multiple, such as a number equal to a preset number of neighboring orders. The representation vector may be a feature vector representing the mixture between each object and media in each order of neighboring nodes.
[0098] In one embodiment, the server obtains representation vectors corresponding to neighbor nodes of each order of the media node and representation vectors corresponding to neighbor nodes of each order of the object node, and then performs cross processing on the obtained representation vectors to obtain cross vectors.
[0099] In one embodiment, the server may first perform aggregation processing on neighbor nodes of each order, and then perform cross processing. Specifically: the server performs aggregation processing on neighbor nodes of each order of the media node to obtain a first neighbor aggregation node; performs aggregation processing on neighbor nodes of each order of the object node to obtain a second neighbor aggregation node; and cross-processes the representation vector of the first neighbor aggregation node and the representation vector of the second neighbor aggregation node to obtain a cross vector.
[0100] The aggregation process may be to sum and average the representation vectors corresponding to the neighbor nodes of each order, or to perform inner product processing, or to perform concatenation processing. The neighbor nodes of each order include the neighbor nodes of each neighbor class.
[0101] In one embodiment, the step of aggregating neighbor nodes of each order of the media node to obtain a first neighbor aggregation node may specifically include: the server aggregating neighbor nodes of the media node belonging to the same neighbor order to obtain a first neighbor aggregation node for each neighbor order of the media node. The step of aggregating neighbor nodes of each order of the object node to obtain a second neighbor aggregation node may specifically include: the server aggregating neighbor nodes of the object node belonging to the same neighbor order to obtain a second neighbor aggregation node for each neighbor order of the object node.
[0102] For example, in the first network node graph, the neighbor nodes of each order corresponding to the object node u and the media node v are extracted, such as the first-order neighbor nodes, second-order neighbor nodes, ..., L-order neighbor nodes of the object node u. These neighbor nodes are recorded as For every two object nodes u and media nodes v, the aggregate representation vectors of the neighbor nodes of order 1 to L (i.e., the neighbor aggregate representation vectors) are extracted. The specific aggregation method is as follows:
[0103]
[0104]
[0105] Among them, l u and l v They are the current neighbor order of the object node and the current neighbor order of the media node, both of which belong to [0,L].
[0106] After obtaining the neighbor aggregation representation vector, the neighbor aggregation representation vectors of the object node and the neighbor aggregation representation vectors of the media node are cross-processed. The specific cross-processing method is as follows:
[0107] z (u,v) =e u .e v
[0108] In one embodiment, the above-mentioned step of cross-processing the representation vector of the first neighbor aggregation node with the representation vector of the second neighbor aggregation node to obtain a cross vector can specifically include: the server cross-processes the representation vector of the first neighbor aggregation node of the first neighbor level with the representation vector of the second neighbor aggregation node of each neighbor level in sequence, until the representation vector of the first neighbor aggregation node of the last neighbor level is cross-processed with the representation vector of the second neighbor aggregation node of each neighbor level in sequence, to obtain a cross sub-vector whose vector number is the number of neighbor orders; and vector splicing each cross sub-vector to obtain a cross vector.
[0109] For example, after obtaining the neighbor aggregation representation vector, the neighbor aggregation representation vector of the object node is Aggregate representation vector of the media node's neighbors Perform cross processing to obtain cross sub-vectors. The specific cross method is as follows:
[0110]
[0111] Then, each cross sub-vector is aggregated. The specific aggregation method is as follows:
[0112]
[0113] Among them, ‖ represents the aggregation operation, which can be the cross sub-vectors Put them together.
[0114] S206: Determine a diversity index of the target object based on the media set with which the target object has interacted.
[0115] The media set may be a set of media that the target object has interacted with. For example, assuming that the media that the target object has interacted with has media i1, media i2, ..., media i3, etc. The media collection is
[0116] The diversity index can be used to represent the target object's demand or interest in different media types. Therefore, when making media recommendations, the number of media recommendations for media types with higher interest levels is greater than the number of media recommendations for media types with lower interest levels, or the number of media recommendations for media types with higher demand levels is greater than the number of media recommendations for media types with lower demand levels. For example, if the recommended media is video, assuming there are four video types, namely, romance, science fiction, costume drama, and comedy, and 10 videos are recommended at one time, then the number of recommendations for science fiction films, which the target object is most interested in, can be 4, the number of recommendations for comedy films, which the target object is second most interested in, can be 3, the number of recommendations for romance films, which the target object is third most interested in, can be 2, and the number of recommendations for costume dramas can be 1. It should be noted that the above video types are merely examples, including but not limited to the above video types. In addition, the above diversity index can change dynamically, and the influencing factors affecting the size of the diversity index can be the number of times or play duration (or dwell time) of media of the corresponding media type, or the interest tags marked by the target object for the corresponding media type.
[0117] In one embodiment, S206 may specifically include: the server obtains the media collection with which the target object has interacted; constructs a second network node graph with the object node of the target object and the media in the media collection as nodes; in the second network node graph, extracts the neighbor nodes of each order corresponding to the media in the media collection; based on the attention coefficient and the representation vector of the neighbor nodes of each order corresponding to the media in the media collection, determines the aggregated sub-vector between every two neighbor nodes of the media collection; and determines the diversity index of the target object based on the aggregated sub-vector.
[0118] The attention coefficient may refer to the contribution degree of neighbor nodes in each order of neighbor nodes to the object node corresponding to the target object, such as the contribution degree of neighbor nodes of a certain neighbor order to the object node.
[0119] For example, the following vector aggregation formula is used to calculate the aggregate subvector between every two order neighbor nodes, as shown below:
[0120]
[0121] in, is the aggregate subvector, l1 and l2 represent the l1th and l2th neighbor orders respectively, and are the representation vectors of neighbor nodes in the l1th and l2th neighbor orders, respectively, α(·) is the attention coefficient, 0≤l1,l2≤L.
[0122] In one embodiment, the above-mentioned step of determining the diversity index of the target object based on the aggregated sub-vectors may specifically include: the server concatenates the aggregated sub-vectors between every two order neighbor nodes to obtain a concatenated vector; maps the concatenated vector based on a multi-layer perceptron, and normalizes the result obtained by the mapping process according to the objective function to obtain a normalized result; and determines the diversity index of the target object based on the normalized result.
[0123] The above attention coefficient α(·) can be obtained by using multi-layer perceptron and normalization processing, that is, therefore For this media collection O u The aggregate subvector between the l1 and l2 order neighbor nodes. The above MLP2 can refer to a multilayer perceptron.
[0124] Then, the aggregation sub-vectors between every two order neighbor nodes are concatenated, and the concatenated vectors are mapped again using a multi-layer perceptron, and then normalized to obtain the diversity index λ of the target object. u , the corresponding calculation formula is as follows:
[0125]
[0126] Among them, σ is the activation function, such as the sigmoid function, the sigmoid function is ‖ represents the concatenation of vectors.
[0127] S208 , selecting media of different media types from the candidate media based on the diversity index and the cross vector for recommendation.
[0128] The media type can be a category to which different media are categorized. For example, if the candidate media is a video, the media type is a video type, which includes romance, science fiction, period films, comedy, education, and food. Video types can also be categorized by video length.
[0129] In one embodiment, the server determines the target subject's first interaction score for candidate media based on the cross vector; then, based on the diversity index and the first interaction score, media of different media types are selected for recommendation from the candidate media. Furthermore, after calculating the first interaction score, the server may also sort the candidate media by the first interaction score to generate a sorted media sequence; and within the media sequence, media of different media types are selected for recommendation based on the diversity index.
[0130] The first interaction score is the estimated score of the target object interacting with the candidate media. A larger first interaction score indicates a greater likelihood that the target object will interact with the candidate media, such as clicking to play the candidate media.
[0131] For example, when the candidate media is a candidate video, the server determines the first interaction score of the target object for the candidate video based on the cross vector; selects videos of different video types from the candidate videos for recommendation based on the diversity index and the first interaction score, thereby achieving diverse video recommendations, such as Figure 4 As shown, the recommended videos include videos 1 to 10, where videos 1 and 3 are romance films, videos 2, 4, and 5 are science fiction films, videos 6 and 10 are period films, and videos 7, 8, and 9 are comedies. Similarly, when the candidate media is a live broadcast room, music, animation, or image, the above method can also be used for recommendation.
[0132] In another embodiment, the method for media diversity recommendation also includes: the server determines the first similarity between each media in the candidate media based on the cross vector; based on the diversity index and the first interaction score, determines the correlation between the target object and the i-th media in the candidate media in turn, and determines the adjustment parameter of the i-th media; based on the correlation and the adjustment parameter, determines the score value of each first media; when the score value reaches the preset recommendation condition, adds the i-th media to the recommended media set, and increments i, and returns to execute based on the diversity index and the first interaction score, and determines the correlation between the target object and the i-th media in the candidate media in turn, until the k-th i-th media that meets the preset recommendation condition is added to the recommended media set; wherein k is the preset number of media recommendations; and recommends each media in the recommended media set to the target object.
[0133] In one embodiment, the above-mentioned step of determining the adjustment parameters of the i-th media may specifically include: when the first similarity between the j-th media in the candidate media and the i-th media reaches a preset similarity condition, the server determines the adjustment parameters of the i-th media based on the diversity index and the first similarity between the i-th media and the j-th media; wherein i≠j.
[0134] For example, when the candidate media is a candidate video, the diversity index, interaction score and MMR with greedy algorithm can be used to select diverse videos to obtain a diverse video set, that is, to initialize an empty set S for the target object. u , and perform cyclic calculations using the following formula:
[0135]
[0136] The first half of the right side of the formula is the correlation between video i and target object u, and the second half indicates whether there is a video j that is most similar to video i in the candidate videos. u,i Biggest video i added to collection S u In the process, the loop is repeated K times, where K is the number of recommended videos.
[0137] In one embodiment, when the pushed media is a live broadcast room, the client can enter the live broadcast room to play the live content. At this time, the server can count the length of time the client stays in the live broadcast room and then determine the target object's interest in the live broadcast room based on the length of time. In the subsequent recommendation process, when the interest level reaches the preset interest condition, the attribute information of the live broadcast room can be used as an influencing factor to predict the live broadcast room that the target object is interested in. In addition, the server can also receive the target object's interaction information with the live broadcast room reported by the client, such as the target object liking the live broadcast room or following the live broadcast room after entering the live broadcast room. Based on this interaction information, the server can determine that the target object is interested in the live broadcast room and then perform weighted processing on the diversity index of this type for application in the next live broadcast room recommendation.
[0138] Among them, the attribute information can be the live broadcast type of the live broadcast room, the live broadcast style of the live broadcaster, and the regular live broadcast time, etc.
[0139] In one embodiment, when the pushed media is a video, if the client plays the recommended target video, the server can also recommend popular video clips of the target video to the client, so that the target object can know the popular video clips of the target video in advance during the video playback process, and locate the popular video clip for playback according to actual needs.
[0140] In the above embodiment, in the first network node graph, neighbor nodes of various orders corresponding to the media node and the object node are extracted, thereby improving the distinguishability of the nodes to a certain extent and facilitating the accuracy of media recommendations. The representation vectors corresponding to the neighbor nodes of various orders of the media node are cross-processed with the representation vectors corresponding to the neighbor nodes of various orders of the object node, thereby obtaining a cross-vector containing a large amount of information. The diversity index of the target object is determined based on the set of media with which the target object has interacted. Among the candidate media, media of different media types are selected for recommendation based on the diversity index and the cross-vector. This not only improves the accuracy of media recommendations, but also increases the diversity of the recommended media, which is conducive to increasing the interaction rate between the target object and the recommended media, such as improving the click-through rate and play rate of the media.
[0141] In one embodiment, the media diversity recommendation method is applied to a graph neural network, such as Figure 5 As shown, the method further includes:
[0142] S502 , in the third network node graph, extracting the training neighbor nodes of each order corresponding to the sample media nodes and the sample object nodes through the graph neural network.
[0143] Among them, the third network node graph is generated based on the interaction matrix between the sample object and the sample media, and includes sample object nodes corresponding to the sample object and sample media nodes corresponding to the sample media. The sample media includes positive sample media that have interacted with the sample object and negative sample media that have not interacted with the sample object. Therefore, the sample object node and the sample media node corresponding to the positive sample media are connected by edges, and the edge between the sample object node and the sample media node corresponding to the positive sample media indicates that there is an interaction between the sample object and the positive sample media, such as the sample object performing a click operation on the positive sample media; in addition, the sample object node and the sample media node corresponding to the negative sample media are not connected, such as Figure 6 shown.
[0144] A sample object node is a node in the third network node graph that represents a sample object. This sample object node has corresponding attribute information, such as an object identifier, interest information, and other information that characterizes the sample object. A sample media node is a node in the third network node graph that represents sample media. This sample media node also has corresponding attribute information, such as a media identifier, data size, release date, media type, and other information that characterizes the sample media. In practical applications, the sample media can be at least one of a live broadcast, video, animation, music, or image.
[0145] The training neighbor nodes of each order are neighbor nodes of each preset neighbor order; each preset neighbor order can be a preset number of neighbor layers, such as a preset number of 1 to L neighbor layers, and the preset neighbor order can be controlled by a hyperparameter.
[0146] In one embodiment, the server obtains an interaction matrix between the sample objects and the sample media and generates a second network node graph of the sample objects and the sample media based on the interaction matrix. The interaction matrix can be a matrix derived from the interactions between the sample objects and the sample media, and can represent the interaction between the sample objects and the sample media. It should be noted that if there is no interaction between the sample object and the negative sample media, the corresponding element in the interaction matrix is 0; if there is interaction between the sample object and the positive sample media, the corresponding element in the interaction matrix is 1.
[0147] For example, let the dimension of the interaction matrix R be (N, M), where the number of sample objects is N and the number of sample media is M. If there is an interaction between the i-th sample object and the j-th sample media, then r i,j =1, otherwise r i,j =0.
[0148] In one embodiment, the server obtains a fused feature vector corresponding to the sample object and the sample media, i.e., a feature vector obtained by fusing the feature vector of the sample object with the feature vector of the sample media. The server may generate a second network node graph of the sample object and the sample media based on the interaction matrix and the fused feature vector.
[0149] For example, the dimension of the fused feature vector E corresponding to the sample object and the sample media is (M+N, K), where the feature vectors in rows 1 to N are the feature vectors of the sample object, the feature vectors in rows N+1 to N+M are the feature vectors of the sample media, and K is the dimension of the representation vector.
[0150] S504 , cross-processing the representation vectors corresponding to the neighboring nodes of each order of the sample media node with the representation vectors corresponding to the neighboring nodes of each order of the sample object node to obtain a training cross-vector.
[0151] The representation vector may be a mixed feature vector between each object and media in each order of neighbor nodes. The training cross vector may be a vector used to characterize the features of sample objects and sample media, and the number of the vectors may be multiple, such as the number of preset neighbor orders.
[0152] S506: Determine the diversity index of the target object based on the positive sample media.
[0153] The diversity index can be used to represent the interest level of the sample subjects in different media types. Therefore, when making media recommendations, the number of media recommendations for media types with a higher level of interest is greater than the number of media recommendations for media types with a lower level of interest.
[0154] S508 , selecting media of different media types from the sample media as recommended media based on the diversity index and the training cross vector.
[0155] The detailed steps of S504 to S508 can be found in Figure 2 S204 to S208 of the embodiment.
[0156] S510: Determine a loss value based on the recommended media and the corresponding media tags, and optimize the parameters of the graph neural network based on the loss value.
[0157] In one embodiment, the server determines a second interaction score between the sample object and the sample media, and a second similarity between each media in the sample media, based on the training cross-vector. Based on the diversity index and the second interaction score, the server sequentially determines the correlation between the sample object and each media in the sample media, and determines an adjustment parameter for each media in the sample media. Based on the currently determined correlation and adjustment parameter, the server determines a score for each media in the sample media. Therefore, S510 may specifically include: the server determining a loss value based on the score, the recommended media, and the corresponding media tag.
[0158] For example, assuming that the sample media is a video, after obtaining the video set S recommended to the sample object u u After that, the BPR loss function can be used to train the graph neural network and optimize the model parameters of the graph neural network. The loss function is as follows:
[0159]
[0160] in, represents the video set where the sample object u does not interact, O u Represents the video collection that the sample object u has interacted with, y u,i is the interaction score of the sample object to the positive sample media, y u,q is the interaction score of the sample object to the negative sample media, y u,j is the interaction label corresponding to the positive sample media, y u,p is the interaction label corresponding to the negative sample media.
[0161] In the above embodiment, the training neighbor nodes of each order corresponding to the sample media node and the sample object node are extracted from the third network node graph, and then the representation vectors corresponding to the neighbor nodes of each order of the sample media node and the representation vectors corresponding to the neighbor nodes of each order of the sample object node are cross-processed, and the diversity index of the target object is determined based on the positive sample media. In the sample media, media of different media types are selected as recommended media based on the diversity index and the training cross vector; the loss value is determined based on the recommended media and the corresponding media label, and the parameters of the graph neural network are optimized based on the loss value to obtain a graph neural network that can accurately recommend diverse media, so that the recommended media can present diversity, which is conducive to improving the interaction rate of the media.
[0162] In one embodiment, in addition to recommending videos, animations, music and images, live broadcast rooms can also be recommended, which can be video live broadcast rooms or music live broadcast rooms, or other live broadcast rooms; the live broadcast room recommendation process includes: when the recommended media is a live broadcast room, the server receives the live broadcast room interaction information sent by the client; based on the live broadcast room interaction information, the target live broadcast room for target object interaction is determined; when the residence time of the target live broadcast room meets the preset conditions, the recommendation index corresponding to the media type to which the target live broadcast room belongs is weighted based on the weighting coefficient to obtain a weighted recommendation index; wherein the above-mentioned diversity index includes recommendation indexes corresponding to different media types, and the weighted recommendation index is used for the next live broadcast room recommendation.
[0163] The client may be a video client or music client of the target object. The live broadcast room interaction information may be information about the interaction between the target object and the live broadcast room, such as operation information of clicking to enter the live broadcast room, operation information of switching the live broadcast room, and other information, such as information of liking or following the live broadcast room.
[0164] The preset condition may be that the dwell time falls within a preset first duration interval, or that the dwell time falls within a preset second duration interval. When the dwell time falls within the preset first duration interval, it indicates that the target object has stayed in the live broadcast room for a longer time, and the corresponding weighting coefficient may be a coefficient greater than one. Therefore, the recommendation index after weighting is greater than the recommendation index before weighting, so that when recommendations are made next time, the number of live broadcast rooms of this type recommended may be greater than that of other types. When the dwell time falls within the preset second duration interval, it indicates that the target object has stayed in the live broadcast room for a shorter time, and the corresponding weighting coefficient may be a coefficient less than one. Therefore, the recommendation index after weighting is less than the recommendation index before weighting, so that when recommendations are made next time, the number of live broadcast rooms of this type recommended may be less than that of other types. The value in the first duration interval is greater than the value in the second duration interval.
[0165] In the above embodiment, the recommendation index corresponding to the specific media type in the diversity index is weighted, so that the size of the recommendation index corresponding to the specific media type changes, so that when recommending a live broadcast room among candidates, the recommended live broadcast room can be more in line with the actual needs of the target object on the basis of satisfying the diversity recommendation, thereby effectively improving the residence rate of the live broadcast room.
[0166] In one embodiment, Figure 7 As shown, after S208, the method further includes:
[0167] S702: When the recommended media is a video, a play request for a target video sent by a client is received; the target video is one of the recommended videos.
[0168] There can be multiple recommended videos, and the target object can select a target video from the recommended videos to play. At this time, the client will send a play request for the target video to the server. On the one hand, it can play the target video on demand, and on the other hand, it can determine the popular video clips in the target video.
[0169] S704, obtaining the bullet text and text playing time of the target video.
[0170] The barrage text can be a commentary text that pops up when other objects watch the target video on a web page or client. The text playback time is generally the video playback time corresponding to when the other object posted the barrage text.
[0171] In one embodiment, before S704, the server obtains the barrage text entered on the playback page of other clients (i.e., clients of other objects) and the video playback time corresponding to the entry of the barrage text, determines the text playback time based on the video playback time, and then stores the text playback time and barrage text.
[0172] S706: Determine the number of barrage texts in each video period of the target video in the barrage text according to the text playback time.
[0173] The video period is a time period divided into a certain time interval for the video, and the time interval can be 1 minute or other time intervals.
[0174] In one embodiment, S706 may specifically include: the server divides the total time period of the video into multiple video time periods according to a preset duration; among the obtained barrage texts, the barrage texts belonging to each video time period are determined according to the text playback time; and the number of barrage texts corresponding to the video time period is counted according to the determined barrage texts. When the text playback time corresponding to a certain barrage text falls within a certain video time period, the barrage text belongs to the video time period. This method is used to count the number of barrage texts belonging to each video time period to obtain the number of barrage texts under each video time period.
[0175] For example, the target video's total duration is divided into 10 video periods. Then, the video period to which the text playback time corresponding to each bullet text belongs is determined. For example, if the playback time corresponding to bullet text A is 1:00, then bullet text A belongs to video period 0 to 1. After determining the video period to which the text playback time belongs, the number of bullet texts falling within that text playback time is calculated to obtain the number of bullet texts in each video period. The number of bullet texts in video period 0 to 1 is 300.
[0176] S708, selecting a target video period in which the number of bullet screen texts meets the quantity condition from the video period.
[0177] Among them, the video clip corresponding to the target video time period has a large number of barrage texts, and a large number of other objects have commented on the video clip, indicating that the video clip is a popular video clip that everyone is paying attention to and has a high popularity.
[0178] In one embodiment, the server arranges each video period in order of the size of the barrage texts, and then selects a target video period in each video period whose number of barrage texts meets the quantity condition.
[0179] S710: Recommend the target video time period to the client as a time period of popular video clips.
[0180] The client may be a video client of the target object. When the client receives the time period of the popular video clip recommended by the server, the client may highlight the time period on the progress bar or display a prompt message at the position corresponding to the time period, so that the target object can know that the time period is the time period of the popular video clip through the highlighting method or prompt message.
[0181] In one embodiment, the server recommends the start time and end time of the target video period to the client to recommend a popular video segment, so that the target object can pull the playback progress to the popular video segment for playback according to his or her interests.
[0182] In addition, the server can also embed corresponding product recommendation information in the target video. The specific steps include: the server determines the information embedding area in the video clip corresponding to the target video time period, obtains the product recommendation information, and embeds the product recommendation information into the information embedding area, and then recommends the video clip with the embedded product recommendation information to the client.
[0183] Among them, the information implantation area can be an area in the target video that is relatively conspicuous and does not affect the viewing of the video. For example, if a video clip of the target video is indoors, the indoor background wall can be used as the information implantation area; if a video clip of the target video is outdoor, the outdoor building can be used as the information implantation area.
[0184] In the above embodiment, by obtaining the barrage text and the corresponding text playback time about the comment target video, it can be determined based on the barrage text and the text playback time that the target video time period has a large number of barrage texts. Then the video clip corresponding to the target video time period is a popular video clip that everyone is paying attention to, and the popular video clip is recommended to the target object as a target recommended video clip. Therefore, even if the target video is longer in duration and has more content, the popular video clip in the target video can be directly located for playback, which is beneficial to the playback efficiency of the target video.
[0185] In one embodiment, Figure 8 As shown, the method further includes:
[0186] S802: When the recommended media is music, a resource sharing message generated based on the music and resources to be shared are received from the first client.
[0187] A resource sharing message can be a conversational message used to notify the message recipient of available resources, such as a red envelope message. The resource to be shared can be a resource available to each message recipient sent by the target, such as an electronic red envelope. If there is only one recipient of the resource sharing message, the number of electronic red envelopes is one; if there are multiple recipients, the number of electronic red envelopes can be multiple.
[0188] In one embodiment, when the resource sharing message is a group resource sharing message, the server may further receive a group identifier sent by the first client for searching for a group.
[0189] S804: Send a resource sharing message to at least one second client.
[0190] The first client and the second client may be communication clients or payment clients of different objects. For example, the first client may be a communication client of a target object, and the second client may be a communication client of another object.
[0191] In one embodiment, when the resource sharing message is a group resource sharing message, the server searches for a corresponding group based on the group identifier sent by the first client, and then sends the resource sharing message to the group, thereby sending the resource sharing message to the second client corresponding to each member in the group.
[0192] S806: When receiving a resource acquisition request uploaded by a target client in the second client, determine the similarity between the music and the performance music carried in the resource acquisition request.
[0193] The singing music is obtained based on the music, for example, the singing music may be obtained by another object (ie, the object receiving the resource sharing message) singing according to the music. The target client is at least one of the second clients.
[0194] The similarity may refer to the degree of similarity in pitch and tempo between the recommended music and the sung music.
[0195] S808: When the similarity satisfies a preset similarity condition, at least a portion of the resources to be shared is transferred to the resource account of the target object.
[0196] The similarity meeting the preset similarity condition may mean that the similarity is greater than or equal to a similarity threshold. The greater the similarity, the more resources are obtained from the resources to be shared.
[0197] In one embodiment, when the similarity is greater than or equal to a similarity threshold, resources of a corresponding amount are collected from the to-be-shared resources based on the similarity, and then the collected resources are transferred to the target object's resource account. When the similarity is less than the similarity threshold, a prompt message is sent to the object corresponding to the singing music, prompting the object to perform the singing again based on the music to obtain new singing music, and then use the new singing music to collect resources.
[0198] In the above embodiment, when the target object receives the recommended music, it can apply the music to resource sharing, that is, send a resource sharing message and the resources to be shared to the server. The server will transfer at least part of the resources to be shared to the resource account of the target object based on the similarity between the music and the singing music uploaded by other objects. If the similarity meets the preset similarity conditions, it will enrich the diversity of resource sharing gameplay and enhance the interactivity between each object and the resources. In addition, it is also conducive to livening up the atmosphere and increasing the fun during the resource sharing process.
[0199] As an example, the above method is described here in combination with the application scenario of video diversity recommendation, as follows:
[0200] (1) Construct the interaction matrix and representation vector matrix between user objects and videos.
[0201] First, define the interaction matrix R between user objects and videos. The dimension of the interaction matrix R is (N, M). The number of user objects is N and the number of videos is M. If there is an interaction between the i-th user object and the j-th video, then the r in the interaction matrix R is i,j =1, otherwise r i,j = 0. The above interaction may be a click operation of the user object on the video.
[0202] Secondly, define the representation vector matrix E between the user object and the video, the dimension of the representation vector matrix E is (M+N, K). Wherein, the feature vectors of 1 to N rows are the feature vectors of the user object, the feature vectors of N+1 to N+M rows are the feature vectors of the video, and K is the dimension of the representation vector.
[0203] (2) Extract the neighbor nodes of each order of the user node and the video node, and cross the representation vectors of the neighbor nodes of each order.
[0204] For each user node u and video node v, the first-order neighbor nodes, second-order neighbor nodes, …, L-order neighbor nodes can be found by using the interaction matrix R, and these neighbor nodes of different neighbor orders are denoted as Then, the representation vectors of the 1st to Lth neighbor nodes are aggregated, and the aggregation mode is as follows:
[0205]
[0206]
[0207] Wherein, l u ,l v ∈[0,1]. After obtaining the aggregated representation vectors of the neighbor nodes of each order, the aggregated representation vectors corresponding to the user node u and the video node v are crossed, and the crossing mode is as follows:
[0208]
[0209] Then, the correlation degree between the two nodes is obtained by using the crossed vector, and if the two nodes are a user node and a video node, it is the interaction score between the user object and the video (representing the possibility of interaction); if the two nodes are video nodes, it is the similarity between the two videos, and the corresponding calculation formula is as follows:
[0210]
[0211] Wherein, MLP1 is a multi-layer perceptron, and ‖ is an aggregation operation (such as concatenating vectors).
[0212] (3) Diversity calculation.
[0213] The diversity index is calculated by the set of interacted videos of the user object, and the specific calculation process of the diversity index is as follows: let the set of interacted videos of the user object be Wherein n u is the number of interacted videos of the user object, and then cross the l1 and l2 neighbor nodes in the set of interacted videos O u
[0214]
[0215] Among them, l u ,l v ∈[0,1], For the interactive video set O u The aggregate representation vector between the l1, l2 neighbor interactions; α(·) is the attention coefficient, which can be obtained using multi-layer perceptron and normalization, that is,
[0216] The diversity index λ of the user object can be calculated through the aggregate representation vector u ,Right now:
[0217]
[0218] Among them, σ is the sigmoid function, which is
[0219] The diversity index and MMR with greedy algorithm can be used to obtain a diverse video set, that is, an empty video set S is initialized for a user object. u , through cyclic calculation, K diverse videos are obtained and added to the video set S u , and then make recommendations. The specific calculation formula is as follows:
[0220]
[0221] The first half of the right side of the above formula is the correlation between video i and user object u, and the second half indicates whether there is a video j that is most similar to video i in the candidate video set. u,i The largest video i added to the video collection S u The loop is repeated K times, where K is the number of recommended videos.
[0222] Get video collection S u After that, the BPR loss function can be used to train the graph neural network to optimize the model parameters. The BPR loss function is as follows:
[0223]
[0224] in, Represents a collection of videos that the user object has not interacted with.
[0225] (4) Perform video diversity recommendation.
[0226] After training, for each user object u, the recommended video set S is calculated based on the graph neural network. u , the video collection Su That is, a diverse video, and then the video set S u Recommend the videos in to the user object u.
[0227] Through the embodiments of the present application, in the process of video recommendation, the diversity index of each user object is found for recommendation, so that each user object can have a different degree of diversity. For user objects with high diversity requirements, high-diversity videos will be recommended as much as possible; for user objects with low diversity requirements, highly relevant videos will be recommended as much as possible, so that the diversity requirements of different user objects can be met.
[0228] It should be understood that, although the various steps in the flowcharts involved in the various embodiments described above are displayed in sequence according to the instructions of the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and these steps can be executed in other orders. Moreover, at least a portion of the steps in the flowcharts involved in the various embodiments described above can include multiple steps or multiple stages, and these steps or stages are not necessarily executed and completed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a portion of steps or stages in other steps.
[0229] Based on the same inventive concept, embodiments of the present application also provide a media diversity recommendation device for implementing the aforementioned media diversity recommendation method. The solution provided by this device is similar to the solution described in the aforementioned method. Therefore, the specific limitations of the one or more media diversity recommendation device embodiments provided below can be found in the limitations of the media diversity recommendation method described above and will not be repeated here.
[0230] In one embodiment, Figure 9 As shown, a media diversity recommendation device is provided, comprising: an extraction module 802, a cross module 904, a determination module 906 and a recommendation module 908, wherein:
[0231] Extraction module 902, configured to extract neighbor nodes of various orders corresponding to the media node and the object node in the first network node graph; the object node and the media node are nodes corresponding to the target object and the candidate media respectively;
[0232] A crossover module 904 is configured to crossover the representation vectors corresponding to the neighboring nodes of each order of the media node with the representation vectors corresponding to the neighboring nodes of each order of the object node to obtain a crossover vector;
[0233] A determination module 906 is configured to determine a diversity index of a target object based on a set of media with which the target object has interacted;
[0234] The recommendation module 908 is configured to select media of different media types from the candidate media based on the diversity index and the cross vector for recommendation.
[0235] In one embodiment, the crossover module is further used to aggregate neighbor nodes of each order of the media node to obtain a first neighbor aggregation node; aggregate neighbor nodes of each order of the object node to obtain a second neighbor aggregation node; and cross-process the representation vector of the first neighbor aggregation node with the representation vector of the second neighbor aggregation node to obtain a crossover vector.
[0236] In one embodiment, each level of neighbor nodes includes neighbor nodes of each neighbor level;
[0237] The crossover module is also used to aggregate neighbor nodes of the media node that belong to the same neighbor class to obtain the first neighbor aggregation node of each neighbor class of the media node; and to aggregate neighbor nodes of the object node that belong to the same neighbor class to obtain the second neighbor aggregation node of each neighbor class of the object node.
[0238] In one embodiment, the crossover module is further used to cross-process the representation vector of the first neighbor aggregation node of the first neighbor level with the representation vector of the second neighbor aggregation node of each neighbor level in sequence, until the representation vector of the first neighbor aggregation node of the last neighbor level is cross-processed with the representation vector of the second neighbor aggregation node of each neighbor level in sequence, to obtain a crossover sub-vector whose vector number is the number of neighbor orders; and each crossover sub-vector is vector-splicing to obtain a crossover vector.
[0239] In one embodiment, the determination module is further used to obtain the media set with which the target object has interacted; construct a second network node graph with the object node of the target object and the media in the media set as nodes; extract the neighbor nodes of each order corresponding to the media in the media set in the second network node graph; determine the aggregated sub-vector between each two neighbor nodes of the media set based on the attention coefficient and the representation vector of the neighbor nodes of each order corresponding to the media in the media set; and determine the diversity index of the target object based on the aggregated sub-vector.
[0240] In one embodiment, the determination module is further used to perform vector splicing on the aggregated sub-vectors between every two order neighbor nodes to obtain a spliced vector; perform mapping processing on the spliced vector based on a multi-layer perceptron, and normalize the result obtained by the mapping processing according to the objective function to obtain a normalized result; and determine the diversity index of the target object based on the normalized result.
[0241] In one embodiment, the recommendation module is further configured to determine a first interaction score of the target object for candidate media based on the cross vector; and select media of different media types for recommendation among the candidate media based on the diversity index and the first interaction score.
[0242] In one embodiment, the recommendation module is further used to determine the first similarity between each media in the candidate media based on the cross vector; based on the diversity index and the first interaction score, determine the correlation between the target object and the i-th media in the candidate media in turn, and determine the adjustment parameter of the i-th media; based on the correlation and the adjustment parameter, determine the score value of each first media; when the score value reaches the preset recommendation condition, add the i-th media to the recommended media set, and increment i, and return to execute based on the diversity index and the first interaction score, and determine the correlation between the target object and the i-th media in the candidate media in turn, until the k-th i-th media that meets the preset recommendation condition is added to the recommended media set; wherein k is the preset number of media recommendations; and recommend each media in the recommended media set to the target object.
[0243] In one embodiment, the recommendation module is further configured to determine an adjustment parameter of the i-th media based on the diversity index and the first similarity between the i-th media and the j-th media when the first similarity between the j-th media and the i-th media in the candidate media reaches a preset similarity condition; wherein i≠j.
[0244] In the above embodiment, in the first network node graph, neighbor nodes of various orders corresponding to the media node and the object node are extracted, thereby improving the distinguishability of the nodes to a certain extent and facilitating the accuracy of media recommendations. The representation vectors corresponding to the neighbor nodes of various orders of the media node are cross-processed with the representation vectors corresponding to the neighbor nodes of various orders of the object node, thereby obtaining a cross-vector containing a large amount of information. The diversity index of the target object is determined based on the set of media with which the target object has interacted. Among the candidate media, media of different media types are selected for recommendation based on the diversity index and the cross-vector. This not only improves the accuracy of media recommendations, but also increases the diversity of the recommended media, which is conducive to increasing the interaction rate between the target object and the recommended media, such as improving the click-through rate and play rate of the media.
[0245] In one embodiment, the media diversity recommendation method is applied to a graph neural network, and the apparatus further includes:
[0246] The extraction module is further configured to extract, from a third network node graph, training neighbor nodes of each order corresponding to the sample media node and the sample object node, using a graph neural network; the third network node graph is generated based on an interaction matrix between the sample object and the sample media; the sample media includes positive sample media that have interacted with the sample object and negative sample media that have not interacted with the sample object;
[0247] The crossover module is further used to cross-process the representation vectors corresponding to the neighboring nodes of each order of the sample media node with the representation vectors corresponding to the neighboring nodes of each order of the sample object node to obtain a training crossover vector;
[0248] The determination module is further used to determine the diversity index of the target object based on the positive sample media;
[0249] A first selection module is used to select media of different media types from the sample media as recommended media based on the diversity index and the training cross vector;
[0250] The optimization module is used to determine the loss value based on the recommended media and the corresponding media tags, and optimize the parameters of the graph neural network based on the loss value.
[0251] In one embodiment, the apparatus further comprises:
[0252] The determination module is further configured to determine, based on the training cross vector, a second interaction score of the sample object with respect to the sample media, and a second similarity between each medium in the sample media; determine, based on the diversity index and the second interaction score, a correlation between the sample object and each medium in the sample media, and determine an adjustment parameter for each medium in the sample media; and determine a score for each medium in the sample media based on the currently determined correlation and adjustment parameter;
[0253] The optimization module is also used to determine the loss value based on the score value and the recommended media and the corresponding media label.
[0254] In the above embodiment, the training neighbor nodes of each order corresponding to the sample media node and the sample object node are extracted from the third network node graph, and then the representation vectors corresponding to the neighbor nodes of each order of the sample media node and the representation vectors corresponding to the neighbor nodes of each order of the sample object node are cross-processed, and the diversity index of the target object is determined based on the positive sample media. In the sample media, media of different media types are selected as recommended media based on the diversity index and the training cross vector; the loss value is determined based on the recommended media and the corresponding media label, and the parameters of the graph neural network are optimized based on the loss value to obtain a graph neural network that can accurately recommend diverse media, so that the recommended media can present diversity, which is conducive to improving the interaction rate of the media.
[0255] In one embodiment, the candidate media includes at least one of a live broadcast room, a video, an animation, music, or an image.
[0256] In one embodiment, the diversity index includes recommendation indexes corresponding to different media types; and the apparatus further includes:
[0257] The second receiving module is used to receive the live broadcast room interaction information sent by the client when the recommended media is a live broadcast room;
[0258] The determination module is further used to determine the target live broadcast room for the target object to interact based on the live broadcast room interaction information;
[0259] The weighting module is used to weight the recommendation index corresponding to the media type of the target live broadcast room based on the weighting coefficient when the residence time of the target live broadcast room meets the preset conditions, and obtain the weighted recommendation index; the weighted recommendation index is used for the next live broadcast room recommendation.
[0260] In the above embodiment, the recommendation index corresponding to the specific media type in the diversity index is weighted, so that the size of the recommendation index corresponding to the specific media type changes, so that when recommending a live broadcast room among candidates, the recommended live broadcast room can be more in line with the actual needs of the target object on the basis of satisfying the diversity recommendation, thereby effectively improving the residence rate of the live broadcast room.
[0261] In one embodiment, the apparatus further comprises:
[0262] A first receiving module is configured to receive a playback request for a target video sent by a client when the recommended media is a video; the target video is one of the recommended videos;
[0263] The acquisition module is used to obtain the bullet text and text playback time of the target video;
[0264] The determination module is further used to determine the number of barrage texts in each video period of the target video in the barrage text according to the text playback time;
[0265] The second selection module is used to select a target video period from the video period whose number of barrage texts meets the quantity condition;
[0266] The recommendation module is further used to recommend the target video period as a period of popular video clips to the client.
[0267] In one embodiment, the recommendation module is further used to determine an information implantation area in a video segment corresponding to a target video time period; obtain product recommendation information, and implant the product recommendation information into the information implantation area; and recommend the video segment implanted with the product recommendation information to the client.
[0268] In the above embodiment, by obtaining the barrage text and the corresponding text playback time about the comment target video, it can be determined based on the barrage text and the text playback time that the target video time period has a large number of barrage texts. Then the video clip corresponding to the target video time period is a popular video clip that everyone is paying attention to, and the popular video clip is recommended to the target object as a target recommended video clip. Therefore, even if the target video is longer in duration and has more content, the popular video clip in the target video can be directly located for playback, which is beneficial to the playback efficiency of the target video.
[0269] In one embodiment, the apparatus further comprises:
[0270] a third receiving module, configured to receive, when the recommended media is music, a resource sharing message generated based on the music and a resource to be shared, sent by the first client;
[0271] a sending module, configured to send a resource sharing message to at least one second client;
[0272] The determination module is further configured to, upon receiving a resource acquisition request uploaded by a target client in the second client, determine a third similarity between the music and the performance music carried in the resource acquisition request; the performance music is obtained based on the music;
[0273] The transfer module is configured to transfer at least a portion of the resources to be shared to the resource account of the target object when the third similarity satisfies a preset similarity condition.
[0274] In the above embodiment, when the target object receives the recommended music, it can apply the music to resource sharing, that is, send a resource sharing message and the resources to be shared to the server. The server will transfer at least part of the resources to be shared to the resource account of the target object based on the similarity between the music and the singing music uploaded by other objects. If the similarity meets the preset similarity conditions, it will enrich the diversity of resource sharing gameplay and enhance the interactivity between each object and the resources. In addition, it is also conducive to livening up the atmosphere and increasing the fun during the resource sharing process.
[0275] Each module in the aforementioned media diversity recommendation device may be implemented in whole or in part through software, hardware, or a combination thereof. Each module may be embedded in or independent of a processor within a computer device in the form of hardware, or may be stored in a computer device memory in the form of software, so that the processor can call and execute the corresponding operations of each module.
[0276] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Figure 10As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, abbreviated as I / O) and a communication interface. The processor, memory and input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and computer program in the non-volatile storage medium. The database of the computer device is used to store media data and object data. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a media diversity recommendation method is implemented.
[0277] Those skilled in the art will understand that Figure 10 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than shown in the figure, or combine certain components, or have a different component arrangement.
[0278] In one embodiment, a computer device is provided, including a memory and a processor. The memory stores a computer program, and the processor implements the steps of a method for recommending diversity of rights-based media when executing the computer program.
[0279] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the media diversity recommendation method are implemented.
[0280] In one embodiment, a computer program product is provided, comprising a computer program, which implements the steps of the media diversity recommendation method when executed by a processor.
[0281] It should be noted that the object information or object characteristics (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions.
[0282] Those skilled in the art will appreciate that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, database or other media used in the embodiments provided in this application may include at least one of non-volatile or volatile memory. Non-volatile memory may include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory may include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in the various embodiments provided herein may include at least one of a relational database and a non-relational database. Non-relational databases may include, but are not limited to, distributed databases based on blockchains. The processor involved in the various embodiments provided herein may be, but are not limited to, a general-purpose processor, a central processing unit, a graphics processing unit, a digital signal processor, a programmable logic unit, a data processing logic unit based on quantum computing, and the like.
[0283] The technical features of the above embodiments can be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0284] The above-described embodiments merely represent several implementation methods of the present application. While the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present application. It should be noted that a person of ordinary skill in the art may make various modifications and improvements without departing from the spirit of the present application, and these modifications and improvements fall within the scope of protection of the present application. Therefore, the scope of protection of the present application shall be determined by the appended claims.
Claims
1. A media diversity recommendation method, characterized in that: The method comprises: Extracting neighbor nodes of each order corresponding to the media node and the object node in the first network node graph; the object node and the media node are nodes corresponding to the target object and the candidate media respectively; the neighbor nodes of each order include neighbor nodes of each neighbor layer number; Cross-processing the representation vectors corresponding to the neighboring nodes of each order of the media node with the representation vectors corresponding to the neighboring nodes of each order of the object node to obtain a cross-vector; Determining a diversity index of the target object based on the media set with which the target object has interacted; the diversity index is used to indicate the degree of interest of the target object in different media types; Among the candidate media, media of different media types are selected for recommendation based on the diversity index and the cross vector.
2. The method according to claim 1, characterized in that The step of performing cross processing on the representation vectors corresponding to the neighboring nodes of each order of the media node and the representation vectors corresponding to the neighboring nodes of each order of the object node to obtain the cross vectors includes: Aggregating neighbor nodes of each order of the media node to obtain a first neighbor aggregation node; Aggregating neighbor nodes of each order of the object node to obtain a second neighbor aggregation node; Cross-processing is performed on the representation vector of the first neighbor aggregation node and the representation vector of the second neighbor aggregation node to obtain a cross-vector.
3. The method according to claim 2, characterized in that The number of neighbor layers corresponds to the neighbor class; aggregating neighbor nodes of each class of the media node to obtain a first neighbor aggregation node includes: Aggregating neighbor nodes of the media node that belong to the same neighbor class to obtain a first neighbor aggregation node of each neighbor class of the media node; The aggregating neighbor nodes of each order of the object node to obtain a second neighbor aggregation node includes: Aggregation processing is performed on neighbor nodes of the object node that belong to the same neighbor level to obtain second neighbor aggregation nodes of each neighbor level of the object node.
4. The method according to claim 3, characterized in that The cross processing of the representation vector of the first neighbor aggregation node and the representation vector of the second neighbor aggregation node to obtain the cross vector includes: Cross-process the representation vector of the first neighbor aggregation node of the first neighbor level with the representation vector of the second neighbor aggregation node of each neighbor level in sequence, until the representation vector of the first neighbor aggregation node of the last neighbor level is crossed with the representation vector of the second neighbor aggregation node of each neighbor level in sequence, to obtain a crossover subvector with the number of neighbor orders; The cross sub-vectors are concatenated to obtain the cross vector.
5. The method according to claim 1, wherein Determining the diversity index of the target object based on the media set with which the target object has interacted includes: Obtaining a media collection with which the target object has interacted; Constructing a second network node graph using the object node of the target object and the media in the media set as nodes; Extracting neighbor nodes of each order corresponding to the media in the media set from the second network node graph; Determine, based on the attention coefficient and the representation vectors of the neighboring nodes of each order corresponding to the media in the media set, an aggregated subvector between every two neighboring nodes of each order in the media set; A diversity index of the target object is determined based on the aggregated sub-vector.
6. The method according to claim 5, characterized in that Determining the diversity index of the target object based on the aggregation sub-vector includes: Performing vector splicing on the aggregated subvectors between every two order neighbor nodes to obtain a spliced vector; Performing mapping processing on the splicing vector based on a multi-layer perceptron, and normalizing the result obtained by the mapping processing according to an objective function to obtain a normalized result; A diversity index of the target object is determined based on the normalized result.
7. The method according to claim 1, characterized in that The selecting media of different media types from the candidate media for recommendation based on the diversity index and the cross vector includes: determining a first interaction score of the target object to the candidate media based on the intersection vector; Among the candidate media, media of different media types are selected for recommendation based on the diversity index and the first interaction score.
8. The method according to claim 7, characterized in that The method further comprises: determining a first similarity between each media in the candidate media based on the intersection vector; The selecting media of different media types from the candidate media for recommendation based on the diversity index and the first interaction score includes: Based on the diversity index and the first interaction score, sequentially determining the relevance between the target object and an i-th medium among the candidate media, and determining an adjustment parameter of the i-th medium; Determining a score value of each of the i-th media based on the relevance and the adjustment parameter; When the score reaches a preset recommendation condition, the i-th media is added to the recommended media set, and i is incremented, and the process of sequentially determining the relevance between the target object and the i-th media in the candidate media based on the diversity index and the first interaction score is returned to, until the k-th i-th media meeting the preset recommendation condition is added to the recommended media set; wherein k is a preset number of media recommendations; Recommend each media in the recommended media set to the target object.
9. The method according to claim 8, characterized in that The determining of the adjustment parameter of the i-th medium includes: When the first similarity between the jth medium in the candidate media and the ith medium reaches a preset similarity condition, an adjustment parameter of the ith medium is determined according to the diversity index and the first similarity between the ith medium and the jth medium; wherein i≠j.
10. The method according to any one of claims 1 to 9, characterized in that Applied to a graph neural network, the method further includes: In a third network node graph, the graph neural network is used to extract training neighbor nodes of each order corresponding to sample media nodes and sample object nodes; the third network node graph is generated based on an interaction matrix between sample objects and sample media; the sample media includes positive sample media that have interacted with the sample objects and negative sample media that have not interacted with the sample objects; Cross-processing the representation vectors corresponding to the neighboring nodes of each order of the sample media node with the representation vectors corresponding to the neighboring nodes of each order of the sample object node to obtain a training cross-vector; Determining a diversity index of the target object based on the positive sample media; the diversity index is used to represent the interest level of the sample object in different media types; Selecting media of different media types from the sample media as recommended media based on the diversity index and the training cross vector; A loss value is determined according to the recommended media and the corresponding media tags, and parameters of the graph neural network are optimized based on the loss value.
11. The method according to claim 10, characterized in that The method further comprises: determining, based on the training cross vector, a second interaction score of the sample object to the sample media and a second similarity between media in the sample media; Based on the diversity index and the second interaction score, sequentially determining the relevance between the sample object and each medium in the sample media, and determining an adjustment parameter for each medium in the sample media; Determining a score value for each media in the sample media based on the currently determined relevance and the adjustment parameter; Determining the loss value based on the recommended media and the corresponding media tags includes: A loss value is determined based on the score value, the recommended media, and the corresponding media tag.
12. The method according to any one of claims 1 to 9, characterized in that The candidate media includes at least one of a live broadcast room, video, animation, music or image.
13. The method according to any one of claims 1 to 9, characterized in that The diversity index includes recommendation indexes corresponding to different media types; the method further includes: When the recommended media is a live broadcast room, receiving live broadcast room interaction information sent by the client; Determining a target live broadcast room for interaction with the target object based on the live broadcast room interaction information; When the residence time of the target live broadcast room meets the preset conditions, the recommendation index corresponding to the media type of the target live broadcast room is weighted based on the weighting coefficient to obtain a weighted recommendation index; the weighted recommendation index is used for the next live broadcast room recommendation.
14. The method according to any one of claims 1 to 9, characterized in that The method further comprises: When the recommended media is a video, receiving a playback request for a target video sent by a client; the target video is one of the recommended videos; Obtain the bullet text and text playback time of the target video; Determining the number of barrage texts in each video period of the target video in the barrage text according to the text playback time; From the video period, select a target video period in which the number of barrage texts reaches a quantity condition; The target video time period is recommended to the client as a time period of popular video clips.
15. The method according to claim 14, characterized in that The recommending the target video time period as a time period of popular video clips to the client includes: Determining an information embedding area in a video segment corresponding to the target video time period; Acquire product recommendation information, and embed the product recommendation information into the information embedding area; The video clip embedded with the product recommendation information is recommended to the client.
16. The method according to any one of claims 1 to 9, characterized in that The method further comprises: When the recommended media is music, receiving a resource sharing message and resources to be shared generated based on the music from the first client; Sending the resource sharing message to at least one second client; When receiving a resource acquisition request uploaded by a target client in the second client, determining a third similarity between the music and the performance music carried in the resource acquisition request; the performance music is obtained based on the music; When the third similarity satisfies a preset similarity condition, at least a portion of the resources to be shared is transferred to the resource account of the target object.
17. A media diversity recommendation device, characterized in that: The device comprises: An extraction module is configured to extract neighbor nodes of various orders corresponding to the media node and the object node, respectively, from the first network node graph; the object node and the media node are nodes corresponding to the target object and the candidate media, respectively; the neighbor nodes of various orders include neighbor nodes of various neighbor layers; a crossover module, configured to cross-process the representation vectors corresponding to the neighboring nodes of each order of the media node with the representation vectors corresponding to the neighboring nodes of each order of the object node to obtain a crossover vector; a determination module, configured to determine a diversity index of the target object based on a set of media with which the target object has interacted; the diversity index is used to indicate the degree of interest of the target object in different media types; A recommendation module is configured to select media of different media types from the candidate media for recommendation based on the diversity index and the cross vector.
18. The device according to claim 17, characterized in that The crossover module is further configured to aggregate neighbor nodes of each order of the media node to obtain a first neighbor aggregation node; aggregate neighbor nodes of each order of the object node to obtain a second neighbor aggregation node; and cross-process the representation vector of the first neighbor aggregation node with the representation vector of the second neighbor aggregation node to obtain a crossover vector.
19. The device according to claim 18, characterized in that The number of neighbor layers corresponds to the neighbor class; The cross-connect module is further configured to aggregate neighbor nodes of the media node that belong to the same neighbor class to obtain a first neighbor aggregation node of each neighbor class of the media node; Aggregation processing is performed on neighbor nodes of the object node that belong to the same neighbor level to obtain second neighbor aggregation nodes of each neighbor level of the object node.
20. The device according to claim 19, characterized in that The crossover module is further used to perform crossover processing on the representation vector of the first neighbor aggregation node of the first neighbor level in sequence with the representation vector of the second neighbor aggregation node of each neighbor level, until the representation vector of the first neighbor aggregation node of the last neighbor level is crossover processed with the representation vector of the second neighbor aggregation node of each neighbor level in sequence, to obtain a crossover sub-vector whose vector number is the number of neighbor orders; and to perform vector splicing on each of the crossover sub-vectors to obtain the crossover vector.
21. The device according to claim 17, characterized in that The determination module is further configured to obtain a media set with which the target object has interacted; construct a second network node graph using the object node of the target object and the media in the media set as nodes; and extract neighbor nodes of each order corresponding to the media in the media set from the second network node graph; Determine, based on the attention coefficient and the representation vectors of the neighboring nodes of each order corresponding to the media in the media set, an aggregated subvector between every two neighboring nodes of each order in the media set; A diversity index of the target object is determined based on the aggregated sub-vector.
22. The device according to claim 21, characterized in that The determination module is further used to perform vector splicing on the aggregated sub-vectors between every two order neighbor nodes to obtain a spliced vector; perform mapping processing on the spliced vector based on a multi-layer perceptron, and normalize the result obtained by the mapping processing according to the objective function to obtain a normalized result; and determine the diversity index of the target object based on the normalized result.
23. The device according to claim 17, wherein The recommendation module is further configured to determine a first interaction score of the target object for the candidate media based on the cross vector; and select media of different media types from the candidate media for recommendation based on the diversity index and the first interaction score.
24. The device according to claim 23, characterized in that The recommendation module is further configured to determine a first similarity between each media in the candidate media based on the cross vector; determine the correlation between the target object and the i-th media in the candidate media in turn based on the diversity index and the first interaction score, and determine the adjustment parameters of the i-th media; determine a score value for each i-th media based on the correlation and the adjustment parameters; when the score value reaches a preset recommendation condition, add the i-th media to the recommended media set, increment i, and return to execute the process of determining the correlation between the target object and the i-th media in the candidate media in turn based on the diversity index and the first interaction score, until the k-th i-th media that meets the preset recommendation condition is added to the recommended media set; wherein k is a preset number of media recommendations; and recommend each media in the recommended media set to the target object.
25. The device according to claim 24, characterized in that The recommendation module is further configured to determine, when a first similarity between the jth medium in the candidate media and the ith medium reaches a preset similarity condition, an adjustment parameter of the ith medium based on the diversity index and the first similarity between the ith medium and the jth medium; wherein i≠j.
26. The device according to any one of claims 17 to 25, characterized in that Applied to a graph neural network, the device further includes: The extraction module is further configured to extract, from a third network node graph, training neighbor nodes of each order corresponding to sample media nodes and sample object nodes, respectively, using the graph neural network; the third network node graph is generated based on an interaction matrix between sample objects and sample media; the sample media includes positive sample media that have interacted with the sample objects and negative sample media that have not interacted with the sample objects; The crossover module is further configured to cross-process the representation vectors corresponding to the neighboring nodes of each order of the sample media node with the representation vectors corresponding to the neighboring nodes of each order of the sample object node to obtain a training crossover vector; The determination module is further configured to determine a diversity index of the target object based on the positive sample media; the diversity index is used to represent the degree of interest of the sample object in different media types; A first selection module is configured to select media of different media types from the sample media as recommended media based on the diversity index and the training cross vector; An optimization module is used to determine a loss value based on the recommended media and the corresponding media tags, and to optimize the parameters of the graph neural network based on the loss value.
27. The device according to claim 26, characterized in that The determination module is further configured to determine, based on the training cross vector, a second interaction score of the sample object with respect to the sample media, and a second similarity between each medium in the sample media; sequentially determine, based on the diversity index and the second interaction score, a correlation between the sample object and each medium in the sample media, and determine an adjustment parameter for each medium in the sample media; and determine a score for each medium in the sample media based on the currently determined correlation and the adjustment parameter. The optimization module is further configured to determine a loss value based on the score value and the recommended media and the corresponding media tag.
28. The device according to any one of claims 17 to 25, characterized in that The candidate media includes at least one of a live broadcast room, video, animation, music or image.
29. The device according to any one of claims 17 to 25, characterized in that The diversity index includes recommendation indexes corresponding to different media types; the apparatus further includes: A second receiving module is configured to receive live broadcast room interaction information sent by the client when the recommended media is a live broadcast room; The determination module is further configured to determine a target live broadcast room for interaction of the target object based on the live broadcast room interaction information; The weighting module is used to weight the recommendation index corresponding to the media type of the target live broadcast room based on the weighting coefficient when the residence time of the target live broadcast room meets the preset conditions, so as to obtain the weighted recommendation index; the weighted recommendation index is used for the next live broadcast room recommendation.
30. The device according to any one of claims 17 to 25, characterized in that The device further comprises: A first receiving module is configured to receive a playback request for a target video sent by a client when the recommended media is a video; the target video is one of the recommended videos; An acquisition module is used to obtain the bullet text and text playback time of the target video; The determining module is further configured to determine the number of barrage texts in the barrage text belonging to each video period of the target video according to the text playback time; The second selection module is used to select a target video period in which the number of the barrage texts meets the quantity condition from the video period; The recommendation module is further configured to recommend the target video time period as a time period of popular video clips to the client.
31. The device according to claim 30, characterized in that The recommendation module is further used to determine an information implantation area in the video segment corresponding to the target video time period; obtain product recommendation information and implant the product recommendation information into the information implantation area; and recommend the video segment implanted with the product recommendation information to the client.
32. The device according to any one of claims 17 to 25, characterized in that The device further comprises: a third receiving module, configured to, when the recommended media is music, receive a resource sharing message and a resource to be shared generated based on the music and sent by the first client; A sending module, configured to send the resource sharing message to at least one second client; The determining module is further configured to, upon receiving a resource acquisition request uploaded by a target client in the second client, determine a third similarity between the music and the performance music carried in the resource acquisition request; the performance music is obtained based on the music; A transfer module is configured to transfer at least a portion of the to-be-shared resources to the resource account of the target object when the third similarity satisfies a preset similarity condition.
33. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 16 are implemented.
34. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 16 are implemented.
35. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 16 are implemented.
Citation Information
Patent Citations
Video recommendation method and computer readable storage medium
CN110941740A
Multimedia recommendation method and device, electronic equipment, and storage medium
CN113792163A