Resource recommendation methods, recommendation model training methods, devices and storage media
By acquiring the attribute and location information of preset objects, using the correlation relationship to determine the model to filter the data to be identified, and inputting it into the resource recommendation model for recommendation, the problem of low accuracy in multimedia resource recommendation is solved, and a higher recommendation accuracy is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- TSINGHUA UNIVERSITY
- Filing Date
- 2023-01-03
- Publication Date
- 2026-05-26
AI Technical Summary
Existing technologies do not consider user location information during multimedia resource recommendation, resulting in low recommendation accuracy.
By acquiring the attributes, location information, and candidate multimedia resource information of preset objects, the relationship determination model is used to determine the location resource relationship, filter out the data to be identified, and input it into the resource recommendation model for recommendation, thereby improving the recommendation accuracy.
By taking user location information into account, the accuracy of multimedia resource recommendations has been improved.
Smart Images

Figure CN116010695B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of computer technology, and in particular to a resource recommendation method, a recommendation model training method, an apparatus, and a storage medium. Background Technology
[0002] With the booming development of mobile internet, users' access to the internet has been freed from geographical limitations. Users can access various content from any location, and the user's location when accessing content has a significant impact on the content accessed.
[0003] In related technologies, multimedia resource recommendation is usually based on user characteristics and the user's browsing history, without considering the user's location information, resulting in low accuracy of multimedia resource recommendation. Summary of the Invention
[0004] This disclosure provides a resource recommendation method, a recommendation model training method, an apparatus, and a storage medium to at least address the problem of low accuracy in multimedia resource recommendation in related technologies. The technical solution of this disclosure is as follows:
[0005] According to a first aspect of the present disclosure, a resource recommendation method is provided, comprising:
[0006] Obtain the preset object attributes of the preset object, the candidate resource information of the candidate multimedia resources, and the preset location information corresponding to the preset object;
[0007] The preset object attributes, the preset location information, and the candidate resource information are input into the association relationship determination model to determine the location resource relationship, thereby obtaining the preset relationship determination result; the preset relationship determination result indicates whether there is an association relationship between the preset object attributes, the preset location information, and the candidate resource information for the preset object.
[0008] Based on the predetermined relationship determination result, data to be identified is determined from the predetermined object attributes, the predetermined location information, and the candidate resource information. The data to be identified is data used for resource recommendation analysis. When the predetermined relationship determination result indicates that the predetermined location information and the candidate resource information are related, the data to be identified is the predetermined object attributes, the predetermined location information, and the candidate resource information. When the predetermined relationship determination result indicates that the predetermined location information and the candidate resource information are not related, the data to be identified is the predetermined object attributes and the candidate resource information.
[0009] The data to be identified is input into a resource recommendation model to perform resource recommendation, and a target recommendation result is obtained; the target recommendation result represents the probability of recommending the candidate multimedia resources to the preset object.
[0010] In an exemplary embodiment, the association relationship determination model includes a central feature extraction network and an association relationship determination network. The step of inputting the preset object attributes, the preset location information, and the candidate resource information into the association relationship determination model to determine the location-resource relationship and obtain the preset relationship determination result includes:
[0011] Based on the central feature extraction network, feature extraction processing is performed on the preset object attributes, the preset location information, and the historical multimedia resources browsed by the preset object at the location corresponding to the preset location information to obtain the resource center feature corresponding to the preset object; the resource center feature is not related to the preset location information.
[0012] Based on the aforementioned relationship, a network is determined, the similarity between the candidate resource information and the resource center features is determined, and the preset relationship determination result is determined based on the similarity.
[0013] In one exemplary implementation, determining the preset relationship determination result based on the similarity includes:
[0014] If the similarity is less than or equal to a preset similarity threshold, it is determined that the candidate resource information and the preset location information are not related.
[0015] If the similarity is greater than the preset similarity threshold, it is determined that the candidate resource information and the preset location information are related.
[0016] In one exemplary embodiment, the data to be identified includes first data to be identified and second data to be identified. The step of determining the data to be identified from the preset object attributes, the preset location information, and the candidate resource information based on the preset relationship determination result includes:
[0017] If the preset relationship determination result indicates that the preset location information and the candidate resource information are not related, the preset object attribute and the candidate resource information are determined as the first data to be identified;
[0018] If the preset relationship determination result indicates that there is an association between the preset location information and the candidate resource information, the preset object attribute, the preset location information, and the candidate resource information are determined as the second data to be identified.
[0019] In one exemplary embodiment, the resource recommendation model includes a first recommendation feature extraction network, a second recommendation feature extraction network, and a resource recommendation network. The step of inputting the data to be identified into the resource recommendation model to perform resource recommendation and obtain the target recommendation result includes:
[0020] The first recommendation feature is extracted from the first recommendation feature extraction network; or the second recommendation feature is extracted from the second recommendation feature extraction network.
[0021] The target recommendation result is obtained by performing recommendation result recognition processing on the target recommendation feature based on the resource recommendation network; the target recommendation feature is either the first recommendation feature or the second recommendation feature.
[0022] In one exemplary embodiment, the preset objects are multiple, and the method further includes:
[0023] A preset heterogeneous graph is constructed based on the preset object attributes, preset location information, and candidate resource information corresponding to each of the multiple preset objects; the nodes of the preset heterogeneous graph represent the preset object attributes and the candidate resource information, and the edges of the preset heterogeneous graph represent the preset location information.
[0024] The step of inputting the preset object attributes, the preset location information, and the candidate resource information into the association relationship determination model to determine the location resource relationship and obtain the preset relationship determination result includes:
[0025] The preset heterogeneous graph is input into the association relationship determination model to determine the location resource relationship, and the preset relationship determination result is obtained.
[0026] According to a second aspect of the present disclosure, a method for training a resource recommendation model is provided, the method comprising:
[0027] Obtain the sample object attributes of the sample object, the sample location information corresponding to the sample object, and the sample resource information of the sample multimedia resources browsed by the sample object at the sample location; the sample location is the location corresponding to the sample location information.
[0028] The sample object attributes, the sample location information, and the sample resource information are input into the association relationship determination model to be trained to determine the location-resource relationship, and the sample relationship determination result is obtained. The sample relationship determination result indicates whether there is an association relationship between the sample object attributes, the sample location information, and the sample resource information for the sample object.
[0029] Based on the sample relationship determination result, sample data to be identified is determined from the sample object attributes, the sample location information, and the sample resource information. The sample data to be identified is data used for resource recommendation analysis. If the sample relationship determination result indicates a correlation between the sample location information and the sample resource information, the sample data to be identified consists of the sample object attributes, the sample location information, and the sample resource information. If the sample relationship determination result indicates no correlation between the sample location information and the sample resource information, the sample data to be identified consists of the sample object attributes and the sample resource information.
[0030] The sample data to be identified is input into the resource recommendation model to be trained to perform resource recommendation and obtain the sample recommendation result.
[0031] Based on the sample relationship determination results and the sample recommendation results, the relationship determination model to be trained and the resource recommendation model to be trained are trained, and the resource recommendation model to be trained at the end of training is determined as the resource recommendation model.
[0032] In an exemplary embodiment, the sample objects include a first sample object and a second sample object. The first sample object's first sample location information is associated with the first sample resource information, while the second sample object's second sample location information is not associated with the second sample resource information. The step of determining the sample data to be identified from the sample object attributes, the sample location information, and the sample resource information based on the sample relationship determination result includes:
[0033] The first sample object attribute, the first sample location information, and the first sample resource information of the first sample object are determined as the first sample data;
[0034] The second sample object attributes and the second sample resource information of the second sample object are determined as the second sample data;
[0035] Based on the first sample data and the second sample data, the sample data to be identified is determined.
[0036] In an exemplary implementation, the sample resource information is labeled with object behavior tags and resource location relationship tags, whereby the resource location relationship tags characterize sample object attributes for the sample object. The step of determining whether there is a correlation between the sample resource information and the sample location information, and training the correlation determination model and the resource recommendation model based on the sample relationship determination result and the sample recommendation result, includes:
[0037] Based on the difference between the sample recommendation results and the object behavior labels, the first loss information is determined;
[0038] Based on the difference between the sample relationship determination result and the resource location relationship label, a second loss information is determined;
[0039] Based on the first loss information and the second loss information, the model parameters corresponding to the relationship determination model to be trained and the resource recommendation model to be trained are adjusted until the training termination condition is met, and the resource recommendation model to be trained at the end of training is determined as the resource recommendation model.
[0040] In an exemplary embodiment, the model for determining the association relationship to be trained includes an attribute feature extraction network, a location feature extraction network, and a resource information extraction network. The step of inputting the sample object attributes, the sample location information, and the sample resource information into the model for determining the association relationship to be trained to determine the location-resource relationship and obtain the sample relationship determination result includes:
[0041] Based on the attribute feature extraction network, the attribute features of the sample object are extracted to obtain the sample attribute features;
[0042] Based on the location feature extraction network, the location features of the sample location information are extracted to obtain the sample location features;
[0043] Based on the resource information extraction network, resource features of the sample resource information are extracted to obtain sample resource features;
[0044] Based on the sample attribute features, the sample location features, and the sample resource features, the sample relationship determination result is determined.
[0045] In one exemplary embodiment, the method further includes:
[0046] The sample attribute features are input into the location prediction model to be trained to obtain the location prediction result; the sample object attributes are labeled with sample location information tags;
[0047] Based on the difference between the location prediction result and the sample location information label, a third loss information is determined;
[0048] The step of adjusting the model parameters corresponding to the relationship determination model and the resource recommendation model to be trained, based on the first loss information and the second loss information, until the training termination condition is met, includes:
[0049] Based on the first loss information, the second loss information, and the third loss information, adjust the model parameters corresponding to the training relationship determination model, the training resource recommendation model, and the training location prediction model until the training termination condition is met.
[0050] In one exemplary embodiment, the resource location relationship label includes a first resource location relationship label and a second resource location relationship label, and the method for determining the resource location relationship label of the sample resource information includes:
[0051] Based on the sample resource center features corresponding to the sample object, determine the similarity between the sample resource information and the sample resource center features;
[0052] The sample resource information is sorted from largest to smallest according to the similarity corresponding to the sample resource information, and a first preset number of sample resource information and a last preset number of sample resource information are determined.
[0053] The first resource location relationship label is used to label the first preset number of sample resource information; the first resource location relationship label indicates that the first preset number of sample resource information is associated with the preset location information.
[0054] The second resource location relationship label is used to label the subsequent preset number of sample resource information; the second resource location relationship label indicates that the subsequent preset number of sample resource information has no correlation with the preset location information.
[0055] According to a third aspect of the present disclosure, a training apparatus for a resource recommendation model is provided, comprising:
[0056] The information acquisition module is configured to acquire preset object attributes of a preset object, candidate resource information of candidate multimedia resources, and preset location information corresponding to the preset object;
[0057] The result determination module is configured to perform location resource relationship determination by inputting the preset object attributes, the preset location information, and the candidate resource information into the association relationship determination model, and obtain the preset relationship determination result; the preset relationship determination result indicates whether there is an association relationship between the preset object attributes, the preset location information, and the candidate resource information for the preset object.
[0058] The data to be identified module is configured to determine data to be identified from the preset object attributes, the preset location information, and the candidate resource information based on the preset relationship determination result. The data to be identified is data used for resource recommendation analysis. When the preset relationship determination result indicates that the preset location information and the candidate resource information are related, the data to be identified is the preset object attributes, the preset location information, and the candidate resource information. When the preset relationship determination result indicates that the preset location information and the candidate resource information are not related, the data to be identified is the preset object attributes and the candidate resource information.
[0059] The recommendation result determination module is configured to input the data to be identified into a resource recommendation model to perform resource recommendation and obtain a target recommendation result; the target recommendation result represents the probability of recommending the candidate multimedia resource to the preset object.
[0060] In one exemplary embodiment, the association determination model includes a central feature extraction network and an association determination network, and the result determination module includes:
[0061] The feature extraction unit is configured to execute on the central feature extraction network to perform feature extraction processing on the preset object attributes, the preset location information, and the historical multimedia resources browsed by the preset object at the location corresponding to the preset location information, to obtain the resource center features corresponding to the preset object; the resource center features are not related to the preset location information;
[0062] The result determination unit is configured to execute the association determination network to determine the similarity between the candidate resource information and the resource center features, and to determine the preset relationship determination result based on the similarity.
[0063] In one exemplary embodiment, the result determination unit includes:
[0064] The first determining subunit is configured to determine that if the similarity is less than or equal to a preset similarity threshold, the candidate resource information and the preset location information are not related.
[0065] The second determining subunit is configured to determine that the candidate resource information and the preset location information are associated if the similarity is greater than the preset similarity threshold.
[0066] In one exemplary embodiment, the data to be identified determination module includes:
[0067] The first data determination unit is configured to determine the preset object attribute and the candidate resource information as the first data to be identified when the preset relationship determination result indicates that the preset location information and the candidate resource information are not related.
[0068] The second data determination unit is configured to determine the preset object attribute, the preset location information, and the candidate resource information as the second data to be identified when the preset relationship determination result indicates that the preset location information and the candidate resource information are associated.
[0069] In one exemplary embodiment, the resource recommendation model includes a first recommendation feature extraction network, a second recommendation feature extraction network, and a resource recommendation network, and the recommendation result determination module includes:
[0070] The recommendation feature extraction unit is configured to perform the following: extracting a first recommendation feature based on the first recommendation feature extraction network; or extracting a second recommendation feature based on the second recommendation feature extraction network;
[0071] The recommendation result determination unit is configured to perform recommendation result recognition processing on the target recommendation feature based on the resource recommendation network to obtain the target recommendation result; the target recommendation feature is the first recommendation feature or the second recommendation feature.
[0072] In one exemplary embodiment, there are multiple preset objects, and the device further includes:
[0073] The heterogeneous graph construction module is configured to construct a preset heterogeneous graph based on the preset object attributes, preset location information, and candidate resource information corresponding to each of the multiple preset objects; the nodes of the preset heterogeneous graph represent the preset object attributes and the candidate resource information, and the edges of the preset heterogeneous graph represent the preset location information;
[0074] In one exemplary embodiment, the result determination module includes:
[0075] The heterogeneous graph input unit is configured to perform location resource relationship determination by inputting the preset heterogeneous graph into the association relationship determination model, and obtain the preset relationship determination result.
[0076] According to a fourth aspect of the present disclosure, a training apparatus for a resource recommendation model is provided, comprising:
[0077] The sample information acquisition module is configured to acquire the sample object attributes of the sample object, the sample location information corresponding to the sample object, and the sample resource information of the sample multimedia resources browsed by the sample object at the sample location; the sample location is the location corresponding to the sample location information.
[0078] The sample result determination module is configured to input the sample object attributes, the sample location information, and the sample resource information into the association determination model to be trained to determine the location-resource relationship and obtain the sample relationship determination result; the sample relationship determination result indicates whether there is an association relationship between the sample object attributes, the sample location information, and the sample resource information for the sample object.
[0079] The sample data determination module is configured to determine sample data to be identified from the sample object attributes, the sample location information, and the sample resource information based on the sample relationship determination result. The sample data to be identified is data used for resource recommendation analysis. If the sample relationship determination result indicates a correlation between the sample location information and the sample resource information, the sample data to be identified consists of the sample object attributes, the sample location information, and the sample resource information. If the sample relationship determination result indicates no correlation between the sample location information and the sample resource information, the sample data to be identified consists of the sample object attributes and the sample resource information.
[0080] The sample recommendation result determination module is configured to input the sample data to be identified into the resource recommendation model to be trained to perform resource recommendation and obtain the sample recommendation result.
[0081] The model training module is configured to train the relationship determination model and the resource recommendation model to be trained based on the sample relationship determination result and the sample recommendation result, and to determine the resource recommendation model to be trained at the end of training as the resource recommendation model.
[0082] In one exemplary embodiment, the sample objects include a first sample object and a second sample object. The first sample object's first sample location information is associated with the first sample resource information, while the second sample object's second sample location information is not associated with the second sample resource information. The module for determining the sample data to be identified includes:
[0083] The first data determining unit is configured to determine the first sample object attribute, the first sample location information, and the first sample resource information of the first sample object as the first sample data.
[0084] The second data determination unit is configured to determine the second sample object attributes and the second sample resource information of the second sample object as the second sample data.
[0085] The sample data determination unit is configured to determine the sample data to be identified based on the first sample data and the second sample data.
[0086] In one exemplary embodiment, the sample resource information is labeled with object behavior tags and resource location relationship tags, wherein the resource location relationship tags characterize sample object attributes for the sample object, and whether there is a correlation between the sample resource information and the sample location information, the model training module includes:
[0087] The first loss determination unit is configured to determine first loss information based on the difference between the sample recommendation result and the object behavior label.
[0088] The second loss determination unit is configured to determine second loss information based on the difference between the sample relationship determination result and the resource location relationship label.
[0089] The parameter adjustment unit is configured to adjust the model parameters corresponding to the relationship determination model and the resource recommendation model to be trained based on the first loss information and the second loss information until the training termination condition is met, and determine the resource recommendation model to be trained at the end of training as the resource recommendation model.
[0090] In one exemplary embodiment, the model for determining the association relationship to be trained includes an attribute feature extraction network, a location feature extraction network, and a resource information extraction network, and the sample result determination module includes:
[0091] The sample attribute feature determination unit is configured to extract attribute features of the sample object based on the attribute feature extraction network to obtain sample attribute features;
[0092] The sample location feature determination unit is configured to extract location features of the sample location information based on the location feature extraction network to obtain sample location features;
[0093] The sample resource feature determination unit is configured to extract resource features from the sample resource information based on the resource information extraction network to obtain sample resource features;
[0094] The sample relationship determination unit is configured to determine the sample relationship determination result based on the sample attribute features, the sample location features, and the sample resource features.
[0095] In one exemplary embodiment, the apparatus further includes:
[0096] The feature input module is configured to input the sample attribute features into the location prediction model to be trained, and obtain the location prediction result; the sample object attributes are labeled with sample location information tags.
[0097] The third loss determination module is configured to determine third loss information based on the difference between the location prediction result and the sample location information label.
[0098] In one exemplary embodiment, the parameter adjustment unit includes:
[0099] The parameter adjustment subunit is configured to adjust the model parameters of the training relation determination model, the training resource recommendation model, and the training location prediction model based on the first loss information, the second loss information, and the third loss information until the training termination condition is met.
[0100] In one exemplary embodiment, the resource location relationship label includes a first resource location relationship label and a second resource location relationship label, and the device further includes:
[0101] The similarity determination module is configured to determine the similarity between the sample resource information and the sample resource center features based on the sample resource center features corresponding to the sample object.
[0102] The sorting module is configured to sort the sample resource information according to the similarity of the sample resource information from largest to smallest, and determine the first preset number of sample resource information and the last preset number of sample resource information.
[0103] The first annotation module is configured to annotate the first resource location relationship label on the first preset number of sample resource information; the first resource location relationship label represents that the first preset number of sample resource information has an association relationship with the preset location information.
[0104] The second annotation module is configured to annotate the subsequent preset number of sample resource information with the second resource location relationship label; the second resource location relationship label represents that the subsequent preset number of sample resource information has no association with the preset location information.
[0105] According to a fifth aspect of the present disclosure, an electronic device is provided, comprising:
[0106] processor;
[0107] Memory used to store the processor's executable instructions;
[0108] The processor is configured to execute the instructions to implement the resource recommendation method or resource recommendation model training method as described above.
[0109] According to a sixth aspect of the present disclosure, a computer-readable storage medium is provided, wherein when the instructions in the computer-readable storage medium are executed by an electronic device processor, the electronic device is enabled to perform the resource recommendation method or the training method for the resource recommendation model as described above.
[0110] According to a seventh aspect of the present disclosure, a computer program product is provided, including a computer program that, when executed by a processor, implements the resource recommendation method or the training method for the resource recommendation model as described above.
[0111] The technical solutions provided by the embodiments of this disclosure have at least the following beneficial effects:
[0112] This disclosure obtains the preset object attributes of a preset object, candidate resource information of candidate multimedia resources, and preset location information corresponding to the preset object; inputs the preset object attributes, preset location information, and candidate resource information into a relationship determination model to determine the location-resource relationship, obtaining the preset relationship determination result; the preset relationship determination result indicates whether there is a relationship between the preset object attributes, preset location information, and candidate resource information for the preset object; based on the preset relationship determination result, data to be identified is determined from the preset object attributes, preset location information, and candidate resource information; the data to be identified is data used for resource recommendation analysis, and when the preset relationship determination result indicates that there is a relationship between the preset location information and the candidate resource information, the data to be identified is... The system includes preset object attributes, preset location information, and candidate resource information. When the preset relationship determination result indicates that the preset location information and candidate resource information are not related, the data to be identified consists of the preset object attributes and candidate resource information. Based on the relationship between the preset location information and candidate resource information, the system filters the preset object attributes, preset location information, and candidate resource information, determining different data to be identified based on different situations, thus improving the accuracy of the data to be identified. The data to be identified is input into a resource recommendation model for resource recommendation, yielding a target recommendation result. The target recommendation result represents the probability of recommending candidate multimedia resources to the preset object. This system improves the accuracy of the recommendation result based on the highly accurate data to be identified.
[0113] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description
[0114] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure, and are not intended to unduly limit this disclosure.
[0115] Figure 1 This is an application environment diagram illustrating a resource recommendation method according to an exemplary embodiment.
[0116] Figure 2 This is a flowchart illustrating a resource recommendation method according to an exemplary embodiment.
[0117] Figure 3 This is a flowchart illustrating a method for determining location-resource relationships by inputting preset object attributes, preset location information, and candidate resource information into an association relationship determination model according to an exemplary embodiment, and obtaining the preset relationship determination result.
[0118] Figure 4 This is a flowchart illustrating a method for determining data to be identified from the aforementioned preset object attributes, the aforementioned preset location information, and the aforementioned candidate resource information, according to an exemplary embodiment.
[0119] Figure 5 This is a flowchart illustrating a training method for a resource recommendation model according to an exemplary embodiment.
[0120] Figure 6 This is a schematic diagram of the data structure before and after extracting embedded features from a sample data set according to an exemplary embodiment.
[0121] Figure 7 This is a schematic diagram of the structure of an initial heterogeneous graph according to an exemplary embodiment.
[0122] Figure 8 This is a flowchart illustrating a method for determining the location-resource relationship by inputting sample object attributes, sample location information, and sample resource information into a model to be trained, according to an exemplary embodiment, and obtaining the sample relationship determination result.
[0123] Figure 9 This is a flowchart illustrating a method for training the aforementioned relationship determination model and resource recommendation model based on sample relationship determination results and sample recommendation results, according to an exemplary embodiment.
[0124] Figure 10 This is a flowchart illustrating a method for determining resource location relationship tags of sample resource information according to an exemplary embodiment.
[0125] Figure 11 This is a schematic diagram illustrating the working principle of a self-supervised network according to an exemplary embodiment.
[0126] Figure 12 This is a schematic diagram illustrating a sample object attribute location map according to an exemplary embodiment.
[0127] Figure 13 This is a schematic diagram illustrating the structure of a multi-task learning module according to an exemplary embodiment.
[0128] Figure 14 This is a schematic diagram illustrating the structure of a feature matching module according to an exemplary embodiment.
[0129] Figure 15 This is a schematic diagram illustrating the structure of a comprehensive recommendation model according to an exemplary embodiment.
[0130] Figure 16 This is a block diagram illustrating a resource recommendation device according to an exemplary embodiment.
[0131] Figure 17 This is a block diagram illustrating a result determination module according to an exemplary embodiment.
[0132] Figure 18 This is a block diagram of a training apparatus for a resource recommendation model according to an exemplary embodiment.
[0133] Figure 19 This is a block diagram illustrating an electronic device for training a resource recommendation model according to an exemplary embodiment. Detailed Implementation
[0134] To enable those skilled in the art to better understand the technical solutions of this disclosure, the technical solutions in the embodiments of this disclosure will be clearly and completely described below with reference to the accompanying drawings.
[0135] It should be noted that the terms "first," "second," etc., used in the specification, claims, and accompanying drawings of this disclosure are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this disclosure described herein can be implemented in orders other than those illustrated or described herein. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this disclosure. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this disclosure as detailed in the appended claims.
[0136] It should be noted that the user information (including but not limited to user device information, user location information, etc.) and data (including but not limited to data used for display, data used for analysis, etc.) involved in this disclosure are all information and data authorized by the user or fully authorized by all parties.
[0137] Among related technologies, Graph Neural Networks (GNNs) have swept across the entire recommender system field due to their powerful ability to learn structured data. For example, in the most basic recommendation task—collaborative filtering—the historical interaction data of users with multimedia resources can be constructed into a bipartite graph of users and multimedia resources. It has been proven that GNN-based collaborative filtering methods can more fully capture the high-order connectivity in the data, thus significantly outperforming methods based on traditional neural networks. Besides traditional collaborative filtering, GNNs have also achieved great success in various recommendation tasks, including social recommendation, conversation-based recommendation, and Point of Interest (POI) recommendation. Generally, these schemes first represent the input data as a graph, and then use GNN technology to define the message propagation method between nodes in the graph to learn the node representation. Although some works have considered constructing graphs containing location / POIs, these works only address the location / POI recommendation problem and do not propose solutions for the geospatial recommendation problem.
[0138] Self-supervised learning techniques have achieved encouraging results in several fields. Recently, self-supervised learning has also been introduced into some recommender system research, achieving good results on a range of tasks. Self-supervised learning methods based on bipartite graph augmentation have been used to learn user and multimedia resource representations, and then use the learned representations to recommend multimedia resources to users. Specifically, three methods are used for graph augmentation: edge removal, node removal, and random walks. In some sequence recommendation models, the sequence encoder is supervised by intentions labeled with pseudo-labels, or multimedia resource masking and sequence pruning operators are used to augment the sequence; however, these recommendation methods ignore the user's positional information when interacting with multimedia resources.
[0139] In order to accurately determine whether a preset object will click on a candidate multimedia resource at a preset location (whether it is interested in the candidate multimedia resource), and to improve the recommendation accuracy of multimedia resources, this disclosure provides a resource recommendation method, a recommendation model training method, an apparatus, and a storage medium.
[0140] Please see Figure 1 The diagram illustrates an application environment for a resource recommendation method according to an exemplary embodiment. The application environment may include a server 01 and a client 02.
[0141] Specifically, in the embodiments of this specification, server 01 may include a standalone server, a distributed server, or a server cluster composed of multiple servers. It may also be a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms. Server 01 may include a network communication unit, a processor, and a memory, etc. Specifically, server 01 can be used to obtain preset object attributes of a preset object, candidate resource information of candidate multimedia resources, and preset location information corresponding to the preset object; and to determine the data to be identified from the preset object attributes, preset location information, and candidate resource information; and input the data to be identified into a resource recommendation model for resource recommendation to obtain the target recommendation result.
[0142] Specifically, in this embodiment of the specification, the client 02 may include physical devices such as smartphones, desktop computers, tablets, laptops, digital assistants, smart wearable devices, and in-vehicle terminals, and may also include software running on the physical device, such as web pages provided to users by some service providers, or applications provided to users by these service providers. Specifically, the client 02 may display recommended results of multimedia resources for a preset object at a preset location.
[0143] Figure 2 This is a flowchart illustrating a resource recommendation method according to an exemplary embodiment, such as... Figure 2 As shown, this method can be applied to Figure 1 The server 01 shown includes the following steps.
[0144] In step S201, the preset object attributes of the preset object, the candidate resource information of the candidate multimedia resources, and the preset location information corresponding to the preset object are obtained.
[0145] In this embodiment of the disclosure, a preset data group corresponding to a preset object can be generated by combining the preset object attributes corresponding to the preset object, the candidate resource information of the candidate multimedia resources, and the preset location information corresponding to the preset object. The candidate multimedia resources can be one or more. The preset object attributes can be determined based on the object identifier of the preset object. The preset object attributes are used to characterize the attribute information of the preset object other than the location information, and may include, but are not limited to, the business domain of the preset object. The preset location information characterizes the geographical location information corresponding to the preset object. The candidate multimedia resources may include, but are not limited to, video, audio, and other resources. The candidate resource information can be information extracted based on the candidate multimedia resources, and the candidate resource information can characterize the resource features of the candidate multimedia resources.
[0146] In some embodiments, there are multiple preset objects, and the method further includes:
[0147] Based on the preset object attributes, preset location information, and candidate resource information corresponding to each of the aforementioned preset objects, a preset heterogeneous graph is constructed; the nodes of the preset heterogeneous graph represent the preset object attributes and the candidate resource information, and the edges of the preset heterogeneous graph represent the preset location information.
[0148] In this embodiment of the disclosure, there can be multiple preset objects. A preset heterogeneous graph can be constructed based on the preset object attributes, preset location information, and candidate resource information corresponding to each preset object. This facilitates the rapid determination of the preset relationship determination result corresponding to each preset object based on the preset heterogeneous graph.
[0149] In some embodiments, the above method further includes:
[0150] Extract the first preset sub-graph corresponding to the first data to be identified from the preset heterogeneous graph;
[0151] Specifically, in this embodiment of the disclosure, a first preset subgraph can be obtained by extracting the heterogeneous graph corresponding to the first data to be identified from the preset heterogeneous graph; the nodes of the first subgraph represent preset object attributes and first preset resource information, and the edges of the first preset subgraph represent the first preset location information of the preset object attributes browsing the first preset resource information.
[0152] Extract the second preset subgraph corresponding to the second preset data from the preset heterogeneous graph;
[0153] Specifically, in this embodiment of the disclosure, a heterogeneous graph corresponding to the second preset data can be extracted from a preset heterogeneous graph to obtain a second preset subgraph; the nodes of the second preset subgraph represent preset object attributes and second preset resource information, the second preset subgraph does not include preset location information, and the edges of the second preset subgraph represent the association between the preset object attributes and the second preset resource information; that is, they represent that the preset object attributes have browsed the second preset multimedia resources.
[0154] The first preset subgraph or the second preset subgraph mentioned above is determined as the target heterogeneous graph.
[0155] In step S203, the preset object attributes, the preset location information, and the candidate resource information are input into the association relationship determination model to determine the location resource relationship and obtain the preset relationship determination result. The preset relationship determination result indicates whether there is an association relationship between the preset object attributes, the preset location information, and the candidate resource information for the preset object.
[0156] In this embodiment, a relationship determination model can be pre-trained. This model determines the relationship between preset object attributes, preset location information, and candidate resource information corresponding to a preset object, yielding a relationship determination result. This result indicates whether a relationship exists between the preset location information and the candidate resource information. The result can include a first result and a second result. The first result indicates that a relationship exists between the preset location information and the candidate resource information; the second result indicates that no relationship exists between the preset location information and the candidate resource information. The relationship determination model can quickly determine whether a relationship exists between the preset location information corresponding to a preset object and the candidate resource information, thereby further determining the data to be identified.
[0157] In this embodiment of the disclosure, the aforementioned association determination model includes a central feature extraction network and an association determination network, such as... Figure 3 As shown, the aforementioned preset object attributes, preset location information, and candidate resource information are input into the association relationship determination model to determine the location resource relationship, and the preset relationship determination result is obtained, including:
[0158] In step S2031, based on the aforementioned central feature extraction network, feature extraction processing is performed on the aforementioned preset object attributes, the aforementioned preset location information, and the historical multimedia resources browsed by the aforementioned preset object at the location corresponding to the aforementioned preset location information to obtain the resource center features corresponding to the aforementioned preset object; the aforementioned resource center features are not related to the aforementioned preset location information.
[0159] In this embodiment of the disclosure, the association relationship determination model may include a central feature extraction network and an association relationship determination network. The central feature extraction network is used to extract the resource center feature corresponding to the preset object based on the historical multimedia resources of the preset object. The resource center feature corresponds to the resource that the preset object will access at any location. The resource center feature has no association with the preset location information.
[0160] In step S2033, the network is determined based on the above-mentioned association relationship, the similarity between the above-mentioned candidate resource information and the above-mentioned resource center features is determined, and the result of the above-mentioned preset relationship determination is determined based on the above-mentioned similarity.
[0161] In this embodiment of the disclosure, the association determination network can be used to determine the similarity between candidate resource information and resource center features, and to determine the preset relationship determination result based on the similarity.
[0162] In this embodiment of the disclosure, the resource center features of the preset object can be extracted based on the historical multimedia resources browsed by the preset object. These resource center features are not related to the preset location information. The preset relationship determination result is determined based on the similarity between the resource center features and the candidate resource information, thereby improving the accuracy of the preset relationship determination result.
[0163] In some embodiments, determining the preset relationship determination result based on the above similarity includes:
[0164] If the above similarity is less than or equal to the preset similarity threshold, it is determined that the above candidate resource information and the above preset location information are not related.
[0165] If the similarity is greater than the preset similarity threshold, it is determined that the candidate resource information and the preset location information are related.
[0166] In this embodiment of the disclosure, the similarity calculation results between the resource center features and the candidate resource information can be used to determine whether there is a correlation between the candidate resource information and the preset location information, thereby accurately determining the data to be identified.
[0167] In some embodiments, the aforementioned preset object attributes, the aforementioned preset location information, and the aforementioned candidate resource information are input into the association relationship determination model to determine the location resource relationship, thereby obtaining the preset relationship determination result, including:
[0168] The aforementioned preset heterogeneous graph is input into the aforementioned relationship determination model to determine the location resource relationship, and the aforementioned preset relationship determination result is obtained.
[0169] In this embodiment of the disclosure, a preset heterogeneous graph can be constructed based on the preset object attributes, preset location information, and candidate resource information corresponding to the preset object; thereby facilitating the rapid determination of the preset relationship determination result corresponding to each preset object based on the preset heterogeneous graph.
[0170] In step S205, based on the preset relationship determination result, data to be identified is determined from the preset object attributes, the preset location information, and the candidate resource information. The data to be identified is data used for resource recommendation analysis. If the preset relationship determination result indicates that the preset location information and the candidate resource information are related, the data to be identified is the preset object attributes, the preset location information, and the candidate resource information. If the preset relationship determination result indicates that the preset location information and the candidate resource information are not related, the data to be identified is the preset object attributes and the candidate resource information.
[0171] In this embodiment of the disclosure, the data to be identified includes first data to be identified and second data to be identified, such as... Figure 4 As shown, based on the results determined by the aforementioned preset relationships, the data to be identified is determined from the aforementioned preset object attributes, the aforementioned preset location information, and the aforementioned candidate resource information, including:
[0172] In step S2051, if the preset relationship determination result indicates that the preset location information and the candidate resource information are not related, the preset object attribute and the candidate resource information are determined as the first data to be identified.
[0173] In this embodiment of the disclosure, if the preset location information and the candidate resource information are not related, it means that the recommendation result of the candidate resource information will not change with the change of the preset location information. In this case, the preset object attribute and the candidate resource information are determined as the first data to be identified, avoiding the introduction of location information and improving the accuracy of the recommendation result determined based on the first data to be identified.
[0174] In step S2053, if the preset relationship determination result indicates that the preset location information and the candidate resource information are related, the preset object attribute, the preset location information, and the candidate resource information are determined as the second data to be identified.
[0175] In this embodiment of the disclosure, if the preset location information and the candidate resource information are related, it means that the recommendation result of the candidate resource information will change as the preset location information changes. At this time, the preset object attribute, the preset location information and the candidate resource information are determined as the second data to be identified. The location information is introduced, which improves the accuracy of the recommendation result determined based on the second data to be identified.
[0176] In this embodiment, the results can be determined based on the correlation between preset location information and candidate resource information to obtain the data to be identified for two different situations; and resource recommendations can be made based on the data to be identified for different situations, thereby improving the recommendation accuracy of multimedia resources.
[0177] In step S207, the data to be identified is input into the resource recommendation model to perform resource recommendation and obtain the target recommendation result; the target recommendation result represents the probability of recommending the candidate multimedia resources to the preset object.
[0178] In this embodiment of the disclosure, the target heterogeneous graph corresponding to the data to be identified can be input into a resource recommendation model to perform resource recommendation and obtain the target recommendation result.
[0179] In this embodiment of the disclosure, the target recommendation result represents the probability of recommending the candidate multimedia resource to the preset object, that is, the probability of the preset object clicking on the candidate multimedia resource at a preset position; when there is only one candidate multimedia resource, it can be determined whether to recommend the candidate multimedia resource to the preset object based on the target recommendation result; wherein, the target recommendation result represents the probability of recommending the candidate multimedia resource to the preset object; it can be determined to recommend the candidate multimedia resource to the preset object when the recommendation probability represented by the target recommendation result is greater than a preset probability threshold; when there are multiple candidate multimedia resources, the multiple candidate multimedia resources can be sorted according to the recommendation probability corresponding to each candidate multimedia resource, and the target multimedia resource can be selected from the multiple candidate multimedia resources according to the sorting result, and the target multimedia resource can be recommended to the preset object.
[0180] In this embodiment of the disclosure, the resource recommendation model includes a first recommendation feature extraction network, a second recommendation feature extraction network, and a resource recommendation network. The data to be identified is input into the resource recommendation model to perform resource recommendation, obtaining the target recommendation result, including:
[0181] The first recommendation feature is extracted from the first recommendation feature extraction network described above; or the second recommendation feature is extracted from the second recommendation feature extraction network described above.
[0182] In this embodiment of the disclosure, the resource recommendation model may include a first recommendation feature extraction network and a second recommendation feature extraction network. The first recommendation feature extraction network is used to process data to be identified without location information, and the second recommendation feature extraction network is used to process data to be identified including location information. For the first data to be identified without location information, feature extraction can be performed by the first recommendation feature extraction network in the resource recommendation model to obtain first recommendation features. For the second data to be identified including location information, feature extraction can be performed by the second recommendation feature extraction network to obtain second recommendation features.
[0183] Based on the above resource recommendation network, the target recommendation features are used to identify and process the recommendation results to obtain the target recommendation results; the above target recommendation features are either the first recommendation features or the second recommendation features.
[0184] In this embodiment of the disclosure, the target recommendation feature is either a first recommendation feature or a second recommendation feature. When the target recommendation feature is the first recommendation feature, the first recommendation feature is processed by the resource recommendation network to identify the recommendation result and obtain the target recommendation result. When the target recommendation feature is the second recommendation feature, the second recommendation feature is processed by the resource recommendation network to identify the recommendation result and obtain the target recommendation result.
[0185] In this embodiment of the disclosure, different recommendation feature extraction networks can be set for different data to be identified, thereby extracting features of different data to be identified in a distinctive manner; thereby improving the accuracy of recommendation feature extraction and improving the recommendation accuracy of multimedia resources.
[0186] In an optional embodiment, multimedia resource recommendations are made based on the resource recommendation model and related technologies constructed in this embodiment. Experiments were conducted on an offline dataset. Each record in the dataset consists of a user, a video, and a location, representing that the user watched the video at that location. The dataset contains 7189 users, 21768 videos, and 4996 locations. Compared to the baseline model, the model in this embodiment consistently achieves optimal performance.
[0187] As shown in Table 1-2 below, the model in this embodiment achieves the highest recall (Recall@K) and NDCG@K metrics for both datasets; where K is the list length. Compared to the existing best-in-class benchmark model, the model in this embodiment achieves an average performance improvement of 8.03% in recall and 4.16% in NDCG.
[0188] Table 1 Comparison results of the Recall@K metric on the offline dataset
[0189]
[0190]
[0191] Table 2 Comparison results of NDCG@K metrics on offline datasets
[0192]
[0193]
[0194] This embodiment utilizes users' offline location access records to assist in modeling their click-through rates on online content, and models and de-entangles location-related and location-independent multimedia resources separately, significantly improving the accuracy of recommendation information.
[0195] This disclosure obtains the preset object attributes of a preset object, candidate resource information of candidate multimedia resources, and preset location information corresponding to the preset object; inputs the preset object attributes, preset location information, and candidate resource information into a relationship determination model to determine the location-resource relationship, obtaining the preset relationship determination result; the preset relationship determination result indicates whether there is a relationship between the preset object attributes, preset location information, and candidate resource information for the preset object; based on the preset relationship determination result, data to be identified is determined from the preset object attributes, preset location information, and candidate resource information; the data to be identified is data used for resource recommendation analysis, and when the preset relationship determination result indicates that there is a relationship between the preset location information and the candidate resource information, the data to be identified is... The system includes preset object attributes, preset location information, and candidate resource information. When the preset relationship determination result indicates that the preset location information and candidate resource information are not related, the data to be identified consists of the preset object attributes and candidate resource information. Based on the relationship between the preset location information and candidate resource information, the system filters the preset object attributes, preset location information, and candidate resource information, determining different data to be identified based on different situations, thus improving the accuracy of the data to be identified. The data to be identified is input into a resource recommendation model for resource recommendation, yielding a target recommendation result. The target recommendation result represents the probability of recommending candidate multimedia resources to the preset object. This system improves the accuracy of the recommendation result based on the highly accurate data to be identified.
[0196] The following describes a training method for a resource recommendation model provided by an embodiment of this disclosure. This classification method can be applied to electronic devices such as terminals or servers. Figure 5 As shown, the method includes the following steps:
[0197] In step S501, the sample object attributes of the sample object, the sample location information corresponding to the sample object, and the sample resource information of the sample multimedia resources browsed by the sample object at the sample location are obtained; the sample location is the location corresponding to the sample location information.
[0198] In this embodiment of the disclosure, there are multiple sample objects. Sample data groups can be constructed based on the sample object attributes of the sample objects, the sample location information corresponding to the sample objects, and the sample resource information of the sample multimedia resources browsed by the sample objects at the sample locations. The ratio of sample object attributes, sample location information, and sample multimedia resources in each sample data group is 1:1:1. There can be multiple sample data groups, which can be constructed based on multiple sample multimedia resources browsed by the same sample object at multiple sample locations. The sample location information is the geographical location of the sample object browsing the sample multimedia resources. The sample multimedia resources may include, but are not limited to, video and audio.
[0199] In one optional embodiment, an original dataset can be obtained, which includes multiple sample location information corresponding to sample object attributes and multiple sample multimedia resources; then, a sample data group can be determined based on the correspondence between sample object attributes, sample location information, and sample multimedia resources in the original dataset.
[0200] In step S503, the above-mentioned sample object attributes, sample location information, and sample resource information are input into the correlation determination model to be trained to determine the location resource relationship, and the sample relationship determination result is obtained; the above-mentioned sample relationship determination result indicates whether there is a correlation between the sample object attributes, the sample location information, and the sample resource information for the above-mentioned sample object.
[0201] In this embodiment of the disclosure, in order to further de-entangle the representation of sample features of position-dependent and position-independent sample object attributes, a self-supervised learning-based method is introduced to provide additional self-supervised signals for the representation of sample features.
[0202] In this embodiment of the disclosure, the sample data group is labeled with object behavior labels and resource location relationship labels. The model to be trained to determine the relationship can be a self-supervised network. A self-supervised network is a self-supervised learning network. Self-supervised learning aims to improve the feature extraction ability of a model by designing proxy tasks to mine the representational characteristics of the data itself as supervision information for unlabeled data.
[0203] In this embodiment of the disclosure, graph structure data extraction processing can be performed on the sample data group corresponding to the sample object attributes, the sample location information, and the sample resource information to construct an initial heterogeneous graph; the nodes of the initial heterogeneous graph represent the sample object attributes and the sample multimedia resources, and the edges of the initial heterogeneous graph represent the sample location information of the sample object attributes browsing the sample multimedia resources.
[0204] In an exemplary embodiment, the association determination model to be trained further includes an embedding layer. Before constructing the initial heterogeneous graph, the sample data set can be input into the embedding layer to obtain the embedding features of each data point in the sample data set, construct an embedding feature set, and then construct an initial heterogeneous graph corresponding to the sample object attribute-sample location information-sample resource information (ULI) based on the embedding feature set. Here, a heterogeneous graph refers to a graph containing multiple types of nodes and relationships. Compared to a homogeneous graph containing only one type of node / relationship, a heterogeneous graph is more complex and contains more information. The edges of the initial heterogeneous graph are directed edges, pointing from the sample multimedia resource to the sample object attribute, and the edges between them represent the sample location information. For multiple sample multimedia resources corresponding to the same sample object attribute, the initial heterogeneous graph can be constructed with the sample object attribute as the center point.
[0205] In one exemplary embodiment, such as Figure 6 As shown, Figure 6 This diagram illustrates the data structure before and after feature extraction from the sample data set. The sample multimedia resources are sample videos, and the sample data set consists of five groups: (u1, l1, i1), (u1, l2, i2), (u1, l3, i3), (u2, l1, i4), and (u3, l1, i1). Through embedding layer processing, the embedding features corresponding to each data point are obtained. q i s l ;in, This indicates a sample object attribute that is independent of the sample video and sample location information. q represents the sample object attribute related to the sample video and sample location information. i s represents the sample resource information of the sample video. l This indicates the sample location information.
[0206] In one exemplary embodiment, such as Figure 7 As shown, Figure 7 This is a schematic diagram of an initial heterogeneous graph; the initial heterogeneous graph G = (V, E), where the node set V consists of sample object attribute nodes (u∈U) and sample resource information nodes (i∈I) corresponding to sample videos, and the edge set E consists of sample object attribute - sample location information - sample resource information (u, l, i). The sample object attribute - sample location information - sample resource information (u, l, i) connects the sample object attribute node u and the sample resource information node i, and the sample location information l is the attribute of the edge. This includes four sample data groups corresponding to the same sample object attribute u1: (u1, l1, i2), (u1, l2, i4), (u1, l3, i3), and (u1, l4, i1).
[0207] In some embodiments, such as Figure 8As shown, the aforementioned model for determining association relationships includes an attribute feature extraction network, a location feature extraction network, and a resource information extraction network. The sample object attributes, sample location information, and sample resource information are input into the model to determine the location-resource relationships, resulting in the sample relationship determination results, including:
[0208] In step S5031, attribute features of the sample object attributes are extracted based on the attribute feature extraction network to obtain sample attribute features;
[0209] In step S5033, the location features of the sample location information are extracted based on the location feature extraction network to obtain the sample location features;
[0210] In step S5035, resource features of the sample resource information are extracted based on the resource information extraction network to obtain sample resource features;
[0211] In this embodiment of the disclosure, sample attribute features, sample location features, and sample resource features can all be vector features.
[0212] In step S5037, the sample relationship determination result is determined based on the above-mentioned sample attribute features, sample location features, and sample resource features.
[0213] In this embodiment of the disclosure, features of multimedia resources in each sample data group can be extracted based on an initial heterogeneous graph to obtain sample resource features; the sample resource features can be embedding vectors; thus facilitating the calculation of the similarity between each sample resource feature and the sample resource center feature.
[0214] In this embodiment of the disclosure, the model for determining the association relationship to be trained includes an attribute feature extraction network, a location feature extraction network, and a resource information extraction network. These three networks can extract sample attribute features, sample location information features, and sample resource features, respectively, thereby facilitating the subsequent determination of the sample relationship determination results.
[0215] In step S505, based on the sample relationship determination result, sample data to be identified is determined from the sample object attributes, sample location information, and sample resource information. The sample data to be identified is data used for resource recommendation analysis. If the sample relationship determination result indicates a correlation between the sample location information and the sample resource information, the sample data to be identified consists of the sample object attributes, sample location information, and sample resource information. If the sample relationship determination result indicates no correlation between the sample location information and the sample resource information, the sample data to be identified consists of the sample object attributes and sample resource information.
[0216] In some embodiments, the sample objects include a first sample object and a second sample object. The first sample location information of the first sample object is associated with the first sample resource information, and the second sample location information of the second sample object is not associated with the second sample resource information. The process of determining the sample data to be identified from the sample object attributes, the sample location information, and the sample resource information based on the sample relationship determination result includes:
[0217] The first sample object attributes, the first sample location information, and the first sample resource information of the aforementioned first sample object are determined as the first sample data;
[0218] The second sample object attributes and the second sample resource information of the aforementioned second sample object are determined as the second sample data;
[0219] Based on the first sample data and the second sample data mentioned above, the sample data to be identified is determined.
[0220] In some embodiments, there can be multiple sample data groups, each including multiple sample resource information, including first sample resource information and second sample resource information. A self-supervised network can be used to predict the association between sample resource information and sample location information within the sample data groups, thereby determining the first sample data and the second sample data. Specifically, in the first sample data, the first sample resource information and the first sample location information are associated; that is, the sample object attribute typically only browses the first sample multimedia resource corresponding to the first sample resource information at the first sample location information, and will not browse the first sample multimedia resource at other locations. For example, if the first sample multimedia resource is a resource associated with the work content of the sample object attribute, the sample object attribute typically browses the first sample multimedia resource at the company's location; in this case, it can be determined that the first sample resource information and the first sample location information are not associated. In the second sample data, the second sample resource information and the second sample location information are not associated; that is, the sample object attribute browses the second sample multimedia resource corresponding to the second sample resource information at multiple locations, and the sample object attribute's browsing of the second sample multimedia resource is not limited to the second sample location information. For example, if the second sample multimedia resource is a video, live stream, etc. that the sample object attribute is interested in, the sample object attribute will browse the second sample multimedia resource when at home, shopping mall, or other locations; in this case, it can be determined that the second sample resource information and the second sample location information are not related.
[0221] In this embodiment of the disclosure, due to the embedding vector of each sample multimedia resource Since the data is variable, these two sets of samples need to be regenerated at the beginning of each training cycle. An initial heterogeneous graph can be constructed based on the sample data sets, and the model can be trained based on the initial heterogeneous graph, thereby improving the training efficiency of the model; and the correlation between multiple sample resource information and sample location information corresponding to the same sample object attribute can be quickly extracted through the initial heterogeneous graph, thereby quickly determining the first sample data and the second sample data.
[0222] In this embodiment of the disclosure, the first sample data and the second sample data can be quickly determined from the sample data group based on the correlation between sample resource information and sample location information, thereby distinguishing the location-related data group from the location-independent data group, which facilitates the rapid construction of the sample data to be identified.
[0223] In some embodiments, the above method further includes:
[0224] Extract the first sample subgraph corresponding to the first sample data from the initial heterogeneous graph;
[0225] Specifically, in this embodiment of the disclosure, a heterogeneous graph corresponding to the first sample data can be extracted from the initial heterogeneous graph to obtain a first sample subgraph; the nodes of the first sample subgraph represent the sample object attributes and the first sample resource information, and the edges of the first sample subgraph represent the first sample location information for browsing the first sample resource information of the sample object attributes.
[0226] Extract the second sample subgraph corresponding to the second sample data from the initial heterogeneous graph;
[0227] Specifically, in this embodiment of the disclosure, a heterogeneous graph corresponding to the second sample data can be extracted from the initial heterogeneous graph to obtain a second sample subgraph; the nodes of the second sample subgraph represent the sample object attributes and the second sample resource information, the second sample subgraph does not include sample location information, and the edges of the second sample subgraph represent the association between the sample object attributes and the second sample resource information; that is, they represent that the sample object attributes have browsed the second sample multimedia resources.
[0228] The first sample subgraph and the second sample subgraph mentioned above are identified as sample heterogeneous graphs.
[0229] In this embodiment of the disclosure, a sample heterogeneous graph can be constructed based on the first sample subgraph and the second sample subgraph; the combined graph of the first sample subgraph and the second sample subgraph can be determined as the sample heterogeneous graph.
[0230] In step S507, the above-mentioned sample data to be identified is input into the resource recommendation model to be trained to perform resource recommendation and obtain the sample recommendation result;
[0231] In some embodiments, the sample heterogeneity graph corresponding to the sample data to be identified can be input into the resource recommendation model to be trained for resource recommendation, and the sample recommendation result can be obtained.
[0232] In some embodiments, the initial heterogeneous graph may include a first sample subgraph and a second sample subgraph; the nodes of the first sample subgraph represent sample object attributes and first sample resource information, and the edges of the first sample subgraph represent the first sample location information of the sample object attributes browsing the first sample resource information; the nodes of the second sample subgraph represent sample object attributes and second sample resource information, the second sample subgraph does not include sample location information, and the edges of the second sample subgraph represent the association relationship between the sample object attributes and the second sample resource information; that is, representing the sample multimedia resources corresponding to the sample object attributes browsing the second sample resource information.
[0233] In some embodiments, the resource recommendation model to be trained may include a first sample network and a second sample network. The first sample subgraph can be input into the first sample network to obtain a first result, and the second sample subgraph can be input into the second sample network to obtain a second result.
[0234] In some embodiments, for the same object attribute, the first sample resource feature and the first position feature corresponding to the first sample subgraph can be extracted through the first sample network; and the inner product of the first sample resource feature and the first position feature is calculated to obtain the first recommendation feature, thereby determining the recommendation result based on the first recommendation feature.
[0235] In an optional embodiment, the sample multimedia information is video, and the information propagation mechanism corresponding to the first sample network for the sample object attribute u is as follows:
[0236]
[0237] in, This refers to the embedding vector of the location-related resources of the sample object attribute u in layer (l+1), i.e., the first sample recommendation feature, N. I (u) represents the set of neighbors of u in graph G, which is the set of videos that the sample object u has interacted with. s is the embedding vector of video i at layer l. l This is the embedding vector of the location where user u interacts with video i. Here, ⊙ represents the Hadamard product. The aggregation function can include, but is not limited to, the mean function, the weighted mean function with attention coefficients as weights, and Long Short-Term Memory (LSTM) networks.
[0238] In some embodiments, for the same object attribute, the corresponding second sample resource features in the second sample subgraph can be extracted through the second sample network; and the average value of multiple second sample resource features is calculated to obtain the second recommendation feature, thereby determining the recommendation result based on the second recommendation feature.
[0239] In an optional embodiment, the sample multimedia information is video, and the information propagation mechanism corresponding to the second sample network for the sample object attribute u is as follows:
[0240]
[0241] in, This refers to the embedding vector of the position-independent resource of the sample object attribute u in the third layer (l+1), which can be aggregated using the averaging function.
[0242] In some embodiments, the first sample recommendation feature and the second sample recommendation feature corresponding to any sample object attribute can be fused to obtain the sample recommendation feature; specifically, the average value of the first sample recommendation feature and the second sample recommendation feature can be calculated, and the average value can be determined as the sample recommendation feature.
[0243] In the main task of recommending videos to users, one can... and The final embedding vector for the sample object attribute u is calculated using the following formula:
[0244]
[0245] in, Recommend features for the first sample. Recommend features for the second sample; Recommend features for the samples.
[0246] In step S509, based on the above sample relationship determination results and the above sample recommendation results, the above-mentioned relationship determination model and the above-mentioned resource recommendation model to be trained are trained, and the resource recommendation model to be trained at the end of training is determined as the resource recommendation model.
[0247] In an optional embodiment, after modeling the user's location-related resources, the video embedding vector can be used as a bridge to obtain the following formula for calculating the location-related resource features:
[0248]
[0249] in, For location-related resource features, N is the recommended feature for the first sample. U(i) represents the set of neighbors of i on graph G, which is the set of users who have interacted with video i.
[0250] In an optional embodiment, after modeling the user's location-related resources, the video embedding vector can be used as a bridge to obtain the following formula for calculating the location-independent resource features:
[0251]
[0252] in, For location-independent resource characteristics, N is the recommended feature for the second sample. U (i) represents the set of neighbors of i on graph G, which is the set of users who have interacted with video i.
[0253] In some embodiments, location-related resource features and location-independent resource features corresponding to any sample multimedia resource can be fused, and the fused features can be determined as sample resource information. Specifically, the average value of location-related resource features and location-independent resource features corresponding to any sample multimedia resource can be calculated, and the average value can be determined as sample resource information. The calculation formula is as follows:
[0254]
[0255] and These are aggregated results of location-related and location-independent resource features of the user. The average of these features is used to generate the output. This is the embedding vector of video i at layer (l+1). The aggregation functions used in user-video propagation are all simple mean functions, while exploration and experimentation with other aggregation functions will be left for future work. Here, only the mean function is used. This is used to generate information passed from the user's location-related resource embedding vector to the video embedding vector in graph propagation, instead of using the location embedding vector as in video-user propagation, because... It already includes resource features related to the user's location.
[0256] After L propagations on the graph, (L+1) embedding vectors are obtained for each user or video. These include the embedding vectors from layer 0, which are the inputs to the graph convolution function. Simple mean pooling is used to combine these embedding vectors to generate the final representations of the user and video. Specifically, the combination method can be described as follows.
[0257]
[0258]
[0259]
[0260] in, Recommendation features for the first sample of users with location-related resources. The second sample recommendation features for users of location-independent resources. These are video features.
[0261] In some embodiments, sample resource features and sample resource information can be fused into sample recommendation features. During the training of the resource recommendation model, the inner product of account resource features and sample resource information in the same sample data group can be calculated, and the inner product can be used as the matching score. The first inner product of the first sample resource features and sample resource information can be calculated respectively. And the second inner product of the second sample resource features and the sample resource information The calculation formula is as follows:
[0262]
[0263]
[0264] In an optional embodiment, the sample recommendation result can be determined based on the matching score; if the first inner product is less than the second inner product, the recommendation result is determined to be not to recommend sample multimedia resources to the sample object; if the first inner product is greater than the second inner product, the recommendation result is determined to recommend sample multimedia resources to the sample object.
[0265] In some embodiments, such as Figure 9 As shown, the above sample resource information is labeled with object behavior tags and resource location relationship tags. The resource location relationship tags represent the sample object attributes for the above sample objects. Whether there is a correlation between the above sample resource information and the above sample location information is determined. Based on the above sample relationship determination results and the above sample recommendation results, the above-mentioned correlation determination model and the above-mentioned resource recommendation model are trained, including:
[0266] In step S5091, the first loss information is determined based on the difference between the above sample recommendation results and the above object behavior labels;
[0267] In some embodiments, the loss function corresponding to the first loss information is as follows:
[0268]
[0269] in This is the training set of user-video interaction data. `i` represents the video that user `u` interacts with, and `j` represents a randomly selected negative sample.
[0270] In step S5093, based on the difference between the above sample relationship determination result and the above resource location relationship label, the second loss information is determined;
[0271] In some embodiments, the results can be determined based on the sample relationship to construct first location loss information corresponding to location-related resources and second location loss information corresponding to location-independent resources.
[0272] The loss function corresponding to the first position loss information is as follows:
[0273]
[0274] in, It is a training set of location-related interaction data.
[0275] The loss function corresponding to the second position loss information is as follows:
[0276]
[0277] in, It is a training set of location-independent interaction data.
[0278] In some embodiments, the sum of the first location loss information and the second location loss information can be determined as the second loss information.
[0279] In step S5095, based on the first loss information and the second loss information, the model parameters corresponding to the training relationship determination model and the training resource recommendation model are adjusted until the training termination condition is met, and the training resource recommendation model at the end of training is determined as the resource recommendation model.
[0280] In this embodiment of the disclosure, the association determination model and the resource recommendation model to be trained can be jointly trained to obtain the association determination model and the resource recommendation model, thereby improving the accuracy of the resource recommendation model.
[0281] In some embodiments, such as Figure 10 As shown, the resource location relationship labels mentioned above include a first resource location relationship label and a second resource location relationship label. The method for determining the resource location relationship labels of the sample resource information includes:
[0282] In step S1001, the similarity between the sample resource information and the sample resource center features is determined based on the sample resource center features corresponding to the sample objects.
[0283] In this embodiment of the disclosure, the sample resource center features of a sample object attribute can be determined based on multiple sample multimedia resources corresponding to the sample object attribute. Multiple sample multimedia resources corresponding to the same sample object attribute can be quickly extracted using an initial heterogeneous graph; specifically, sample resource information corresponding to each sample multimedia resource is then extracted; and the sample resource center features of the sample object attribute are then determined based on the information of each sample resource.
[0284] In an optional instance, the average value of each sample resource information of the sample object attribute can be calculated, and the average value can be determined as the sample resource center feature of the sample object attribute. The sample resource center feature can be an embedding vector, and the calculation formula is as follows:
[0285]
[0286] in, Resource center features of sample object attributes Here, N represents the sample resource information corresponding to the sample multimedia resource; i is the identifier of the sample multimedia resource, and N is the identifier of the sample multimedia resource. I (u) is the sample multimedia resource set corresponding to the sample object attribute u.
[0287] In this embodiment, the similarity between the sample resource information and the aforementioned sample resource center features can be determined based on the cosine distance between the sample resource information and the aforementioned sample resource center features; the distance between each sample resource information of the sample object attribute and the sample resource center feature can be calculated; that is, for each video that the user has interacted with, the distance between its embedding vector and the sample resource center in the latent space is calculated. For video i, the distance calculation formula is as follows:
[0288]
[0289] Where d is the distance. The sample resource center feature is the attribute of the sample object. This refers to the sample resource information corresponding to the sample multimedia resources.
[0290] In step S1003, the above sample resource information is sorted from largest to smallest according to the similarity corresponding to the above sample resource information, and a first preset number of sample resource information and a second preset number of sample resource information are determined.
[0291] In this embodiment of the disclosure, multiple sample resource information can be sorted from largest to smallest according to the similarity of each of the multiple sample resource information; and a first preset number of sample resource information and a second preset number of sample resource information are taken; wherein, the first preset number and the second preset number can be the same number, and the first preset number and the second preset number can be set according to the actual situation; for example, the first preset number and the second preset number can both be 10% of the total number of sample multimedia resources of sample object attributes.
[0292] In some embodiments, multiple sample resource information can be sorted from smallest to largest according to the similarity of each of the multiple sample resource information; the difference between sorting from largest to smallest is that the labels corresponding to the first preset number of sample resource information and the last preset number of sample resource information need to be swapped.
[0293] In step S1005, the first resource location relationship label is marked on the aforementioned first preset number of sample resource information; the first resource location relationship label indicates that the aforementioned first preset number of sample resource information has an association relationship with the aforementioned preset location information;
[0294] In this embodiment of the disclosure, the sample position information corresponding to each of the first preset number of sample resource information can be determined based on the corresponding edges of each of the first preset number of sample resource information in the aforementioned initial heterogeneous graph; the sample position information corresponding to each of the first preset number of sample resource information corresponding to the sample object attribute can be determined based on the initial heterogeneous graph. Specifically, the corresponding edges in the initial heterogeneous graph can be determined based on the sample object attribute and the first preset number of sample resource information, and the attribute information of the edges can be obtained to obtain the sample position information.
[0295] In this embodiment of the disclosure, for the same sample object attribute, since the distance between the sample resource features and the resource center features corresponding to the first preset number of sample multimedia resources is large, it can be determined that there is a correlation between the first preset number of sample resource information and its corresponding sample location information. That is, the sample object attribute will only browse the first preset number of sample resource information when it is in a preset location, and will not browse the sample multimedia resources corresponding to the first preset number of sample resource information when it is in other locations. The first resource location relationship label is used to annotate the first preset number of sample resource information; the first resource location relationship label indicates that the first preset number of sample resource information is associated with the preset location information.
[0296] In step S1007, the second resource location relationship label is marked on the aforementioned preset number of sample resource information; the second resource location relationship label indicates that the aforementioned preset number of sample resource information has no correlation with the aforementioned preset location information.
[0297] In this embodiment of the disclosure, the sample location information corresponding to each of the subsequent preset number of sample multimedia resources corresponding to the sample object attributes can be determined based on the initial heterogeneous graph. Specifically, the corresponding edges in the initial heterogeneous graph can be determined based on the sample object attributes and the subsequent preset number of sample multimedia resources, and the attribute information of the edges can be obtained to obtain the sample location information.
[0298] In this embodiment of the disclosure, for the same sample object attribute, since the distance between the sample resource features corresponding to the subsequent preset number of sample multimedia resources and the resource center features is small, it can be determined that the sample object attribute has a high probability of browsing the subsequent preset number of sample multimedia resources, and this is not affected by location; that is, there is no correlation between the information of the subsequent preset number of sample resources and their corresponding sample location information, meaning that the sample object attribute may browse the subsequent preset number of sample multimedia resources at any location. Sample objects can be divided into first sample objects and second sample objects using labeled tags, and in each training cycle, the sample objects are re-divided based on the results of the previous label determination until the training ends.
[0299] In this embodiment of the disclosure, the sample resource information and its corresponding sample location information can be determined based on the similarity between the sample resource information corresponding to the sample multimedia resource and the resource center features; and the data group corresponding to the sample resource information is labeled with the corresponding location relationship label, thereby determining the location association label corresponding to the sample data through self-supervised learning training, which improves the accuracy of the sample label.
[0300] In one exemplary embodiment, such as Figure 11 As shown, Figure 11 This is a schematic diagram illustrating the working principle of a self-supervised network. For each sample object attribute u, the top 10% of multimedia resources with the largest d are selected and added to the self-supervised sample set. The location-related resource information used to supervise the attributes of sample objects is used, and the corresponding recommendation feature is: Select the multimedia resources with the smallest values in the top 10% and move them to another sample set. The corresponding recommendation feature used to supervise location-independent resources for users is:
[0301] In this embodiment of the disclosure, multiple sample resource information can be sorted according to the similarity between multiple sample resource information and sample resource center features, and sample resource information with high similarity and sample resource information with low similarity can be determined according to the sorting results; thereby, sample resource information associated with location and sample resource information unrelated to location can be quickly and accurately determined.
[0302] In some embodiments, a user's online behavior (watching multimedia information online) and offline behavior (visiting different geographical locations) are inevitably interconnected and influence each other. The accuracy of online content recommendation can be improved by leveraging the user's offline physical visits. To achieve this, an auxiliary task of predicting the user's offline physical visits is introduced. An additional loss is used to supervise this task, complementing the loss of the main user-video recommendation task. Both tasks share the same set of input user and location embedding vectors. In this way, user location information is utilized to supplement user modeling, resulting in more informative and interpretable location embedding vectors.
[0303] In some embodiments, graph structure data extraction processing can be performed based on sample object attributes and sample location information to obtain a sample object attribute location graph. This graph includes sample object attribute-sample location information data sets, and is a heterogeneous graph. The nodes of the sample object attribute location graph represent sample object attributes and sample location information, such as... Figure 12 As shown, Figure 12 This is a schematic diagram of a sample object attribute location graph, in which there can be multiple nodes, the sample object attribute can be the central node, and the sample location information nodes corresponding to the same sample object attribute can be distributed around the sample object attribute node; the edges of the above sample object attribute location graph represent the sample object attribute access to sample location information.
[0304] In some embodiments, the above method further includes:
[0305] The above sample attribute features are input into the location prediction model to be trained to obtain the location prediction result; the above sample object attributes are labeled with sample location information tags;
[0306] In some embodiments, location-related features can be extracted from multiple sample attribute features to obtain comprehensive location features, where the location-related features can be embedding vectors; wherein, the initialization of the embedding vector propagation process can be set... and s l Let u be the embedding vector of user and position l at layer 0, and its representation is as follows:
[0307]
[0308] The shared embedding vectors allow two models, one for user-video recommendation and the other for user-location access prediction, to be optimized together. After L propagations, (L+1) embedding vectors are obtained for each user u and each location l. These can be aggregated using an averaging function to generate the final embedding vectors for user u and location l, used for the access prediction task. This aggregation can be expressed as follows:
[0309]
[0310]
[0311] in, For location-related features, This is based on comprehensive location features.
[0312] Then, based on the matching results between the initial sample location information features and the comprehensive location features, the location loss information is determined. Specifically, the inner product of the initial sample location information features and the comprehensive location features can be calculated to obtain the matching score. The calculation formula is as follows:
[0313]
[0314] Among them, fractions This indicates the degree to which a user's location preference matches location attributes.
[0315] In an optional embodiment, a multi-task learning module can be constructed based on the location prediction network, such as... Figure 13 As shown, Figure 13 This is a schematic diagram of the structure of a multi-task learning module; where, This represents the embedding vector of the sample object attribute u1 at the (l+1)th layer; Corresponding to multiple positions same, This refers to the embedding vector at position l in layer (l+1); Corresponding to multiple sample object attributes Among them, the resource features corresponding to the sample object attributes With sample location information The characterization methods are as follows:
[0316]
[0317]
[0318] Where l represents propagation at the l-th layer, This represents the embedding vector of user u at layer (l+1). Similarly, This refers to the embedding vector at position l in layer (l+1); a simple averaging function can be used as the aggregation function.
[0319] In an alternative embodiment, such as Figure 14 As shown, Figure 14 This is a schematic diagram of the structure of a feature matching module, which calculates the attributes corresponding to the same sample object. and The average value is obtained. And calculate and The inner product of the two is used to obtain the matching result.
[0320] To optimize the prediction model, a Bayesian personalized ranking loss function can be used. Observed user location visits should receive higher matching scores than unobserved location visits.
[0321] Based on the difference between the above location prediction results and the above sample location information labels, the third loss information is determined.
[0322] The loss function corresponding to the third loss information is as follows:
[0323]
[0324] in, It is the training set of user location access data. Make n represents a randomly selected negative sample, and σ(·) is the sigmoid function.
[0325] In some embodiments, based on the first loss information and the second loss information, the model parameters corresponding to the training relationship determination model and the training resource recommendation model are adjusted until the training termination condition is met, including:
[0326] Based on the first loss information, the second loss information, and the third loss information, adjust the model parameters of the aforementioned correlation determination model, resource recommendation model, and location prediction model until the training termination condition is met.
[0327] In an optional embodiment, the target loss function is as follows:
[0328]
[0329] Where Θ represents all trainable parameters in the model, and λ is the L2 regularization coefficient. The overall loss of the model is the recommendation loss. Location prediction loss Self-supervised learning loss and and the weighted sum of the L2 normalized terms ||Θ||2; α, β, and γ are respectively The weighting coefficients.
[0330] In an optional embodiment, the model for determining the association relationship, the model for recommending resources, and the model for predicting the location to be trained can be iteratively trained based on the numerical value corresponding to the target loss information. In each training cycle, the parameters of each model are adjusted until the preset training conditions are met and the training ends. The model for recommending resources to be trained corresponding to the model parameters at the end of training is determined as the resource recommendation model. The preset training conditions may include the number of iterations reaching a preset number or the numerical value corresponding to the target loss information being less than or equal to a preset value.
[0331] In an optional embodiment, such as Figure 15 As shown, Figure 15 This diagram illustrates the structure of a comprehensive recommendation model, which includes an association determination model, a resource recommendation model, and a location prediction model. The association determination model includes an embedding layer, and the resource recommendation model includes a multi-task learning module and a self-supervised learning module. In the diagram, the embedding layer (a) is used to input a data set of sample object attributes, sample location information, and sample videos, and extract the embedding features of each data point in the data set. The multi-task learning module (b) is used to construct a sample heterogeneity graph (sample object attributes - sample location information - sample videos) and a sample object attribute location graph (sample object attributes - sample location information). Based on the information propagation mechanism, information propagation and feature extraction are performed at different layers to obtain the account features of each sample object attribute and the location features of each sample location information. The self-supervised learning module (c) is used to self-supervise the learning of unentangled location-related and location-independent sample data, and extract the account resource features of each sample object attribute and the resource information of each sample multimedia resource.
[0332] This disclosure models location-related user preferences through user-video representation propagation based on location edges; it separates geographically relevant and geographically unrelated user preferences through deentangled representations and self-supervised learning design; and it optimizes location access prediction and video recommendation tasks through a multi-task learning design to obtain high-quality location representations. This design clearly captures the complex interdependencies between users' physical access and online content consumption, improving the accuracy of multimedia resource recommendations.
[0333] Figure 16 This is a block diagram illustrating a resource recommendation apparatus according to an exemplary embodiment. (Refer to...) Figure 16 The device includes:
[0334] The information acquisition module 1610 is configured to acquire the preset object attributes of the preset object, the candidate resource information of the candidate multimedia resources, and the preset location information corresponding to the preset object.
[0335] The result determination module 1620 is configured to perform location resource relationship determination by inputting the preset object attributes, the preset location information and the candidate resource information into the association relationship determination model, and obtain the preset relationship determination result; the preset relationship determination result indicates whether there is an association relationship between the preset object attributes, the preset location information and the candidate resource information for the preset object.
[0336] The data to be identified module 1630 is configured to determine data to be identified from the preset object attributes, the preset location information, and the candidate resource information based on the preset relationship determination result. The data to be identified is data used for resource recommendation analysis. When the preset relationship determination result indicates that the preset location information and the candidate resource information are related, the data to be identified is the preset object attributes, the preset location information, and the candidate resource information. When the preset relationship determination result indicates that the preset location information and the candidate resource information are not related, the data to be identified is the preset object attributes and the candidate resource information.
[0337] The recommendation result determination module 1640 is configured to input the data to be identified into a resource recommendation model to perform resource recommendation and obtain a target recommendation result; the target recommendation result represents the probability of recommending the candidate multimedia resources to the preset object.
[0338] In one exemplary embodiment, the association determination model includes a central feature extraction network and an association determination network, such as... Figure 17 As shown, the result determination module 1620 includes:
[0339] The feature extraction unit 16201 is configured to execute in the central feature extraction network to perform feature extraction processing on the preset object attributes, the preset location information, and the historical multimedia resources browsed by the preset object at the location corresponding to the preset location information, to obtain the resource center features corresponding to the preset object; the resource center features are not related to the preset location information.
[0340] The result determination unit 16203 is configured to execute the relationship determination network based on the association, determine the similarity between the candidate resource information and the resource center features, and determine the preset relationship determination result based on the similarity.
[0341] In one exemplary embodiment, the result determination unit includes:
[0342] The first determining subunit is configured to determine that if the similarity is less than or equal to a preset similarity threshold, the candidate resource information and the preset location information are not related.
[0343] The second determining subunit is configured to determine that the candidate resource information and the preset location information are associated if the similarity is greater than the preset similarity threshold.
[0344] In one exemplary embodiment, the data to be identified determination module includes:
[0345] The first data determination unit is configured to determine the preset object attribute and the candidate resource information as the first data to be identified when the preset relationship determination result indicates that the preset location information and the candidate resource information are not related.
[0346] The second data determination unit is configured to determine the preset object attribute, the preset location information, and the candidate resource information as the second data to be identified when the preset relationship determination result indicates that the preset location information and the candidate resource information are associated.
[0347] In one exemplary embodiment, the resource recommendation model includes a first recommendation feature extraction network, a second recommendation feature extraction network, and a resource recommendation network, and the recommendation result determination module includes:
[0348] The recommendation feature extraction unit is configured to perform the following: extracting a first recommendation feature based on the first recommendation feature extraction network; or extracting a second recommendation feature based on the second recommendation feature extraction network;
[0349] The recommendation result determination unit is configured to perform recommendation result recognition processing on the target recommendation feature based on the resource recommendation network to obtain the target recommendation result; the target recommendation feature is the first recommendation feature or the second recommendation feature.
[0350] In one exemplary embodiment, there are multiple preset objects, and the device further includes:
[0351] The heterogeneous graph construction module is configured to construct a preset heterogeneous graph based on the preset object attributes, preset location information, and candidate resource information corresponding to each of the multiple preset objects; the nodes of the preset heterogeneous graph represent the preset object attributes and the candidate resource information, and the edges of the preset heterogeneous graph represent the preset location information;
[0352] In one exemplary embodiment, the result determination module includes:
[0353] The heterogeneous graph input unit is configured to perform location resource relationship determination by inputting the preset heterogeneous graph into the association relationship determination model, and obtain the preset relationship determination result.
[0354] Regarding the apparatus in the above embodiments, the specific manner in which each module performs its operation has been described in detail in the embodiments related to the method, and will not be elaborated upon here.
[0355] Figure 18 This is a block diagram illustrating a training apparatus for a resource recommendation model according to an exemplary embodiment. (Refer to...) Figure 18 The device includes:
[0356] The sample information acquisition module 1810 is configured to acquire the sample object attributes of the sample object, the sample location information corresponding to the sample object, and the sample resource information of the sample multimedia resources browsed by the sample object at the sample location; the sample location is the location corresponding to the sample location information.
[0357] The sample result determination module 1820 is configured to perform location and resource relationship determination by inputting the sample object attributes, the sample location information, and the sample resource information into the association relationship determination model to be trained, and obtain the sample relationship determination result; the sample relationship determination result indicates whether there is an association relationship between the sample object attributes, the sample location information, and the sample resource information for the sample object.
[0358] The sample data determination module 1830 is configured to determine sample data to be identified from the sample object attributes, the sample location information, and the sample resource information based on the sample relationship determination result. The sample data to be identified is data used for resource recommendation analysis. If the sample relationship determination result indicates a correlation between the sample location information and the sample resource information, the sample data to be identified is the sample object attributes, the sample location information, and the sample resource information. If the sample relationship determination result indicates no correlation between the sample location information and the sample resource information, the sample data to be identified is the sample object attributes and the sample resource information.
[0359] The sample recommendation result determination module 1840 is configured to input the sample data to be identified into the resource recommendation model to be trained to perform resource recommendation and obtain the sample recommendation result.
[0360] The model training module 1850 is configured to train the relationship determination model and the resource recommendation model to be trained based on the sample relationship determination result and the sample recommendation result, and to determine the resource recommendation model to be trained at the end of training as the resource recommendation model.
[0361] In one exemplary embodiment, the sample objects include a first sample object and a second sample object. The first sample object's first sample location information is associated with the first sample resource information, while the second sample object's second sample location information is not associated with the second sample resource information. The module for determining the sample data to be identified includes:
[0362] The first data determining unit is configured to determine the first sample object attribute, the first sample location information, and the first sample resource information of the first sample object as the first sample data.
[0363] The second data determination unit is configured to determine the second sample object attributes and the second sample resource information of the second sample object as the second sample data.
[0364] The sample data determination unit is configured to determine the sample data to be identified based on the first sample data and the second sample data.
[0365] In one exemplary embodiment, the sample resource information is labeled with object behavior tags and resource location relationship tags, wherein the resource location relationship tags characterize sample object attributes for the sample object, and whether there is a correlation between the sample resource information and the sample location information, the model training module includes:
[0366] The first loss determination unit is configured to determine first loss information based on the difference between the sample recommendation result and the object behavior label.
[0367] The second loss determination unit is configured to determine second loss information based on the difference between the sample relationship determination result and the resource location relationship label.
[0368] The parameter adjustment unit is configured to adjust the model parameters corresponding to the relationship determination model and the resource recommendation model to be trained based on the first loss information and the second loss information until the training termination condition is met, and determine the resource recommendation model to be trained at the end of training as the resource recommendation model.
[0369] In one exemplary embodiment, the model for determining the association relationship to be trained includes an attribute feature extraction network, a location feature extraction network, and a resource information extraction network, and the sample result determination module includes:
[0370] The sample attribute feature determination unit is configured to extract attribute features of the sample object based on the attribute feature extraction network to obtain sample attribute features;
[0371] The sample location feature determination unit is configured to extract location features of the sample location information based on the location feature extraction network to obtain sample location features;
[0372] The sample resource feature determination unit is configured to extract resource features from the sample resource information based on the resource information extraction network to obtain sample resource features;
[0373] The sample relationship determination unit is configured to determine the sample relationship determination result based on the sample attribute features, the sample location features, and the sample resource features.
[0374] In one exemplary embodiment, the apparatus further includes:
[0375] The feature input module is configured to input the sample attribute features into the location prediction model to be trained, and obtain the location prediction result; the sample object attributes are labeled with sample location information tags.
[0376] The third loss determination module is configured to determine third loss information based on the difference between the location prediction result and the sample location information label.
[0377] In one exemplary embodiment, the parameter adjustment unit includes:
[0378] The parameter adjustment subunit is configured to adjust the model parameters of the training relation determination model, the training resource recommendation model, and the training location prediction model based on the first loss information, the second loss information, and the third loss information until the training termination condition is met.
[0379] In one exemplary embodiment, the resource location relationship label includes a first resource location relationship label and a second resource location relationship label, and the device further includes:
[0380] The similarity determination module is configured to determine the similarity between the sample resource information and the sample resource center features based on the sample resource center features corresponding to the sample object.
[0381] The sorting module is configured to sort the sample resource information according to the similarity of the sample resource information from largest to smallest, and determine the first preset number of sample resource information and the last preset number of sample resource information.
[0382] The first annotation module is configured to annotate the first resource location relationship label on the first preset number of sample resource information; the first resource location relationship label represents that the first preset number of sample resource information has an association relationship with the preset location information.
[0383] The second annotation module is configured to annotate the subsequent preset number of sample resource information with the second resource location relationship label; the second resource location relationship label represents that the subsequent preset number of sample resource information has no association with the preset location information.
[0384] Regarding the apparatus in the above embodiments, the specific manner in which each module performs its operation has been described in detail in the embodiments related to the method, and will not be elaborated upon here.
[0385] In one exemplary embodiment, an electronic device is also provided, including a processor; a memory for storing processor-executable instructions; wherein, when the processor is configured to execute the instructions stored in the memory, it implements the resource recommendation method or the training method of the resource recommendation model provided in any of the above embodiments.
[0386] The electronic device can be a terminal, a server, or a similar computing device. Taking a server as an example... Figure 19 This is a block diagram illustrating an electronic device according to an exemplary embodiment, such as... Figure 19As shown, the server 1900 can vary significantly due to different configurations or performance. It may include one or more central processing units (CPUs) 1910 (CPUs 1910 may include, but are not limited to, microprocessors (MCUs) or programmable logic devices (FPGAs), a memory 1930 for storing data, and one or more storage media 1920 (e.g., one or more mass storage devices) for storing application programs 1923 or data 1922. The memory 1930 and storage media 1920 may be temporary or persistent storage. The program stored in the storage media 1920 may include one or more modules, each module may include a series of instruction operations on the server. Furthermore, the CPU 1910 may be configured to communicate with the storage media 1920 and execute the series of instruction operations in the storage media 1920 on the server 1900. Server 1900 may also include one or more power supplies 1960, one or more wired or wireless network interfaces 1950, one or more input / output interfaces 1940, and / or one or more operating systems 1921, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, etc.
[0387] The input / output interface 1940 can be used to receive or send data via a network. Specific examples of the network described above may include a wireless network provided by the communication provider of server 1900. In one example, input / output interface 1940 includes a network interface controller (NIC), which can connect to other network devices via a base station to communicate with the Internet. In another example, input / output interface 1940 may be a radio frequency (RF) module for wireless communication with the Internet.
[0388] Those skilled in the art will understand that Figure 19 The structure shown is for illustrative purposes only and does not limit the structure of the aforementioned electronic device. For example, server 1900 may also include... Figure 19 The more or fewer components shown, or having the same Figure 19 The different configurations shown.
[0389] In one exemplary embodiment, a computer-readable storage medium including instructions is also provided, such as a memory 1930 including instructions, which can be executed by a processor 1910 of device 1900 to perform the above-described method. Optionally, the computer-readable storage medium may be a ROM, random access memory (RAM), CD-ROM, magnetic tape, floppy disk, and optical data storage device, etc.
[0390] In one exemplary embodiment, a computer program product is also provided, including a computer program that, when executed by a processor, implements the resource recommendation method or the training method for the resource recommendation model provided in any of the above embodiments.
[0391] In an exemplary embodiment, a computer program product is also provided, including a computer program that, when executed by a processor, implements the resource recommendation method or the training method for the resource recommendation model described above.
[0392] This disclosure obtains the preset object attributes of a preset object, candidate resource information of candidate multimedia resources, and preset location information corresponding to the preset object; inputs the preset object attributes, preset location information, and candidate resource information into a relationship determination model to determine the location-resource relationship, obtaining the preset relationship determination result; the preset relationship determination result indicates whether there is a relationship between the preset object attributes, preset location information, and candidate resource information for the preset object; based on the preset relationship determination result, data to be identified is determined from the preset object attributes, preset location information, and candidate resource information; the data to be identified is data used for resource recommendation analysis, and when the preset relationship determination result indicates that there is a relationship between the preset location information and the candidate resource information, the data to be identified is... The system includes preset object attributes, preset location information, and candidate resource information. When the preset relationship determination result indicates that the preset location information and candidate resource information are not related, the data to be identified consists of the preset object attributes and candidate resource information. Based on the relationship between the preset location information and candidate resource information, the system filters the preset object attributes, preset location information, and candidate resource information, determining different data to be identified based on different situations, thus improving the accuracy of the data to be identified. The data to be identified is input into a resource recommendation model for resource recommendation, yielding a target recommendation result. The target recommendation result represents the probability of recommending candidate multimedia resources to the preset object. This system improves the accuracy of the recommendation result based on the highly accurate data to be identified.
[0393] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. This computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and RAMbus dynamic RAM (RDRAM), etc.
[0394] Other embodiments of this disclosure will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this disclosure that follow the general principles of this disclosure and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this disclosure are indicated by the following claims.
[0395] It should be understood that this disclosure is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this disclosure is limited only by the appended claims.
Claims
1. A resource recommendation method, characterized in that, The method includes: Obtain the preset object attributes of the preset object, the candidate resource information of the candidate multimedia resources, and the preset location information corresponding to the preset object; The preset object attributes, preset location information, and candidate resource information are input into an association relationship determination model. This model includes a central feature extraction network and an association relationship determination network. Based on the central feature extraction network, feature extraction processing is performed on the preset object attributes, the preset location information, and the historical multimedia resources viewed by the preset object at the location corresponding to the preset location information to obtain the resource center features corresponding to the preset object. Based on the association relationship determination network, the similarity between the candidate resource information and the resource center features is determined, and a preset relationship determination result is determined based on the similarity. The preset relationship determination result characterizes whether there is an association relationship between the preset object attributes, the preset location information, and the candidate resource information for the preset object. Based on the predetermined relationship determination result, data to be identified is determined from the predetermined object attributes, the predetermined location information, and the candidate resource information. The data to be identified is data used for resource recommendation analysis. When the predetermined relationship determination result indicates that the predetermined location information and the candidate resource information are related, the data to be identified is the predetermined object attributes, the predetermined location information, and the candidate resource information. When the predetermined relationship determination result indicates that the predetermined location information and the candidate resource information are not related, the data to be identified is the predetermined object attributes and the candidate resource information. The data to be identified is input into a resource recommendation model to perform resource recommendation, and a target recommendation result is obtained; the target recommendation result represents the probability of recommending the candidate multimedia resources to the preset object.
2. The method according to claim 1, characterized in that, The determination of the preset relationship based on the similarity includes: If the similarity is less than or equal to a preset similarity threshold, it is determined that the candidate resource information and the preset location information are not related. If the similarity is greater than the preset similarity threshold, it is determined that the candidate resource information and the preset location information are related.
3. The method according to claim 2, characterized in that, The data to be identified includes first data to be identified and second data to be identified. The step of determining the data to be identified from the preset object attributes, the preset location information, and the candidate resource information based on the preset relationship determination result includes: If the preset relationship determination result indicates that the preset location information and the candidate resource information are not related, the preset object attribute and the candidate resource information are determined as the first data to be identified; If the preset relationship determination result indicates that there is an association between the preset location information and the candidate resource information, the preset object attribute, the preset location information, and the candidate resource information are determined as the second data to be identified.
4. The method according to claim 3, characterized in that, The resource recommendation model includes a first recommendation feature extraction network, a second recommendation feature extraction network, and a resource recommendation network. The step of inputting the data to be identified into the resource recommendation model to perform resource recommendation and obtain the target recommendation result includes: The first recommendation feature is extracted from the first recommendation feature extraction network; or the second recommendation feature is extracted from the second recommendation feature extraction network. The target recommendation result is obtained by performing recommendation result recognition processing on the target recommendation feature based on the resource recommendation network; the target recommendation feature is either the first recommendation feature or the second recommendation feature.
5. The method according to claim 1, characterized in that, The preset objects are multiple, and the method further includes: A preset heterogeneous graph is constructed based on the preset object attributes, preset location information, and candidate resource information corresponding to each of the multiple preset objects; the nodes of the preset heterogeneous graph represent the preset object attributes and the candidate resource information, and the edges of the preset heterogeneous graph represent the preset location information. The step of inputting the preset object attributes, the preset location information, and the candidate resource information into the association determination model includes: The preset heterogeneous graph is input into the association relationship to determine the model.
6. A training method for a resource recommendation model, characterized in that, The method further includes: Obtain the sample object attributes of the sample object, the sample location information corresponding to the sample object, and the sample resource information of the sample multimedia resources browsed by the sample object at the sample location; the sample location is the location corresponding to the sample location information. The sample object attributes, the sample location information, and the sample resource information are input into the association relationship determination model to be trained to determine the location-resource relationship, and the sample relationship determination result is obtained. The sample relationship determination result indicates whether there is an association relationship between the sample object attributes, the sample location information, and the sample resource information for the sample object. Based on the sample relationship determination result, sample data to be identified is determined from the sample object attributes, the sample location information, and the sample resource information. The sample data to be identified is data used for resource recommendation analysis. If the sample relationship determination result indicates that there is a correlation between the sample location information and the sample resource information, the sample data to be identified is the sample object attributes, the sample location information, and the sample resource information. If the sample relationship determination result indicates that there is no correlation between the sample location information and the sample resource information, the sample data to be identified is the sample object attributes and the sample resource information. The sample data to be identified is input into the resource recommendation model to be trained for resource recommendation, and the sample recommendation result is obtained; the sample resource information is labeled with object behavior tags and resource location relationship tags, and the resource location relationship tags include a first resource location relationship tag and a second resource location relationship tag; Based on the difference between the sample recommendation result and the object behavior label, a first loss information is determined; based on the sample resource center feature corresponding to the sample object, the similarity between the sample resource information and the sample resource center feature is determined; the sample resource information is sorted from largest to smallest according to the similarity corresponding to the sample resource information to determine a first preset number of sample resource information and a second preset number of sample resource information; a first resource location relationship label is labeled on the first preset number of sample resource information; a second resource location relationship label is labeled on the second preset number of sample resource information; based on the difference between the sample relationship determination result and the resource location relationship label, a second loss information is determined. Based on the first loss information and the second loss information, the model is determined by adjusting the correlation to be trained. The model parameters corresponding to each of the resource recommendation models to be trained are calculated until the training ends, and the resource recommendation model to be trained at the end of training is determined as the resource recommendation model.
7. The method according to claim 6, characterized in that, The sample objects include a first sample object and a second sample object. The first sample object's first sample location information is associated with the first sample resource information, while the second sample object's second sample location information is not associated with the second sample resource information. The step of determining the sample data to be identified from the sample object attributes, the sample location information, and the sample resource information based on the sample relationship determination result includes: The first sample object attribute, the first sample location information, and the first sample resource information of the first sample object are determined as the first sample data; The second sample object attributes and the second sample resource information of the second sample object are determined as the second sample data; Based on the first sample data and the second sample data, the sample data to be identified is determined.
8. The method according to claim 6, characterized in that, The model for determining the association relationship to be trained includes an attribute feature extraction network, a location feature extraction network, and a resource information extraction network. The step of inputting the sample object attributes, the sample location information, and the sample resource information into the model for determining the association relationship to be trained to determine the location-resource relationship and obtain the sample relationship determination result includes: Based on the attribute feature extraction network, the attribute features of the sample object are extracted to obtain the sample attribute features; Based on the location feature extraction network, the location features of the sample location information are extracted to obtain the sample location features; Based on the resource information extraction network, resource features of the sample resource information are extracted to obtain sample resource features; Based on the sample attribute features, the sample location features, and the sample resource features, the sample relationship determination result is determined.
9. The method according to claim 8, characterized in that, The method further includes: The sample attribute features are input into the location prediction model to be trained to obtain the location prediction result; the sample object attributes are labeled with sample location information tags; Based on the difference between the location prediction result and the sample location information label, a third loss information is determined; The step of adjusting the model parameters corresponding to the relationship determination model and the resource recommendation model to be trained, based on the first loss information and the second loss information, until the training termination condition is met, includes: Based on the first loss information, the second loss information, and the third loss information, adjust the model parameters corresponding to the training relationship determination model, the training resource recommendation model, and the training location prediction model until the training termination condition is met.
10. A resource recommendation device, characterized in that, include: The information acquisition module is configured to acquire preset object attributes of a preset object, candidate resource information of candidate multimedia resources, and preset location information corresponding to the preset object; The result determination module is configured to execute the input of the preset object attributes, the preset location information and the candidate resource information into the association relationship determination model. The association relationship determination model includes a central feature extraction network and an association relationship determination network. Based on the central feature extraction network, feature extraction processing is performed on the preset object attributes, the preset location information and the historical multimedia resources browsed by the preset object at the location corresponding to the preset location information to obtain the resource center features corresponding to the preset object. Based on the association relationship, the network determines the similarity between the candidate resource information and the resource center features, and determines the result based on the similarity and a preset relationship. The preset relationship determination result characterizes the preset object attributes for the preset object, and whether there is a correlation between the preset location information and the candidate resource information; The data to be identified module is configured to determine the data to be identified from the preset object attributes, the preset location information, and the candidate resource information by performing a determination based on the preset relationship. The data to be identified is data used for resource recommendation analysis. When the preset relationship determination result indicates that there is a correlation between the preset location information and the candidate resource information, the data to be identified is the preset object attribute, the preset location information, and the candidate resource information. When the preset relationship determination result indicates that the preset location information and the candidate resource information are not related, the data to be identified is the preset object attribute and the candidate resource information; The recommendation result determination module is configured to input the data to be identified into the resource recommendation model to perform resource recommendation and obtain the target recommendation result; The target recommendation result represents the probability of recommending the candidate multimedia resources to the preset object.
11. A training device for a resource recommendation model, characterized in that, include: The sample information acquisition module is configured to acquire the sample object attributes of the sample object, the sample location information corresponding to the sample object, and the sample resource information of the sample multimedia resources browsed by the sample object at the sample location; the sample location is the location corresponding to the sample location information. The sample result determination module is configured to input the sample object attributes, the sample location information, and the sample resource information into the association determination model to be trained to determine the location resource relationship and obtain the sample relationship determination result. The sample relationship determination result characterizes the sample object attributes for the sample object, and whether there is a correlation between the sample location information and the sample resource information; The sample data determination module is configured to determine the sample data to be identified from the sample object attributes, the sample location information, and the sample resource information based on the result determined by the sample relationship. The sample data to be identified is data used for resource recommendation analysis. When the sample relationship determination result indicates that there is a correlation between the sample location information and the sample resource information, the sample data to be identified includes the sample object attributes, the sample location information, and the sample resource information. When the sample relationship determination result indicates that the sample location information and the sample resource information are not related, the sample data to be identified is the sample object attribute and the sample resource information; The sample recommendation result determination module is configured to input the sample data to be identified into the resource recommendation model to be trained to perform resource recommendation and obtain the sample recommendation result. The sample resource information is labeled with object behavior tags and resource location relationship tags, and the resource location relationship tags include a first resource location relationship tag and a second resource location relationship tag; The model training module is configured to determine first loss information based on the difference between the sample recommendation results and the object behavior labels; Based on the sample resource center features corresponding to the sample object, determine the similarity between the sample resource information and the sample resource center features; The sample resource information is sorted from largest to smallest according to the similarity corresponding to the sample resource information, and a first preset number of sample resource information and a last preset number of sample resource information are determined. The first resource location relationship label is used to label the resource information of the first preset number of samples; The second resource location relationship label is used to label the resource information of the subsequent preset number of samples; Based on the difference between the sample relationship determination result and the resource location relationship label, a second loss information is determined; based on the first loss information and the second loss information, the model parameters corresponding to the relationship determination model to be trained and the resource recommendation model to be trained are adjusted until the training termination condition is met, and the resource recommendation model to be trained at the end of training is determined as the resource recommendation model.
12. An electronic device, characterized in that, include: processor; Memory used to store the processor's executable instructions; The processor is configured to execute the instructions to implement the resource recommendation method as described in any one of claims 1-5 or the training method of the resource recommendation model as described in any one of claims 6-9.
13. A computer-readable storage medium, characterized in that, When the instructions in the computer-readable storage medium are executed by the processor of an electronic device, the electronic device is able to perform the resource recommendation method as described in any one of claims 1-5 or the training method of the resource recommendation model as described in any one of claims 6-9.