Object Recommendation Method, Device, Equipment, Medium and Product

By iteratively training the target graph neural network and using training round control with different parameters, the problem of instability in training frequency domain graph neural networks in large-scale social network data is solved, and the model training efficiency and recommendation accuracy are improved.

CN117009635BActive Publication Date: 2025-07-25TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

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

AI Technical Summary

Technical Problem

In large-scale social network data, frequency domain graph neural network training is unstable, resulting in low model training efficiency and affecting recommendation accuracy.

Method used

By iteratively training the target graph neural network, the training round control of different parameters is adopted, the first and second types of parameters are updated respectively to improve the model training efficiency.

Benefits of technology

Improves the training stability and recommendation accuracy of graph neural networks under large-scale data sets.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117009635B_ABST
    Figure CN117009635B_ABST
Patent Text Reader

Abstract

The present application discloses an object recommendation method, apparatus, device, medium and product, relating to the field of artificial intelligence. The method includes: obtaining graph data corresponding to a plurality of candidate objects; inputting the graph data into a target graph neural network to obtain object node representations respectively corresponding to the plurality of candidate objects; in response to receiving an object recommendation request for a first object, determining a target object to be recommended to an account corresponding to the first object from second objects based on the correlation score between the first object node representation corresponding to the first object and a second object node representation; the target graph neural network is obtained by iteratively training a graph neural network, and in the iterative training process of the graph neural network, in each round of iterative training, first type of parameters are iteratively updated, and in the iterative training rounds meeting the round requirement, second type of parameters are iteratively updated. This method improves the training efficiency of the model, thereby ensuring the recommendation accuracy in downstream object recommendation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of artificial intelligence, and particularly to an object recommendation method, apparatus, device, medium and product. Background Art

[0002] A graph is a basic data structure. Graph data consists of nodes and edges. Graph data can record the relationships between the objects corresponding to the nodes. In many fields, by learning the features of the nodes and edges in the graph data, support can be provided for downstream tasks.

[0003] Since graph data can well record the association relationships between nodes, graph data is commonly applied in the recommendation field. For example, in the friend recommendation scenario, graph data can be generated based on the friend relationships between users. By learning the features of the graph data, the node representations corresponding to each node can be obtained, and the friend recommendation function can be implemented according to the similarity between the node representations. In related technologies, frequency-domain graph neural networks are often used to obtain the node vector representations in graph data, and then the recommendation scores are calculated according to the similarity between the node vector representations.

[0004] However, with the development of the Internet, when social network data is converted into graph data, there are more than one million nodes, that is, the data scale is huge. When frequency-domain graph neural networks process large-scale data, due to the large deviation in the structural distribution of different parts in the large-scale graph data, a very severe problem of training instability occurs, resulting in difficult convergence of network parameters, low training efficiency of the model, and thus affecting the downstream recommendation accuracy. Summary of the Invention

[0005] Embodiments of this application provide an object recommendation method, apparatus, device, medium and product, which can improve the stability and training efficiency of graph neural network training in the scenario of large-scale data sets, thereby ensuring the accuracy of downstream recommendations. The technical solutions are as follows:

[0006] On the one hand, an object recommendation method is provided. The method includes:

[0007] Obtain graph data corresponding to multiple candidate objects. The graph data includes nodes corresponding to the multiple candidate objects respectively, and the nodes in the graph data are connected by edges according to the association relationships between the multiple candidate objects;

[0008] Input the graph data into a target graph neural network, extract the features of the association relationships between the nodes in the graph data, and obtain the object node representations corresponding to the multiple candidate objects respectively. The multiple candidate objects include a first object;

[0009] In response to receiving an object recommendation request for the first object, based on the association degree score between the first object node representation corresponding to the first object and the second object node representation, a target object to be recommended to the account corresponding to the first object is determined from the second objects, where the second objects are at least one candidate object other than the first object among the multiple candidate objects, and the second object node representation corresponds to the second object;

[0010] Wherein, the target graph neural network is obtained by iteratively training a graph neural network. The network parameters of the graph neural network include a first type of parameter and a second type of parameter. During the iterative training process of the graph neural network, the first type of parameter is iteratively updated in each round of iterative training, and the second type of parameter is iteratively updated in the iterative training rounds that meet the round requirements. When the iterative training rounds reach the target iterative number corresponding to the graph neural network, the target neural network is obtained.

[0011] On the other hand, an object recommendation device is provided, and the device includes:

[0012] An acquisition module, configured to acquire graph data corresponding to multiple candidate objects, where the graph data includes nodes corresponding to the multiple candidate objects respectively, and the nodes in the graph data are connected by edges according to the association relationship between the multiple candidate objects;

[0013] A prediction module, configured to input the graph data into a target graph neural network, extract features from the association relationship between each node in the graph data, and obtain object node representations corresponding to the multiple candidate objects respectively, where the multiple candidate objects include a first object;

[0014] A recommendation module, configured to, in response to receiving an object recommendation request for the first object, based on the association degree score between the first object node representation corresponding to the first object and the second object node representation, determine a target object to be recommended to the account corresponding to the first object from the second objects, where the second objects are at least one candidate object other than the first object among the multiple candidate objects, and the second object node representation corresponds to the second object;

[0015] Wherein, the target graph neural network is obtained by iteratively training a graph neural network. The network parameters of the graph neural network include a first type of parameter and a second type of parameter. During the iterative training process of the graph neural network, the first type of parameter is iteratively updated in each round of iterative training, and the second type of parameter is iteratively updated in the iterative training rounds that meet the round requirements. When the iterative training rounds reach the target iterative number corresponding to the graph neural network, the target neural network is obtained.

[0016] On the other hand, a computer device is provided. The terminal includes a processor and a memory. At least one instruction, at least one program, a code set, or an instruction set is stored in the memory. The at least one instruction, the at least one program, the code set, or the instruction set is loaded and executed by the processor to implement any one of the object recommendation methods in the embodiments of the present application.

[0017] On the other hand, a computer-readable storage medium is provided. At least one program code is stored in the computer-readable storage medium. The program code is loaded and executed by the processor to implement any one of the object recommendation methods in the embodiments of the present application.

[0018] On the other hand, a computer program product or a computer program is provided. The computer program product or the computer program includes computer instructions. The computer instructions are stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes any one of the object recommendation methods in the above embodiments.

[0019] The technical solutions provided in the present application at least include the following beneficial effects:

[0020] In the process of object recommendation, object node representations corresponding to each candidate object are obtained by a target graph neural network trained from graph data corresponding to multiple candidate objects, and object recommendation is realized through the correlation degree scores between the object node representations. Among them, the above target graph neural network is obtained by iterative training of a graph neural network. The above graph neural network includes a first type of parameters and a second type of parameters. In the iterative training process, the first type of parameters are iteratively updated in each round of iterative training, while the second type of parameters are iteratively updated in the iterative training rounds that meet the round requirements. That is, this method controls the network parameters to converge better in the iterative training process by adjusting the training rounds of different parameters in the graph neural network and adopting the method of updating parameters separately, thereby improving the training efficiency of the model and further ensuring the recommendation accuracy in downstream object recommendation. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for the description of the embodiments will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.

[0022] Figure 1 is a schematic diagram of a computer system provided by an exemplary embodiment of the present application;

[0023] Figure 2 It is a flowchart of an object recommendation method provided by an exemplary embodiment of the present application;

[0024] Figure 3 It is a flowchart of a training method of a graph neural network provided by an exemplary embodiment of the present application;

[0025] Figure 4 It is a flowchart of a training method of a graph neural network provided by an exemplary embodiment of the present application;

[0026] Figure 5 It is a flowchart of an object recommendation method provided by an exemplary embodiment of the present application;

[0027] Figure 6 It is a schematic diagram of a node representation acquisition process provided by an exemplary embodiment of the present application;

[0028] Figure 7 It is a schematic diagram of an item recommendation task provided by an exemplary embodiment of the present application;

[0029] Figure 8 It is a schematic diagram of game item recommendation provided by an exemplary embodiment of the present application;

[0030] Figure 9 It is a schematic diagram of a friend recommendation task provided by an exemplary embodiment of the present application;

[0031] Figure 10 It is a schematic diagram of friend recommendation provided by an exemplary embodiment of the present application;

[0032] Figure 11 It is a structural block diagram of an object recommendation device provided by an exemplary embodiment of the present application;

[0033] Figure 12 It is a structural block diagram of an object recommendation device provided by an exemplary embodiment of the present application;

[0034] Figure 13 It is a schematic diagram of the structure of a server provided by an exemplary embodiment of the present application. Detailed implementation manners

[0035] To make the objectives, technical solutions and advantages of the present application clearer, the embodiments of the present application will be further described in detail below with reference to the accompanying drawings.

[0036] First, the nouns involved in the embodiments of the present application will be briefly introduced:

[0037] Artificial Intelligence: It uses digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, including theories, methods, technologies, and application systems that can perceive the environment, acquire knowledge, and use knowledge to achieve the best results. In other words, artificial intelligence is a comprehensive technology in computer science that attempts to understand the essence of intelligence and produce an intelligent machine that can respond in a way similar to human intelligence. Artificial intelligence also studies the design principles and implementation methods of various intelligent machines, enabling machines to have the functions of perception, reasoning, and decision-making.

[0038] Artificial intelligence technology is an interdisciplinary subject with a wide range of fields, including both hardware-level and software-level technologies. The basic technologies of artificial intelligence generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, and mechatronics. The software technologies of artificial intelligence mainly include several major directions such as computer vision technology, speech processing technology, natural language processing technology, and machine learning / deep learning, autonomous driving, and intelligent transportation.

[0039] Machine Learning (ML): It is an interdisciplinary subject involving multiple fields such as probability theory, statistics, approximation theory, convex analysis, and algorithm complexity theory. It specifically studies how computers simulate or implement human learning behaviors to acquire new knowledge or skills and reorganize the existing knowledge structure to continuously improve their own performance. Machine learning is the core of artificial intelligence and the fundamental way to make computers intelligent, and its applications cover all fields of artificial intelligence. Machine learning and deep learning usually include technologies such as artificial neural networks, belief networks, reinforcement learning, transfer learning, inductive learning, and learning from demonstration.

[0040] Graph: Graph data consists of nodes and edges, and is symbolically represented as where represents the set of nodes, and ε = {e i}, |ε| = M represents the set of edges. As a data structure that can well record node attributes and edge attributes, graph data thus has good learning effects in the field of machine learning for learning the association relationships between objects.

[0041] Graph representation learning: Generate a representation vector for each node, which helps to utilize downstream tasks for a full understanding of graph data. The implementation can be to use the node classification task. Given the entire graph structure and the initial representation of each node on the graph, obtain the hidden layer representation of the nodes through a graph neural network. Finally, calculate the cross-entropy using the known class labels of the training set and the obtained representations of the training set, and update the parameters of the graph neural network. Since the initial representations of all nodes are known and only the labels of the training set are available, this task is usually also called a semi-supervised node classification task, which is a general method for obtaining the vector representations of nodes in a graph.

[0042] Graph Neural Networks (GNN): Common graph neural networks include graph recurrent neural networks, Graph Convolutional Networks (GCN), graph autoencoders, and spatio-temporal graph neural networks. Among them, graph convolutional networks include spectral-based graph convolutional networks and spatial-based graph convolutional networks.

[0043] Schematically, the application scenarios in the embodiments of the present application are schematically described:

[0044] Applied to the recommendation scenario. Schematically, taking an e-commerce platform as an example, in the e-commerce platform, graph data of account-account-item-item can be generated based on the purchase situation of items by an account, the social relationship between accounts, and the similarity relationship between items. The above graph data is trained by the method provided in the embodiments of the present application to obtain a target graph neural network. Among them, the obtained target graph neural network has learned the association relationships between accounts and accounts, accounts and items, and items and items in the graph data. Through this target graph neural network, the node representations corresponding to each node in the graph data can be output. The association relationship between accounts can be determined through the similarity between the account node representations, thereby realizing the friend recommendation function. The association relationship between an account and an item can be determined through the similarity between the account node representation and the item node representation, thereby realizing the item recommendation function.

[0045] It should be noted that the target graph neural network involved in the embodiments of the present application can also be applied to the following scenarios:

[0046] 1. Applied to the chemical field. Schematically, taking compound discovery as an example, model the compound molecule as graph data, and train the above graph data by the method provided in the embodiments of the present application to obtain a target graph neural network. The obtained target graph neural network has learned the biological activity under the molecular structure in the graph data. Through this target graph neural network, the node representations corresponding to each node in the graph data can be output, so as to discover new compounds through the node representations between atoms.

[0047] 2. Applied to the citation network. Schematically, in a paper database, there may be citation relationships between different papers. According to the citation relationships between papers, there is a certain degree of correlation between the papers with citation relationships. The above graph data is trained by the method provided in the embodiments of the present application to obtain a target graph neural network. The obtained target graph neural network has learned the correlation degree between papers in the graph data. Through this target graph neural network, the node representations corresponding to each node in the graph data can be output, so as to determine the correlation degree between papers through the node representations between papers, thereby realizing functions such as indexing and recommendation of relevant papers.

[0048] Combined with the above noun introduction and application scenarios, taking the application in the recommendation scenario as an example, the implementation environment of the embodiments of the present application is described. As Figure 1 shown, the computer system of this implementation environment includes: a terminal device 110, a server 120, and a communication network 130.

[0049] The terminal device 110 includes devices in various forms such as mobile phones, tablet computers, desktop computers, portable laptops, intelligent voice interaction devices, intelligent home appliances, vehicle terminals, and aircraft. A target application runs on the terminal device 110, and the target application includes a module for providing a recommendation service for the logged-in target account. This service module will perform content recommendation when the user uses the target application. Schematically, the target application can be a traditional application software, a cloud application software, can be implemented as a small program or application module in a host application program, or can be a certain web platform, which is not limited here. Optionally, the above target application can be an e-commerce application, a short video application, an audio application, a novel application, etc., which is not specifically limited here.

[0050] The server 120 is used to provide backend services for the target application in the terminal device 110, where the backend services include recommendation services. Schematically, taking the recommended content as a commodity as an example, the server 120 obtains the historical interaction record of the target account for the commodity under the condition of obtaining the authorization of the target account. The historical interaction record may include the commodities purchased / collected / shared by the target account during the historical period. The server 120 obtains the historical interaction records corresponding to multiple accounts in the platform, the social relationship data between multiple accounts, and the similarity relationship between commodities, generates graph data according to the above historical interaction records, social relationship data, and similarity relationship between commodities, and uses the above graph data to train the graph neural network by the method provided in the embodiments of the present application to obtain a target graph neural network.

[0051] When it is necessary to recommend products to a target account, the server 120 obtains the node representation corresponding to the node of the target account in the graph data through the target graph neural network, that is, obtains the account node representation. Then, candidate products are screened from the product library, and the node representation corresponding to the candidate products is obtained through the target graph neural network, that is, obtains the product node representation. By calculating the feature similarity between the account node representation and the product node representation, the above similarity is used as the recommendation score when recommending the candidate products to the target account, and the candidate products are screened based on the recommendation score to determine the target products recommended to the target account.

[0052] It should be noted that the above server 120 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, Content Delivery Network (CDN), and big data and artificial intelligence platforms.

[0053] Among them, cloud technology refers to a hosting technology that unifies a series of resources such as hardware, software, and networks within a wide area network or local area network to achieve data computing, storage, processing, and sharing. Cloud technology is the general term for network technology, information technology, integration technology, management platform technology, application technology, etc. based on the cloud computing business model. It can form a resource pool, be used on demand, and is flexible and convenient. Cloud computing technology will become an important support. The background services of the technical network system require a large amount of computing and storage resources, such as video websites, picture websites, and more portal websites. With the highly developed application of the Internet industry, in the future, each item may have its own identification mark and needs to be transmitted to the background system for logical processing. Data at different levels will be processed separately, and various industry data requires a powerful system backup support, which can only be achieved through cloud computing.

[0054] In some embodiments, the above server 120 can also be implemented as a node in a blockchain system. Blockchain is a new application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, and encryption algorithm.

[0055] Schematically, the terminal device 110 and the server 120 are connected through the communication network 130. Among them, the above communication network 130 can be a wired network or a wireless network, which is not limited here.

[0056] Please refer to Figure 2, which shows the object recommendation method shown in an embodiment of the present application. In the embodiment of the present application, taking this method as an example, it is applied to a server as shown in Figure 1 The method includes:

[0057] Step 210, obtain graph data corresponding to multiple candidate objects, where the graph data includes nodes corresponding to multiple candidate objects respectively.

[0058] Among them, the nodes in the above graph data are connected by edges according to the association relationships between multiple candidate objects. Schematically, the association relationships between nodes are indicated by the recommendation scenarios to which the graph data is applied.

[0059] Optionally, in the account recommendation scenario, the above candidate objects include candidate accounts, and the graph data is connected according to the social relationships between candidate accounts, that is, the association relationships between nodes can be the social relationships between accounts.

[0060] Optionally, in the content recommendation scenario, the above candidate objects include candidate accounts and candidate content, and the graph data is connected according to the interaction relationships between candidate accounts and candidate content, and the category relationships between content and content, that is, the association relationships between nodes can be the interaction relationships between accounts and content, and the category relationships between content and content.

[0061] Optionally, the above content can be at least one of text recommendation content, video recommendation content, image recommendation content, music recommendation content, goods, virtual props, etc.

[0062] Step 220, input the graph data into the target graph neural network, extract the association relationships between each node in the graph data, and obtain the object node representations corresponding to multiple candidate objects respectively.

[0063] Schematically, the above target graph neural network is obtained by iteratively training the graph neural network. In the embodiment of the present application, the network parameters of the above graph neural network include the first type of parameters and the second type of parameters. In the iterative training process of the graph neural network, the first type of parameters are iteratively updated in each round of iterative training, and the second type of parameters are iteratively updated in the iterative training rounds that meet the round requirements. When the iterative training rounds reach the target iterative times corresponding to the graph neural network, the target neural network is obtained.

[0064] Optionally, the above target graph neural network is a network pre-trained and stored through graph data. In some embodiments, the server collects relevant data at a specified update frequency to update the graph data. When the graph data is updated, the graph neural network can be synchronously trained and updated, and the updated target graph neural network is stored.

[0065] In some embodiments, after the target graph neural network is trained, the server inputs graph data into the target graph neural network to obtain object node representations corresponding to each node, and stores the above object node representations and candidate objects in correspondence to improve the acquisition efficiency of downstream object node representations.

[0066] Step 230, in response to receiving an object recommendation request for a first object, determine a target object to be recommended to the account corresponding to the first object from the second objects based on the correlation score between the first object node representation corresponding to the first object and the second object node representation.

[0067] Illustratively, the above multiple candidate objects include a first object, and the first object is the object for which object recommendation is to be performed. For example, in an account recommendation scenario, the first object is the first account for which account recommendation is to be performed. In some embodiments, the above object recommendation request is sent through the terminal corresponding to the first object.

[0068] Illustratively, the above second object is at least one candidate object other than the first object among the multiple candidate objects, and the second object node representation corresponds to the second object.

[0069] In some embodiments, after receiving an object recommendation request for a first object, the server obtains the first object node representation corresponding to the first object and the second object node representation corresponding to the second object from the object node representations corresponding to the above multiple candidate objects respectively, and calculates the feature similarity between the first object node representation and the second object node representation, and uses the above feature similarity as the correlation score between the first object and the second object.

[0070] Optionally, the above feature distance may be at least one of Euclidean Distance, Mahalanobis Distance, Manhattan Distance, cosine distance, etc., which is not limited herein.

[0071] Optionally, the above second object may be all objects other than the first object among all candidate objects corresponding to the graph data; or, the above second object may be an object determined after screening other candidate objects other than the first object.

[0072] In some embodiments, it is determined whether to recommend the second object to the account corresponding to the first object according to the relationship between the correlation score between the first object and the second object and the recommendation score threshold, that is, in response to the correlation score between the first object and the second object reaching the recommendation score threshold, recommend the second object to the account corresponding to the first object.

[0073] In some other embodiments, when there are multiple second objects, the multiple second objects can also be sorted according to the above-mentioned association degree scores to obtain a second object list, and the N second objects with the highest association degree scores are obtained from the second object list as the target objects recommended to the account corresponding to the first object, where N is a positive integer.

[0074] In summary, in the object recommendation method provided by the embodiments of the present application, during the process of object recommendation, the object node representations corresponding to each candidate object are obtained by the target graph neural network trained by the graph data corresponding to multiple candidate objects, and object recommendation is achieved through the association degree scores between the object node representations. Among them, the above-mentioned target graph neural network is obtained by iterative training of a graph neural network. The above-mentioned graph neural network includes first-type parameters and second-type parameters. During the iterative training process, the first-type parameters are iteratively updated in each round of iterative training, while the second-type parameters are iteratively updated in the iterative training rounds that meet the round requirements. That is, this method controls the network parameters to better converge during the iterative training process by adjusting the training rounds of different parameters in the graph neural network and adopting the method of separately updating the parameters, thereby improving the training efficiency of the model and further ensuring the recommendation accuracy in downstream object recommendation.

[0075] Please refer to Figure 3 , which shows a flowchart of a method for training a graph neural network provided by an exemplary embodiment of the present application. In the embodiments of the present application, the training process of the above-mentioned target graph neural network is schematically described. The method includes:

[0076] Step 310, obtain graph data, where the graph data includes multiple nodes.

[0077] Among them, the above-mentioned multiple nodes are connected by edges according to the association relationship. In one example, when the nodes in the graph data represent accounts, the association relationship between the nodes can be the social relationship between the accounts. For example, if the first account and the second account are friends, the first node corresponding to the first account and the second node corresponding to the second account can be connected; in another example, when the nodes in the graph data represent items, the association relationship between the nodes can be the category relationship between the items. For example, if the first item and the second item belong to the same item category, the first node corresponding to the first item and the second node corresponding to the second item can be connected.

[0078] Optionally, the graph structure corresponding to the above graph data can be a directed graph or an undirected graph. Schematically, the graph structure of the graph data can be adaptively selected according to different application scenarios. In one example, in a social recommendation scenario, the graph data represents the social relationship between accounts, and the graph data used can be an undirected graph; in another example, in the recommendation of Points of Interest (POIs) in a map scenario, the graph data represents the access order of an account to geographical locations to indicate the path direction between nodes.

[0079] Optionally, the edges connecting the nodes in the above graph data can be unweighted edges or weighted edges.

[0080] When the connection between nodes is an unweighted edge, it can be applied to graph data where the association relationship between nodes is a binary classification relationship. For example, the edges between nodes are used to represent the social relationship between the accounts corresponding to the nodes. Among them, the social relationship includes friend relationship and non-friend relationship. If the first account and the second account are friends, then the first node corresponding to the first account and the second node corresponding to the second account are connected. If the first account and the second account are not friends, then there is no edge between the first node corresponding to the first account and the second node corresponding to the second account.

[0081] When the connection between nodes is a weighted edge, it can be applied to graph data where the association relationship between nodes is a multi-classification relationship, and the edges established according to different relationships have different weights. For example, the edges between nodes are used to represent the social relationship between the accounts corresponding to the nodes. Among them, the social relationship includes friend relationship and non-friend relationship. In the friend relationship, there are further divided into a first relationship where the interaction frequency reaches the frequency threshold and a second relationship where the interaction frequency does not reach the frequency threshold. In the non-friend relationship, there are further divided into a third relationship with an interaction history and a fourth relationship without an interaction history. The weight of the edge corresponding to the first relationship is "1", the weight of the edge corresponding to the second relationship is "0.75", the weight of the edge corresponding to the third relationship is "0.5", and the weight of the edge corresponding to the fourth relationship is "0", that is, there is no connected edge between the account nodes in the fourth relationship.

[0082] In some embodiments, multiple nodes respectively correspond to node labels. Schematically, the above node labels are labels obtained by annotating the graph data before training the graph neural network. In some embodiments, the above node labels are used to label the categories of nodes.

[0083] Step 320, in the i-th round of iterative training, the graph neural network extracts features of the nodes according to the association relationship between the nodes, and outputs intermediate node representations respectively corresponding to the multiple nodes.

[0084] Among them, the network parameters of the above graph neural network include first-class parameters and second-class parameters. In some embodiments, the first-class parameters and the second-class parameters have different effects during the process of the graph neural network processing graph data. In one example, the first-class parameters are used to reduce the dimension of the features corresponding to the nodes in the graph data, and the second-class parameters are used to factorize the graph structure corresponding to the graph data. In some other embodiments, it can also be implemented that the first-class parameters are used to factorize the graph structure corresponding to the graph data, and the second-class parameters are used to reduce the dimension of the features corresponding to the nodes in the graph data.

[0085] Optionally, the first-class parameters may include multiple parameters; and / or, the second-class parameters may include multiple parameters.

[0086] Optionally, the above graph neural network may be at least one of a graph recurrent neural network, a graph convolutional neural network, a graph autoencoder, and a spatio-temporal graph neural network. In some embodiments, the network structure of the above graph neural network may be preset by the server or indicated by the terminal, which is not limited herein.

[0087] In some embodiments, before the iterative training of the graph neural network, parameter initialization processing may be performed on the first-class parameters and the second-class parameters. Optionally, the initialized parameters may be preset by the system or indicated by the terminal.

[0088] In some other embodiments, before the iterative training of the graph neural network, the network parameters of the graph neural network are set, where the set network parameters may come from the network parameters of the historical graph neural network. Schematically, the server collects relevant data at a specified update frequency to update the graph data. When the graph data is updated, synchronous training and update of the graph neural network can be performed, and the network parameters corresponding to the graph neural network when starting the current training process may be inherited from the network parameters of the historical graph neural network, where the above historical graph neural network may be a graph neural network that has completed training within a historical period, for example, the last graph neural network that has completed training and been put into use.

[0089] In some embodiments, the graph neural network includes a target number of iterations, that is, the number of iterative training rounds of the graph neural network needs to reach the target number of iterations.

[0090] Optionally, the above target number of iterations may be preset by the system or indicated by the terminal, which is not limited herein.

[0091] Step 330, based on the difference between the intermediate node representation and the node label, determine the first parameter adjustment gradient of the first-class parameters and the second parameter adjustment gradient of the second-class parameters.

[0092] In some embodiments, the difference between the intermediate node representation and the node label is determined by a loss function. Optionally, the above loss function may be at least one of a squared loss function, an exponential loss function, a Hinge loss function, a perceptron loss function, a cross-entropy loss function, a mean squared error loss function, etc.

[0093] Schematically, the first type of parameter is differentiated according to the loss function to obtain the first parameter adjustment gradient corresponding to the first type of parameter; the second type of parameter is differentiated according to the loss function to obtain the second parameter adjustment gradient corresponding to the second type of parameter.

[0094] Step 340, iteratively update the first type of parameter based on the first parameter adjustment gradient, and in response to the i-th round of iterative training meeting the round requirement, iteratively update the second type of parameter based on the second parameter adjustment gradient.

[0095] Schematically, during the training process of the graph neural network, the first type of parameter is updated in each iterative training round, while the second type of parameter is updated only when the iterative training round meets the round requirement.

[0096] In some embodiments, the round requirement indicates that the iterative update of the second type of parameter meets a specified training round interval. Schematically, the second type of parameter corresponds to a training round interval g. When i is divisible by g, it is determined that the i-th round of iterative training meets the round requirement, that is, in response to i being an integer multiple of g, the second type of parameter is iteratively updated based on the second parameter adjustment gradient.

[0097] Optionally, the above training round interval g can be preset by the server or indicated by the terminal. Optionally, the above training round interval g can be a specified fixed value or obtained by conversion according to a preset conversion rule.

[0098] In some embodiments, the above preset conversion rule may indicate determining the corresponding training round interval g according to the data volume size of the graph data. Schematically, the more nodes and edges included in the data, the larger the data volume corresponding to the graph data. In some embodiments, the training round interval g and the data volume of the graph data are in a positive correlation relationship, that is, when the data volume of the graph data is larger, the set training round interval g is larger.

[0099] In some embodiments, the number of nodes and the number of edges in the graph data can be added to determine the data volume of the graph. In one example, the corresponding relationship between the data volume range of the graph data and the training round interval g is pre-stored in the server; in another example, the conversion formula between the data volume of the graph data and the training round interval is pre-stored in the server. The server first determines the corresponding data volume according to the graph data, and then substitutes the data volume into the above conversion formula to obtain the training round interval g.

[0100] In some embodiments, when iteratively updating network parameters, to avoid missing the extreme point due to convergence at the same step size during the gradient descent process, a specified learning rate needs to be set. Illustratively, the first type of parameters are iteratively updated by adjusting the gradient and the first learning rate with the first parameter, and the second type of parameters are iteratively updated by adjusting the gradient and the second learning rate with the second parameter. Optionally, the first learning rate and the second learning rate may be the same or different, which is not limited herein.

[0101] Step 350, in response to the number of iterative training rounds of the graph neural network reaching the target number of iterations, generate a target graph neural network.

[0102] Among them, the target graph neural network is used to extract target node representations for multiple nodes in the graph data, and the target node representations are used to predict the node association relationships between at least two nodes among the multiple nodes. That is, by extracting node features from the graph data through the trained target graph neural network, the target node representations corresponding to the nodes can be obtained, and the target node representations can be applied to downstream tasks.

[0103] Optionally, the above-mentioned downstream tasks may be at least one of a recommendation task, compound discovery, content association task, etc.

[0104] In summary, in the training method of the graph neural network provided by the embodiments of the present application, during the training process of the graph neural network, the graph data is input into the graph neural network, and the intermediate node representations corresponding to the nodes in the graph data are predicted. According to the difference between the intermediate node representations and the node labels corresponding to the nodes, the first parameter adjustment gradient corresponding to the first type of parameters of the graph neural network and the second parameter adjustment gradient corresponding to the second type of parameters are determined, and the first type of parameters are iteratively updated according to the first parameter adjustment gradient in each iterative training round, and the second type of parameters are iteratively updated according to the second parameter adjustment gradient in the iterative training rounds that meet the round requirements, so as to realize the training of the graph neural network and obtain a target graph neural network. After inputting the graph data into the target graph neural network, the target node representations corresponding to each node in the graph data can be obtained, and the target node representations can be used to calculate the association relationships between the nodes in the graph data in downstream tasks. That is, this method controls the better convergence of network parameters during the iterative training process by adjusting the training rounds of different parameters in the graph neural network and adopting the method of updating parameters separately, thereby improving the training efficiency of the model.

[0105] Please refer to Figure 4 , which shows a flowchart of the training method of the graph neural network provided by an exemplary embodiment of the present application. In the embodiments of the present application, taking the graph neural network as a frequency-domain graph neural network as an example, the training process of the graph neural network is illustratively described. The method includes:

[0106] Step 410: Obtain graph data, where the graph data includes multiple nodes.

[0107] Among them, the multiple nodes are connected by edges according to the association relationship.

[0108] In the embodiment of the present application, since the graph neural network used is a frequency-domain graph neural network, the above graph data can be an undirected graph.

[0109] Each of the multiple nodes corresponds to a node label. Schematically, the above node labels are the labels obtained by annotating the graph data before training the graph neural network.

[0110] Step 420: In the i-th round of iterative training, use the graph neural network to extract features of the nodes according to the association relationship between the nodes, and output the intermediate node representations corresponding to the multiple nodes respectively.

[0111] The network parameters of the above graph neural network include first-class parameters and second-class parameters. In the embodiment of the present application, the graph neural network is implemented as a frequency-domain graph neural network, and the frequency-domain graph neural network is described as follows:

[0112] The graph data consists of nodes and edges, that is, the graph Among them, represents the node set, ε = {e i}, |ε| = M represents the edge set. The graph corresponds to an adjacency matrix A ∈ R N×N , A ij ∈ {0, 1}, and the node degree matrix The Laplacian matrix L = D - A of the graph structure can be obtained through the adjacency matrix A and the node degree matrix D. The Laplacian matrix L can be normalized by Formula 1 to obtain the standard Laplacian matrix

[0113] Formula 1:

[0114] The standard Laplacian matrix is a real symmetric positive semi-definite matrix, so it can be eigen-decomposed as shown in Formula 2, where Λ = {λ i} ∈ [0, 2] represents the eigenvalues, and U is the eigenvector matrix corresponding to the eigenvalues.

[0115] Formula 2:

[0116] Frequency-domain graph neural networks regard eigenvalues as numerical representatives of graph structures. Essentially, they aim to learn an eigenvalue function \(g(\lambda)\) that best adapts to the graph node signals \(X\) and labels \(Y\) given the graph data, which is also called a filter. Different frequency-domain graph neural networks make different functional assumptions about \(g(\lambda)\) and then learn the parameters through semi-supervised node classification tasks.

[0117] Frequency-domain graph neural networks need to learn a filter function to adaptively fit graph signals, so requirements are imposed on the expressive power of the filter function. However, since directly learning the filter costs requires factoring the entire graph structure, polynomial functions are generally used to approximate an arbitrarily shaped function, as shown in Equation (3). Here, \(K\) represents the order of the polynomial. The higher the order, the stronger the ability of the function to express and fit an arbitrary shape; \(P\) k (\lambda)\) represents the polynomial function form of the \(k\)-th order. In one example, as shown in Equation (4); \(\theta\) k represents the parameters of the filter.

[0118] Equation (3):

[0119] Equation (4): \(P\) k (x)=x k

[0120] In addition, different polynomial functions can be selected as bases, such as the ChebyShev polynomial (\(\in[-1,1]\)) shown in Equation (5), or the Bernstein polynomial (\(\in[-1,1]\)) shown in Equation (6).

[0121] Equation (5):

[0122] Equation (6):

[0123] In the actual application process, as shown in Equation (7), the method of using the polynomial \(g(L)\) to fit the filter can also avoid factoring the Laplacian matrix, thereby learning a filter on the Laplacian matrix.

[0124] Equation (7): \(g(L)=Ug(\Lambda)U\) T

[0125] Generally speaking, the expression of the frequency-domain graph neural network is as shown in Equation (8), where \(P\) k (L)\) represents the \(k\)-th order expression of different polynomials (such as the ChebyShev polynomial) mentioned above, and \(\sigma(XW_1)W_2\) can be regarded as reducing the dimension of the input features through a multilayer perceptron (MLP).

[0126] Equation (8):

[0127] At present, the frequency-domain graph neural network has shown very good performance on small-scale data sets. However, the entire graph structure information is input during each iterative training. With the expansion of the application scenarios of graph data, the scale of graph data in many scenarios is getting larger and larger. For example, when graph data is applied to the recommendation process in social scenarios, and the social network data has nodes in the millions or more. Due to the methods in the related technologies that need to input the entire graph data, the storage space and computing power of existing computing machines limit the application of the frequency-domain graph neural network in large-scale data scenarios.

[0128] In the embodiments of the present application, it is possible to enable the frequency-domain graph neural network to be applied in large-scale graph learning scenarios.

[0129] Schematically, when the graph neural network is implemented as a frequency-domain graph neural network, the above-mentioned first type of parameters is used to reduce the dimension of the features corresponding to the nodes in the graph data. That is, the first type of parameters includes W1 and W2 in Formula VIII; the above-mentioned second type of parameters is used to factorize the graph structure corresponding to the graph data. That is, the second type of parameters is the filter parameter θ k .

[0130] In some embodiments, before training the graph neural network, the network parameters of the graph neural network are first initialized, that is, the above-mentioned W1, W2, and θ k are initialized to obtain W1 (0) , W2 (0) , In the embodiments of the present application, when initializing the network parameters, the gradient set is also initialized. The gradient set is used to store the adjusted gradient of the second parameter in the iterative training rounds where the second type of parameters are not updated.

[0131] In some embodiments, a recording parameter H for recording node representations is also set in the cache area of the server. Before training, the recording parameter H is initialized. In one example, the initialization of H is performed using H (0) ←X, where X = R N×d is the pre-set initial representation of the node.

[0132] In some embodiments, in each round of iterative training, the complete graph data is input into the graph neural network to determine the intermediate node representations, that is, the complete graph data is used in each round of training.

[0133] In some other embodiments, to reduce the amount of data during the training process, in each round of iterative training, only a part of the graph data is input into the graph neural network to determine the intermediate node representation.

[0134] In some embodiments, the graph data is sampled to obtain at least two batches of sampled data; the target sampled data is determined from the at least two batches of sampled data; the target sampled data is input into the graph neural network, and feature extraction is performed according to the association relationship between nodes, and the intermediate node representation is output. That is, the graph data is divided into multiple batches (Batch), and in each round of iterative training, a batch of sampled data is selected from the multiple batches and input into the graph neural network.

[0135] Optionally, when sampling the graph data to obtain multiple batches of sampled data, a node sampling method can be used. Schematically, the graph data includes n nodes and m edges, where n≥2 and n is an integer, and m is a positive integer. s candidate nodes are uniformly sampled from the n nodes, where s < n and s is a positive integer. All the edges including the candidate nodes are extracted from the m edges as candidate edges, and the sampled data is generated based on the s candidate nodes and the candidate edges.

[0136] Optionally, when sampling the graph data to obtain multiple batches of sampled data, an edge sampling method can also be used. Schematically, s candidate edges are uniformly sampled from the m edges, where s < m and s is a positive integer. All the nodes including the candidate edges are extracted from the n nodes as candidate nodes, and the sampled data is generated based on the s candidate edges and the candidate nodes.

[0137] Schematically, in the i-th round of iterative training, the above-mentioned sampled data is input into the graph neural network, and the graph neural network will perform feature extraction on the input sampled data with the network parameters updated in the previous round of iterative training, so as to output the intermediate node representations corresponding to the multiple nodes in the sampled data.

[0138] In the embodiments of the present application, when the graph neural network is implemented as a frequency-domain graph neural network, the target node representation H s (i+1) As shown in Equation (9), where K represents the order of the polynomial, is the second type of parameter corresponding to the graph neural network during the i-th round of iterative training, W1 (i) and W2 (i) are the first type of parameters corresponding to the graph neural network during the i-th round of iterative training, P k (L s ) represents the k-th order expression of the selected polynomial, and H s (i) is the target node representation output by the graph neural network during the (i - 1)-th round of iterative training.

[0139] Formula Nine:

[0140] Step 430: Based on the difference between the intermediate node representation and the node label, determine the first parameter adjustment gradient of the first type of parameter and the second parameter adjustment gradient of the second type of parameter.

[0141] Schematically, determine the difference between the intermediate node representation and the node label through a loss function. In the embodiments of the present application, the cross-entropy loss function is used to determine the difference between the intermediate node representation and the node label, that is, determine where H s (i+1) is the target node representation output by the graph neural network during the i-th round of iterative training, and Y s represents the node label corresponding to the node.

[0142] According to the above Take the derivatives of the first type of parameter and the second type of parameter to obtain the first parameter adjustment gradient ΔW1 (i) and ΔW2 (i) , and the second parameter adjustment gradient corresponding to the second type of parameter

[0143] Step 440: Iteratively update the first type of parameter based on the first parameter adjustment gradient.

[0144] Schematically, according to the first parameter adjustment gradients ΔW1 (i) and ΔW2 (i) iteratively update the first type of parameter, that is, W1 (i+1) ←W1 (i) +ηΔW1 (i) , W2 (i+1) ←W2 (i) +ηΔW2 (i) , where η is a preset learning rate.

[0145] Step 451: In response to i being an integer multiple of g, iteratively update the second type of parameter based on the second parameter adjustment gradient and the gradient set.

[0146] In the embodiments of the present application, the second type of parameter corresponds to a training round interval g. When i is divisible by g, then in this round of iterative training, the second type of parameter is iteratively updated. Schematically, when iteratively updating the second type of parameter, by using the second parameter adjustment gradient obtained in step 330 and the recorded in the gradient set together to iteratively update the second type of parameter. In one example, where η is a preset learning rate.

[0147] Step 452: Initialize the gradient set.

[0148] In the i-th round of iterative training, if the second type of parameter is iteratively updated, then initialize the gradient set for recording the adjustment gradient of the second parameter during the subsequent process where the second type of parameter is not iteratively updated.

[0149] Step 453: In response to i not being an integer multiple of g, record the adjustment gradient of the second parameter in the gradient set.

[0150] When the current iterative training round does not satisfy the training round interval g, that is, i cannot be divided evenly by g, record the obtained adjustment gradient of the second parameter in the gradient set, that is, let

[0151] Step 460: In response to the iterative training round of the graph neural network reaching the target number of iterations, generate the target graph neural network.

[0152] Schematically, when the graph neural network is implemented as a frequency-domain graph neural network, a schematic description of the training process of the specific training task of this frequency-domain graph neural network is as follows:

[0153] The input of this training task includes: graph data where represents the node set, ε = {e i}}, |ε| = M represents the edge set, initialize the node representation X, the node label Y s ; the polynomial order K of the frequency-domain graph neural network; the activation function σ; the size s of the batch; the sampling method m ∈ {node, edge} (sampling by edges or nodes) for each batch; the training round interval g for updating the filter parameters; the maximum number of training iterations E; the cross-entropy loss function the learning rate η.

[0154] The output of this training task includes: the identification vector H of each node and the network parameters of the frequency-domain graph neural network

[0155] The training process is as follows:

[0156] (1) Initialize the parameters W1 (0) , W2 (0) , and the gradient set of the filter parameters

[0157] (2) Initialize the representation H of the nodes (0) ←X;

[0158] (3) Initialize the partition of the dataset:

[0159] a) If the sampling method m for each batch is m = node, repeat the following process until D contains all nodes

[0160] i. Uniformly sample s nodes from and then extract all the edges that include the nodes in from ε

[0161] ii. Construct Add to D:

[0162] b) If the sampling method m for each batch is m = edge, repeat the following process until D contains all edges ε:

[0163] i. Uniformly sample s edges ε from ε s , and then extract all the nodes that appear in ε from s

[0164] ii. Construct Add to D:

[0165] (4) If the requirement for stopping training is not met, such as reaching the maximum number of training iterations E, repeat the following iterations i = 0, 1,..., E:

[0166] a) Sample a in D from the uniform distribution, and accordingly there is a Laplacian matrix L s ;

[0167] b) Obtain the model parameters of the previous iteration and the corresponding node representations W1 (i) , W2 (i) , H s (i) , and calculate the node representations for this time:

[0168] c) Calculate the loss function for the training set samples in each batch Take the derivative of the parameters to obtain the gradients ΔW1 (i) , ΔW2 (i) ,

[0169] d) Update the parameters of feature dimensionality reduction: W1 (i+1) ← W1(i) +ηΔW1 (i) ,W2 (i+1) ←W2 (i) +ηΔW2 (i) ;

[0170] e) If i divides g: Update the parameters of the filter: Otherwise, superimpose the gradients of the filter:

[0171] f) i = i + 1;

[0172] (5) Output the obtained parameters and the final node representation:

[0173] Schematically, when the number of iterative training rounds of the graph neural network reaches a preset target number of iterations, it is determined that the training of the graph neural network is completed, and a target graph neural network is obtained. The above-mentioned target graph neural network is used to extract target node representations for multiple nodes in the graph data, and the target node representations are used to predict the node association relationships between at least two nodes among the multiple nodes. That is, by using the trained target graph neural network to extract node features from the graph data, the target node representations corresponding to the nodes can be obtained, and the target node representations can be applied to downstream tasks.

[0174] In summary, in the training method of the graph neural network provided by the embodiments of the present application, during the training process of the graph neural network, the graph data is input into the graph neural network, and the intermediate node representations corresponding to the nodes in the graph data are predicted. According to the difference between the intermediate node representations and the node labels corresponding to the nodes, the first parameter adjustment gradient corresponding to the first type of parameters and the second parameter adjustment gradient corresponding to the second type of parameters of the graph neural network are determined, and the first type of parameters are iteratively updated according to the first parameter adjustment gradient in each iterative training round, and the second type of parameters are iteratively updated according to the second parameter adjustment gradient in the iterative training rounds that meet the round requirements, so as to realize the training of the graph neural network and obtain a target graph neural network. After inputting the graph data into the target graph neural network, the target node representations corresponding to each node in the graph data can be obtained, and the target node representations can be used to calculate the association relationships between the nodes in the graph data in downstream tasks. That is, this method controls the network parameters to converge better during the iterative training process by adjusting the training rounds of different parameters in the graph neural network and adopting the method of updating parameters separately, thereby improving the training efficiency of the model.

[0175] In the embodiments of the present application, during the training process of the frequency-domain graph neural network, the first type of parameters and the second type of parameters are updated separately, and the sum of the gradient results of multiple batches is used to provide a more stable update estimate for the parameters of the filter, thereby helping the convergence of the parameters of the filter.

[0176] Schematically, the above method was applied to two large-scale publicly available datasets for experiments, and the experimental results are as follows:

[0177] The above two large-scale publicly available datasets include: Ogbn-product, a co-purchase network of commodities, where each node represents a commodity, and the connected commodities represent co-purchases. The category of the commodity is predicted, with 90% used for training and 10% for testing; Ogbn-arxiv, where the papers in the data science category of the arxiv dataset represent nodes and the citation relationship represents edges, and the sub-category to which the paper belongs is predicted.

[0178] Among them, the number of nodes, edges, and categories of the above two large-scale publicly available datasets is shown in Table 1.

[0179] Table 1

[0180] Number of nodes Number of edges Number of categories Ogbn-product 2,449,029 61,859,140 47 Ogbn-arxiv 169,343 1,166,243 40

[0181] During the training process, the maximum number of training iterations was set to 1000, and the training was stopped when the loss function value of 50 validation sets no longer decreased. The size of the Batch was set to 8000, and sampling was performed using the edges. For all experimental results, accuracy was selected as the metric, and the calculation formula for accuracy is shown in Formula 10, where #correct represents the number of correct predictions and #test represents the total number of predictions.

[0182] Formula 10:

[0183] The experimental results are shown in Table 2. Among them, ChebNet is a frequency-domain graph neural network that applies Chebyshev polynomials, and GPRGNN is an Adaptive Universal Generalized PageRank Graph Neural Network, which is also a frequency-domain graph neural network; ChebNet+ and GPRGNN+ are respectively the frequency-domain graph neural networks obtained by applying the above frequency-domain graph neural networks to the training method provided by the implementation of this application. It can be seen from the accuracy indicated in Table 2 that the training method provided by the implementation of the application can improve the prediction accuracy of the frequency-domain graph neural network.

[0184] Table 2

[0185]

[0186]

[0187] Please refer to Figure 5, which shows the object recommendation method provided by an exemplary embodiment of the present application. In the embodiment of the present application, after training the target graph neural network in the above embodiment, the application of the target node representation obtained through the target graph neural network in the item recommendation scenario and the account recommendation scenario is schematically described. The method includes:

[0188] Step 510, input the graph data into the target graph neural network, and output the account node representation corresponding to the account node and the item node representation corresponding to the item node.

[0189] In the embodiment of the present application, the graph data includes account nodes and item nodes, and the account nodes are connected by edges according to the account social relationship. Optionally, when there is a friendship relationship between two accounts, the account nodes corresponding to the two accounts are connected by an edge; when there is an interaction relationship between two accounts, the account nodes corresponding to the two accounts are connected by an edge. For example, in a game application, if two player accounts have participated in a virtual game in the same game session, the account nodes of the two player accounts are connected by an edge.

[0190] The item nodes are connected by edges according to the item type relationship of the items. In one example, when two items belong to the same item type, the item nodes corresponding to the two items are connected by an edge.

[0191] The account nodes and the item nodes are connected by edges according to the interaction relationship of the account with the item. Optionally, when the account has purchased / collected / shared / liked an item during the historical period, the account node and the item node are connected by an edge.

[0192] Schematically, after iteratively training the graph neural network with the graph data, the above target graph neural network is obtained. In some embodiments, after the target graph neural network is trained, the graph data is input into the above target graph neural network again, and the account node representation corresponding to the account node in the graph data and the item node representation corresponding to the item node are output.

[0193] In one example, taking the player accounts and virtual items in the game scenario as an example, such as Figure 6As shown, it shows a schematic diagram of the node representation acquisition process provided by an exemplary embodiment of the present application. Prop purchase and usage data are obtained from the first database 610, and player social and game relationship data are obtained from the second database 620. According to the above-mentioned prop purchase and usage data and player social and game relationship data, the player account node 630 and the virtual prop node 640 are connected to obtain graph data 650. The graph data 650 is input into the graph neural network 660 for iterative training. After obtaining the trained graph neural network 660, the above-mentioned graph data 650 is input into the trained graph neural network 660 again, and the player account node representation 670 and the virtual prop node representation 680 are output.

[0194] Step 520, in response to receiving an item recommendation request for a target account, obtain the target account node representation corresponding to the target account from the account node representations.

[0195] Schematically, the account nodes in the above graph data include the nodes corresponding to the target account.

[0196] Optionally, the above item recommendation request can be sent by the terminal corresponding to the target account, or can be automatically triggered by the server according to a specified recommendation frequency.

[0197] In some embodiments, after the server trains the target graph neural network, it obtains the account node representation and the item node representation in the graph data according to the target graph neural network, and pre-stores the above account node representation and item node representation in the database, so as to directly obtain the corresponding node representations in the downstream recommendation tasks.

[0198] Optionally, the above account node representation and item node representation can be stored in different databases. In one example, the account node representation is stored in the account database corresponding to the account identifier, and the item node representation is stored in the item database corresponding to the item identifier.

[0199] Schematically, when receiving an item recommendation request for a target account, obtain the target account node representation from the account database according to the account identifier of the target account.

[0200] Step 530, obtain the candidate item node representations corresponding to multiple candidate items from the item node representations.

[0201] Optionally, the multiple candidate items described above can be filtered from an item list. In some embodiments, when filtering the items in the item list to obtain candidate items, the items in the item list can be pre-filtered first according to the interaction relationship between the target account and the items during the historical period. In one example, the items that have interacted with the target account in the item list are screened out, and the above candidate items are determined from the remaining items.

[0202] Optionally, when obtaining candidate items through filtering, they can be obtained through random filtering; or, the items in the item list are sorted according to the popularity of the items on the recommendation platform, and the top N items with the highest popularity are selected as the above candidate items.

[0203] In some embodiments, after determining the multiple candidate items, according to the item identifiers corresponding to the candidate items, the candidate item node representations corresponding to the candidate items are obtained from the item database.

[0204] In other embodiments, the above multiple candidate items can also be global items, that is, all items included in the graph data.

[0205] Step 540, calculate the first association degree score between the target account and each candidate item based on the target account node representation and the candidate item node representation.

[0206] In some embodiments, the feature distance between the target account node representation and each candidate item node representation is calculated to obtain the feature similarity between the target account node representation and each candidate item node representation, and the above feature similarity is used as the first association degree score between the target account and the candidate item.

[0207] Optionally, the above feature distance can be at least one of Euclidean distance, Mahalanobis distance, Manhattan distance, cosine distance, etc., which is not limited herein.

[0208] In other embodiments, when determining the first association degree score between the target account and each candidate item, it can also be achieved by calculating the vector inner product and Softmax normalization as shown in Formula Eleven, where u i represents the account node, i j represents the item node, h i represents the account node representation, and h j represents the item node representation.

[0209] Formula Eleven:

[0210] Step 550, determine the recommended items from the multiple candidate items based on the first association degree score, and recommend the recommended items to the target account.

[0211] In some embodiments, multiple candidate items are sorted according to the first correlation score between the target account and the candidate items to obtain a candidate item queue, and the top N candidate items with the highest first correlation score are obtained from the candidate item queue as the recommended items recommended to the target account, where N is a positive integer.

[0212] In other embodiments, when the multiple candidate items are global items, after obtaining the candidate item queue, the items that already have an interaction relationship with the target account in the candidate item queue are excluded to obtain a filtered candidate item queue, and the recommended items are determined by filtering the filtered candidate item queue.

[0213] In other embodiments, a recommended score threshold is obtained, and in response to the first correlation score corresponding to the candidate item reaching the recommended score threshold, the candidate item is recommended to the target account.

[0214] In one example, as Figure 7 shown, it shows a schematic diagram of an item recommendation task provided by an exemplary embodiment of the present application. In the node representation 710, there are an account node representation 720 and an item node representation 730. In the account node representation 720, there is a target account node representation 721 corresponding to the target account. By calculating the first correlation score between the target account node representation 721 and the candidate item node representations 731 corresponding to multiple candidate items, and sorting the multiple candidate items according to the first correlation score, a candidate item queue 740 is obtained, and the top two candidate items with the highest first correlation score in the candidate item queue 740 are selected as the recommended items 741 recommended to the target account.

[0215] Schematically, taking the recommendation of game props in a game application as an example, as Figure 8 shown, it shows a schematic diagram of game prop recommendation provided by an exemplary embodiment of the present application. In the game prop sales interface 800, there is a recommended area 810. In the recommended area 810, the target game props filtered by the server according to the correlation score between the account node representation of the currently logged-in account and the candidate game prop node representation are displayed. Among them, the recommended area 810 is preferentially displayed over the ordinary area 820, and the above-mentioned ordinary area 820 is used to display game props according to the default sorting. Optionally, the game props in the ordinary area 820 and the game props in the recommended area 810 together form global game props.

[0216] Step 560, in response to receiving an account recommendation request for the target account, obtain the target account node representation corresponding to the target account from the account node representation.

[0217] Schematically, when a request for account recommendation for a target account is received, a target account node representation is obtained from an account database according to the account identifier of the target account.

[0218] Step 570: Obtain candidate account node representations corresponding to multiple candidate accounts respectively from the account node representation.

[0219] Among them, the above-mentioned multiple candidate accounts are candidate accounts that do not include the target account.

[0220] Optionally, the above-mentioned multiple candidate accounts can be screened from an account list. In some embodiments, when screening the accounts in the account list to obtain multiple candidate accounts, pre-screening can be performed first according to the accounts having a social relationship with the target account. In one example, the accounts that already have a friendship relationship with the target account in the account list are screened out, and the above-mentioned candidate accounts are determined from the remaining accounts.

[0221] In some embodiments, after determining multiple candidate accounts, candidate account node representations corresponding to the candidate accounts are obtained from the account database according to the account identifiers corresponding to the candidate accounts.

[0222] Step 580: Calculate second correlation degree scores corresponding to the target account and the multiple candidate accounts respectively based on the target account node representation and the candidate account node representations.

[0223] In some embodiments, the feature distance between the target account node representation and each candidate account node representation is calculated to obtain the feature similarity between the target account node representation and each candidate account node representation, and the above-mentioned feature similarity is used as the second correlation degree score between the target account and the candidate account.

[0224] Optionally, the above-mentioned feature distance can be at least one of Euclidean distance, Mahalanobis distance, Manhattan distance, cosine distance, etc., which is not limited herein.

[0225] In some other embodiments, when determining the first correlation degree score between the target account and each candidate item, it can also be achieved by calculating the vector inner product and Softmax normalization, which is not limited herein.

[0226] Step 590: Determine recommended accounts for recommending accounts to the target account from the multiple candidate accounts based on the second correlation degree scores.

[0227] In some embodiments, the multiple candidate accounts are sorted according to the second correlation degree scores between the target account and the candidate accounts to obtain a candidate account queue, and the N candidate accounts with the highest second correlation degree scores are obtained from the candidate account queue as the recommended accounts for recommending to the target account, where N is a positive integer.

[0228] In one example, as Figure 9 shown, it shows a schematic diagram of a friend recommendation task provided by an exemplary embodiment of the present application. In the node representation 910, there is an account node representation. In the account node representation, there is a target account node representation 921 corresponding to the target account. By calculating the association degree score between the target account node representation 921 and other account node representations 922 corresponding to other accounts, and sorting the other accounts according to the association degree score, an account queue 930 is obtained, and the top two other accounts with the highest association degree score in the account queue 930 are selected as the recommended accounts 931 recommended to the target account.

[0229] Schematically, taking the friend recommendation in a game application as an example, as Figure 10 shown, it shows a schematic diagram of friend recommendation provided by an exemplary embodiment of the present application. In the social interface 1000, a friend list 1010 and a recommendation list 1020 are displayed. In the recommendation list 1020, a target account 1021 filtered by the server according to the association degree score between the account node representation of the currently logged-in account and other account node representations is displayed. The player can select the recommended target account 1021 in the recommendation list 1020 to add a friend.

[0230] In summary, for the item recommendation method provided by the embodiments of the present application, based on the trained target graph neural network, the target graph neural network is used to obtain the node representations corresponding to each node in the graph data, so as to determine the association degree between nodes according to the feature relationship between the node representations, thereby serving the downstream item recommendation scenario and improving the item recommendation effect.

[0231] It should be noted that the information (including but not limited to user device information, user personal information, etc.), data (including but not limited to data for analysis, stored data, displayed data, etc.) and signals involved in the present application are all authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data need to comply with the relevant laws, regulations and standards of relevant countries and regions. For example, the data such as the account social relationship and the interaction relationship between the account and the item involved in the present application are obtained under full authorization.

[0232] Please refer to Figure 11 , which shows a structural block diagram of an object recommendation device provided by an exemplary embodiment of the present application. The device includes the following modules:

[0233] An acquisition module 1110, configured to acquire graph data corresponding to multiple candidate objects, where the graph data includes nodes corresponding to the multiple candidate objects respectively, and the nodes in the graph data are connected by edges according to the association relationship between the multiple candidate objects;

[0234] A prediction module 1120, configured to input the graph data into a target graph neural network, extract features of the association relationships between the nodes in the graph data, and obtain object node representations corresponding to the multiple candidate objects respectively, where the multiple candidate objects include a first object;

[0235] A recommendation module 1130, configured to, in response to receiving an object recommendation request for the first object, determine a target object recommended to the account corresponding to the first object from the second objects based on the association degree score between the first object node representation corresponding to the first object and the second object node representation, where the second objects are at least one candidate object other than the first object among the multiple candidate objects, and the second object node representation corresponds to the second object;

[0236] Wherein, the target graph neural network is obtained by iteratively training a graph neural network, the network parameters of the graph neural network include a first type of parameter and a second type of parameter, in the iterative training process of the graph neural network, the first type of parameter is iteratively updated in each round of iterative training, the second type of parameter is iteratively updated in the iterative training rounds that meet the round requirements, and when the iterative training rounds reach the target number of iterative times corresponding to the graph neural network, the target neural network is obtained.

[0237] In some alternative embodiments, as Figure 12 shown, the apparatus further includes:

[0238] A training module 1140, including:

[0239] An acquisition unit 1141, configured to acquire the graph data, and each of the multiple nodes in the graph data corresponds to a node label;

[0240] A training unit 1142, configured to, in the i-th round of iterative training, extract features of the nodes through the graph neural network according to the association relationships between the nodes, and output intermediate node representations corresponding to the multiple nodes respectively;

[0241] The training unit 1142 is further configured to determine a first parameter adjustment gradient of the first type of parameter and a second parameter adjustment gradient of the second type of parameter based on the difference between the intermediate node representation and the node label;

[0242] The training unit 1142 is further configured to iteratively update the first type of parameter based on the first parameter adjustment gradient, and in response to the i-th round of iterative training meeting the round requirements, iteratively update the second type of parameter based on the second parameter adjustment gradient;

[0243] The training unit 1142 is further configured to generate the target graph neural network in response to the number of iterative training rounds of the graph neural network reaching the target number of iterations.

[0244] In some alternative embodiments, the second type of parameter corresponds to a training round interval g;

[0245] The training unit 1142 is further configured to, in response to i being an integer multiple of g, iteratively update the second type of parameter based on the gradient adjusted by the second parameter.

[0246] In some alternative embodiments, the training unit 1142 is further configured to iteratively update the second type of parameter based on the gradient adjusted by the second parameter and a gradient set, where the gradient set is used to store the gradient adjusted by the second parameter in the iterative training rounds when the second type of parameter is not updated; initialize the gradient set;

[0247] The training unit 1142 is further configured to, in response to i not being an integer multiple of g, record the gradient adjusted by the second parameter in the gradient set.

[0248] In some alternative embodiments, the apparatus further includes:

[0249] A determination module 1150, configured to determine the data volume of the graph data based on the number of nodes and the number of edges in the graph data;

[0250] The determination module 1150 is further configured to determine the training round interval g based on the data volume of the graph data and a preset conversion rule, where the preset conversion rule indicates a positive correlation between the training round interval g and the data volume of the graph data.

[0251] In some alternative embodiments, the first type of parameter is used to reduce the dimension of the features corresponding to the nodes in the graph data; the second type of parameter is used to factorize the graph structure corresponding to the graph data.

[0252] In some alternative embodiments, the apparatus further includes:

[0253] A sampling module 1160, configured to sample the graph data to obtain at least two batches of sampled data;

[0254] The determination module 1150 is further configured to determine target sampled data from the at least two batches of sampled data;

[0255] The training unit 1142 is further configured to input the target sampled data into the graph neural network, perform feature extraction according to the association relationship between the nodes, and output the intermediate node representation.

[0256] In some alternative embodiments, the graph data includes n nodes and m edges, where n ≥ 2 and n is an integer, and m is a positive integer;

[0257] The sampling module 1160 is further configured to uniformly sample s candidate nodes from the n nodes, where s < n and s is a positive integer; extract all the edges including the candidate nodes from the m edges as candidate edges; and generate the sampling data based on the s candidate nodes and the candidate edges.

[0258] In some alternative embodiments, the graph data includes n nodes and m edges, where n ≥ 2 and n is an integer, and m is a positive integer;

[0259] The sampling module 1160 is further configured to uniformly sample s candidate edges from the m edges, where s < m and s is a positive integer; extract all the nodes including the candidate edges from the n nodes as candidate nodes; and generate the sampling data based on the s candidate edges and the candidate nodes.

[0260] In some alternative embodiments, the multiple candidate objects include candidate accounts and candidate items. The graph data includes account nodes and item nodes. The account nodes are connected by edges according to account social relationships. The item nodes are connected by edges according to item type relationships of the items. The account nodes and the item nodes are connected by edges according to interaction relationships between accounts and items. The account nodes include the node corresponding to the target account;

[0261] The prediction module 1120 is further configured to input the graph data into the target graph neural network, and output the account node representation corresponding to the account node and the item node representation corresponding to the item node;

[0262] The recommendation module 1130 is further configured to, in response to receiving an item recommendation request for a target account, obtain the target account node representation corresponding to the target account from the account node representations; obtain the candidate item node representations corresponding to multiple candidate items from the item node representations; calculate the first association degree scores between the target account and each candidate item based on the target account node representation and the candidate item node representations; and determine the recommended items for item recommendation to the target account from the multiple candidate items based on the first association degree scores.

[0263] The recommendation module 1130 is further configured to, in response to receiving an account recommendation request for the target account, obtain the target account node representation corresponding to the target account from the account node representation; obtain the candidate account node representations corresponding to multiple candidate accounts respectively from the account node representation, where the multiple candidate accounts are candidate accounts excluding the target account; calculate the second correlation degree scores corresponding to the target account and the multiple candidate accounts respectively based on the target account node representation and the candidate account node representations; and determine a recommended account for recommending to the target account from the multiple candidate accounts based on the second correlation degree scores.

[0264] In summary, in the process of object recommendation by the object recommendation device provided in the embodiment of the present application, the object node representations corresponding to each candidate object are obtained by the target graph neural network trained by the graph data corresponding to multiple candidate objects, and object recommendation is implemented through the correlation degree scores between the object node representations. Among them, the above target graph neural network is obtained by iterative training of a graph neural network. The above graph neural network includes a first type of parameter and a second type of parameter. In the iterative training process, the first type of parameter is iteratively updated in each round of iterative training, while the second type of parameter is iteratively updated in the iterative training rounds that meet the round requirements. That is, this method controls the network parameters to better converge in the iterative training process by adjusting the training rounds of different parameters in the graph neural network and adopting the method of separately updating the parameters, thereby improving the training efficiency of the model and further ensuring the recommendation accuracy in downstream object recommendation.

[0265] It should be noted that: for the object recommendation device provided in the above embodiment, only the above division of each functional module is used for illustration. In actual application, the above functions can be allocated to different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the object recommendation device provided in the above embodiment and the object recommendation method embodiment belong to the same concept, and the specific implementation process is detailed in the method embodiment, which will not be repeated here.

[0266] Figure 13 The structural schematic diagram of a server provided by an exemplary embodiment of the present application is shown. Specifically, it includes the following structure.

[0267] The server 1300 includes a Central Processing Unit (CPU) 1301, a system memory 1304 including a Random Access Memory (RAM) 1302 and a Read Only Memory (ROM) 1303, and a system bus 1305 connecting the system memory 1304 and the central processing unit 1301. The server 1300 also includes a mass storage device 1306 for storing an operating system 1313, application programs 1314, and other program modules 1315.

[0268] The mass storage device 1306 is connected to the central processing unit 1301 through a mass storage controller (not shown) connected to the system bus 1305. The mass storage device 1306 and its associated computer-readable medium provide non-volatile storage for the server 1300. That is, the mass storage device 1306 may include a computer-readable medium (not shown) such as a hard disk or a Compact Disc Read Only Memory (CD-ROM) drive.

[0269] Without loss of generality, computer-readable media can include computer storage media and communication media. Computer storage media includes volatile and non-volatile, removable and non-removable media implemented by any method or technology for storing information such as computer-readable instructions, data structures, program modules, or other data. Computer storage media includes RAM, ROM, Erasable Programmable Read Only Memory (EPROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other solid-state memory technologies, CD-ROM, Digital Versatile Disc (DVD) or other optical storage, magnetic tape cartridges, tapes, disk storage or other magnetic storage devices. Of course, those skilled in the art will know that computer storage media is not limited to the above several. The above-mentioned system memory 1304 and mass storage device 1306 can be collectively referred to as memory.

[0270] According to various embodiments of the present application, the server 1300 may also run on a remote computer on the network through a network such as the Internet. That is, the server 1300 may be connected to the network 1312 through the network interface unit 1311 connected to the system bus 1305, or in other words, the network interface unit 1311 may also be used to connect to other types of networks or remote computer systems (not shown).

[0271] The above-mentioned memory further includes one or more programs, and the one or more programs are stored in the memory and configured to be executed by the CPU.

[0272] Embodiments of the present application further provide a computer device, which includes a processor and a memory. At least one instruction, at least one program, a code set or an instruction set is stored in the memory, and the at least one instruction, at least one program, the code set or the instruction set is loaded and executed by the processor to implement the object recommendation method provided by the above-mentioned method embodiments. Optionally, the computer device may be a terminal or a server.

[0273] Embodiments of the present application further provide a computer-readable storage medium, on which at least one instruction, at least one program, a code set or an instruction set is stored, and the at least one instruction, at least one program, the code set or the instruction set is loaded and executed by the processor to implement the object recommendation method provided by the above-mentioned method embodiments.

[0274] Embodiments of the present application further provide a computer program product or a computer program, which includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the object recommendation method described in any one of the above embodiments.

[0275] Optionally, the computer-readable storage medium may include: read-only memory (ROM, Read Only Memory), random access memory (RAM, Random Access Memory), solid state drive (SSD, Solid State Drives), or optical disc, etc. Among them, the random access memory may include resistive random access memory (ReRAM, Resistance RandomAccess Memory) and dynamic random access memory (DRAM, Dynamic Random Access Memory). The serial numbers of the above embodiments of the present application are only for description and do not represent the advantages and disadvantages of the embodiments.

[0276] Those of ordinary skill in the art can understand that all or part of the steps to implement the above embodiments can be completed by hardware, or can be completed by instructing relevant hardware through a program. The program can be stored in a computer-readable storage medium, and the above-mentioned storage medium can be a read-only memory, a disk, an optical disc, etc.

[0277] The above are only alternative embodiments of the present application and are not intended to limit the present application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principle of the present application shall be included within the protection scope of the present application.

Claims

1. An object recommendation method, characterized in that, The method includes: Obtaining graph data corresponding to multiple candidate objects, where the graph data includes nodes corresponding to the multiple candidate objects respectively, and the nodes in the graph data are connected by edges according to the association relationships between the multiple candidate objects; Inputting the graph data into a target graph neural network, extracting features of the association relationships between the nodes in the graph data, and obtaining object node representations corresponding to the multiple candidate objects respectively, where the multiple candidate objects include a first object; In response to receiving an object recommendation request for the first object, determining, based on the association degree score between the first object node representation corresponding to the first object and the second object node representation, a target object to be recommended to the account corresponding to the first object from the second objects, where the second objects are at least one candidate object other than the first object among the multiple candidate objects, and the second object node representation corresponds to the second object; Wherein, the target graph neural network is obtained by iteratively training a graph neural network, and the network parameters of the graph neural network include a first type of parameter and a second type of parameter. The first type of parameter is used to reduce the dimension of the features corresponding to the nodes in the graph data, and the second type of parameter is used to factorize the graph structure corresponding to the graph data. The training process of the graph neural network includes: Obtaining the graph data, where multiple nodes in the graph data respectively correspond to node labels; In the i-th round of iterative training, extracting features of the nodes through the graph neural network according to the association relationships between the nodes, and outputting intermediate node representations corresponding to the multiple nodes respectively; Based on the difference between the intermediate node representation and the node label, determining a first parameter adjustment gradient of the first type of parameter and a second parameter adjustment gradient of the second type of parameter; Iteratively updating the first type of parameter based on the first parameter adjustment gradient, and in response to the i-th round of iterative training meeting the round requirement, iteratively updating the second type of parameter based on the second parameter adjustment gradient; In response to the iterative training round of the graph neural network reaching the target iteration number, generating the target graph neural network.

2. The method according to claim 1, characterized in that The second type of parameter corresponds to a training round interval g; The step of, in response to the i-th round of iterative training meeting the round requirement, iteratively updating the second type of parameter based on the second parameter adjustment gradient includes: In response to i being an integer multiple of g, iteratively updating the second type of parameter based on the second parameter adjustment gradient.

3. The method according to claim 2, characterized in that, The step of iteratively updating the second type of parameter based on the second parameter adjustment gradient includes: Iteratively updating the second type of parameter based on the second parameter adjustment gradient and a gradient set, where the gradient set is used to store the second parameter adjustment gradient in the iterative training rounds when the second type of parameter is not updated; initializing the gradient set; The training process of the graph neural network further includes: In response to i not being an integer multiple of g, recording the second parameter adjustment gradient in the gradient set.

4. The method according to claim 2 or 3, characterized in that, The training process of the graph neural network further includes: Determining the data volume of the graph data based on the number of nodes and the number of edges in the graph data; Determining the training round interval g based on the data volume of the graph data and a preset conversion rule, where the preset conversion rule indicates a positive correlation between the training round interval g and the data volume of the graph data.

5. The method according to any one of claims 1 to 3, characterized in that Before iteratively training the graph neural network, the method further includes: Sampling the graph data to obtain at least two batches of sampled data; The feature extraction of the nodes by the graph neural network according to the association relationship between the nodes and outputting the intermediate node representations corresponding to the multiple nodes respectively includes: Determining target sampled data from the at least two batches of sampled data; Inputting the target sampled data into the graph neural network, performing feature extraction according to the association relationship between the nodes, and outputting the intermediate node representation.

6. The method according to claim 5, characterized in that, The graph data includes n nodes and m edges, where n≥2 and n is an integer, and m is a positive integer; The sampling of the graph data to obtain at least two batches of sampled data includes: Uniformly sampling s candidate nodes from the n nodes, where s<n and s is a positive integer; Extracting all the edges including the candidate nodes from the m edges as candidate edges; Generating the sampled data based on the s candidate nodes and the candidate edges.

7. The method according to claim 5, wherein The graph data includes n nodes and m edges, where n≥2 and n is an integer, and m is a positive integer; The sampling of the graph data to obtain at least two batches of sampled data includes: Uniformly sampling s candidate edges from the m edges, where s<m and s is a positive integer; Extracting all the nodes including the candidate edges from the n nodes as candidate nodes; Generating the sampled data based on the s candidate edges and the candidate nodes.

8. The method according to any one of claims 1 to 3, characterized in that, The multiple candidate objects include candidate accounts and candidate items. The graph data includes account nodes and item nodes. The account nodes are connected by edges according to the account social relationship, the item nodes are connected by edges according to the item type relationship of the items, the account nodes and the item nodes are connected by edges according to the interaction relationship between the account and the item, and the account nodes include the nodes corresponding to the target account; Inputting the graph data into the target graph neural network, performing feature extraction on the association relationship between the nodes in the graph data, and obtaining the object node representations corresponding to the multiple candidate objects respectively includes: Inputting the graph data into the target graph neural network and outputting the account node representations corresponding to the account nodes and the item node representations corresponding to the item nodes; In response to receiving an object recommendation request for the first object, determining a target object to be recommended to the account corresponding to the first object from the second objects based on the association degree score between the first object node representation corresponding to the first object and the second object node representation. In response to receiving an item recommendation request for a target account, obtain a target account node representation corresponding to the target account from the account node representation; Obtain candidate item node representations corresponding to multiple candidate items respectively from the item node representation; Calculate a first correlation score between the target account and each candidate item based on the target account node representation and the candidate item node representations; Determine a recommended item for item recommendation to the target account from the multiple candidate items based on the first correlation score; In response to receiving an account recommendation request for the target account, obtain a target account node representation corresponding to the target account from the account node representation; Obtain candidate account node representations corresponding to multiple candidate accounts respectively from the account node representation, where the multiple candidate accounts do not include the target account; Calculate second correlation scores corresponding between the target account and the multiple candidate accounts respectively based on the target account node representation and the candidate account node representations; Determine a recommended account for account recommendation to the target account from the multiple candidate accounts based on the second correlation scores; 9. An object recommendation device, characterized in that, The apparatus includes: An acquisition module, configured to acquire graph data corresponding to multiple candidate objects, where the graph data includes nodes corresponding to the multiple candidate objects respectively, and the nodes in the graph data are connected by edges according to the association relationships between the multiple candidate objects; A prediction module, configured to input the graph data into a target graph neural network, extract features from the association relationships between the nodes in the graph data, and obtain object node representations corresponding to the multiple candidate objects respectively, where the multiple candidate objects include a first object; A recommendation module, configured to, in response to receiving an object recommendation request for the first object, determine a target object for recommendation to the account corresponding to the first object from the second objects based on the correlation score between the first object node representation corresponding to the first object and the second object node representations, where the second objects are at least one candidate object other than the first object among the multiple candidate objects, and the second object node representations correspond to the second objects; Wherein, the target graph neural network is obtained by iteratively training a graph neural network, and the network parameters of the graph neural network include a first type of parameter and a second type of parameter, the first type of parameter is used to reduce the dimension of the features corresponding to the nodes in the graph data, and the second type of parameter is used to factorize the graph structure corresponding to the graph data; The apparatus further includes a training module, and the training module includes: An acquisition unit, configured to acquire the graph data, where multiple nodes in the graph data respectively correspond to node labels; A training unit, configured to, in the i-th round of iterative training, extract features from the nodes through the graph neural network according to the association relationships between the nodes, and output intermediate node representations corresponding to the multiple nodes respectively; The training unit is further configured to determine a first parameter adjustment gradient of the first type of parameters and a second parameter adjustment gradient of the second type of parameters based on the difference between the intermediate node representation and the node label; The training unit is further configured to iteratively update the first type of parameters based on the first parameter adjustment gradient, and in response to the i-th round of iterative training meeting the round requirement, iteratively update the second type of parameters based on the second parameter adjustment gradient; The training unit is further configured to generate the target graph neural network in response to the iterative training round of the graph neural network reaching the target number of iterations.

10. A computer device, characterized in that, The computer device includes a processor and a memory, and at least one program is stored in the memory and is loaded and executed by the processor to implement the object recommendation method according to any one of claims 1 to 8.

11. A computer-readable storage medium, characterized in that, At least one program code is stored in the computer-readable storage medium, and the program code is loaded and executed by the processor to implement the object recommendation method according to any one of claims 1 to 8.

12. A computer program product, characterized in that, It includes a computer program or instruction, and when the computer program or instruction is executed by a processor, it implements the object recommendation method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Model parameter updating system, method and device

    CN112085074A

  • Graph neural network training method and device

    CN112085172A