WO2023213157A1 - 数据处理方法、装置、程序产品、计算机设备和介质 - Google Patents

数据处理方法、装置、程序产品、计算机设备和介质 Download PDF

Info

Publication number
WO2023213157A1
WO2023213157A1 PCT/CN2023/084690 CN2023084690W WO2023213157A1 WO 2023213157 A1 WO2023213157 A1 WO 2023213157A1 CN 2023084690 W CN2023084690 W CN 2023084690W WO 2023213157 A1 WO2023213157 A1 WO 2023213157A1
Authority
WO
WIPO (PCT)
Prior art keywords
resource
feature
embedding
graph
prediction
Prior art date
Application number
PCT/CN2023/084690
Other languages
English (en)
French (fr)
Inventor
沈春旭
成昊
薛扣英
Original Assignee
腾讯科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 腾讯科技(深圳)有限公司 filed Critical 腾讯科技(深圳)有限公司
Publication of WO2023213157A1 publication Critical patent/WO2023213157A1/zh
Priority to US18/437,118 priority Critical patent/US20240177006A1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • G06N3/082Learning methods modifying the architecture, e.g. adding, deleting or silencing nodes or connections
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/04Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/22Matching criteria, e.g. proximity measures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/042Knowledge-based neural networks; Logical representations of neural networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods

Definitions

  • the present application relates to the field of computer technology, and in particular, to a data processing method, device, program product, computer equipment and medium.
  • AI Artificial Intelligence
  • the prediction network when predicting the user's conversion index for resources (such as software or advertising, etc.), the prediction network can usually be trained based on the existing user's conversion behavior for the resource, and then the trained prediction network can be used to predict the user's conversion index for the resource.
  • Resource conversion index If there is a user who does not have conversion behavior for the resource, or the resource does not exist and a user has conversion behavior for it, the characteristics of the user and the resource will not be effectively transferred when training the prediction network, which will lead to the trained prediction network. It is also impossible to accurately predict the user's conversion index for resources.
  • This application provides a data processing method, device, program product, computer equipment and medium, which can improve the accuracy of the trained prediction network, so as to use the trained prediction network to accurately predict the object's conversion index for resources.
  • this application provides a data processing method, which is executed by a computer device.
  • the method includes:
  • the transformation heterogeneous graph contains N object nodes and M resource nodes. Each object node represents an object, and each resource node represents a resource. N and M are both positive integers; if N If any object among the objects has transformation behavior for any resource among the M resources, then the object node of any object and the resource node of any resource have connecting edges in the transformation heterogeneous graph;
  • any object homogeneity graph contains multiple object feature nodes, and any object feature node is used to represent the object features of the corresponding object in one dimension;
  • any resource homogeneity graph contains multiple resource feature nodes, and any resource feature node is used to represent the resource characteristics of the corresponding resource in one dimension;
  • the prediction network is trained based on the transformation heterogeneous graph, the object homogeneity graph of each object, and the resource homogeneity graph of each resource to obtain a trained prediction network; the trained prediction network is used to predict the conversion index of the object for the resource.
  • this application provides a data processing device, which includes:
  • the first acquisition module is used to obtain the transformation heterogeneous graph;
  • the transformation heterogeneous graph contains N object nodes and M resource nodes.
  • Each object node represents an object, and each resource node represents a resource.
  • N and M both represent is a positive integer; if any object among N objects has transformation behavior for any resource among M resources, then the object node of any object and the resource node of any resource have connecting edges in the transformation heterogeneous graph;
  • the second acquisition module is used to obtain the object homogeneity graph corresponding to each object among the N objects; any object homogeneity graph contains multiple object feature nodes, and any object feature node is used to represent the corresponding object in one dimension. object characteristics;
  • the third acquisition module is used to obtain the resource homogeneity graph corresponding to each resource in the M resources; any resource homogeneity graph contains multiple resource feature nodes, and any resource feature node is used to represent the corresponding resource in one dimension. resource characteristics;
  • the training module is used to train the prediction network based on the transformation heterogeneous graph, the object homogeneity graph of each object, and the resource homogeneity graph of each resource, to obtain a trained prediction network; the trained prediction network is used to predict the object for the resource conversion index.
  • One aspect of this application provides a computer device, including a memory and a processor.
  • the memory stores a computer program.
  • the computer program When executed by the processor, it causes the processor to execute the method in one aspect of this application.
  • the present application provides a computer-readable storage medium.
  • the computer-readable storage medium stores a computer program.
  • the computer program includes program instructions. When executed by a processor, the program instructions cause the processor to perform the above-mentioned aspect. method.
  • a computer program product or computer program includes computer instructions 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 method provided in various ways such as the above aspect.
  • Figure 1 is a schematic structural diagram of a network architecture provided by this application.
  • FIG. 2 is a schematic diagram of a data processing scenario provided by this application.
  • Figure 3 is a schematic flow chart of a data processing method provided by this application.
  • Figure 4 is a schematic diagram of a scenario for generating a transformation heterogeneous graph provided by this application.
  • Figure 5 is a schematic diagram of a scenario for generating an object homogeneity graph provided by this application.
  • Figure 6 is a schematic diagram of a scenario for generating a resource homogeneity map provided by this application.
  • Figure 7 is a schematic flow chart of a model training method provided by this application.
  • Figure 8 is a schematic diagram of a network training scenario provided by this application.
  • Figure 9 is a schematic flow chart of a loss generation method provided by this application.
  • Figure 10 is a schematic diagram of a scenario for generating predicted loss values provided by this application.
  • Figure 11 is a schematic diagram of a model training scenario provided by this application.
  • Figure 12 is a schematic structural diagram of a data processing device provided by this application.
  • Figure 13 is a schematic structural diagram of a computer device provided by this application.
  • AI artificial intelligence
  • This application involves artificial intelligence related technologies.
  • artificial intelligence is a theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results.
  • artificial intelligence is a comprehensive technology of computer science that attempts to understand the essence of intelligence and produce a new intelligent machine that can respond in a similar way to human intelligence.
  • Artificial intelligence is the study of the design principles and implementation methods of various intelligent machines, so that the machines have the functions of perception, reasoning and decision-making.
  • Artificial intelligence technology is a comprehensive subject that covers a wide range of fields, including both hardware-level technology and software-level technology.
  • Basic artificial intelligence technologies generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation/interaction systems, mechatronics and other technologies.
  • Artificial intelligence software technology mainly includes computer vision technology, speech processing technology, natural language processing technology, and machine learning/deep learning.
  • Machine Learning is a multi-field interdisciplinary subject involving probability theory, statistics, approximation theory, convex analysis, algorithm complexity theory and other disciplines. It specializes in studying how computers can simulate or realize human learning. Behavior to acquire new knowledge or skills and reorganize existing knowledge structures to continuously improve their performance.
  • Machine learning is the core of artificial intelligence and the fundamental way to make computers intelligent. Its applications cover all fields of artificial intelligence.
  • Machine learning and deep learning usually include artificial neural networks, belief networks, reinforcement learning, transfer learning, inductive learning, teaching learning and other technologies.
  • the machine learning involved in this application mainly refers to how to train a prediction model (i.e., prediction network) to predict the object's conversion index for resources through the trained prediction model.
  • a prediction model i.e., prediction network
  • the machine learning involved in this application mainly refers to how to train a prediction model (i.e., prediction network) to predict the object's conversion index for resources through the trained prediction model.
  • a prediction model i.e., prediction network
  • Cloud Technology refers to a hosting technology that unifies a series of resources such as hardware, software, and network within a wide area network or local area network to realize data calculation, storage, processing, and sharing.
  • Cloud technology is a 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 and use it on demand, which is flexible and convenient. Cloud computing technology will become an important support.
  • the background services of technical network systems require a large amount of computing and storage resources, such as video websites, picture websites and more portal websites.
  • each item may have its own identification mark, which needs to be transmitted to the backend system for logical processing. Data at different levels will be processed separately, and all types of industry data need to be powerful.
  • System backing support can only be achieved through cloud computing.
  • the cloud technology involved in this application can mean that the backend can push resources to the front end of the object through the "cloud”.
  • this application can display a prompt interface before collecting user-related data (such as the following user data on resource conversion behavior and user characteristics) and during the process of collecting user-related data. Or a pop-up window.
  • the prompt interface or pop-up window is used to prompt the user that his relevant data is currently being collected, so that this application only starts to obtain the user's relevant data after obtaining the user's confirmation operation on the prompt interface or pop-up window.
  • Relevant steps otherwise (that is, when the user's confirmation operation on the prompt interface or pop-up window is not obtained), the relevant steps of obtaining the user-related data are ended, that is, the user-related data is not obtained.
  • all user data collected by this application is collected with the consent and authorization of the user, and the collection, use and processing of relevant user data need to comply with the relevant laws, regulations and standards of the relevant countries and regions.
  • Conversion rate The probability of a user successfully converting after an advertisement is exposed. Successful conversion usually refers to completing the purchase of the target product and other behaviors.
  • the conversion rate may be the following conversion index.
  • Homogeneous graph A graph with only one type of vertices and edges.
  • Heterogeneous graph A graph with two or more types of vertices and edges.
  • Bipartite graph The vertex set of the graph can be divided into two disjoint subsets.
  • the vertices at both ends of each edge in the graph (such as the object nodes or resource nodes below) belong to two different subsets. sets, and vertices in the same subset are not adjacent.
  • Self-supervised A method that directly obtains supervision signals from unlabeled data for learning without manual labeling of data.
  • the network architecture may include a server 200 and a terminal device cluster.
  • the terminal device cluster may include one or more terminal devices. There will be no limit on the number of terminal devices here.
  • multiple terminal devices may specifically include terminal device 100a, terminal device 101a, terminal device 102a,..., terminal device 103a; as shown in Figure 1, terminal device 100a, terminal device 101a, terminal device 102a,... , the terminal device 103a can all have a network connection with the server 200, so that each terminal device can perform data interaction with the server 200 through the network connection.
  • the server 200 shown in Figure 1 can be an independent physical server, a server cluster or a distributed system composed of multiple physical servers, or can provide cloud services, cloud databases, cloud computing, cloud functions, cloud storage, Cloud servers for basic cloud computing services such as network services, cloud communications, middleware services, domain name services, security services, Content Delivery Network (CDN), and big data and artificial intelligence platforms.
  • Terminal devices can be: smart phones, tablets, laptops, desktop computers, smart TVs, vehicle-mounted terminals and other smart terminals. The following takes the communication between the terminal device 100a and the server 200 as an example to provide a detailed description of the embodiment of the present application.
  • FIG. 2 is a schematic diagram of a data processing scenario provided by this application.
  • the above terminal equipment 100a, terminal equipment 101a, terminal equipment 102a, ..., terminal equipment 103a can be terminal equipment held by each user (which can be the following object), and the terminal equipment can contain an application program.
  • the application page of the program can display several Advertisements (which can be the following resources), users can purchase the products recommended in the advertisements on the application page of the application through the terminal device they hold.
  • the server 200 can be the backend server of the application.
  • the server 200 can obtain the user's purchasing behavior for the products recommended in the advertisement (which can be called the user's conversion behavior for the advertisement). Furthermore, the server 200 can use each user to target the product.
  • the purchasing behavior of the goods in each advertisement constructs a conversion heterogeneous graph.
  • the conversion heterogeneous graph includes the user node of the user and the advertising node of the advertisement. If a user has purchasing behavior for the goods in an advertisement, the conversion heterogeneous graph will There is an edge between the user node of the user and the advertisement node of the advertisement.
  • the server 200 can also construct a homogeneous graph corresponding to each user according to the object characteristics of each user (including the user's characteristic nodes, which can be called object characteristic nodes), and can construct a homogeneous graph corresponding to each advertisement according to the advertising characteristics of each advertisement. Homogeneous graph (containing advertising feature nodes, which can be called resource feature nodes).
  • the server 200 can combine the above-mentioned transformation heterogeneous graph, the homogeneous graph of each user and the homogeneous graph of each advertisement to jointly train the prediction network, thereby obtaining a trained prediction network, and the trained prediction network can be used to predict users.
  • Conversion index for advertising which represents the probability of users purchasing the products recommended in the advertisement. For this process, please refer to the relevant description in the embodiment corresponding to Figure 3 below.
  • the prediction network can be used to transform relatively isolated nodes (user nodes or advertisements) in the heterogeneous graph.
  • Features corresponding to nodes) can also be effectively learned, which improves the accuracy of the trained prediction network, thereby improving the prediction accuracy of the user's conversion index for advertising.
  • FIG 3 is a schematic flow chart of a data processing method provided by this application.
  • the execution subject in the embodiment of this application may be one computer device or a computer device cluster composed of multiple computer devices.
  • the computer device may be a server or a terminal device.
  • the execution subjects in this application are collectively referred to as computer equipment as an example.
  • the method may include:
  • Step S101 obtain the transformation heterogeneous graph;
  • the transformation heterogeneous graph contains N object nodes and M resource nodes, each object node represents an object, each resource node represents a resource, and N and M are both positive integers; If any object among the N objects has a transformation behavior for any resource among the M resources, then the object node of any object and the resource node of any resource have a connecting edge in the transformation heterogeneous graph.
  • the computer device can obtain the transformation heterogeneous graph.
  • the transformation heterogeneity graph is a heterogeneous graph.
  • the transformation heterogeneity graph can include N object nodes and M resource nodes. Each object node represents an object, and each object node represents an object. Each resource node represents a resource. In other words, there are N objects and M resources. An object can have an object node in the transformation heterogeneous graph, and a resource can have a resource node in the transformation heterogeneous graph.
  • N and M are both positive integers. The specific values of N and M are determined according to the actual application scenario, and there are no restrictions on this.
  • the N objects and M resources can be objects and resources in any application platform.
  • the object can refer to the user, and the resource can refer to any data that can be recommended or pushed to the user.
  • the resource can be advertising data, and the advertising data can be used to recommend corresponding products to the user.
  • the product can be a purchaseable product (such as shampoo, hand cream, sun hat or sunglasses, etc.), or the product It can also be an application (such as software (app)) that can be downloaded and installed.
  • the specific data of the resource can be determined according to the actual application scenario, and there is no restriction on this.
  • any object among N objects has a transformation behavior for any resource among M resources
  • the object node of any object and the resource node of any resource have connecting edges in the transformation heterogeneous graph ( That is, the object node and the resource node are rotating are interconnected in heterogeneous graphs).
  • edges interconnections between the object node of the object and the resource node of the resource in the transformation heterogeneous graph.
  • the object's conversion behavior for resources can be determined based on the actual application scenario. For example, if the resource is advertising data for products, the subject's conversion behavior of the resource can mean that the subject purchases the products recommended in the advertising data; for another example, if the resource is recommendation data for software (it can also belong to advertising data) , then the object's conversion behavior of resources may mean that the object downloads and installs the software recommended in the recommendation data.
  • the above-mentioned transformation heterogeneous graph is also an incomplete (that is, the vertices are not completely connected) bipartite graph.
  • the transformation heterogeneous graph includes two types of vertices (i.e., nodes), one is the object node of the object, One is the resource node of the resource.
  • nodes two types of vertices (i.e., nodes), one is the object node of the object, One is the resource node of the resource.
  • an object has transformation behavior for a resource, there is an edge between the object node of the object in the transformation heterogeneous graph and the resource node of the resource. Otherwise, That is, the object does not have conversion behavior for the resource, and there is no edge between the object node of the object and the resource node of the resource in the conversion heterogeneous graph.
  • Figure 4 is a schematic diagram of a scenario for generating a transformation heterogeneous graph provided by this application.
  • the N objects may include Object 1 to Object 9
  • the M resources may include Resources 1 to 5 .
  • object 1 has a transformation behavior for resource 1, so the object node 1 of object 1 in the transformation heterogeneous graph has an edge with the resource node 1 of resource 1;
  • object 2 has a transformation behavior for resource 3, so the object in the transformation heterogeneous graph
  • Object node 2 of 2 has an edge with resource node 3 of resource 3;
  • object 3 does not have transformation behavior for any resource, so object node 3 of object 3 in the transformation heterogeneous graph does not have any resource node for any resource.
  • Even side is a transformation behavior for resource 1, so the object node 1 of object 1 in the transformation heterogeneous graph has an edge with the resource node 1 of resource 1;
  • object 2 has a transformation behavior for resource 3, so the object in the transformation heterogeneous graph
  • Object node 2 of 2
  • object 4 has a transformation behavior for resource 1, so object node 4 of object 4 in the transformation heterogeneous graph has an edge with resource node 1 of resource 1; object 5 has a transformation behavior for resource 4, so the transformation heterogeneous graph Object node 5 of object 5 in the graph has an edge with resource node 4 of resource 4; object 6 has transformation behavior for resource 1 and resource 3, so object node 6 of object 6 in the transformation heterogeneous graph has an edge with resource node 1 of resource 1. is connected, and object node 6 of object 6 has an edge with resource node 3 of resource 3; object 7 has a transformation behavior for resource 4, so object node 7 of object 7 and resource node 4 of resource 4 in the transformation heterogeneous graph have Even side.
  • object 8 has a transformation behavior for resource 5, so object node 8 of object 8 in the transformation heterogeneous graph has an edge with resource node 5 of resource 5; object 9 does not have a transformation behavior for any resource, so transformation The object node 9 of the object 9 in the heterogeneous graph does not have any connecting edge with the resource node of any resource.
  • Step S102 Obtain the object homogeneity graph corresponding to each object among the N objects; any object homogeneity graph contains multiple object feature nodes, and any object feature node is used to represent the object features of the corresponding object in one dimension.
  • the computer device can obtain the homogeneity graph corresponding to each of the above N objects.
  • the homogeneity graph of the object can be called an object homogeneity graph, and one object can have one object homogeneity graph.
  • Any object homogeneity graph can contain multiple feature nodes.
  • the feature nodes in the object homogeneity graph can be called object feature nodes.
  • Any object feature node is used to represent the object features of the corresponding object in one dimension.
  • the object homogeneity graph of an object can be a complete graph, that is, any pair of object feature nodes in any object homogeneity graph can be connected to each other.
  • an object can have multiple-dimensional (i.e., multi-dimensional) object characteristics.
  • the multi-dimensional object characteristics can include the characteristics of the age of the object, the characteristics of the city where the object is located, and the characteristics of the object's work.
  • the object homogeneity map of the object can include the age of the object.
  • the specific characteristics of the multi-dimensional object characteristics of the object can be set according to the actual application scenario, and the one-dimensional object characteristics of the object can correspond to an object characteristic node in the object homogeneity graph of the object.
  • the multi-dimensional object characteristics of different objects can be the same or different, which is determined according to the actual application scenario.
  • Figure 5 is a schematic diagram of a scenario for generating an object homogeneity graph provided by this application. If an object has object characteristics in multiple dimensions (including the first to fifth dimensions), then the object homogeneity graph constructed for the object can include the object characteristics corresponding to the object in the first dimension. Object feature node, object feature node corresponding to the object feature of the object in the second dimension, object feature node corresponding to the object feature of the object in the third dimension, object feature corresponding to the object in the fourth dimension The object feature node of the object and the object feature node corresponding to the object feature of the object in the fifth dimension, these five object feature nodes are connected in pairs.
  • Step S103 Obtain a resource homogeneity graph corresponding to each of the M resources; any resource homogeneity graph contains multiple resource feature nodes, and any resource feature node is used to represent the resource features of the corresponding resource in one dimension.
  • the computer device can obtain the homogeneity map corresponding to each of the above M resources.
  • the homogeneity map of the resource can be called a resource homogeneity map, and one resource can have one resource homogeneity map.
  • Any resource homogeneity graph can contain multiple feature nodes.
  • the feature nodes in the resource homogeneity graph can be called resource feature nodes.
  • Any resource feature node is used to represent the resource features of the corresponding resource in one dimension.
  • the resource homogeneity graph of resources can be a complete graph, that is, any pair of resource feature nodes in any resource homogeneity graph can be connected to each other.
  • resources can have resource characteristics in multiple dimensions (i.e., multi-dimensional).
  • the multi-dimensional resource characteristics can include the characteristics of the resource style of the resource, the characteristics of the field to which the resource belongs, and the characteristics of the resource type.
  • the resource homogeneity graph of the resource can include Characteristic nodes of the resource style, characteristic nodes of the domain to which the resource belongs, and characteristic nodes of the resource type.
  • the specific characteristics of the multi-dimensional resource characteristics of the resource can be set according to the actual application scenario, and the one-dimensional resource characteristics of the resource can correspond to a resource characteristic node in the resource homogeneity graph of the resource.
  • the multi-dimensional resource characteristics of different resources can be the same or different, which is determined based on the actual application scenario.
  • Figure 6 is a schematic diagram of a scenario for generating a resource homogeneity map provided by this application. If a resource has resource characteristics in multiple dimensions (including the 1st dimension to the 6th dimension), then the resource homogeneity graph constructed for the resource can include the resource characteristics corresponding to the resource in the 1st dimension. Resource characteristic node, the resource characteristic node corresponding to the resource characteristic of the resource in the second dimension, the resource characteristic node corresponding to the resource characteristic of the resource in the third dimension, the resource characteristic node corresponding to the resource characteristic in the fourth dimension The resource characteristic node of the resource, the resource characteristic node corresponding to the resource characteristic of the resource in the fifth dimension, and the resource characteristic node corresponding to the resource characteristic of the resource in the sixth dimension. These six resource characteristic nodes are connected in pairs. .
  • Step S104 train the prediction network based on the transformation heterogeneous graph, the object homogeneity graph of each object, and the resource homogeneity graph of each resource to obtain a trained prediction network; the trained prediction network is used to predict the transformation of objects to resources. index.
  • the transformation heterogeneity graph contains the transformation relationship between objects and resources.
  • the homogeneity graph of the object represents the characteristics of the object itself.
  • the homogeneity graph of the resource represents the characteristics of the resource itself.
  • the computer equipment can obtain the transformation heterogeneity according to the above. graph, each object
  • the object homogeneity graph and the resource homogeneity graph of each resource are used to train the prediction network, and then the trained prediction network is obtained.
  • the trained prediction network can be used to predict the conversion index of the object for the resource.
  • the conversion index represents the probability that the object will perform the conversion behavior of the resource.
  • the computer device can predict the conversion index of each object for each resource based on the predicted conversion index. Determine the strategy for resource push for each object (referred to as the resource push strategy).
  • the resource push strategy determines whether the conversion index of an object for a resource is larger. It indicates that the probability of the object performing conversion behavior for the resource is greater. On the contrary, if the conversion index of an object for a resource is smaller, it indicates that the object is for the resource. The probability of performing conversion behavior is smaller.
  • the computer device can obtain the prediction object and the prediction resource, and the prediction object can be any one of the N objects mentioned above, or the prediction object can also be a new one (that is, it does not belong to any of the N objects), Similarly, the predicted resource may be any one of the M resources mentioned above, or the predicted resource may be newly added (that is, it does not belong to any of the M resources).
  • the computer device can obtain the object identifier of the predicted object and the resource identifier of the predicted resource, and can map the object identifier of the predicted object and the resource identifier of the predicted resource to a unified hash space. It may be the same as the hash space to which the object identifiers of N objects and the resource identifiers of M resources are mapped in step S201 below. For specific explanation, please refer to the description in step S201 below.
  • the computer device can obtain the object label characteristics of the predicted object and the resource label characteristics of the predicted resource.
  • the process of obtaining the object label characteristics of the predicted object is the same as the process of obtaining the object label characteristics of each object in the following step S202.
  • Obtaining The process of predicting resource tag features of resources is the same as the process of obtaining the resource tag features of each resource in step S203 below.
  • the computer device can input the feature values of the predicted object mapped in the hash space, the object label features of the predicted object, the feature values of the predicted resources mapped in the hash space, and the resource tag features of the predicted resources into the trained prediction network, Call the prediction network to predict the prediction object's response to the prediction resource based on the feature values mapped by the prediction object in the hash space, the object label features of the prediction object, the feature values mapped by the prediction resource in the hash space, and the resource label features of the prediction resource.
  • Conversion index the conversion index can be a value from 0 to 1.
  • the prediction resource can be pushed to the prediction object.
  • the prediction resources can also include each of the above-mentioned M resources. Therefore, the computer device can obtain the conversion index of the prediction object for each prediction resource, and can correspond to each prediction resource respectively.
  • the conversion index sorts each predicted resource in descending order, and the top T resources can be pushed to the prediction object.
  • T is a positive integer, and the specific value of T can be determined according to the actual application scenario.
  • this application focuses on describing how to accurately train the prediction network, and then how to generate an accurate conversion index of the object for resources through the trained prediction network, and how to push resources to the object through the object's conversion index for resources. It can be determined according to the actual application scenario, and there is no restriction on this.
  • This application trains the prediction network by combining the transformation heterogeneous graph between objects and resources, and the homogeneous graph of objects and resources, which can make the prediction network more effective in transforming relatively isolated nodes (such as other resource nodes or objects) in the heterogeneous graph.
  • Nodes with no edges or few edges can also learn the characteristics of corresponding objects or resources better, which can solve the cold start problem for objects and resources (for example, when there are new objects or resources, the Insufficient learning of new objects or resources Also, when some existing objects or resources are not closely related to other objects or resources (for example, in the transformation heterogeneous graph, the corresponding connecting edges do not exist or there are very few), the objects and resources that are not closely related will The problem of insufficient resource learning) enables the trained prediction network to accurately predict the conversion index of all objects for all resources.
  • This application can obtain the transformation heterogeneous graph; the transformation heterogeneous graph contains object nodes of N objects and resource nodes of M resources, where N and M are both positive integers; if any object among the N objects If a resource has transformation behavior, then the object node of any object and the resource node of any resource have connected edges in the transformation heterogeneous graph; obtain the object homogeneity graph corresponding to each object in the N objects; any object has the same
  • the homogeneity graph contains multiple object feature nodes, and any object feature node is used to represent the object characteristics of the corresponding object in one dimension; the resource homogeneity graph corresponding to each resource in the M resources is obtained; any resource homogeneity graph contains Multiple resource feature nodes, any resource feature node is used to represent the resource features of the corresponding resource in one dimension; the prediction network is trained based on the transformation heterogeneous graph, the object homogeneity graph of each object and the resource homogeneity graph of each resource , to obtain a trained prediction network; the trained prediction network is
  • the method proposed in this application can simultaneously combine the heterogeneous graph of objects and resources, the homogeneous graph of objects and the homogeneous graph of resources to train the prediction network, so that when training the prediction network, for each object and each resource (simultaneously Characteristics including objects and resources that do not have access behavior between them and objects and resources that have access behavior between them can be effectively propagated, so the accuracy of the prediction network obtained by training can be improved, and the prediction network obtained by training can also Achieve accurate prediction of the object's conversion index for resources.
  • Figure 7 is a schematic flow chart of a model training method provided by this application.
  • the execution subject in the embodiment of the present application may be the same as the execution subject in the corresponding embodiment of Figure 3.
  • the method includes:
  • Step S201 Call the prediction network to generate the first object embedding feature of each object and the first resource embedding feature of each resource based on the transformed heterogeneous graph.
  • the computer device can obtain the object identifier (object ID) of each object and the resource identifier (resource ID) of each resource.
  • the computer device can map the object identifier of each object and the resource identifier of each resource into a unified hash space.
  • the object identifier of each object and the resource identifier of each resource can be calculated through a specific hash algorithm, and the object identifier of each object and the resource identifier of each resource can be mapped to a unified hash space.
  • the object identifier is mapped to a hash value in the hash space, and the resource identifier of a resource is also mapped to a hash value in the hash space.
  • the computer device can represent the above-mentioned transformation heterogeneous graph as a relationship matrix through the hash values of each of the above-mentioned resources and each object mapped in the hash space.
  • the horizontal direction of the relationship matrix can represent each resource, and the vertical direction can represent each object. If a If the object node of an object and the resource node of a resource have an edge in the transformation heterogeneous graph, then the element value at the corresponding position of the object and the resource in the relationship matrix is 1. Otherwise (that is, there is no edge), the element value is 1. The element value at the corresponding position of the object and the resource in the relationship matrix is 0.
  • the relationship matrix is used to indicate the edge relationship between each resource node and object node in the transformed heterogeneous graph.
  • the matrix space of the above-mentioned relationship matrix is the hash space to which the object identifier and resource identifier are mapped.
  • the horizontal positions in the relationship matrix can include positions corresponding to the hash values that the resource identifier can be mapped to.
  • This relationship Vertical positions in the matrix can contain hash values to which object identifiers can be mapped.
  • the relationship matrix may also include locations to which the above-mentioned N objects and M resources are not mapped. That is, there may be several elements with values 0 in the relationship matrix. The existing positions where the element value is 0 can support subsequent mapping of new objects and new resources.
  • the prediction network can also identify and map the new objects and resources to the corresponding positions in the hash space. Even if the prediction network can also identify and predict new objects and resources that have not been exposed to it, it can improve predictions.
  • the relationship matrix that transforms the heterogeneous graph can be expressed as R, and the computer device can also obtain the adjacency matrix of the relationship matrix R, and the adjacency matrix can be expressed as A, as shown in the following formula (1),
  • the adjacency matrix A is:
  • R T represents the transpose of the relationship matrix R.
  • the structure of the transformed heterogeneous graph itself is the structure of the adjacency matrix A, and the adjacency matrix A is a symmetric matrix.
  • the transformed heterogeneous graph can be expressed as an adjacency matrix A, and the adjacency matrix A also records Transform the transformation behavior of each object contained in the heterogeneous graph for each resource, thereby making it possible to perform simpler operations through the adjacency matrix in the prediction network.
  • the computer device can input the above-mentioned adjacency matrix A into the prediction network.
  • the process of calling the prediction network to generate the embedded features of each object and the embedded features of each resource based on the adjacency matrix A can be:
  • the prediction network can include NGCF (a kind of graph neural network), which can propagate information between various nodes in the heterogeneous graph very well. Therefore, this application can generate the first object of the object by calling the NGCF in the prediction network.
  • the process may include: the computer device may call NGCF to obtain a feature propagation matrix. The feature propagation matrix is used to transform each node in the heterogeneous graph (including resource nodes and object nodes).
  • NGCF here can have 4 layers (or other layers) of network layers used for feature learning and generation.
  • the value of k can be 0 to 3, and the first layer performs feature learning.
  • the generated network layer can generate the feature matrix E (1) according to E (0 ).
  • the second layer performs feature learning and the generated network layer can generate the feature matrix E (2) according to E ( 1) .
  • the third layer performs feature learning.
  • the network layer generated by and can generate the feature matrix E (3) according to E (2)
  • the fourth layer of the network layer for feature learning and generation can generate the feature matrix E (4) according to E (3 ).
  • represents the activation function
  • L represents the above-mentioned feature propagation matrix
  • L belongs to the graph Laplacian matrix, which is used to perform inter-node
  • D represents the degree matrix.
  • D records the degree of each node (including object nodes and resource nodes) in the transformed heterogeneous graph.
  • the degree of a node is equal to the number of other nodes that have edges with the node.
  • I represents the identity matrix.
  • W 1 and W 2 both belong to the parameter matrix in NGCF (also used for information dissemination between nodes). During the continuous training process of the prediction network, W 1 and W 2 will also be continuously updated and corrected. .
  • E (1) ⁇ E (4) can be obtained through the above formula (2) and formula (3), and the obtained E (1) ⁇ E (4 ) can be used as the embedded feature matrix, formula (4)
  • in represents splicing, that is, by splicing multiple embedded feature matrices (including E (0) ⁇ E (4) ), the spliced embedded feature matrix can be obtained
  • E (0) ⁇ E (4) are all embedded feature matrices, and any embedded feature matrix contains embedded features (which can be feature vectors) corresponding to each node in the transformed heterogeneous graph.
  • E (0) belongs to the initialized embedded feature matrix.
  • the initialized embedded feature matrix contains the initialized embedded features corresponding to each object and the corresponding initialized features of each resource.
  • the initialized embedding features, the initialized embedding features corresponding to each object, and the initialized embedding features corresponding to each resource can be obtained by random initialization.
  • the prediction network can be continuously trained iteratively, during each iterative training process, the prediction network can generate E (1) ⁇ E (4) . Therefore, during the iterative training process of the prediction network, the prediction network For non-initial training (that is, not the first training), E (0) in the next iterative training process can be E (4) in the previous iterative training process.
  • each embedded feature in E (0) ⁇ E (4) (a node in the transformed heterogeneous graph corresponds to an embedded feature in an embedded feature matrix) is 16 dimensions (it can also be other dimensions), then after splicing
  • the embedded feature matrix of Each embedded feature in is 16*5 with a total of 80 dimensions. Therefore, the spliced embedded feature matrix can be Perform feature dimensionality reduction (that is, perform feature mapping processing, which can be mapped through a mapping matrix in a multilayer perceptron (MLP), and the mapping matrix can also be obtained by training) to obtain the target embedded feature matrix, which is the target embedded feature
  • the matrix is the embedded feature matrix after splicing Obtained after feature dimensionality reduction.
  • the target embedded feature matrix includes the embedded features of each object and the embedded features of each resource. Each embedded feature included in the target embedded feature matrix may also be 16-dimensional.
  • the computer device can extract the embedded features of each object from the target embedded feature matrix.
  • As the first object embedded feature of each object an object has a first object embedded feature.
  • the computer network can also extract the embedded features of each object from the target embedded feature matrix.
  • the embedding feature of each resource is extracted as the first resource embedding feature of each resource.
  • One resource has one first resource embedding feature.
  • the first object embedding feature of each object and the first resource embedding feature of each resource are the embedding features of each object and the embedding feature of each resource generated by the prediction network by converting the heterogeneous graph.
  • Step S202 Call the prediction network to generate the second object embedding feature of each object based on the object homogeneity map of each object.
  • the prediction network can also include an inductive learning network, or Graph Attention Network (GAT).
  • GAT Graph Attention Network
  • This GAT has good inductive learning capabilities. Therefore, the computer network can call the GAT in the prediction network according to each The object homogeneity graph of each object is used to generate the embedding features of each object (which can be called the second object embedding feature).
  • the following description takes the generation of the second object embedding feature of the target object through GAT as an example, where the target object may be one of N objects. For any object, please see the description below.
  • the object homogeneity graph is a fully connected graph.
  • the computer device can represent the object homogeneous graph of the target object as a corresponding adjacency matrix (the process of obtaining the adjacency matrix of the object homogeneous graph of the target object is the same as the above-mentioned process of obtaining the adjacency matrix of the transformed heterogeneous graph), and the target object can be
  • the adjacency matrix of the object homogeneous graph is represented as AD , and then the computer device can input the adjacency matrix AD into the prediction network.
  • the computer device can also input the object label features (which can be represented as vectors) of each object into the prediction network.
  • the object label characteristics of each object can be obtained through the specific object characteristics of each object on the object characteristics of each dimension (reflected by the characteristic values of the object characteristics of each dimension). For example, an object has object features in three dimensions, and the feature space of any one of the three dimensions is 1000 (that is, the object feature in one dimension has 1000 values, that is, 1000 feature values), then The object label feature of the object may be composed of the feature values of the object features in the three dimensions.
  • the three-dimensional object characteristics correspond to the characteristics of the subject's age, the characteristics of the city where the subject is located, and the characteristics of the subject's work.
  • the feature space of can be 1000 in size, that is, the feature of the subject's age can have 1000 selectable feature values, and the 1000 selectable feature values can include mapping values corresponding to 0 to 999 years old (which can be understood as using For the identification of a certain age, one age can correspond to one mapping value); the characteristics of the city where the object is located can also have 1000 selectable feature values, and the 1000 selectable feature values can include mappings corresponding to 1000 cities.
  • mapping value (can be understood as an identifier used to represent a certain city, and a city can correspond to a mapping value); similarly, the characteristics of an object's work can also have 1,000 selectable feature values, and the 1,000 selectable feature values can It includes mapping values corresponding to 1,000 types of jobs (which can be understood as an identifier used to represent a certain job, and a job can correspond to a mapping value).
  • the object label feature of object 1 can be (0.3, 0.5, 0.2).
  • Each feature value (i.e. mapping value) in each dimension can be obtained by mapping the corresponding object features into a unified hash space.
  • the object features of one dimension can correspond to a hash space, by mapping the corresponding object features in each dimension.
  • Several object features are mapped to the corresponding hash space, which can ensure that various object features in each dimension (one feature value can correspond to one object feature) are controllable, and for new object features (For example, the object characteristics indicated by a certain feature value in a certain dimension that are not used during training but are used in actual prediction) can also be guaranteed to be in the preset feature space (i.e., hash space), even if The prediction network can identify all object features in the hash space in various dimensions.
  • a specific hash algorithm (the specific expression of the algorithm can be determined according to the actual application scenario) can be used to map all the ages that can be selected by the age of the object into a hash space.
  • the age of the object is Each age that can be selected includes 0 to 999 years old.
  • a hash operation can be performed on a total of 1000 ages from 0 to 999 to obtain the mapping value corresponding to each age (belonging to the hash value).
  • the mapping value corresponding to each age is Characteristics for the age of the object Each characteristic value that can be selected in the dimension.
  • the process of generating the second object embedding feature of the target object may be: the computer device may call GAT to delete the connected edges in the object homogeneous graph of the target object, and obtain the activated subgraph of the object homogeneous graph of the target object,
  • the activation subgraph of the object homogeneity graph of the target object can be called the first activation subgraph.
  • the first activation subgraph is the edge between the object feature nodes that have little correlation in the object homogeneity graph of the target object. Obtained after removal, the first activation subgraph is an incompletely connected graph.
  • the first activation subgraph can be expressed as a relationship matrix obtained by deleting the connected edges in the object homogeneous graph of the target object, Then, the adjacency matrix of the first activation subgraph can be obtained.
  • the process of obtaining the adjacency matrix of the first activation subgraph is the same as the above-mentioned process of obtaining the adjacency matrix of the transformed heterogeneous graph. As shown in the following formulas (5) to (7), the process can be:
  • M i,j represents the correlation (can be understood as similarity) between the i-th object feature node and the j-th object feature node in the object homogeneity graph of the target object, and the i-th object feature node and the j-th object feature node
  • the j object feature nodes can be any two object feature nodes in the object homogeneity graph of the target object.
  • each object feature node in the object homogeneity graph of the target object contains the embedded features corresponding to each object feature node, express The embedded feature corresponding to the i-th object feature node in , express The embedded feature corresponding to the jth object feature node in , express and cosine distance between them.
  • represents how many edges in the object homogeneous graph of the target object are to be retained (it is also used to indicate how many edges in the object homogeneity graph of the target object are to be deleted), for example, If ⁇ is 30 (it can also be other values, determined according to the actual application scenario), then the correlation between the object feature nodes in the object homogeneity graph of the target object can be sorted, and the top 30% of the correlations are retained.
  • the edges between the object feature nodes are deleted, that is, the edges between the object feature nodes ranked in the bottom 70% by correlation are deleted. There is a correlation between any two object feature nodes, that is, any edge corresponds to a correlation Spend.
  • the target object can be retained The edge between object feature node 1 and object feature node 2 in the object homogeneous graph of the target object, otherwise, that is, if the correlation between object feature node 1 and object feature node 2 in the object homogeneous graph of the target object is ranked among all If the correlation between object feature nodes reaches the last 70%, the edge between object feature node 1 and object feature node 2 in the object homogeneity graph of the target object can be deleted.
  • the first activation subgraph includes the edges between the object feature nodes whose correlation degrees are ranked in the top 30% of the object homogeneity graph of the target object.
  • the edges between feature nodes are the edges between the object feature nodes ranked in the top ⁇ % by correlation in the object homogeneity graph in the first activation subgraph that contains the target object.
  • the above formula (5) indicates that in the adjacency matrix of the first activation subgraph, only the object feature nodes whose correlation degrees are ranked in the top ⁇ % have a connection relationship (that is, it indicates that there are connected edges in the first activation subgraph), and vice versa. , there is no connection relationship between object feature nodes whose correlation degree is not ranked in the top ⁇ %.
  • H represents the initialized feature matrix, and H contains the initialized corresponding object features in each dimension of the target object.
  • Embedded features that is, H contains the initialized embedded features corresponding to each object feature node in the object homogeneity graph of the target object.
  • One dimension of object features corresponds to an initialized embedded feature, that is, one object feature node corresponds to an initialized embedded feature.
  • the initialized embedded features corresponding to each object feature node in H can be obtained by random initialization.
  • the computer device can obtain the initialized embedded features corresponding to each object feature node through the object label features of the target object.
  • the feature values of the target object on the object features of each dimension can be established in advance (i.e. The above mapping values) are associated with the corresponding initialized embedded features, and one feature value corresponds to one initialized embedded feature. Since an object feature of one dimension corresponds to an object feature node, and an object feature of one dimension also corresponds to an initialized embedded feature, therefore, an object feature node corresponds to an initialized embedded feature, and this initialized embedded feature is indicated by the object feature node.
  • Initialized embedding features corresponding to dimensional object features are associated with the corresponding initialized embedded features, and one feature value corresponds to one initialized embedded feature.
  • the computer device can obtain the initialized embedded features with an associated relationship through the feature values corresponding to the object features of each dimension contained in the object label feature of the target object, as the initialized embedded features corresponding to each object feature node of the target object. Embedded features.
  • the prediction network can be continuously iteratively trained, during each iterative training process, the prediction network can be generated through the logic of formula (7) Right now It is also constantly updated during each training process. Therefore, in the iterative training process of the prediction network, for the non-initial training of the prediction network (that is, not the first training), formula (7) is brought into the subsequent iterative training process.
  • H can be the value in the previous iteration of training W 3 in formula (7) belongs to the parameter matrix of GAT, and b 3 is the bias vector.
  • W 3 and b 3 will also be continuously updated, that is, W 3 and b 3 also belong to the prediction network. network parameters.
  • the computer device can be based on the adjacency matrix of the first activation subgraph To generate the second object embedding feature of the target object, the process is as shown in the following formula (8) to formula (10):
  • Ni represents the set of neighbor nodes of the i-th object feature node.
  • the set of neighbor nodes of the i-th object feature node can be obtained through the adjacency matrix of the first activation subgraph above.
  • the neighbor nodes of the i-th object feature node refers to the object feature node that has an edge with the i-th object feature node in the first activation subgraph.
  • u belongs to N i , that is, u belongs to the neighbor node of the i-th object feature node.
  • the object characteristics of the target object in the first activation subgraph in the dimensions indicated by each object characteristic node can be propagated, and then the corresponding node characteristics of each object characteristic node can be generated.
  • the node features that generate the i-th object feature node are specifically described here.
  • M feature generation network layers in GAT, and the value range of m can be 0 ⁇ M-2.
  • Each feature generation network layer can generate the i-th object feature node.
  • K embedded features, k ranges from 1 to K.
  • K can be generated in the mth layer
  • represents the activation function
  • in formula (8) represents splicing
  • W (m) represents the parameter matrix of the m-th feature generation network layer
  • ⁇ iu represents the relationship between the i-th object feature node and the u-th object feature node Normalized edge weights.
  • exp represents the exponential function
  • W represents the parameter matrix of the prediction network, which belongs to the network parameters (i.e., model parameters), and the training process is continuously updated
  • v also belongs to N i , that is, v also belongs to the neighbor node of the i-th object feature node.
  • v can It is u, or it may not be u.
  • the i-th object generated by the first M-1 feature generation network layers of the above-mentioned M feature generation network layers can be obtained through formulas (8) to (9).
  • the embedded features of the feature nodes that is, the processing logic of the first M-1 feature generation network layers among the M feature generation network layers can be the logic of formula (8) to formula (9).
  • the processing logic of the last layer among the M feature generation network layers i.e., the Mth feature generation network layer
  • the processing logic of the Mth feature generation network layer can be different from the first M-1 feature generation network layers.
  • the processing logic of the Mth feature generation network layer can be the formula ( 10)
  • the processing logic, through the Mth feature generation network layer can output the final embedded feature of the i-th object feature node as the node feature of the i-th object feature node
  • W (M) represents the parameter matrix of the Mth feature generation network layer, which belongs to the network parameters and needs to be continuously updated. It represents the embedded feature of the i-th object feature node generated by the M-1 feature generation network layer (that is, when m equals M-2).
  • the computer device can generate each object characteristic node in the object homogeneous graph of the target object (i.e., each object characteristic node in the first activation subgraph, the An activation subgraph contains the same object feature nodes as the object homogeneous graph of the target object, but the edges are different) corresponding node features, and the dimensions of each node feature are the same, for example, they are both feature vectors with a dimension of 16.
  • the computer device can sum the node features corresponding to each object feature node of the target object to obtain the second object embedded feature of the target object.
  • summing the node features corresponding to each object feature node may be summing the element values at the same position in the node features corresponding to each object feature node. Therefore, the second obtained target object
  • the dimensions of object embedding features and individual node features are the same.
  • the node features of each object feature node of the target object include node features (0.1, 0.2, 0.3) and node features (0.2, 0.4, 0.6)
  • the node features (0.1, 0.2, 0.3) and node features The result of summing the features (0.2, 0.4, 0.6) can be (0.3, 0.6, 0.9), that is, the second object embedding feature of the target object is (0.3, 0.6, 0.9).
  • the computer device can generate the second object embedding features corresponding to each object in the same manner as generating the second object embedding features of the target object.
  • Step S203 Call the prediction network to generate the second resource embedding feature of each resource based on the resource homogeneity graph of each resource.
  • the process of generating the second resource embedding feature of each resource is the same as the above-mentioned process of generating the second object embedding feature of the target object.
  • the object homogeneity graph of the target object needs to be replaced by the resource homogeneity graph of the resource. Replace object feature nodes with resource feature nodes. Therefore, for the specific process of generating the second resource embedding feature of each resource, please refer to the specific description in S202 above.
  • the computer device before generating the second resource embedding feature of each resource, the computer device also needs to input the resource tag feature of each resource into the prediction network.
  • the resource tag feature of each resource can also be obtained by each resource.
  • the label features are obtained.
  • the dimensions of the resource tag features of each resource can be different. If a resource has tag features in which dimensions, then the resource tag feature of the resource can have feature values corresponding to the tag features of these dimensions.
  • a label feature can correspond to a resource feature of one dimension. Therefore, a resource feature of one dimension can have only one feature value.
  • the resource tag feature of the resource may be composed of feature values corresponding to the tag features in the three dimensions.
  • Resource 1 For example, if a resource (such as Resource 1) is animation, Resource 1 has three-dimensional label features.
  • the three-dimensional label features are the characteristics of Chinese style, magical characteristics, and character close-up characteristics.
  • the eigenvalue corresponding to the characteristics of wind is 0.1
  • the eigenvalue corresponding to the characteristics of magic is 0.2
  • the eigenvalue corresponding to the characteristics of close-up characters is 0.6
  • the resource tag characteristics of resource 1 can be (0.1, 0.2, 0.6).
  • Resource 2 For another example, if a resource (such as Resource 2) is an advertisement for a product, Resource 2 has 4-dimensional label features.
  • the 4-dimensional label features are household features, electrical appliance features, energy-saving features, and
  • the eigenvalue corresponding to the household feature is 0.11
  • the eigenvalue corresponding to the electrical appliance feature is 0.22
  • the eigenvalue corresponding to the energy-saving feature is 0.33
  • the eigenvalue corresponding to the portable feature is 0.44.
  • the resource label feature of resource 2 can be (0.11, 0.22, 0.33, 0.44).
  • each feature value (i.e., mapping value) in each dimension can be obtained by mapping the corresponding label feature to a unified hash space.
  • the label features of all dimensions can have a unified hash space (this The hash space is different from the hash space of the above object features).
  • mapping the tag features of each dimension into a unified hash space it is possible to ensure that various tag features in each dimension (i.e. resource features, a kind of tag feature Resource features that can correspond to one dimension) are controllable, and new resource features (such as label features in a certain dimension that are not used during training but are used in actual prediction) can also be guaranteed to be processed in advance.
  • the prediction network can identify the resource features in each dimension corresponding to all resource features in the hash space.
  • a specific hash algorithm (the specific expression of the algorithm can be determined according to the actual application scenario) can be used to map the characteristics of the specific style of resources into the hash space.
  • the feature of the specific style of the resource may have a feature identifier (id), and then a hash operation can be performed on the feature ID to obtain the feature value corresponding to the feature of the specific style.
  • the computer device can obtain the initialized embedded features corresponding to each resource feature node of the resource through the feature values contained in the resource tag features of each resource.
  • any one of the M resources can be represented as a target resource.
  • the computer device can call GAT to perform edge deletion processing on the resource homogeneity graph of the target resource to obtain an activated subgraph of the resource homogeneity graph of the target resource.
  • the target resource can be The activated subgraph of the resource homogeneity graph is called the second activated subgraph.
  • the method of obtaining the second activated subgraph is the same as the above method of obtaining the first activated subgraph.
  • the computer device can perform feature propagation processing on the resource characteristics of the target resource in multiple dimensions according to the second activation subgraph, and obtain each resource characteristic node of the target resource in the second activation subgraph (i.e., in the resource homogeneity graph
  • the resource feature node in the resource homogeneity graph of the target resource is the same as the resource feature node in the second activated subgraph of the target resource, except that the edges between the resource feature nodes are different
  • the process of obtaining the node characteristics corresponding to each resource characteristic node of the target resource is the same as the above-mentioned process of obtaining the node characteristics corresponding to each object characteristic node of the target object.
  • the computer device can generate the second resource embedding feature of the target resource through node features corresponding to each resource feature node of the target resource.
  • the process of generating the second resource embedding feature of the target resource based on the node features respectively corresponding to each resource feature node of the target resource is the same as the process of generating the second object embedding feature of the target object based on the node features respectively corresponding to each object feature node of the target object.
  • the process for features is the same.
  • the computer device can generate the second resource embedding feature of each resource, and one resource corresponds to one second resource embedding feature.
  • Step S204 train the prediction network based on the first object embedding feature of each object, the second object embedding feature of each object, the first resource embedding feature of each resource, and the second resource embedding feature of each resource, and obtain the trained prediction network. prediction network.
  • the computer device may generate a prediction for the prediction network through the first object embedding feature of each object, the second object embedding feature of each object, the first resource embedding feature of each resource, and the second resource embedding feature of each resource.
  • Loss value represents the prediction deviation of the prediction network for objects and resources. The greater the prediction loss value, the greater the prediction deviation of the prediction network. On the contrary, the smaller the prediction loss value, the prediction deviation of the prediction network. The smaller.
  • the computer device can use the prediction loss value to modify the network parameters (ie, model parameters) of the prediction network, for example, by adjusting the network parameters of the prediction network so that the prediction loss value reaches a minimum value.
  • the network parameters ie, model parameters
  • the prediction network can be continuously iteratively trained, and each training will have a corresponding prediction loss value.
  • the network parameters of the prediction network are constantly updated and corrected, and the final training can be completed.
  • the prediction network (such as the network parameters are trained to the convergence state or the number of training times reaches a certain threshold) is used as the trained prediction network.
  • Figure 8 is a schematic diagram of a network training scenario provided by this application.
  • the computer device can call the prediction network to generate the first object embedding feature of each object and the first resource embedding feature of each resource by transforming the heterogeneous graph.
  • the computer device can also call the prediction network to generate the first object embedding feature of each object by converting the heterogeneous graph.
  • the object homogeneity map generates a second object embedding feature for each object, and the computer device may also invoke the prediction network to generate a second resource embedding feature for each resource through the resource homogeneity map for each resource.
  • the computer device may generate predictions of the prediction network through the generated first object embedding features of each object, the second object embedding features of each object, the first resource embedding features of each resource, and the second resource embedding features of each resource.
  • the loss function i.e., the above-mentioned prediction loss value
  • modify the network parameters of the prediction network through the prediction loss function can obtain the trained prediction network.
  • This application uses self-supervision to compare the embedding features (such as second resource embedding features and second object embedding features) obtained through homogeneous graphs (such as resource homogeneous graphs and object homogeneous graphs) with those obtained by transforming heterogeneous graphs.
  • Embedding features such as the first resource embedding feature and the first object embedding feature
  • the homogeneous graph can effectively generalize to the heterogeneous bipartite graph (i.e., transform the heterogeneous graph) and replace the bipartite graph in the cold start scenario.
  • Figure 9 is a schematic flow chart of a loss generation method provided by this application.
  • the embodiment of this application mainly describes how to generate the prediction loss value of the prediction network.
  • the execution subject in the embodiment of this application can be the same as the execution subject in the corresponding embodiment of Figure 3 above. As shown in Figure 9, the method includes:
  • Step S301 Generate a feature general feature of the prediction network based on the first object embedding feature of each object, the second object embedding feature of each object, the first resource embedding feature of each resource, and the second resource embedding feature of each resource.
  • ization loss value is used to indicate the feature difference between the first object embedding feature and the second object embedding feature of each object, and is used to indicate the first resource embedding feature and the second resource embedding feature of each resource. Characteristic differences between features.
  • the computer device generalizes the feature space of the homogeneous graph to transform the feature space of the heterogeneous graph. Specifically, the computer device can convert the embedded features (including the second object embedded features of each object and each object) obtained through the homogeneous graph.
  • the second resource embedding feature of the resource is aligned with the embedding feature obtained by transforming the heterogeneous graph (including the first object embedding feature of each object and the first object embedding feature of each resource) (i.e., making the two similar) , and then generate the feature generalization loss value of the prediction network.
  • the feature generalization loss value is used to characterize the feature difference between the first object embedding feature and the second object embedding feature of each object, and is used to characterize each resource.
  • the feature difference between the first resource embedding feature and the second resource embedding feature is used to convert the feature space of the homogeneous graph to transform the feature space of the heterogeneous graph.
  • the computer device can convert the embedded features (including the second object
  • the larger the feature generalization loss value the more characteristic the difference between the first object embedding feature and the second object embedding feature of each object and the difference between the first resource embedding feature and the second resource embedding feature of each resource.
  • the greater the difference in characteristics i.e., the more dissimilar similar
  • conversely, the smaller the feature generalization loss value the characteristic difference between the first object embedding feature and the second object embedding feature of each object and the first resource embedding feature and the second resource embedding feature of each resource
  • the smaller the feature differences between them that is, the more similar they are).
  • a represents the a-th object among N objects, and the value range of a is 1 to N.
  • b represents the b-th resource among M resources, and the value range of b is 1 to M.
  • e a represents the first object embedding feature of the a-th object
  • e′ a represents the second object embedding feature of the a-th object
  • e b represents the first resource embedding feature of the b-th resource
  • e′ b represents the second object embedding feature of the a-th object.
  • the second resource embedding feature of b resources The second resource embedding feature of b resources.
  • e a -e′ a represents the feature difference between the first object embedding feature and the second object embedding feature of the a-th object. It can be ⁇ a ⁇ [1, N] (
  • the feature difference between the first resource embedding feature and the second resource embedding feature can be called ⁇ b ⁇ [1, M] (
  • 1 represents 1 norm.
  • Step S302 Generate a first conversion prediction loss value of the prediction network based on the first object embedding feature of each object and the first resource embedding feature of each resource.
  • the computer device may generate a first transformation prediction loss value of the prediction network based on the first object embedding feature of each object and the first resource embedding feature of each resource, the first transformation prediction loss value characterizing the prediction network through the transformation heterogeneity Figure to predict the predicted loss of the object against the resource's conversion index.
  • the transformation index of the a-th object for the b-th resource predicted by the prediction network based on the transformation heterogeneous graph during the training process can be recorded as This conversion index can be It is called the first predicted conversion index of the a-th object for the b-th resource.
  • the first predicted conversion index of the a-th object for the b-th resource for:
  • sigmoid represents the activation function (an S-shaped function)
  • W 4 represents the parameter matrix of the prediction network, which belongs to the network parameters and will be continuously updated during the training process.
  • b 4 is the bias vector
  • e a represents the a-th object.
  • An object embedding feature, e b represents the first resource embedding feature of the b-th resource,
  • represents splicing.
  • the first conversion prediction loss value can be recorded as L z1 , as shown in the following formula (13), the first conversion prediction loss value L z1 is:
  • Y a, b represents the actual conversion label between the a-th object and the b-th resource (can be input when training the prediction network, or can be obtained by converting the heterogeneous graph).
  • the conversion label indicates the actual conversion label of the a-th object. Whether to have conversion behavior for the b-th resource. Indicates the conversion index of the a-th object for the b-th resource predicted by the above-mentioned transformation of the heterogeneous graph.
  • Step S303 Generate a second conversion prediction loss value of the prediction network based on the second object embedding feature of each object and the second resource embedding feature of each resource.
  • the computer device can generate a second conversion prediction loss value of the prediction network based on the second object embedding feature of each object and the second resource embedding feature of each resource.
  • the second conversion prediction loss value represents the prediction network through Homogeneity graphs (including object homogeneity graphs and resource homogeneity graphs) are used to predict the predicted loss of the object's conversion index for resources.
  • the conversion index of the a-th object to the b-th resource predicted by the prediction network based on the homogeneous graph during the training process can be recorded as This conversion index can be It is called the second predicted conversion index of the a-th object for the b-th resource.
  • the second predicted conversion index of the a-th object for the b-th resource for:
  • sigmoid represents the activation function (an S-shaped function)
  • W 5 represents the parameter matrix of the prediction network (usually different from the above W 4 ), which belongs to the network parameters and will be continuously updated during the training process.
  • b 5 is the bias vector (usually Different from b 4 above)
  • e′ a represents the second object embedding feature of the a-th object
  • e′ b represents the second resource embedding feature of the b-th resource
  • represents splicing.
  • the second conversion prediction loss value can be recorded as L z2 , as shown in the following formula (15), the second conversion prediction loss value L z2 is:
  • Y a, b represents the actual conversion tag between the above-mentioned a-th object and the b-th resource.
  • the conversion tag indicates whether the a-th object actually has conversion behavior for the b-th resource.
  • the above formula (14 ) to generate the conversion index of the above prediction object for prediction resources.
  • This process requires replacing the second object embedding feature of the a-th object with the second object embedding feature of the prediction object generated by the trained prediction network, It is also necessary to replace the second resource embedding feature of the b-th resource with the second resource embedding feature of the predicted resource generated by the trained prediction network.
  • Step S304 Generate the regularization loss of the prediction network based on the first object embedding feature of each object, the second object embedding feature of each object, the first resource embedding feature of each resource, and the second resource embedding feature of each resource. value.
  • the computer device may also generate a regularization of the prediction network based on the first object embedding feature of each object, the second object embedding feature of each object, the first resource embedding feature of each resource, and the second resource embedding feature of each resource. loss value. Should The regular loss value is used to ensure that the feature space learned by transforming heterogeneous graphs and homogeneous graphs (such as the above-mentioned first object embedding features, second object embedding features, first resource embedding features, and second resource embedding features) is located space) on the surface of the unit sphere to avoid overfitting of the prediction network.
  • heterogeneous graphs and homogeneous graphs such as the above-mentioned first object embedding features, second object embedding features, first resource embedding features, and second resource embedding features
  • the regular loss value can be recorded as L R , as shown in the following formula (16), the regular loss value L R is:
  • ⁇ 1 , ⁇ 2 , ⁇ 3 and ⁇ 4 are all hyperparameters and can be defined in advance.
  • 2 represents the second norm.
  • Step S305 Determine the prediction loss value based on the feature generalization loss value, the first transformation prediction loss value, the second transformation prediction loss value and the regularization loss value.
  • the computer device can generate (such as weighted summation) the final prediction loss value of the prediction network through the obtained feature generalization loss value, the first transformation prediction loss value, the second transformation prediction loss value and the regularization loss value.
  • L z2 is the second transformation prediction loss value generated above
  • L s is the above feature generalization loss value
  • L z1 is the above first transformation prediction loss value
  • LR is the above regularization loss value.
  • is a predefined hyperparameter used to control the loss weight of L s ;
  • is also a predefined hyperparameter used to control the loss weight of L z1 .
  • the above L, L z2 , L s , L z1 and L R all belong to the loss function.
  • this application uses the second conversion prediction loss value L z2 as the main loss value.
  • this application can only use the transformation heterogeneous graph of objects and resources when training the prediction network. After obtaining the trained prediction network, there is no need to use the transformation heterogeneity graph of objects and resources, but use the object and resource transformation heterogeneous graphs.
  • the homogeneity graph of the resource is used to predict the conversion index of the object for the resource.
  • the needs are first generated
  • the second object embedding feature of the predicted object and the second resource embedding feature of the resource to be predicted are subsequently generated through the second object embedding feature and the second resource embedding feature (as indicated by the above formula (14))
  • the object's conversion index against the resource is first generated
  • Figure 10 is a schematic diagram of a scenario for generating a prediction loss value provided by this application.
  • the computer device can generate a feature generalization loss value through the first object embedding feature and the second object embedding feature of each object, and the first resource embedding feature and the second resource embedding feature of each resource; the computer device also The first conversion prediction loss value can be generated through the first object embedding feature of each object and the first resource embedding feature of each resource; the computer device can also use the second object embedding feature of each object and the second resource embedding feature of each resource.
  • the computer device can also use the first object embedding feature and the second object embedding feature of each object, and the first resource of each resource.
  • the source embedding feature and the second resource embedding feature generate a regular loss value.
  • the computer device can generate the prediction loss value of the prediction network through the above-mentioned feature generalization loss value, the first transformation prediction loss value, the second transformation prediction loss value and the regularization loss value.
  • the training effect of the prediction network in all aspects can be improved.
  • the loss value L s can be generalized based on the above characteristics.
  • the supervised method generalizes the feature space of homogeneous graphs to transform the feature space of heterogeneous graphs.
  • Figure 11 is a schematic diagram of a model training scenario provided by this application.
  • this application can construct the user's homogeneous graph through the user's multi-dimensional feature label (used to indicate the user's multi-dimensional features, that is, multi-dimensional object features), and obtain the user's homogeneous graph through the user's homogeneous graph in the prediction network.
  • Activating the subgraph ie, the above-mentioned first activation subgraph
  • the user's embedded features such as the above-mentioned second object embedded features
  • this application can also construct a homogeneous graph of advertisements through the multi-dimensional feature labels of advertisements (i.e. resources) (used to indicate the multi-dimensional advertising characteristics of advertisements, i.e. multi-dimensional resource characteristics), and use the homogeneous graph of advertisements in the prediction network
  • the activation subgraph of the advertisement ie, the above-mentioned second activation subgraph
  • the embedded feature of the advertisement such as the above-mentioned second resource embedding feature
  • This application can construct a conversion heterogeneous graph between users and advertisements, and can also transfer information between nodes in the conversion heterogeneous graph through user identification (i.e., object identification) and advertising identification (i.e., resource identification) (through mapping). to the corresponding hash space) to obtain the user's embedding characteristics (such as the above-mentioned first object embedding characteristics) and the advertisement's embedding characteristics (such as the above-mentioned first resource embedding characteristics).
  • user identification i.e., object identification
  • advertising identification i.e., resource identification
  • mapping through mapping
  • the prediction network can perform self-supervised learning through the user's first object embedding feature, the user's second object embedding feature, the advertisement's first resource embedding feature, and the advertisement's second resource embedding feature (the loss can be generalized through the above features) value), the transformation prediction loss can also be learned through the user's first object embedding feature, the user's second object embedding feature, the advertisement's first resource embedding feature, and the advertisement's second resource embedding feature (the above-mentioned first The transformation prediction loss value and the second transformation prediction loss value are reflected).
  • the trained prediction network can be learned through the learning of regular loss (which can be reflected by the above-mentioned regular loss value).
  • this application can also be applied in the field of game recommendation.
  • the above-mentioned N objects can be N users, and the M resources can be M game applications that can be recommended to users.
  • the objects are targeted at the transformation of resources.
  • the behavior can be the behavior of the user who has registered for the game application.
  • a user registers a user account in a game application, the user has conversion behavior for the game application, and the user's node (i.e., object node) and the node of the game application (i.e., resource node) are in transformation. There are connected edges in the quality graph.
  • the user does not register a user account in a game application, the user does not have conversion behavior for the game application, and the conversion behavior of the user's nodes and the nodes of the game application is heterogeneous. There are no connected edges in the picture.
  • this application can also obtain the homogeneous graph of each user (i.e., object homogeneity graph) and the homogeneous graph of each game application (i.e., resource homogeneity graph), and then combine the transformation heterogeneous graph of users and game applications, user
  • the prediction network is trained with homogeneous graphs and homogeneous graphs of game applications to obtain a trained prediction network.
  • the trained prediction network can accurately predict the conversion index of any user for any game application.
  • the first condition of the user's conversion behavior to game applications is taken into account.
  • the second condition is the characteristics of each user and each game application (reflected through homogeneous graphs), so that in the process of training the prediction network, the prediction network can transfer the features learned based on these two conditions to each other. In this way, a very accurate prediction network can be trained.
  • the method provided by this application can also well solve the user cold start problem in the field of game recommendation. For example, when there is a new user, the new user has no interest in most or all of the M game applications. Does not have conversion behavior (if the new user belongs to the users in N objects, the node of the new user is a relatively isolated node in the conversion heterogeneous graph), and the prediction network obtained through training can also accurately predict the The new user's conversion index for each game application can be used to accurately recommend game applications to the new user.
  • this application can use the data from days -9 to -3 of a certain date in the past as the training set, the data from day -2 as the verification set, and the data from day -1 as the test set. set. Observe the training results of any 10 dates and compare the results of the multi-domain self-attention model. The experimental results are shown in Table 1 below:
  • the indicators under the above-mentioned self-supervision graph are indicators obtained by using the method provided by this application.
  • the test of Acc, AUC and AUCG in this application is in most cases There is a big improvement in both.
  • the data processing device may be a computer program (including program code) running in a computer device.
  • the data processing device may be an application software.
  • the data processing device may be used to execute corresponding steps in the method provided by the embodiments of the present application.
  • the data processing device 1 may include: a first acquisition module 11 , a second acquisition module 12 , a third acquisition module 13 and a training module 14 .
  • the first acquisition module 11 is used to obtain the transformation heterogeneous graph;
  • the transformation heterogeneous graph contains N object nodes and M resource nodes.
  • Each object node represents an object, and each resource node represents a resource.
  • N and M are all positive integers; if any object among N objects has transformation behavior for any resource among M resources, then the object node of any object and the resource node of any resource have connecting edges in the transformation heterogeneous graph;
  • the second acquisition module 12 is used to obtain the object homogeneity graph corresponding to each object among the N objects; any object homogeneity graph contains multiple object feature nodes, and any object feature node is used to represent the corresponding object in one dimension. object characteristics;
  • the third acquisition module 13 is used to obtain the resource homogeneity graph corresponding to each resource in the M resources; any resource homogeneity graph contains multiple resource feature nodes, and any resource feature node is used to represent the corresponding resource in one dimension. resource characteristics;
  • the training module 14 is used to train the prediction network based on the transformation heterogeneous graph, the object homogeneity graph of each object and the resource homogeneity graph of each resource, to obtain a trained prediction network; the trained prediction network is used to predict the object for Resource conversion index.
  • the training module 14 trains the prediction network based on the transformation heterogeneous graph, the object homogeneity graph of each object, and the resource homogeneity graph of each resource, and obtains a trained prediction network, including:
  • the call prediction network generates the second resource embedding feature of each resource separately based on the resource homogeneity graph of each resource;
  • the prediction network is trained according to the first object embedding feature of each object, the second object embedding feature of each object, the first resource embedding feature of each resource, and the second resource embedding feature of each resource, and the trained prediction network is obtained .
  • the training module 14 calls the prediction network to generate the first object embedding feature of each object and the first resource embedding feature of each resource based on the transformed heterogeneous graph, including:
  • the transformation heterogeneous graph is expressed as a relationship matrix; the relationship matrix is used to indicate the edge relationship between resource nodes and object nodes in the transformation heterogeneous graph;
  • a first object embedding feature for each object and a first resource embedding feature for each resource are generated based on the embedding feature matrix.
  • the training module 14 generates the first object embedding feature of each object and the first resource embedding feature of each resource based on the embedding feature matrix, including:
  • the first object embedding feature of each object and the first resource embedding feature of each resource are extracted from the target embedding feature matrix.
  • Any one of the N objects is represented as a target object, and there is a connecting edge between any two object feature nodes in the object homogeneity graph of the target object;
  • the training module 14 calls the prediction network to generate the second object embedding features of each object based on the object homogeneity map of each object, including:
  • the second object embedding feature of the target object is generated according to node features respectively corresponding to each object feature node of the target object.
  • Any one of the M resources is represented as a target resource, and there is a connecting edge between any two resource feature nodes in the resource homogeneity graph of the target resource;
  • the training module 14 calls the prediction network to generate the second resource embedding feature of each resource based on the resource homogeneity graph of each resource, including:
  • the second resource embedding feature of the target resource is generated according to node features respectively corresponding to each resource feature node of the target resource.
  • the training module 14 trains the prediction network based on the first object embedding feature of each object, the second object embedding feature of each object, the first resource embedding feature of each resource, and the second resource embedding feature of each resource, and obtains a well-trained Predictive network methods include:
  • the training module 14 generates a prediction loss of the prediction network based on the first object embedding feature of each object, the second object embedding feature of each object, the first resource embedding feature of each resource, and the second resource embedding feature of each resource.
  • Value methods include:
  • the feature generalization loss value is used to indicate the feature difference between the first object embedding feature and the second object embedding feature of each object, and is used to indicate the feature difference between the first resource embedding feature and the second resource embedding feature of each resource. differences in characteristics;
  • the prediction loss value is determined based on the feature generalization loss value, the first transformation prediction loss value, the second transformation prediction loss value and the regularization loss value.
  • the training module 14 generates a feature general feature of the prediction network based on the first object embedding feature of each object, the second object embedding feature of each object, the first resource embedding feature of each resource, and the second resource embedding feature of each resource.
  • Methods of converting loss values include:
  • a feature generalization loss value is generated based on the first generalization loss value and the second generalization loss value.
  • the training module 14 generates the first transformation prediction loss value of the prediction network based on the first object embedding feature of each object and the first resource embedding feature of each resource, including:
  • a first predicted conversion loss value is generated based on the first predicted conversion index of each object for each resource and the conversion behavior of each object for each resource.
  • the training module 14 generates a second transformation prediction loss value of the prediction network based on the second object embedding feature of each object and the second resource embedding feature of each resource, including:
  • a second predicted conversion loss value is generated based on the second predicted conversion index of each object for each resource and the conversion behavior of each object for each resource.
  • the above device 1 is also used for:
  • the prediction resource will be pushed to the prediction object.
  • the steps involved in the data processing method shown in Figure 3 can be performed by various modules in the data processing device 1 shown in Figure 12 .
  • step S101 shown in FIG. 3 can be performed by the first acquisition module 11 in FIG. 12
  • step S102 shown in FIG. 3 can be performed by the second acquisition module 12 in FIG. 12
  • Step S103 may be performed by the third acquisition module 13 in FIG. 12
  • step S104 shown in FIG. 3 may be performed by the training module 14 in FIG. 12 .
  • This application can obtain the transformation heterogeneous graph; the transformation heterogeneous graph contains object nodes of N objects and resource nodes of M resources, where N and M are both positive integers; if any object among the N objects If a resource has transformation behavior, then the object node of any object and the resource node of any resource have connected edges in the transformation heterogeneous graph; obtain the object homogeneity graph corresponding to each object in the N objects; any object has the same
  • the homogeneity graph contains multiple object feature nodes, and any object feature node is used to represent the object characteristics of the corresponding object in one dimension; the resource homogeneity graph corresponding to each resource in the M resources is obtained; any resource homogeneity graph contains Multiple resource feature nodes, any resource feature node is used to represent the resource features of the corresponding resource in one dimension; the prediction network is trained based on the transformation heterogeneous graph, the object homogeneity graph of each object and the resource homogeneity graph of each resource , to obtain a trained prediction network; the trained prediction network is
  • the device proposed in this application can simultaneously combine the heterogeneous graph of objects and resources, the homogeneous graph of objects and the homogeneous graph of resources to train the prediction network, so that when training the prediction network, for each object and each resource (simultaneously Characteristics including objects and resources that do not have access behavior between them and objects and resources that have access behavior between them can be effectively propagated, so the accuracy of the prediction network obtained by training can be improved, and the prediction network obtained by training can also Achieve accurate prediction of the object's conversion index for resources.
  • each module in the data processing device 1 shown in Figure 12 can be separately or entirely combined into one or several units, or some of the units can be further divided into Multiple subunits with smaller functions can implement the same operation without affecting the realization of the technical effects of the embodiments of the present application.
  • the above modules are divided based on logical functions.
  • the function of one module can also be realized by multiple units, or the functions of multiple modules can be realized by one unit.
  • the data processing device 1 may also include other units.
  • these functions may also be implemented with the assistance of other units, and may be implemented by multiple units in cooperation.
  • the method can be run on a general computer device such as a computer including a central processing unit (CPU), a random access storage medium (RAM), a read-only storage medium (ROM), and other processing elements and storage elements.
  • a computer program (including program code) capable of executing the steps involved in the corresponding method as shown in Figure 3, to construct the data processing device 1 as shown in Figure 12, and to implement the data processing method of the embodiment of the present application.
  • the above-mentioned computer program may be recorded on, for example, a computer-readable storage medium, loaded into the above-mentioned computing device through the computer-readable storage medium, and run therein.
  • the computer device 1000 may include: a processor 1001, a network interface 1004 and a memory 1005.
  • the computer device 1000 may also include: a user interface 1003, and at least one communication bus 1002.
  • the communication bus 1002 is used to realize connection communication between these components.
  • the user interface 1003 may include a display screen (Display) and a keyboard (Keyboard), and the user interface 1003 may also include a standard wired interface and a wireless interface.
  • the network interface 1004 may include standard wired interfaces and wireless interfaces (such as WI-FI interfaces).
  • the memory 1005 may be a high-speed RAM memory or a non-transitory memory, such as at least one disk memory.
  • the memory 1005 may also be at least one storage device located remotely from the aforementioned processor 1001.
  • memory 1005, which is a computer storage medium, may include an operating system, a network communication module, a user interface module, and a device control application program.
  • the network interface 1004 can provide network communication functions;
  • the user interface 1003 is mainly used to provide an input interface for the user; and
  • the processor 1001 can be used to call the device control application stored in the memory 1005 program to achieve:
  • the transformation heterogeneous graph contains N object nodes and M resource nodes, each object node represents its own An object, each resource node represents a resource, and N and M are both positive integers; if any object among the N objects has conversion behavior for any of the M resources, then the object node of any object is the same as any
  • the resource nodes of resources have connected edges in the transformation heterogeneous graph;
  • any object homogeneity graph contains multiple object feature nodes, and any object feature node is used to represent the object features of the corresponding object in one dimension;
  • any resource homogeneity graph contains multiple resource feature nodes, and any resource feature node is used to represent the resource characteristics of the corresponding resource in one dimension;
  • the prediction network is trained based on the transformation heterogeneous graph, the object homogeneity graph of each object, and the resource homogeneity graph of each resource to obtain a trained prediction network; the trained prediction network is used to predict the conversion index of the object for the resource.
  • the computer device 1000 described in the embodiment of the present application can perform the description of the above-mentioned data processing method in the embodiment corresponding to FIG. 3, and can also perform the description of the above-mentioned data processing device 1 in the embodiment corresponding to FIG. 12. , which will not be described in detail here.
  • the description of the beneficial effects of using the same method will not be described again.
  • this application also provides a computer-readable storage medium, and the computer-readable storage medium stores the computer program executed by the aforementioned data processing device 1, and the computer program includes program instructions.
  • the processor executes the program instructions, it can execute the previous description of the data processing method in the embodiment corresponding to Figure 3, therefore, the details will not be described again here.
  • the computer storage medium embodiments involved in this application please refer to the description of the method embodiments in this application.
  • the above program instructions may be deployed for execution on one computer device, or on multiple computer devices located at one location, or on multiple computers distributed at multiple locations and interconnected through a communication network.
  • Executed on the device, multiple computer devices distributed in multiple locations and interconnected through a communication network can form a blockchain network.
  • the above-mentioned computer-readable storage medium may be the data processing apparatus provided in any of the foregoing embodiments or the internal storage unit of the above-mentioned computer equipment, such as the hard disk or memory of the computer equipment.
  • the computer-readable storage medium can also be an external storage device of the computer device, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card equipped on the computer device, Flash card, etc.
  • the computer-readable storage medium may also include both an internal storage unit of the computer device and an external storage device.
  • the computer-readable storage medium is used to store the computer program and other programs and data required by the computer device.
  • the computer-readable storage medium can also be used to temporarily store data that has been output or is to be output.
  • the present application provides a computer program product or computer program, which includes computer instructions 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 performs the description of the above-mentioned data processing method in the corresponding embodiment of Figure 3. Therefore, the description will not be repeated here. Elaborate. For technical details not disclosed in the computer-readable storage medium embodiments involved in this application, please refer to the description of the method embodiments in this application.
  • each process and/or the method flowcharts and/or structural schematic diagrams can be implemented by computer program instructions. or blocks, and combinations of processes and/or blocks in flowcharts and/or block diagrams.
  • These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing device to produce a machine, such that the instructions executed by the processor of the computer or other programmable data processing device produce a use A device for realizing the functions specified in one process or multiple processes in the flowchart and/or one block or multiple blocks in the structural diagram.
  • These computer program instructions may also be stored in a computer-readable memory that causes a computer or other programmable data processing apparatus to operate in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including the instruction means, the instructions
  • the device implements the functions specified in one process or multiple processes in the flowchart and/or in one block or multiple blocks in the structural diagram.
  • These computer program instructions may also be loaded onto a computer or other programmable data processing device, causing a series of operating steps to be performed on the computer or other programmable device to produce computer-implemented processing, thereby executing on the computer or other programmable device. Instructions provide steps for implementing the functions specified in a process or processes of a flowchart and/or a block or blocks of a structural diagram.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Artificial Intelligence (AREA)
  • Evolutionary Computation (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Software Systems (AREA)
  • Mathematical Physics (AREA)
  • Computing Systems (AREA)
  • Molecular Biology (AREA)
  • General Health & Medical Sciences (AREA)
  • Computational Linguistics (AREA)
  • Biophysics (AREA)
  • Biomedical Technology (AREA)
  • Health & Medical Sciences (AREA)
  • Business, Economics & Management (AREA)
  • Strategic Management (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Economics (AREA)
  • Evolutionary Biology (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Human Resources & Organizations (AREA)
  • Entrepreneurship & Innovation (AREA)
  • General Business, Economics & Management (AREA)
  • Quality & Reliability (AREA)
  • Operations Research (AREA)
  • Tourism & Hospitality (AREA)
  • Marketing (AREA)
  • Game Theory and Decision Science (AREA)
  • Development Economics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

本申请公开了一种数据处理方法、装置、程序产品、计算机设备和介质,该方法由计算机设备执行,包括:获取包含N个对象的对象节点和M个资源的资源节点的转化异质图;若对象对资源具有转化行为,则对象的对象节点与资源的资源节点在转化异质图中具有连边;获取每个对象对应的对象同质图;任一对象同质图包含对应对象在多个维度上的对象特征的对象特征节点;获取每个资源对应的资源同质图;任一资源同质图包含对应资源在多个维度上的资源特征的资源特征节点;基于转化异质图、每个对象的对象同质图和每个资源的资源同质图训练预测网络,得到训练好的预测网络;训练好的预测网络用于预测对象针对资源的转化指数。

Description

数据处理方法、装置、程序产品、计算机设备和介质
本申请要求于2022年5月5日提交中国专利局、申请号为202210479316.8、发明名称为“数据处理方法、装置、程序产品、计算机设备和介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及计算机技术领域,尤其涉及一种数据处理方法、装置、程序产品、计算机设备和介质。
发明背景
人工智能(Artificial Intelligence,AI)是利用数字计算机或者数字计算机控制的机器模拟、延伸和扩展人的智能,感知环境、获取知识并使用知识获得最佳结果的理论、方法、技术及应用系统。其中,人工智能中的机器学习就应用到了生活的方方面面。
现有应用中,在预测用户针对资源(如软件或者广告等)的转化指数时,通常可以通过已有的用户针对资源的转化行为来训练预测网络,进而通过训练好的预测网络来预测用户针对资源的转化指数。但是若是有用户对资源并不存在转化行为,或者资源不存在有用户对其具有转化行为,则在训练预测网络时该用户和该资源的特征将无法进行有效传递,进而导致训练得到的预测网络也不能对用户针对资源的转化指数进行准确预测。
发明内容
本申请提供了一种数据处理方法、装置、程序产品、计算机设备和介质,可提升训练得到的预测网络的准确性,以采用训练得到的预测网络对对象针对资源的转化指数进行准确预测。
本申请一方面提供了一种数据处理方法,由计算机设备执行,该方法包括:
获取转化异质图;转化异质图包含N个对象节点和M个资源节点,每个对象节点各自表示一个对象,每个资源节点各自表示一个资源,N和M均为正整数;若N个对象中任一对象对M个资源中任一资源具有转化行为,则任一对象的对象节点与任一资源的资源节点在转化异质图中具有连边;
获取N个对象中每个对象分别对应的对象同质图;任一对象同质图包含多个对象特征节点,任一对象特征节点用于表示对应对象在一个维度上的对象特征;
获取M个资源中每个资源分别对应的资源同质图;任一资源同质图包含多个资源特征节点,任一资源特征节点用于表示对应资源在一个维度上的资源特征;
基于转化异质图、每个对象的对象同质图和每个资源的资源同质图训练预测网络,得到训练好的预测网络;训练好的预测网络用于预测对象针对资源的转化指数。
本申请一方面提供了一种数据处理装置,该装置包括:
第一获取模块,用于获取转化异质图;转化异质图包含N个对象节点和M个资源节点,每个对象节点各自表示一个对象,每个资源节点各自表示一个资源,N和M均为正整数;若N个对象中任一对象对M个资源中任一资源具有转化行为,则任一对象的对象节点与任一资源的资源节点在转化异质图中具有连边;
第二获取模块,用于获取N个对象中每个对象分别对应的对象同质图;任一对象同质图包含多个对象特征节点,任一对象特征节点用于表示对应对象在一个维度上的对象特征;
第三获取模块,用于获取M个资源中每个资源分别对应的资源同质图;任一资源同质图包含多个资源特征节点,任一资源特征节点用于表示对应资源在一个维度上的资源特征;
训练模块,用于基于转化异质图、每个对象的对象同质图和每个资源的资源同质图训练预测网络,得到训练好的预测网络;训练好的预测网络用于预测对象针对资源的转化指数。
本申请一方面提供了一种计算机设备,包括存储器和处理器,存储器存储有计算机程序,计算机程序被处理器执行时,使得处理器执行本申请中一方面中的方法。
本申请一方面提供了一种计算机可读存储介质,该计算机可读存储介质存储有计算机程序,该计算机程序包括程序指令,该程序指令被处理器执行时使该处理器执行上述一方面中的方法。
根据本申请的一个方面,提供了一种计算机程序产品或计算机程序,该计算机程序产品或计算机程序包括计算机指令,该计算机指令存储在计算机可读存储介质中。计算机设备的处理器从计算机可读存储介质读取该计算机指令,处理器执行该计算机指令,使得该计算机设备执行上述一方面等各种方式中提供的方法。
附图简要说明
为了更清楚地说明本申请或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是本申请提供的一种网络架构的结构示意图;
图2是本申请提供的一种数据处理的场景示意图;
图3是本申请提供的一种数据处理方法的流程示意图;
图4是本申请提供的一种生成转化异质图的场景示意图;
图5是本申请提供的一种生成对象同质图的场景示意图;
图6是本申请提供的一种生成资源同质图的场景示意图;
图7是本申请提供的一种模型训练方法的流程示意图;
图8是本申请提供的一种网络训练的场景示意图;
图9是本申请提供的一种损失生成方法的流程示意图;
图10是本申请提供的一种生成预测损失值的场景示意图;
图11是本申请提供的一种模型训练的场景示意图;
图12是本申请提供的一种数据处理装置的结构示意图;
图13是本申请提供的一种计算机设备的结构示意图。
实施方式
下面将结合本申请中的附图,对本申请中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
本申请涉及到人工智能相关技术。其中,人工智能(Artificial Intelligence,AI)是利用数字计算机或者数字计算机控制的机器模拟、延伸和扩展人的智能,感知环境、获取知识并使用知识获得最佳结果的理论、方法、技术及应用系统。换句话说,人工智能是计算机科学的一个综合技术,它企图了解智能的实质,并生产出一种新的能以人类智能相似的方式做出反应的智能机器。人工智能也就是研究各种智能机器的设计原理与实现方法,使机器具有感知、推理与决策的功能。
人工智能技术是一门综合学科,涉及领域广泛,既有硬件层面的技术也有软件层面的技术。人工智能基础技术一般包括如传感器、专用人工智能芯片、云计算、分布式存储、大数据处理技术、操作/交互系统、机电一体化等技术。人工智能软件技术主要包括计算机视觉技术、语音处理技术、自然语言处理技术以及机器学习/深度学习等几大方向。
本申请中主要涉及到了人工智能中的机器学习。其中,机器学习(Machine Learning,ML)是一门多领域交叉学科,涉及概率论、统计学、逼近论、凸分析、算法复杂度理论等多门学科,专门研究计算机怎样模拟或实现人类的学习行为,以获取新的知识或技能,重新组织已有的知识结构使之不断改善自身的性能。机器学习是人工智能的核心,是使计算机具有智能的根本途径,其应用遍及人工智能的各个领域。机器学习和深度学习通常包括人工神经网络、置信网络、强化学习、迁移学习、归纳学习、式教学习等技术。
本申请中所涉及到的机器学习主要指,如何训练预测模型(即预测网络),以通过训练好的预测模型来预测对象针对资源的转化指数,具体可以参见下述图3对应的实施例中的描述。
本申请涉及到云技术。其中,云技术(Cloud Technology)是指在广域网或局域网内将硬件、软件、网络等系列资源统一起来,实现数据的计算、储存、处理和共享的一种托管技术。
云技术是基于云计算商业模式应用的网络技术、信息技术、整合技术、管理平台技术、应用技术等的总称,可以组成资源池,按需所用,灵活便利。云计算技术将变成重要支撑。技术网络系统的后台服务需要大量的计算、存储资源,如视频网站、图片类网站和更多的门户网站。 伴随着互联网行业的高度发展和应用,将来每个物品都有可能存在自己的识别标志,都需要传输到后台系统进行逻辑处理,不同程度级别的数据将会分开处理,各类行业数据皆需要强大的系统后盾支撑,只能通过云计算来实现。本申请中所涉及到的云技术可以指后台可以通过“云”向对象的前端推送资源。
首先,需要进行说明的是,本申请在收集用户的相关数据(如下述用户针对资源的转化行为及用户的特征等用户数据)之前以及在收集用户的相关数据的过程中,都可以显示提示界面或者弹窗,该提示界面或者弹窗用于提示用户当前正在搜集其相关数据,使得本申请仅仅在获取到用户对该提示界面或者弹窗发出的确认操作后,才开始执行获取用户相关数据的相关步骤,否则(即未获取到用户对该提示界面或者弹窗发出的确认操作时),结束获取用户相关数据的相关步骤,即不获取用户的相关数据。换句话说,本申请所采集的所有用户数据都是在用户同意并授权的情况下进行采集的,且相关用户数据的收集、使用和处理需要遵守相关国家和地区的相关法律法规和标准。
此处,对本申请所涉及到的相关概念进行解释:
转化率(conversion rate,CVR):广告曝光后用户成功转化的概率,成功转化通常指完成对目标商品的购买等行为。该转化率可以是下述转化指数。
同质图(Homogeneous graph):顶点和边都只有一种类型的图。
异质图(Heterogeneous graph):顶点和边的类型大于或等于两种的图。
二部图(bipartite graph):图的顶点集可以被分割成两个互不相交的子集,图中每条边两端的顶点(如下述中的对象节点或者资源节点)都属于不同的两个子集,并且同一个子集中的顶点不相邻。
自监督(self-supervised):无需对数据进行人工标注,直接从无标签数据中获得监督信号用于学习的一种方法。
请参见图1,图1是本申请提供的一种网络架构的结构示意图。如图1所示,网络架构可以包括服务器200和终端设备集群,终端设备集群可以包括一个或者多个终端设备,这里将不对终端设备的数量进行限制。如图1所示,多个终端设备具体可以包括终端设备100a、终端设备101a、终端设备102a、…、终端设备103a;如图1所示,终端设备100a、终端设备101a、终端设备102a、…、终端设备103a均可以与服务器200进行网络连接,以便于每个终端设备可以通过网络连接与服务器200之间进行数据交互。
如图1所示的服务器200可以是独立的物理服务器,也可以是多个物理服务器构成的服务器集群或者分布式系统,还可以是提供云服务、云数据库、云计算、云函数、云存储、网络服务、云通信、中间件服务、域名服务、安全服务、内容分发网络(Content Delivery Network,CDN)、以及大数据和人工智能平台等基础云计算服务的云服务器。终端设备可以是:智能手机、平板电脑、笔记本电脑、桌上型电脑、智能电视、车载终端等智能终端。下面以终端设备100a与服务器200之间的通信为例,进行本申请实施例的具体描述。
请一并参见图2,图2是本申请提供的一种数据处理的场景示意图。如图2所示上述终端设备100a、终端设备101a、终端设备102a、…、终端设备103a可以是各个用户(可以是下述对象)所持有的终端设备,终端设备中可以包含应用程序,应用程序的应用页面上可以显示若干 广告(可以是下述资源),用户可以通过所持有的终端设备在应用程序的应用页面购买广告中所推荐的商品。服务器200可以是该应用程序的后台服务器,服务器200可以获取到用户针对广告中所推荐的商品的购买行为(可以称之为是用户针对广告的转化行为),进而,服务器200可以通过各个用户针对各个广告中的商品的购买行为构建转化异质图,该转化异质图中包含用户的用户节点和广告的广告节点,若一个用户对一个广告中的商品具有购买行为,则该转化异质图中该用户的用户节点与该广告的广告节点之间就具有连边。
进而,服务器200还可以根据各个用户的对象特征构建各个用户分别对应的同质图(包含用户的特征节点,可以称为对象特征节点),并可以根据各个广告的广告特征构建各个广告分别对应的同质图(包含广告的特征节点,可以称为资源特征节点)。
进而,服务器200可以结合上述转化异质图、各个用户的同质图以及各个广告的同质图来一同训练预测网络,进而得到训练好的预测网络,训练好的预测网络就可以用于预测用户针对广告的转化指数,该转化指数表征了用户购买广告中所推荐的商品的概率。该过程可以参见下述图3对应实施例中的相关描述。
本申请中,通过结合上述转化异质图、各个用户的同质图以及各个广告的同质图来一同训练预测网络,可以使得预测网络对于转化异质图中较为孤立的节点(用户节点或者广告节点)对应的特征也能进行有效学习,提升了所训练得到的预测网络的准确性,进而提升了对用户针对广告的转化指数的预测准确性。
请参见图3,图3是本申请提供的一种数据处理方法的流程示意图。本申请实施例中的执行主体可以是一个计算机设备或者多个计算机设备所构成的计算机设备集群,该计算机设备可以是服务器,也可以终端设备。下述将本申请中的执行主体统称为计算机设备为例进行说明。如图3所示,该方法可以包括:
步骤S101,获取转化异质图;转化异质图包含N个对象节点和M个资源节点,每个对象节点各自表示一个对象,每个资源节点各自表示一个资源,N和M均为正整数;若N个对象中任一对象对M个资源中任一资源具有转化行为,则任一对象的对象节点与任一资源的资源节点在转化异质图中具有连边。
计算机设备可以获取到转化异质图,顾名思义,该转化异质图是一个异质图,该转化异质图可以包括N个对象节点以及M个资源节点,每个对象节点各自表示一个对象,每个资源节点各自表示一个资源,换句话说,共有N个对象和M个资源,一个对象在转化异质图中可以有一个对象节点,一个资源在转化异质图中可以有一个资源节点,N和M均为正整数,N和M的具体取值根据实际应用场景确定,对此不做限制。该N个对象和M个资源可以是任意一个应用平台中的对象和资源。
其中,对象可以是指用户,资源可以是指可以向用户进行推荐或者推送的任意数据。例如,资源可以是广告数据,该广告数据可以用于向用户推荐相应的产品,该产品可以是可以购买的商品(如洗发水、护手霜、遮阳帽或者墨镜等等),或者,该产品还可以是可以下载安装的应用程序(如软件(app))。资源具体是什么数据可以根据实际应用场景确定,对此不做限制。
其中,若N个对象中的任一对象对M个资源中的任一资源具有转化行为,则该任一对象的对象节点与该任一资源的资源节点在转化异质图中具有连边(即该对象节点和该资源节点在转 化异质图中是相互连接的)。换句话说,若某个对象对某个资源具有转化行为,则转化异质图中该对象的对象节点与该资源的资源节点之间具有连边(相互连接)。
对象针对资源的转化行为可以根据实际应用场景确定。例如,若资源是针对商品的广告数据,则对象对资源的转化行为可以是指对象购买了广告数据中所推荐的商品;再如,若资源是针对软件的推荐数据(也可以属于广告数据),则对象对资源的转化行为可以是指对象下载安装了该推荐数据中所推荐的软件。
其中,上述转化异质图也属于非完全(即顶点之间并不完全连接)的二部图,转化异质图中包括两种类型的顶点(即节点),一种是对象的对象节点,一种是资源的资源节点,在转化异质图中,若一个对象对一个资源具有转化行为,则转化异质图中该对象的对象节点与该资源的资源节点之间具有连边,否则,即该对象对该资源不具有转化行为,则转化异质图中该对象的对象节点与该资源的资源节点之间就不具有连边。
请参见图4,图4是本申请提供的一种生成转化异质图的场景示意图。如图4所示,上述N个对象可以包括对象1~对象9,上述M个资源可以包括资源1~资源5。其中,对象1对资源1具有转化行为,因此转化异质图中对象1的对象节点1与资源1的资源节点1具有连边;对象2对资源3具有转化行为,因此转化异质图中对象2的对象节点2与资源3的资源节点3具有连边;对象3对任一个资源都不具有转化行为,因此转化异质图中对象3的对象节点3与任一资源的资源节点都不具有连边。
更多的,对象4对资源1具有转化行为,因此转化异质图中对象4的对象节点4与资源1的资源节点1具有连边;对象5对资源4具有转化行为,因此转化异质图中对象5的对象节点5与资源4的资源节点4具有连边;对象6对资源1和资源3具有转化行为,因此转化异质图中对象6的对象节点6与资源1的资源节点1具有连边,且对象6的对象节点6与资源3的资源节点3具有连边;对象7对资源4具有转化行为,因此转化异质图中对象7的对象节点7与资源4的资源节点4具有连边。
更多的,对象8对资源5具有转化行为,因此转化异质图中对象8的对象节点8与资源5的资源节点5具有连边;对象9对任一个资源都不具有转化行为,因此转化异质图中对象9的对象节点9与任一资源的资源节点都不具有连边。
步骤S102,获取N个对象中每个对象分别对应的对象同质图;任一对象同质图包含多个对象特征节点,任一对象特征节点用于表示对应对象在一个维度上的对象特征。
计算机设备可以获取到上述N个对象中每个对象分别对应的同质图,可以将对象的同质图称之为是对象同质图,一个对象可以具有一个对象同质图。任一个对象同质图可以包含多个特征节点,可以将对象同质图中的特征节点称之为是对象特征节点,任一个对象特征节点用于表示对应对象在一个维度上的对象特征。
其中,对象的对象同质图可以是完全图,即任一个对象同质图中两两对象特征节点之间都可以是相互连接的。
例如,对象可以有多个维度(即多维)的对象特征,该多维对象特征可以包括对象年龄的特征、对象所在城市的特征及对象工作的特征,则对象的对象同质图中可以包含对象年龄的特征节点、对象所在城市的特征节点以及对象工作的特征节点。
其中,对象的多维对象特征具体是什么特征可以根据实际应用场景进行设置,对象的一维对象特征可以对应对象的对象同质图中一个对象特征节点。不同对象的多维对象特征可以相同,也可以不相同,具体根据实际应用场景确定。
请参见图5,图5是本申请提供的一种生成对象同质图的场景示意图。若一个对象具有多个维度(包括第1个维度~第5个维度)的对象特征,那么构建的该对象的对象同质图中就可以包括该对象在第1个维度上的对象特征对应的对象特征节点、该对象在第2个维度上的对象特征对应的对象特征节点、该对象在第3个维度上的对象特征对应的对象特征节点、该对象在第4个维度上的对象特征对应的对象特征节点及该对象在第5个维度上的对象特征对应的对象特征节点,这5个对象特征节点之间两两相连。
步骤S103,获取M个资源中每个资源分别对应的资源同质图;任一资源同质图包含多个资源特征节点,任一资源特征节点用于表示对应资源在一个维度上的资源特征。
计算机设备可以获取到上述M个资源中每个资源分别对应的同质图,可以将资源的同质图称之为是资源同质图,一个资源可以具有一个资源同质图。任一个资源同质图可以包含多个特征节点,可以将资源同质图中的特征节点称之为是资源特征节点,任一个资源特征节点用于表示对应资源在一个维度上的资源特征。
其中,资源的资源同质图可以是完全图,即任一个资源同质图中两两资源特征节点之间都可以是相互连接的。
例如,资源可以有多个维度(即多维)的资源特征,该多维资源特征可以包括资源的资源风格的特征、资源所属领域的特征及资源类型的特征,则资源的资源同质图中可以包含资源风格的特征节点、资源所属领域的特征节点以及资源类型的特征节点。
其中,资源的多维资源特征具体是什么特征可以根据实际应用场景进行设置,资源的一维资源特征可以对应资源的资源同质图中一个资源特征节点。不同资源的多维资源特征可以相同,也可以不相同,具体根据实际应用场景确定。
请参见图6,图6是本申请提供的一种生成资源同质图的场景示意图。若一个资源具有多个维度(包括第1个维度~第6个维度)的资源特征,那么构建的该资源的资源同质图中就可以包括该资源在第1个维度上的资源特征对应的资源特征节点、该资源在第2个维度上的资源特征对应的资源特征节点、该资源在第3个维度上的资源特征对应的资源特征节点、该资源在第4个维度上的资源特征对应的资源特征节点、该资源在第5个维度上的资源特征对应的资源特征节点及该资源在第6个维度上的资源特征对应的资源特征节点,这6个资源特征节点之间两两相连。
步骤S104,基于转化异质图、每个对象的对象同质图和每个资源的资源同质图训练预测网络,得到训练好的预测网络;训练好的预测网络用于预测对象针对资源的转化指数。
转化异质图包含了对象与资源之间的转化关系,对象的同质图表征了对象本身的特征,资源的同质图表征了资源本身的特征,计算机设备可以根据上述获取到的转化异质图、每个对象 的对象同质图以及每个资源的资源同质图来训练预测网络,进而得到训练好的预测网络。其中,训练预测网络的具体过程也可以参见下述图7对应实施例中的相关描述。
其中,训练好的预测网络可以用于预测对象针对资源的转化指数,该转化指数表征了对象会对资源执行转化行为的概率,计算机设备可以根据所预测得到的各个对象针对各个资源的转化指数来确定对各个对象进行资源推送的策略(简称资源推送策略)。其中,若一个对象针对一个资源的转化指数越大,则表明该对象对该资源执行转化行为的概率越大,反之,若一个对象针对一个资源的转化指数越小,则表明该对象对该资源执行转化行为的概率越小。
例如,计算机设备可以获取到预测对象和预测资源,该预测对象可以是上述N个对象中的任一个,或者该预测对象也可以是新增的(即不属于N个对象中的任一个),同理,该预测资源可以是上述M个资源中的任一个,或者该预测资源也可以是新增的(即不属于M个资源中的任一个)。
进而,计算机设备可以获取到该预测对象的对象标识,并获取到预测资源的资源标识,并可以将该预测对象的对象标识以及预测资源的资源标识映射到统一的哈希空间,该哈希空间可以与下述步骤S201中N个对象的对象标识以及M个资源的资源标识所映射到的哈希空间相同,具体阐释可以参见下述步骤S201中的描述。
进而,计算机设备可以获取到预测对象的对象标签特征以及预测资源的资源标签特征,其中,获取预测对象的对象标签特征的过程与下述步骤S202中获取各个对象的对象标签特征的过程相同,获取预测资源的资源标签特征的过程与下述步骤S203中获取各个资源的资源标签特征的过程相同。
进而,计算机设备可以将预测对象在哈希空间中映射的特征值、预测对象的对象标签特征、预测资源在哈希空间中映射的特征值、预测资源的资源标签特征输入训练好的预测网络,调用预测网络根据预测对象在哈希空间中映射的特征值、预测对象的对象标签特征、预测资源在哈希空间中映射的特征值、预测资源的资源标签特征,预测该预测对象针对预测资源的转化指数,该转化指数可以是0~1的值。
若上述所预测得到的预测对象针对预测资源的转化指数大于转化指数阈值,则可以将预测资源推送给预测对象。
预测资源还可以有多个,如预测资源还可以包括上述M个资源中的各个资源,因此,计算机设备可以获取到预测对象针对每个预测资源的转化指数,并可以根据每个预测资源分别对应的转化指数按照从大到小的顺序对每个预测资源进行排序,并可以将排序在前T个的资源推送给预测对象,T为正整数,T的具体取值可以根据实际应用场景确定。
其中,本申请重点描述了如何准确训练预测网络,进而如何通过所训练的预测网络生成对象针对资源准确的转化指数,后续具体如何通过对象针对资源的转化指数来向对象进行资源的推送的策略,可以根据实际应用场景确定,对此不做限制。
本申请通过结合对象和资源之间的转化异质图、对象以及资源的同质图来一同训练预测网络,可以使得预测网络对转化异质图中比较孤立的节点(如与其他资源节点或者对象节点不存在连边或者连边很少的节点)对应对象或者资源的特征也可以进行较好的学习,这可以解决针对对象和资源的冷启动问题(如存在新增的对象或者资源时,对新增的对象或者资源学习不充 分的问题;还如某些已有的对象或者资源与其他对象或者资源关联不大(如在转化异质图中对应连边不存在或者存在极少)时,对该关联不大的对象和资源学习不充分的问题),使得训练得到的预测网络对于所有对象针对所有资源的转化指数都能进行准确的预测。
本申请可以获取转化异质图;转化异质图包含N个对象的对象节点和M个资源的资源节点,N和M均为正整数;若N个对象中任一对象对M个资源中任一资源具有转化行为,则任一对象的对象节点与任一资源的资源节点在转化异质图中具有连边;获取N个对象中每个对象分别对应的对象同质图;任一对象同质图包含多个对象特征节点,任一对象特征节点用于表示对应对象在一个维度上的对象特征;获取M个资源中每个资源分别对应的资源同质图;任一资源同质图包含多个资源特征节点,任一资源特征节点用于表示对应资源在一个维度上的资源特征;基于转化异质图、每个对象的对象同质图和每个资源的资源同质图训练预测网络,得到训练好的预测网络;训练好的预测网络用于预测对象针对资源的转化指数。由此可见,本申请提出的方法可以同时结合对象和资源的异质图、对象的同质图以及资源的同质图来训练预测网络,使得在训练预测网络时对于各个对象和各个资源(同时包括之间不具有访问行为的对象与资源及之间具有访问行为的对象与资源)的特征都能进行有效传播,因此可以提升训练得到的预测网络的准确性,通过训练得到的预测网络也可以实现对对象针对资源的转化指数的准确预测。
请参见图7,图7是本申请提供的一种模型训练方法的流程示意图。本申请实施例中的执行主体可以与上述图3对应实施例中的执行主体相同,如图6所示,该方法包括:
步骤S201,调用预测网络基于转化异质图生成每个对象的第一对象嵌入特征及每个资源的第一资源嵌入特征。
首先,计算机设备可以获取到各个对象的对象标识(对象id)以及各个资源的资源标识(资源id),计算机设备可以将各个对象的对象标识以及各个资源的资源标识映射到统一的哈希空间中,如可以通过特定的哈希算法对各个对象的对象标识以及各个资源的资源标识进行运算,即可将各个对象的对象标识以及各个资源的资源标识映射到统一的哈希空间中,一个对象的对象标识映射为该哈希空间中的一个哈希值,一个资源的资源标识也映射为该哈希空间中的一个哈希值。
计算机设备可以通过上述各个资源以及各个对象映射在哈希空间中的哈希值将上述转化异质图表示为关系矩阵,该关系矩阵中横向可以表示各个资源,竖向可以表示各个对象,若一个对象的对象节点与一个资源的资源节点在转化异质图中具有连边,则该关系矩阵中该对象与该资源对应位置处的元素值就为1,否则(即不具有连边),该关系矩阵中该对象与该资源对应位置处的元素值就为0。例如,若关系矩阵中第1行表示对象1,第1列表示资源1,若对象1具有对资源1的转化行为,则关系矩阵中第1行第1列位置处的元素值就为1,否则,若对象1不具有对资源1的转化行为,则关系矩阵中第1行第1列位置处的元素值就为0。换句话说,该关系矩阵用于指示转化异质图中各个资源节点与对象节点之间的连边关系。
其中,上述关系矩阵的矩阵空间即为上述将对象标识及资源标识映射至的哈希空间,该关系矩阵中的横向位置可以包含资源标识可以映射为的一个个哈希值对应的位置,该关系矩阵中的纵向位置可以包含对象标识可以映射为的一个个哈希值。该关系矩阵中还可以包含上述N个对象和M个资源未映射到的位置,即该关系矩阵中可以存在若干的元素值为0,关系矩阵中所 存在的元素值为0的位置可以支持在后续继续映射新的对象和新的资源。因此,可以理解的是,通过将对象的对象标识和资源的资源标识都映射到统一的哈希空间中,可以使得后续即使出现预测网络训练时未出现但预测网络应用时新出现的对象以及资源,预测网络也可以识别出将该新出现的对象以及资源映射到哈希空间中的对应位置,即使得预测网络对于未接触过的新出现的对象和资源也可以进行识别和预测,可以提升预测网络的针对对象及资源的预测范围以及预测准确性。
其中,可以将转化异质图表示为的关系矩阵记为R,计算机设备还可以获取到该关系矩阵R的邻接矩阵,可以将该邻接矩阵表示为A,如下述公式(1)所示,该邻接矩阵A为:
其中,RT表示关系矩阵R的转置。
其中,可以理解的是,转化异质图本身的结构就是邻接矩阵A的结构,邻接矩阵A是一个对称矩阵,本申请中可以将转化异质图表示为邻接矩阵A,邻接矩阵A也记录了转化异质图所包含的各个对象针对各个资源的转化行为,进而使得在预测网络中通过该邻接矩阵可以进行更简便的运算。
计算机设备可以将上述邻接矩阵A输入预测网络。
调用预测网络根据邻接矩阵A生成各个对象的嵌入特征以及各个资源的嵌入特征的过程可以是:
预测网络可以包括NGCF(一种图神经网络),该NGCF可以很好地对异质图中各个节点之间的信息进行传播,因此,本申请可以通过调用预测网络中的NGCF来生成对象的第一对象嵌入特征及资源的第一资源嵌入特征,该过程可以包括:计算机设备可以调用NGCF获取到特征传播矩阵,该特征传播矩阵用于对转化异质图中各个节点(包括资源节点和对象节点)对应的特征(包括资源特征和对象特征)之间的信息进行相互传播,进而可以生成N个对象和M个资源对应的嵌入特征矩阵,如下述公式(2)~公式(4)所示:
E(k+1)=σ((I+L)E(k)W1+(LE(k))⊙E(k)W2)      (2)
L=D1/2AD1/2     (3)
其中,此处NGCF可以具有4层(还可以是其他层数)用于进行特征学习和生成的网络层,根据公式(2),k的取值可以是0~3,第1层进行特征学习和生成的网络层可以根据E(0)生成特征矩阵E(1),第2层进行特征学习和生成的网络层可以根据E(1)生成特征矩阵E(2),第3层进行特征学习和生成的网络层可以根据E(2)生成特征矩阵E(3),第4层进行特征学习和生成的网络层可以根据E(3)生成特征矩阵E(4)
σ表示激活函数,L就表示上述特征传播矩阵,L属于图拉普拉斯矩阵,用于进行节点间 信息的传播,D表示度的矩阵,D中记录了转化异质图中每个节点(包括对象节点和资源节点)的度,一个节点的度就等于与该节点具有连边的其他节点的数量。I表示单位矩阵,W1和W2均属于NGCF中的参数矩阵(也是用于进行节点间信息传播),在对预测网络进行不断训练过程中,该W1和W2也会进行不断更新修正。
进而通过上述公式(2)和公式(3)就可以获取到E(1)~E(4),可以将获取到的E(1)~E(4)均作为嵌入特征矩阵,公式(4)中的||表示拼接,即通过对多个嵌入特征矩阵(包括E(0)~E(4))进行拼接即可获取到拼接后的嵌入特征矩阵
其中,E(0)~E(4)均为嵌入特征矩阵,任一个嵌入特征矩阵均包含转化异质图中各个节点分别对应的嵌入特征(可以是特征向量)。其中,对于预测网络的初次训练(即第1次训练),E(0)属于初始化的嵌入特征矩阵,该初始化的嵌入特征矩阵中包含各个对象分别对应的初始化的嵌入特征以及各个资源分别对应的初始化的嵌入特征,各个对象分别对应的初始化的嵌入特征以及各个资源分别对应的初始化的嵌入特征可以是进行随机初始化得到的。此外,由于预测网络是可以不断进行迭代训练的,每一次迭代训练过程中,预测网络均可以生成E(1)~E(4),因此,在预测网络的迭代训练过程中,对于预测网络的非初次训练(即不是第1次训练),后一次迭代训练过程中的E(0)可以是前一次迭代训练过程中的E(4)
若E(0)~E(4)中每个嵌入特征(转化异质图中一个节点在一个嵌入特征矩阵中对应一个嵌入特征)都是16维(还可以是其他维度)的,那么拼接后的嵌入特征矩阵中每个嵌入特征就为16*5共80维的,因此,可以对拼接后的嵌入特征矩阵进行特征降维(即进行特征映射处理,可以在多层感知机(Multilayer Perceptron,MLP)通过映射矩阵来映射,该映射矩阵也可以是训练得到的),得到目标嵌入特征矩阵,该目标嵌入特征矩阵就是对拼接后的嵌入特征矩阵进行特征降维后得到。该目标嵌入特征矩阵中就包括各个对象的嵌入特征以及各个资源的嵌入特征,目标嵌入特征矩阵中所包含的各个嵌入特征也可以是16维的。
进而,计算机设备就可以从目标嵌入特征矩阵中提取得到各个对象的嵌入特征,作为各个对象的第一对象嵌入特征,一个对象具有一个第一对象嵌入特征,计算机网络还可以从目标嵌入特征矩阵中提取得到各个资源的嵌入特征,作为各个资源的第一资源嵌入特征,一个资源具有一个第一资源嵌入特征。
其中,上述各个对象的第一对象嵌入特征和各个资源的第一资源嵌入特征就是预测网络通过转化异质图所生成的各个对象的嵌入特征和各个资源的嵌入特征,在对预测网络进行迭代训练过程中,对预测网络进行每一次训练(可以理解为每一轮训练)都可以生成该次训练过程中各个对象的第一对象嵌入特征和各个资源的第一资源嵌入特征。
步骤S202,调用预测网络基于每个对象的对象同质图分别生成每个对象的第二对象嵌入特征。
预测网络还可以包含归纳学习网络、或称为图注意力网络(Graph Attention Network,GAT),该GAT具有良好的归纳学习能力,因此,计算机网络可以通过调用预测网络中的GAT根据每 个对象的对象同质图来生成每个对象的嵌入特征(可以称之为第二对象嵌入特征)。
由于通过GAT生成每个对象的第二对象嵌入特征的过程均相同,因此,下述以通过GAT生成目标对象的第二对象嵌入特征为例进行说明,其中,目标对象可以是N个对象中的任意一个对象,请参见下述内容描述。
目标对象的对象同质图中任两个对象特征节点之间均具有连边(即对象同质图是完全连接图)。
计算机设备可以将目标对象的对象同质图表示为对应的邻接矩阵(获取目标对象的对象同质图的邻接矩阵的过程与上述获取转化异质图的邻接矩阵的过程相同),可以将目标对象的对象同质图的邻接矩阵表示为AD,进而计算机设备可以将邻接矩阵AD输入预测网络。
更多的,计算机设备还可以将每个对象的对象标签特征(可以表示为向量)输入预测网络。
其中,每个对象的对象标签特征可以是分别通过每个对象在每个维度的对象特征上具体的对象特征(通过在各个维度的对象特征上的特征值体现)得到。例如,一个对象具有3个维度上的对象特征,该3个维度中的任一个维度的特征空间都为1000(即一个维度上的对象特征有1000种取值,即1000个特征值),则该对象的对象标签特征就可以是由该对象分别在该3个维度上的对象特征中的特征值构成。
举个例子,若一个对象具有3个维度的对象特征,该3个维度的对象特征分别对应是对象年龄的特征、对象所在城市的特征以及对象工作的特征,其中,该3个维度的对象特征的特征空间都可以是1000的大小,即对象年龄的特征可以具有1000种可以选取的特征值,该1000种可以选取的特征值可以包括0岁到999岁分别对应的映射值(可以理解为用于表示某个年龄的标识,一个年龄可以对应一个映射值);对象所在城市的特征也可以具有1000种可以选取的特征值,该1000种可以选取的特征值可以包括1000个城市分别对应的映射值(可以理解为用于表示某个城市的标识,一个城市可以对应一个映射值);同理,对象工作的特征也可以具有1000种可以选取的特征值,该1000种可以选取的特征值可以包括1000种工作分别对应的映射值(可以理解为用于表示某个工作的标识,一个工作可以对应一个映射值)。因此,若某个对象(如对象1)的年龄是20岁,20岁对应的映射值是0.3,对象1所在城市是重庆,重庆对应的映射值是0.5,对象1的工作是自由工作,自由工作对应的映射值是0.2,则该对象1的对象标签特征就可以为(0.3,0.5,0.2)。
每种维度上的每种特征值(即映射值)可以是通过将对应的对象特征映射到统一的哈希空间中得到,一个维度的对象特征可以对应具有一个哈希空间,通过将各个维度上的若干种对象特征都映射到对应的哈希空间中,可以保证各个维度上的各种对象特征(一个特征值可以对应表示一种对象特征)都是可控的,并且对于新出现的对象特征(如训练时未用到,但实际预测时用到的某个维度上的某种特征值所指示的对象特征)也能保证在预先设定的特征空间(即哈希空间)中,即使得预测网络可以识别出在各个维度的哈希空间中的所有对象特征。
例如,对于对象年龄的特征,可以通过特定的哈希算法(算法的具体表达可以根据实际应用场景确定)将对象年龄所能够选取的各个年龄都映射到一个哈希空间中,例如,对象年龄所能够选取的各个年龄包括0到999岁,则可以对0到999共1000个年龄进行哈希运算,得到各个年龄分别对应的映射值(属于哈希值),该各个年龄分别对应的映射值就为对象年龄的特征 维度上可以选取的各个特征值。
因此,生成目标对象的第二对象嵌入特征的过程可以是:计算机设备可以调用GAT对目标对象的对象同质图中的连边进行删除处理,得到目标对象的对象同质图的激活子图,可以将目标对象的对象同质图的激活子图称之为第一激活子图,该第一激活子图是对目标对象的对象同质图中关联不大的对象特征节点之间的连边进行去除后所得到的,该第一激活子图是不完全连接的图,该第一激活子图可以表示为对目标对象的对象同质图中的连边进行删除后所得到的关系矩阵,进而可以得到第一激活子图的邻接矩阵,此处获取第一激活子图的邻接矩阵的过程与上述获取转化异质图的邻接矩阵的过程相同。如下述公式(5)~公式(7)所示,该过程可以是:


其中,Mi,j表示目标对象的对象同质图中第i个对象特征节点和第j个对象特征节点之间的相关度(可以理解为是相似性),第i个对象特征节点和第j个对象特征节点可以是目标对象的对象同质图中任意两个对象特征节点。
为目标对象的对象同质图中各个对象特征节点的特征矩阵,中包含各个对象特征节点分别对应的嵌入特征,表示中第i个对象特征节点对应的嵌入特征,表示中第j个对象特征节点对应的嵌入特征,表示之间的余弦距离。
其中,就表示第一激活子图的邻接矩阵,∈表示要保留目标对象的对象同质图中的多少连边(也用于指示要删除目标对象的对象同质图中的多少连边),例如,若∈为30(还可以是其他值,具体根据实际应用场景确定),则可以对目标对象的对象同质图中各个对象特征节点之间的相关度进行排序,保留相关度排序在前30%的对象特征节点之间的连边,即删除相关度排序在后70%的对象特征节点之间的连边,任意两个对象特征节点之间具有一个相关度,即任一条连边对应一个相关度。
例如,若∈为30,目标对象的对象同质图中对象特征节点1与对象特征节点2之间的相关度排序在所有对象特征节点之间的相关度的前30%,则可以保留目标对象的对象同质图中对象特征节点1与对象特征节点2之间的连边,否则,即若目标对象的对象同质图中对象特征节点1与对象特征节点2之间的相关度排序在所有对象特征节点之间的相关度的后70%,则可以删除目标对象的对象同质图中对象特征节点1与对象特征节点2之间的连边。可以理解的是,第一激活子图中就包含目标对象的对象同质图中相关度排序在前30%的对象特征节点之间的连边。
因此,就表示目标对象的对象同质图中相关度排序在前∈%的对象特 征节点之间的连边,即第一激活子图中就包含目标对象的对象同质图中相关度排序在前∈%的对象特征节点之间的连边。上述公式(5)就表示在第一激活子图的邻接矩阵中只有相关度排序在前∈%的对象特征节点之间具有连接关系(即表明在第一激活子图中具有连边),反之,相关度排序不在前∈%的对象特征节点之间就不具有连接关系。
更多的,可以理解的是,在对预测网络进行初次训练(即第1次训练)时,H表示初始化的特征矩阵,H中包含目标对象的每个维度上的对象特征分别对应的初始化的嵌入特征,即H包含目标对象的对象同质图中每个对象特征节点分别对应的初始化的嵌入特征,一个维度的对象特征对应一个初始化的嵌入特征,即一个对象特征节点对应一个初始化的嵌入特征,H中各个对象特征节点分别对应的初始化的嵌入特征可以是进行随机初始化得到。
其中,计算机设备可以通过目标对象的对象标签特征来获取到各个对象特征节点分别对应的初始化的嵌入特征,其中可以理解的是,可以预先建立目标对象在各个维度的对象特征上的特征值(即上述映射值)分别与对应的初始化的嵌入特征之间的关联关系,一个特征值对应一个初始化的嵌入特征。由于一个维度的对象特征对应一个对象特征节点,一个维度的对象特征也对应一个初始化的嵌入特征,因此,一个对象特征节点对应一个初始化的嵌入特征,这个初始化的嵌入特征就是这个对象特征节点所指示维度的对象特征对应的初始化的嵌入特征。
因此,计算机设备可以通过目标对象的对象标签特征所包含的各个维度的对象特征分别对应的特征值来获取具有关联关系的初始化的嵌入特征,作为目标对象的每个对象特征节点分别对应的初始化的嵌入特征。
此外,由于预测网络是可以不断进行迭代训练的,每一次迭代训练过程中,预测网络均可以通过公式(7)的逻辑生成也在每次训练过程中不断在更新,因此,在预测网络的迭代训练过程中,对于预测网络的非初次训练(即不是第1次训练),后一次迭代训练过程中带入公式(7)的H可以是前一次迭代训练过程中的公式(7)中的W3属于GAT的参数矩阵,b3是偏置向量,在预测网络的训练过程中,W3和b3也会不断进行更新,即W3和b3也属于预测网络的网络参数。
其中可以理解的是,在对预测网络的每次迭代过程中,都可以在目标对象的对象同质图的基础上去掉不同的连边,得到不同的第一激活子图,可以理解的是,预测网络的后一次迭代训练过程是在前一次迭代训练的结果上进行训练的。
更多的,计算机设备可以基于上述第一激活子图的邻接矩阵来生成目标对象的第二对象嵌入特征,该过程如下公式(8)~公式(10)所示:


其中,Ni表示第i个对象特征节点的邻居节点的集合,第i个对象特征节点的邻居节点的集合可以通过上述第一激活子图的邻接矩阵得到,第i个对象特征节点的邻居节点是指在第一激活子图中与第i个对象特征节点具有连边的对象特征节点,u属于Ni,即u属于第i个对象特征节点的邻居节点。
通过上述公式(8)~公式(10)可以对第一激活子图中目标对象在各个对象特征节点所指示维度上的对象特征进行特征传播,进而生成各个对象特征节点的分别对应的节点特征,此处具体描述了生成第i个对象特征节点的节点特征
其中,GAT中可以有M个特征生成网络层,m的取值范围可以是0~M-2,表示M个特征生成网络层中第m个特征生成网络层所生成的第i个对象特征节点的嵌入特征,表示M个特征生成网络层中第m个特征生成网络层的下一个特征生成网络层所生成的第i个对象特征节点的嵌入特征,每个特征生成网络层均可以生成第i个对象特征节点的K个嵌入特征,k的取值范围为1~K,如在第m层可以生成K个σ表示激活函数,公式(8)中的||表示拼接,W(m)表示第m个特征生成网络层的参数矩阵,αiu表示第i个对象特征节点与第u个对象特征节点之间归一化的连边权重。
对于公式(9),exp表示指数函数,LeakyRelu和α均表示激活函数(两种激活函数可以不同),W表示预测网络的参数矩阵,属于网络参数(即模型参数),训练过程不断更新,||表示拼接。表示M个特征生成网络层中第m个特征生成网络层所生成的第u个对象特征节点的嵌入特征,表示M个特征生成网络层中第m个特征生成网络层所生成的第v个对象特征节点的嵌入特征,v也属于Ni,即v也属于第i个对象特征节点的邻居节点,v可以是u,也可以不是u。
其中,通过公式(8)~公式(9)可以获取到上述M个特征生成网络层的前M-1个特征生成网络层(即当m小于等于M-2时)所生成的第i个对象特征节点的嵌入特征,即M个特征生成网络层中的前M-1个特征生成网络层的处理逻辑可以是公式(8)~公式(9)的逻辑。M个特征生成网络层中最后一层(即第M个特征生成网络层)的处理逻辑可以与前M-1个特征生成网络层不同,第M个特征生成网络层的处理逻辑可以是公式(10)的处理逻辑,通过第M个特征生成网络层就可以输出第i个对象特征节点最终的嵌入特征作为第i个对象特征节点的节点特征
对于公式(10),W(M)表示第M个特征生成网络层的参数矩阵,属于网络参数,需要不断更新,就表示第M-1个特征生成网络层(即当m等于M-2)所生成的第i个对象特征节点的嵌入特征。
通过上述与获取第i个对象特征节点的节点特征同样的过程,计算机设备就可以生成目标对象的对象同质图中每个对象特征节点(即第一激活子图中每个对象特征节点,第一激活子图与目标对象的对象同质图所包含的对象特征节点相同,只是连边不同)分别对应的节点特征,每个节点特征的维度相同,如都是维度为16的特征向量。
进而,计算机设备就可以将目标对象的每个对象特征节点分别对应的节点特征进行求和,即可得到目标对象的第二对象嵌入特征。其中,对每个对象特征节点分别对应的节点特征进行求和可以是对每个对象特征节点分别对应的节点特征中相同位置处的元素值进行求和,因此,所得到的目标对象的第二对象嵌入特征与各个节点特征的维度是相同的。
举个例子,若目标对象的各个对象特征节点的节点特征包括节点特征(0.1,0.2,0.3)和节点特征(0.2,0.4,0.6),则对该节点特征(0.1,0.2,0.3)和节点特征(0.2,0.4,0.6)进行求和的结果可以是(0.3,0.6,0.9),即目标对象的第二对象嵌入特征就为(0.3,0.6,0.9)。
进而,计算机设备就可以以生成目标对象的第二对象嵌入特征同样的方式生成每个对象分别对应的第二对象嵌入特征。
步骤S203,调用预测网络基于每个资源的资源同质图分别生成每个资源的第二资源嵌入特征。
生成每个资源的第二资源嵌入特征的过程均与上述生成目标对象的第二对象嵌入特征的过程相同,此过程中需要将上述目标对象的对象同质图替换为资源的资源同质图,将对象特征节点替换为资源特征节点。因此,生成各个资源的第二资源嵌入特征的具体过程可以参见上述S202中的具体描述。
且需要强调的是,在生成各个资源的第二资源嵌入特征之前,计算机设备也需要将各个资源的资源标签特征输入预测网络,每个资源的资源标签特征也可以是分别通过每个资源所具有的标签特征得到。每个资源的资源标签特征的维度可以是不同的,一个资源具有哪些维度上的标签特征,则该资源的资源标签特征就可以具有这些维度的标签特征对应的特征值。本申请中,一种标签特征就可以对应是一个维度的资源特征,因此,一个维度的资源特征就可以只具有一个特征值。
例如,一个资源具有3个维度上的标签特征,则该资源的资源标签特征就可以是由该3个维度上的标签特征对应的特征值构成。
举个例子,若某个资源(如资源1)是动漫,资源1具有3个维度的标签特征,该3个维度的标签特征分别是国风的特征、魔幻的特征以及人物特写的特征,国风的特征对应的特征值是0.1,魔幻的特征对应的特征值是0.2,人物特写的特征对应的特征值是0.6,则该资源1的资源标签特征就可以为(0.1,0.2,0.6)。再举个例子,若某个资源(如资源2)是商品的广告,资源2具有4个维度的标签特征,该4个维度的标签特征分别是家用的特征、电器的特征、节能的特征以及便携的特征,该家用的特征对应的特征值是0.11,电器的特征对应的特征值是0.22, 节能的特征对应的特征值是0.33,便携的特征对应的特征值是0.44,则该资源2的资源标签特征就可以为(0.11,0.22,0.33,0.44)。
同理,每种维度上的每种特征值(即映射值)可以是通过将对应的标签特征映射到统一的哈希空间中得到,所有维度的标签特征可以具有一个统一的哈希空间(此哈希空间与上述对象特征的哈希空间不同),通过将各个维度的标签特征都映射到统一的哈希空间中,可以保证各个维度上的各种标签特征(即资源特征,一种标签特征可以对应表示一个维度的资源特征)都是可控的,并且对于新出现的资源特征(如训练时未用到,但实际预测时用到的某个维度上的标签特征)也能保证在预先设定的特征空间(即哈希空间)中,即使得预测网络可以识别出在各个维度的资源特征对应哈希空间中的所有资源特征。
例如,对于资源某种特定风格的特征,可以通过特定的哈希算法(算法的具体表达可以根据实际应用场景确定)将资源的该种特定风格的特征映射到哈希空间中。例如,资源的该种特定风格的特征可以具有特征标识(id),则可以对该特征标识进行哈希运算,即可得到该种特定风格的特征对应的特征值。
同理,计算机设备可以通过各个资源的资源标签特征所包含的特征值来获取资源的各个资源特征节点分别对应的初始化的嵌入特征。
例如,M个资源中的任意一个可以表示为目标资源,计算机设备可以调用GAT对目标资源的资源同质图进行连边删除处理,得到目标资源的资源同质图的激活子图,可以将目标资源的资源同质图的激活子图称之为是第二激活子图。其中,获取第二激活子图的方式与上述获取第一激活子图的方式相同。
进而,计算机设备可以根据该第二激活子图对目标资源在多个维度上的资源特征进行特征传播处理,得到第二激活子图中目标资源的每个资源特征节点(即资源同质图中每个资源特征节点,目标资源的资源同质图中的资源特征节点与目标资源的第二激活子图中的资源特征节点相同,只是资源特征节点之间的连边不同)分别对应的节点特征,其中,获取目标资源的各个资源特征节点分别对应的节点特征的过程与上述获取目标对象的各个对象特征节点分别对应的节点特征的过程相同。
因此,计算机设备就可以通过目标资源的各个资源特征节点分别对应的节点特征生成目标资源的第二资源嵌入特征。其中,根据目标资源的各个资源特征节点分别对应的节点特征生成目标资源的第二资源嵌入特征的过程,与上述根据目标对象的各个对象特征节点分别对应的节点特征生成目标对象的第二对象嵌入特征的过程相同。
通过上述与生成目标资源的第二资源嵌入特征相同的过程,计算机设备可以生成每个资源的第二资源嵌入特征,一个资源对应一个第二资源嵌入特征。
步骤S204,根据每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征训练预测网络,得到训练好的预测网络。
计算机设备可以通过上述每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征生成针对预测网络的预测损失值,该预测损失值表征了预测网络针对对象以及资源的预测偏差,该预测损失值越大,预测网络的预测偏差就越大,反之,该预测损失值越小,预测网络的预测偏差就越小。
因此,计算机设备可以通过该预测损失值来修正预测网络的网络参数(即模型参数),如可以通过调整预测网络的网络参数,使得该预测损失值达到最小值。
其中,可以对预测网络进行不断迭代训练,每次训练均会有对应的预测损失值,通过每个迭代训练过程中所产生的预测损失值不断更新修正预测网络的网络参数,可以将最终训练完成的预测网络(如网络参数训练至收敛状态或者训练次数达到某个次数阈值)作为训练好的预测网络。
请参见图8,图8是本申请提供的一种网络训练的场景示意图。如图8所示,计算机设备可以调用预测网络通过转化异质图生成每个对象的第一对象嵌入特征以及每个资源的第一资源嵌入特征,计算机设备还可以调用预测网络通过每个对象的对象同质图生成每个对象的第二对象嵌入特征,计算机设备还可以调用预测网络通过每个资源的资源同质图生成每个资源的第二资源嵌入特征。
进而,计算机设备可以通过所生成的各个对象的第一对象嵌入特征、各个对象的第二对象嵌入特征、各个资源的第一资源嵌入特征以及各个资源的第二资源嵌入特征,生成预测网络的预测损失函数(即上述预测损失值),进而,通过该预测损失函数修正预测网络的网络参数,即可得到训练好的预测网络。
本申请通过自监督的方式让通过同质图(如资源同质图和对象同质图)得到的嵌入特征(如第二资源嵌入特征和第二对象嵌入特征)与通过转化异质图得到的嵌入特征(如第一资源嵌入特征和第一对象嵌入特征)进行对齐,以期同质图能有效泛化到异质二部图(即转化异质图)并在冷启动场景替代二部图,能够解决传统二部图方法的冷启动问题(如在二部图中新增的节点可能存在的孤立的问题),使得预测网络可以对异质二部图中各个节点(包括对象节点和资源节点)对应的节点特征都可以进行有效学习,后续也能对对象针对资源的转化指数进行准确预测。
请参见图9,图9是本申请提供的一种损失生成方法的流程示意图。本申请实施例主要描述了如何生成预测网络的预测损失值,本申请实施例中的执行主体可以与上述图3对应实施例中的执行主体相同,如图9所示,该方法包括:
步骤S301,根据每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征,生成预测网络的特征泛化损失值;特征泛化损失值用于指示每个对象的第一对象嵌入特征和第二对象嵌入特征之间的特征差异,并用于指示每个资源的第一资源嵌入特征和第二资源嵌入特征之间的特征差异。
计算机设备将同质图的特征空间泛化到转化异质图的特征空间,具体的,计算机设备可以将通过同质图所得到的嵌入特征(包括每个对象的第二对象嵌入特征和每个资源的第二资源嵌入特征)与通过转化异质图所得到的嵌入特征(包括每个对象的第一对象嵌入特征和每个资源的第一对象嵌入特征)进行对齐(即使得两者相似),进而生成预测网络的特征泛化损失值,该特征泛化损失值就用于表征每个对象的第一对象嵌入特征和第二对象嵌入特征之间的特征差异,以及用于表征每个资源的第一资源嵌入特征与第二资源嵌入特征之间的特征差异。
如,特征泛化损失值越大,表征每个对象的第一对象嵌入特征和第二对象嵌入特征之间的特征差异及每个资源的第一资源嵌入特征与第二资源嵌入特征之间的特征差异越大(即越不相 似),反之,特征泛化损失值越小,表征每个对象的第一对象嵌入特征和第二对象嵌入特征之间的特征差异及每个资源的第一资源嵌入特征与第二资源嵌入特征之间的特征差异越小(即越相似)。
可以将特征泛化损失值记为Ls,如下述公式(11)所示,该特征泛化损失值Ls为:
Ls=Σa∈[1,N],b∈[1,M](||ea-e′a||1+||eb-e′b||1)    (11)
其中,a表示N个对象中第a个对象,a的取值范围即为1~N,同理,b表示M个资源中第b个资源,b的取值范围即为1~M。其中,ea表示第a个对象的第一对象嵌入特征,e′a表示第a个对象的第二对象嵌入特征,eb表示第b个资源的第一资源嵌入特征,e′b表示第b个资源的第二资源嵌入特征。
其中,ea-e′a就表示第a个对象的第一对象嵌入特征与第二对象嵌入特征之间的特征差异,可以将Σa∈[1,N](||ea-e′a||1)称之为是第一泛化损失值,表征对象的第一对象嵌入特征和第二对象嵌入特征之间的泛化损失值;eb-e′b就表示第b个资源的第一资源嵌入特征与第二资源嵌入特征之间的特征差异,可以将Σb∈[1,M](||eb-e′b||1)称之为是第二泛化损失值,表征资源的第一资源嵌入特征和第二资源嵌入特征之间的泛化损失值;特征泛化损失值Ls就为第一泛化损失值和第二泛化损失值之和。||...||1表示1范数。
步骤S302,根据每个对象的第一对象嵌入特征和每个资源的第一资源嵌入特征,生成预测网络的第一转化预测损失值。
计算机设备可以根据每个对象的第一对象嵌入特征和每个资源的第一资源嵌入特征,生成预测网络的第一转化预测损失值,该第一转化预测损失值表征了预测网络通过转化异质图来预测对象针对资源的转化指数的预测损失。
首先,可以将预测网络在训练过程中根据转化异质图所预测得到的第a个对象针对第b个资源的转化指数记为可以将该转化指数称之为是第a个对象针对第b个资源的第一预测转化指数,如下述公式(12)所示,第a个对象针对第b个资源的第一预测转化指数为:
其中,sigmoid表示激活函数(一种S型函数),W4表示预测网络的参数矩阵,属于网络参数,训练过程中会不断更新,b4为偏置向量,ea表示第a个对象的第一对象嵌入特征,eb表示第b个资源的第一资源嵌入特征,||表示拼接。
因此,可以将第一转化预测损失值记为Lz1,如下述公式(13)所示,该第一转化预测损失值Lz1为:
其中,Ya,b表示第a个对象与第b个资源之间真实的转化标签(训练预测网络时可以输入,也可以通过转化异质图得到),该转化标签指示了第a个对象实际是否对第b个资源具有转化行为。表示上述通过转化异质图所预测得到的第a个对象针对第b个资源的转化指数。
步骤S303,根据每个对象的第二对象嵌入特征和每个资源的第二资源嵌入特征,生成预测网络的第二转化预测损失值。
同理,计算机设备可以根据每个对象的第二对象嵌入特征和每个资源的第二资源嵌入特征,生成预测网络的第二转化预测损失值,该第二转化预测损失值表征了预测网络通过同质图(包括对象同质图和资源同质图)来预测对象针对资源的转化指数的预测损失。
首先,可以将预测网络在训练过程中根据同质图所预测得到的第a个对象针对第b个资源的转化指数记为可以将该转化指数称之为是第a个对象针对第b个资源的第二预测转化指数,如下述公式(14)所示,第a个对象针对第b个资源的第二预测转化指数为:
其中,sigmoid表示激活函数(一种S型函数),W5表示预测网络的参数矩阵(通常与上述W4不同),属于网络参数,训练过程中会不断更新,b5为偏置向量(通常与上述b4不同),e′a表示第a个对象的第二对象嵌入特征,e′b表示第b个资源的第二资源嵌入特征,||表示拼接。
因此,可以将第二转化预测损失值记为Lz2,如下述公式(15)所示,该第二转化预测损失值Lz2为:
其中,Ya,b表示上述第a个对象与第b个资源之间真实的转化标签,该转化标签指示了第a个对象实际是否对第b个资源具有转化行为。表示上述根据同质图所预测得到的第a个对象针对第b个资源的转化指数。
其中,可以理解的是,在对预测网络训练完成,得到训练好的预测网络后(训练好的预测网络包括更新完成后的W4和更新完成后的b4),也可以通过上述公式(14)所示的原理来生成上述预测对象针对预测资源的转化指数,该过程需要将第a个对象的第二对象嵌入特征替换为训练好的预测网络所生成的预测对象的第二对象嵌入特征,还需要将第b个资源的第二资源嵌入特征替换为训练好的预测网络所生成的预测资源的第二资源嵌入特征。
步骤S304,根据每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征,生成预测网络的正则损失值。
计算机设备还可以根据每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征,生成预测网络的正则损失值。该 正则损失值是用于确保通过转化异质图和同质图学习到的特征空间(如上述第一对象嵌入特征、第二对象嵌入特征、第一资源嵌入特征及第二资源嵌入特征所在的特征空间)在单位球表面,避免预测网络过拟合。
可以将正则损失值记为LR,如下述公式(16)所示,该正则损失值LR为:
其中,λ1、λ2、λ3和λ4均为超参数,可以预先定义,||...||2表示二范数。
步骤S305,根据特征泛化损失值、第一转化预测损失值、第二转化预测损失值和正则损失值确定预测损失值。
计算机设备可以通过上述所获取到的特征泛化损失值、第一转化预测损失值、第二转化预测损失值以及正则损失值生成(如加权求和)预测网络最终的预测损失值。
其中,可以将预测损失值记为L,如下述公式(17)所示,该预测损失值记为L为:
L=Lz2+αLs+βLz1+LR   (17)
其中,Lz2即为上述所生成的第二转化预测损失值,Ls即为上述特征泛化损失值,Lz1即为上述第一转化预测损失值,LR即为上述正则损失值。α为预先定义好的超参数,用于控制Ls的损失权重;β也为预先定义好的超参数,用于控制Lz1的损失权重。上述L、Lz2、Ls、Lz1和LR均属于损失函数。
其中,本申请在获取到训练好的预测网络之后,也可以基于训练好的预测网络通过对象(如上述预测对象)和资源(如上述预测资源)的同质图来预测对象针对资源的转化指数,因此,如公式(17)所示,本申请是以第二转化预测损失值Lz2作为主要的损失值。
可以理解的是,本申请可以只在训练预测网络时使用对象和资源的转化异质图,在得到训练好的预测网络之后,就无需使用对象和资源的转化异质图,而是使用对象和资源的同质图,来预测对象针对资源的转化指数,如通过上述图7对应实施例中所描述的过程通过需要预测对象的对象同质图和需要预测资源的资源同质图,先生成需要预测的对象的第二对象嵌入特征以及需要预测的资源的第二资源嵌入特征,后续再通过该第二对象嵌入特征和该第二资源嵌入特征生成(如上述公式(14)所指示的方式)对象针对资源的转化指数。
请参见图10,图10是本申请提供的一种生成预测损失值的场景示意图。如图10所示,计算机设备可以通过各个对象的第一对象嵌入特征和第二对象嵌入特征、各个资源的第一资源嵌入特征和第二资源嵌入特征,生成特征泛化损失值;计算机设备还可以通过各个对象的第一对象嵌入特征、各个资源的第一资源嵌入特征,生成第一转化预测损失值;计算机设备还可以通过各个对象的第二对象嵌入特征、各个资源的第二资源嵌入特征,生成第二转化预测损失值;计算机设备还可以通过各个对象的第一对象嵌入特征和第二对象嵌入特征、各个资源的第一资 源嵌入特征和第二资源嵌入特征,生成正则损失值。
进而,计算机设备即可通过上述特征泛化损失值、第一转化预测损失值、第二转化预测损失值以及正则损失值,生成预测网络的预测损失值。
采用本申请所提供的方法,通过结合多种损失值来最终确定预测网络的预测损失值,可以提升预测网络在各方面的训练效果,其间,可以通过上述特征泛化损失值Ls可以基于自监督的方式将同质图的特征空间泛化到转化异质图的特征空间。
请参见图11,图11是本申请提供的一种模型训练的场景示意图。如图11所示,本申请可以通过用户的多维特征标签(用于指示用户的多维特征,即多维对象特征)构建用户的同质图,并在预测网络中通过用户的同质图得到用户的激活子图(即上述第一激活子图),进而通过该激活子图得到用户的嵌入特征(如上述第二对象嵌入特征)。
同理,本申请还可以通过广告(即资源)的多维特征标签(用于指示广告的多维广告特征,即多维资源特征)构建广告的同质图,并在预测网络中通过广告的同质图得到广告的激活子图(即上述第二激活子图),进而通过该激活子图得到广告的嵌入特征(如上述第二资源嵌入特征)。
本申请可以构建用户与广告的转化异质图,进而还可以通过用户标识(即对象标识)以及广告标识(即资源标识)对该转化异质图中各个节点之间的信息进行传递(通过映射到对应的哈希空间中传递),得到用户的嵌入特征(如上述第一对象嵌入特征)以及广告的嵌入特征(如上述第一资源嵌入特征)。
进而,预测网络可以通过用户的第一对象嵌入特征、用户的第二对象嵌入特征、广告的第一资源嵌入特征以及广告的第二资源嵌入特征可以进行自监督学习(可以通过上述特征泛化损失值体现),还可以通过用户的第一对象嵌入特征、用户的第二对象嵌入特征、广告的第一资源嵌入特征以及广告的第二资源嵌入特征进行转化预测损失的学习(可以通过上述第一转化预测损失值以及第二转化预测损失值体现),另外,还可以通过正则损失的学习(可以通过上述正则损失值体现),即可学习得到训练好的预测网络。
在一种可行的实施方式中,本申请还可以应用在游戏推荐领域,上述N个对象可以是N个用户,M个资源可以是M个可以向用户进行推荐的游戏应用,对象针对资源的转化行为可以是用户已经注册游戏应用的行为。
因此,若一个用户在一个游戏应用中注册了用户账户,则该用户对该游戏应用就具有转化行为,该用户的节点(即对象节点)与该游戏应用的节点(即资源节点)在转化异质图中就具有连边,反之,若一个用户在一个游戏应用中未注册用户账户,则该用户对该游戏应用就不具有转化行为,该用户的节点与该游戏应用的节点在转化异质图中就不具有连边。
此外,本申请还可以获取到各个用户的同质图(即对象同质图)以及各个游戏应用的同质图(即资源同质图),进而结合用户和游戏应用的转化异质图、用户的同质图以及游戏应用的同质图对预测网络进行训练,以得到训练好的预测网络,该训练好的预测网络就可以对任意用户针对任意游戏应用的转化指数进行准确的预测。
在此种游戏推荐的领域中,通过将用户和游戏应用的转化异质图结合上用户的同质图以及游戏应用的同质图,在考虑到用户对游戏应用的转化行为的第一条件的基础上,还充分考虑到 了各个用户和各个游戏应用本身特征(通过同质图体现)的第二条件,使得在对预测网络进行训练的过程中,预测网络可以对基于该两种条件所学习到的特征进行相互迁移,以此可以训练得到非常准确的预测网络。
因此,采用本申请提供的方法也可以很好地解决在游戏推荐领域的用户冷启动问题,如当存在新用户时,该新用户对M个游戏应用中极大部分游戏应用或者全部游戏应用都不具有转化行为(若该新用户属于N个对象中的用户,则表现为该新用户的节点在转化异质图中属于比较孤立的节点),通过训练得到的预测网络也可以准确预测得到该新用户对每个游戏应用的转化指数,进而通过该新用户对各个游戏应用的转化指数就可以向该新用户进行准确的游戏应用推荐。
更多的,本申请在进行离线实验时,可以采用过去某一日期的第-9~-3天的数据作为训练集,第-2天的数据作为验证集,第-1天的数据作为测试集。观察任取10个日期的训练结果,对多域自注意力模型的结果进行对比,实验结果如下述表1所示:
表1

上述自监督图下的指标是采用本申请所提供方法得到的指标,由上述表1可以看出,本申请相比多域的自注意力模型,对于Acc、AUC和AUCG的测试在极多数情况下均有较大提升。
请参见图12,图12是本申请提供的一种数据处理装置的结构示意图。该数据处理装置可以是运行于计算机设备中的一个计算机程序(包括程序代码),例如该数据处理装置为一个应用软件,该数据处理装置可以用于执行本申请实施例提供的方法中的相应步骤。如图12所示,该数据处理装置1可以包括:第一获取模块11、第二获取模块12、第三获取模块13和训练模块14。
第一获取模块11,用于获取转化异质图;转化异质图包含N个对象节点和M个资源节点,每个对象节点各自表示一个对象,每个资源节点各自表示一个资源,N和M均为正整数;若N个对象中任一对象对M个资源中任一资源具有转化行为,则任一对象的对象节点与任一资源的资源节点在转化异质图中具有连边;
第二获取模块12,用于获取N个对象中每个对象分别对应的对象同质图;任一对象同质图包含多个对象特征节点,任一对象特征节点用于表示对应对象在一个维度上的对象特征;
第三获取模块13,用于获取M个资源中每个资源分别对应的资源同质图;任一资源同质图包含多个资源特征节点,任一资源特征节点用于表示对应资源在一个维度上的资源特征;
训练模块14,用于基于转化异质图、每个对象的对象同质图和每个资源的资源同质图训练预测网络,得到训练好的预测网络;训练好的预测网络用于预测对象针对资源的转化指数。
训练模块14基于转化异质图、每个对象的对象同质图和每个资源的资源同质图训练预测网络,得到训练好的预测网络的方式,包括:
调用预测网络基于转化异质图生成每个对象的第一对象嵌入特征及每个资源的第一资源嵌入特征;
调用预测网络基于每个对象的对象同质图分别生成每个对象的第二对象嵌入特征;
调用预测网络基于每个资源的资源同质图分别生成每个资源的第二资源嵌入特征;
根据每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征训练预测网络,得到训练好的预测网络。
训练模块14调用预测网络基于转化异质图生成每个对象的第一对象嵌入特征及每个资源的第一资源嵌入特征的方式,包括:
将转化异质图表示为关系矩阵;关系矩阵用于指示转化异质图中资源节点与对象节点之间的连边关系;
调用预测网络获取特征传播矩阵,并基于特征传播矩阵和关系矩阵对N个对象的对象特征和M个资源的资源特征进行相互传播,生成N个对象和M个资源对应的嵌入特征矩阵;
基于嵌入特征矩阵生成每个对象的第一对象嵌入特征和每个资源的第一资源嵌入特征。
嵌入特征矩阵有多个;训练模块14基于嵌入特征矩阵生成每个对象的第一对象嵌入特征和每个资源的第一资源嵌入特征的方式,包括:
对多个嵌入特征矩阵进行拼接,得到拼接后的嵌入特征矩阵;
对拼接后的嵌入特征矩阵进行特征映射处理,得到目标嵌入特征矩阵;
从目标嵌入特征矩阵中提取每个对象的第一对象嵌入特征和每个资源的第一资源嵌入特征。
N个对象中的任一个表示为目标对象,目标对象的对象同质图中任两个对象特征节点之间具有连边;
训练模块14调用预测网络基于每个对象的对象同质图分别生成每个对象的第二对象嵌入特征的方式,包括:
调用预测网络对目标对象的对象同质图中的连边进行删除处理,得到目标对象的对象同质图的第一激活子图;
基于第一激活子图对目标对象的在多个维度上的对象特征进行特征传播处理,得到第一激活子图中目标对象的每个对象特征节点分别对应的节点特征;
根据目标对象的每个对象特征节点分别对应的节点特征生成目标对象的第二对象嵌入特征。
M个资源中的任一个表示为目标资源,目标资源的资源同质图中任两个资源特征节点之间具有连边;
训练模块14调用预测网络基于每个资源的资源同质图分别生成每个资源的第二资源嵌入特征的方式,包括:
调用预测网络对目标资源的资源同质图中的连边进行删除处理,得到目标资源的资源同质图的第二激活子图;
基于第二激活子图对目标资源在多个维度上的资源特征进行特征传播处理,得到第二激活子图中目标资源的每个资源特征节点分别对应的节点特征;
根据目标资源的每个资源特征节点分别对应的节点特征生成目标资源的第二资源嵌入特征。
训练模块14根据每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征训练预测网络,得到训练好的预测网络的方式,包括:
根据每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征,生成预测网络的预测损失值;
基于预测损失值修正预测网络的网络参数,得到训练好的预测网络。
训练模块14根据每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征,生成预测网络的预测损失值的方式,包括:
根据每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征,生成预测网络的特征泛化损失值;特征泛化损失值用于指示每个对象的第一对象嵌入特征和第二对象嵌入特征之间的特征差异,并用于指示每个资源的第一资源嵌入特征和第二资源嵌入特征之间的特征差异;
根据每个对象的第一对象嵌入特征和每个资源的第一资源嵌入特征,生成预测网络的第一 转化预测损失值;
根据每个对象的第二对象嵌入特征和每个资源的第二资源嵌入特征,生成预测网络的第二转化预测损失值;
根据每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征,生成预测网络的正则损失值;
根据特征泛化损失值、第一转化预测损失值、第二转化预测损失值和正则损失值确定预测损失值。
训练模块14根据每个对象的第一对象嵌入特征、每个对象的第二对象嵌入特征、每个资源的第一资源嵌入特征及每个资源的第二资源嵌入特征,生成预测网络的特征泛化损失值的方式,包括:
根据每个对象的第一对象嵌入特征和第二对象嵌入特征,生成针对对象嵌入特征的第一泛化损失值;
根据每个资源的第一资源嵌入特征和第二资源嵌入特征,生成针对资源嵌入特征的第二泛化损失值;
根据第一泛化损失值和第二泛化损失值生成特征泛化损失值。
训练模块14根据每个对象的第一对象嵌入特征和每个资源的第一资源嵌入特征,生成预测网络的第一转化预测损失值的方式,包括:
根据每个对象的第一对象嵌入特征和每个资源的第一资源嵌入特征,生成每个对象分别针对每个资源的第一预测转化指数;
根据每个对象分别针对每个资源的第一预测转化指数及每个对象分别针对每个资源的转化行为,生成第一转化预测损失值。
训练模块14根据每个对象的第二对象嵌入特征和每个资源的第二资源嵌入特征,生成预测网络的第二转化预测损失值的方式,包括:
根据每个对象的第二对象嵌入特征和每个资源的第二资源嵌入特征,生成每个对象分别针对每个资源的第二预测转化指数;
根据每个对象分别针对每个资源的第二预测转化指数及每个对象分别针对每个资源的转化行为,生成第二转化预测损失值。
上述装置1还用于:
获取预测对象和预测资源;
调用训练好的预测网络预测上述预测对象针对预测资源的转化指数;
若预测对象针对预测资源的转化指数大于或等于转化指数阈值,则将预测资源推送给预测对象。
根据本申请的一个实施例,图3所示的数据处理方法所涉及的步骤可由图12所示的数据处理装置1中的各个模块来执行。例如,图3中所示的步骤S101可由图12中的第一获取模块11来执行,图3中所示的步骤S102可由图12中的第二获取模块12来执行;图3中所示的步骤S103可由图12中的第三获取模块13来执行,图3中所示的步骤S104可由图12中的训练模块14来执行。
本申请可以获取转化异质图;转化异质图包含N个对象的对象节点和M个资源的资源节点,N和M均为正整数;若N个对象中任一对象对M个资源中任一资源具有转化行为,则任一对象的对象节点与任一资源的资源节点在转化异质图中具有连边;获取N个对象中每个对象分别对应的对象同质图;任一对象同质图包含多个对象特征节点,任一对象特征节点用于表示对应对象在一个维度上的对象特征;获取M个资源中每个资源分别对应的资源同质图;任一资源同质图包含多个资源特征节点,任一资源特征节点用于表示对应资源在一个维度上的资源特征;基于转化异质图、每个对象的对象同质图和每个资源的资源同质图训练预测网络,得到训练好的预测网络;训练好的预测网络用于预测对象针对资源的转化指数。由此可见,本申请提出的装置可以同时结合对象和资源的异质图、对象的同质图以及资源的同质图来训练预测网络,使得在训练预测网络时对于各个对象和各个资源(同时包括之间不具有访问行为的对象与资源及之间具有访问行为的对象与资源)的特征都能进行有效传播,因此可以提升训练得到的预测网络的准确性,通过训练得到的预测网络也可以实现对对象针对资源的转化指数的准确预测。
根据本申请的一个实施例,图12所示的数据处理装置1中的各个模块可以分别或全部合并为一个或若干个单元来构成,或者其中的某个(些)单元还可以再拆分为功能上更小的多个子单元,可以实现同样的操作,而不影响本申请的实施例的技术效果的实现。上述模块是基于逻辑功能划分的,在实际应用中,一个模块的功能也可以由多个单元来实现,或者多个模块的功能由一个单元实现。在本申请的其它实施例中,数据处理装置1也可以包括其它单元,在实际应用中,这些功能也可以由其它单元协助实现,并且可以由多个单元协作实现。
根据本申请的一个实施例,可以通过在包括中央处理单元(CPU)、随机存取存储介质(RAM)、只读存储介质(ROM)等处理元件和存储元件的例如计算机的通用计算机设备上运行能够执行如图3中所示的相应方法所涉及的各步骤的计算机程序(包括程序代码),来构造如图12中所示的数据处理装置1,以及来实现本申请实施例的数据处理方法。上述计算机程序可以记载于例如计算机可读存储介质上,并通过计算机可读存储介质装载于上述计算设备中,并在其中运行。
请参见图13,图13是本申请提供的一种计算机设备的结构示意图。如图13所示,计算机设备1000可以包括:处理器1001,网络接口1004和存储器1005,此外,计算机设备1000还可以包括:用户接口1003,和至少一个通信总线1002。其中,通信总线1002用于实现这些组件之间的连接通信。其中,用户接口1003可以包括显示屏(Display)、键盘(Keyboard),用户接口1003还可以包括标准的有线接口、无线接口。网络接口1004可以包括标准的有线接口、无线接口(如WI-FI接口)。存储器1005可以是高速RAM存储器,也可以是非易失性存储器(non-transitory memory),例如至少一个磁盘存储器。存储器1005还可以是至少一个位于远离前述处理器1001的存储装置。如图13所示,作为一种计算机存储介质的存储器1005中可以包括操作系统、网络通信模块、用户接口模块以及设备控制应用程序。
在图13所示的计算机设备1000中,网络接口1004可提供网络通讯功能;而用户接口1003主要用于为用户提供输入的接口;而处理器1001可以用于调用存储器1005中存储的设备控制应用程序,以实现:
获取转化异质图;转化异质图包含N个对象节点和M个资源节点,每个对象节点各自表示 一个对象,每个资源节点各自表示一个资源,N和M均为正整数;若N个对象中任一对象对M个资源中任一资源具有转化行为,则任一对象的对象节点与任一资源的资源节点在转化异质图中具有连边;
获取N个对象中每个对象分别对应的对象同质图;任一对象同质图包含多个对象特征节点,任一对象特征节点用于表示对应对象在一个维度上的对象特征;
获取M个资源中每个资源分别对应的资源同质图;任一资源同质图包含多个资源特征节点,任一资源特征节点用于表示对应资源在一个维度上的资源特征;
基于转化异质图、每个对象的对象同质图和每个资源的资源同质图训练预测网络,得到训练好的预测网络;训练好的预测网络用于预测对象针对资源的转化指数。
应当理解,本申请实施例中所描述的计算机设备1000可执行前文图3对应实施例中对上述数据处理方法的描述,也可执行前文图12所对应实施例中对上述数据处理装置1的描述,在此不再赘述。另外,对采用相同方法的有益效果描述,也不再进行赘述。
此外,这里需要指出的是:本申请还提供了一种计算机可读存储介质,且计算机可读存储介质中存储有前文提及的数据处理装置1所执行的计算机程序,且计算机程序包括程序指令,当处理器执行程序指令时,能够执行前文图3所对应实施例中对数据处理方法的描述,因此,这里将不再进行赘述。对于本申请所涉及的计算机存储介质实施例中未披露的技术细节,请参照本申请方法实施例的描述。
作为示例,上述程序指令可被部署在一个计算机设备上执行,或者被部署在位于一个地点的多个计算机设备上执行,又或者,在分布在多个地点且通过通信网络互连的多个计算机设备上执行,分布在多个地点且通过通信网络互连的多个计算机设备可以组成区块链网络。
上述计算机可读存储介质可以是前述任一实施例提供的数据处理装置或者上述计算机设备的内部存储单元,例如计算机设备的硬盘或内存。该计算机可读存储介质也可以是该计算机设备的外部存储设备,例如该计算机设备上配备的插接式硬盘,智能存储卡(smart media card,SMC),安全数字(secure digital,SD)卡,闪存卡(flash card)等。进一步地,该计算机可读存储介质还可以既包括该计算机设备的内部存储单元也包括外部存储设备。该计算机可读存储介质用于存储该计算机程序以及该计算机设备所需的其他程序和数据。该计算机可读存储介质还可以用于暂时地存储已经输出或者将要输出的数据。
本申请提供了一种计算机程序产品或计算机程序,该计算机程序产品或计算机程序包括计算机指令,该计算机指令存储在计算机可读存储介质中。计算机设备的处理器从计算机可读存储介质读取该计算机指令,处理器执行该计算机指令,使得该计算机设备执行前文图3对应实施例中对上述数据处理方法的描述,因此,这里将不再进行赘述。对于本申请所涉及的计算机可读存储介质实施例中未披露的技术细节,请参照本申请方法实施例的描述。
本申请实施例的说明书和权利要求书及附图中的术语“第一”、“第二”等是用于区别不同对象,而非用于描述特定顺序。此外,术语“包括”以及它们的任何变形,意图在于覆盖不排他的包含。例如包含了一系列步骤或单元的过程、方法、装置、产品或设备没有限定于已列出的步骤或模块,而是还包括没有列出的步骤或模块,或还包括对于这些过程、方法、装置、产品或设备固有的其他步骤单元。
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、计算机软件或者二者的结合来实现,为了清楚地说明硬件和软件的可互换性,在上述说明中已经按照功能一般性地描述了各示例的组成及步骤。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
本申请实施例提供的方法及相关装置是参照本申请实施例提供的方法流程图和/或结构示意图来描述的,具体可由计算机程序指令实现方法流程图和/或结构示意图的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。这些计算机程序指令可提供到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或结构示意图一个方框或多个方框中指定的功能的装置。这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或结构示意图一个方框或多个方框中指定的功能。这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或结构示意图一个方框或多个方框中指定的功能的步骤。
以上所揭露的仅为本申请较佳实施例而已,当然不能以此来限定本申请之权利范围,因此依本申请权利要求所作的等同变化,仍属本申请所涵盖的范围。

Claims (20)

  1. 一种数据处理方法,由计算机设备执行,其特征在于,所述方法包括:
    获取转化异质图;所述转化异质图包含N个对象节点和M个资源节点,每个对象节点各自表示一个对象,每个资源节点各自表示一个资源,N和M均为正整数;若N个对象中任一对象对M个资源中任一资源具有转化行为,则所述任一对象的对象节点与所述任一资源的资源节点在所述转化异质图中具有连边;
    获取所述N个对象中每个对象分别对应的对象同质图;任一对象同质图包含多个对象特征节点,任一对象特征节点用于表示对应对象在一个维度上的对象特征;
    获取所述M个资源中每个资源分别对应的资源同质图;任一资源同质图包含多个资源特征节点,任一资源特征节点用于表示对应资源在一个维度上的资源特征;
    基于所述转化异质图、所述每个对象的对象同质图和所述每个资源的资源同质图训练预测网络,得到训练好的预测网络;所述训练好的预测网络用于预测对象针对资源的转化指数。
  2. 根据权利要求1所述的方法,其特征在于,所述基于所述转化异质图、所述每个对象的对象同质图和所述每个资源的资源同质图训练预测网络,得到训练好的预测网络,包括:
    调用所述预测网络基于所述转化异质图生成所述每个对象的第一对象嵌入特征及所述每个资源的第一资源嵌入特征;
    调用所述预测网络基于所述每个对象的对象同质图分别生成所述每个对象的第二对象嵌入特征;
    调用所述预测网络基于所述每个资源的资源同质图分别生成所述每个资源的第二资源嵌入特征;
    根据所述每个对象的第一对象嵌入特征、所述每个对象的第二对象嵌入特征、所述每个资源的第一资源嵌入特征及所述每个资源的第二资源嵌入特征训练所述预测网络,得到所述训练好的预测网络。
  3. 根据权利要求2所述的方法,其特征在于,所述调用所述预测网络基于所述转化异质图生成所述每个对象的第一对象嵌入特征及所述每个资源的第一资源嵌入特征,包括:
    将所述转化异质图表示为关系矩阵;所述关系矩阵用于指示所述转化异质图中资源节点与对象节点之间的连边关系;
    调用所述预测网络获取特征传播矩阵,并基于所述特征传播矩阵和所述关系矩阵,对所述N个对象的对象特征和所述M个资源的资源特征进行相互传播,生成所述N个对象和所述M个资源对应的嵌入特征矩阵;
    基于所述嵌入特征矩阵生成所述每个对象的第一对象嵌入特征和所述每个资源的第一资源嵌入特征。
  4. 根据权利要求3所述的方法,其特征在于,所述嵌入特征矩阵有多个;所述基于所述嵌入特征矩阵生成所述每个对象的第一对象嵌入特征和所述每个资源的第一资源嵌入特征,包括:
    对多个嵌入特征矩阵进行拼接,得到拼接后的嵌入特征矩阵;
    对所述拼接后的嵌入特征矩阵进行特征映射处理,得到目标嵌入特征矩阵;
    从所述目标嵌入特征矩阵中提取所述每个对象的第一对象嵌入特征和所述每个资源的第一 资源嵌入特征。
  5. 根据权利要求2所述的方法,其特征在于,所述N个对象中的任一个表示为目标对象,所述目标对象的对象同质图中任两个对象特征节点之间具有连边;
    所述调用所述预测网络基于所述每个对象的对象同质图分别生成所述每个对象的第二对象嵌入特征,包括:
    调用所述预测网络对所述目标对象的对象同质图中的连边进行删除处理,得到所述目标对象的对象同质图的第一激活子图;
    基于所述第一激活子图,对所述目标对象的在多个维度上的对象特征进行特征传播处理,得到所述第一激活子图中所述目标对象的每个对象特征节点分别对应的节点特征;
    根据所述目标对象的每个对象特征节点分别对应的节点特征生成所述目标对象的第二对象嵌入特征。
  6. 根据权利要求2所述的方法,其特征在于,所述M个资源中的任一个表示为目标资源,所述目标资源的资源同质图中任两个资源特征节点之间具有连边;
    所述调用所述预测网络基于所述每个资源的资源同质图分别生成所述每个资源的第二资源嵌入特征,包括:
    调用所述预测网络对所述目标资源的资源同质图中的连边进行删除处理,得到所述目标资源的资源同质图的第二激活子图;
    基于所述第二激活子图,对所述目标资源在多个维度上的资源特征进行特征传播处理,得到所述第二激活子图中所述目标资源的每个资源特征节点分别对应的节点特征;
    根据所述目标资源的每个资源特征节点分别对应的节点特征生成所述目标资源的第二资源嵌入特征。
  7. 根据权利要求2所述的方法,其特征在于,所述根据所述每个对象的第一对象嵌入特征、所述每个对象的第二对象嵌入特征、所述每个资源的第一资源嵌入特征及所述每个资源的第二资源嵌入特征训练所述预测网络,得到训练好的预测网络,包括:
    根据所述每个对象的第一对象嵌入特征、所述每个对象的第二对象嵌入特征、所述每个资源的第一资源嵌入特征及所述每个资源的第二资源嵌入特征,生成所述预测网络的预测损失值;
    基于所述预测损失值修正所述预测网络的网络参数,得到所述训练好的预测网络。
  8. 根据权利要求7所述的方法,其特征在于,所述根据所述每个对象的第一对象嵌入特征、所述每个对象的第二对象嵌入特征、所述每个资源的第一资源嵌入特征及所述每个资源的第二资源嵌入特征,生成所述预测网络的预测损失值,包括:
    根据所述每个对象的第一对象嵌入特征、所述每个对象的第二对象嵌入特征、所述每个资源的第一资源嵌入特征及所述每个资源的第二资源嵌入特征,生成所述预测网络的特征泛化损失值;所述特征泛化损失值用于指示所述每个对象的第一对象嵌入特征和第二对象嵌入特征之间的特征差异,并用于指示所述每个资源的第一资源嵌入特征和第二资源嵌入特征之间的特征差异;
    根据所述每个对象的第一对象嵌入特征和所述每个资源的第一资源嵌入特征,生成所述预测网络的第一转化预测损失值;
    根据所述每个对象的第二对象嵌入特征和所述每个资源的第二资源嵌入特征,生成所述预测网络的第二转化预测损失值;
    根据所述每个对象的第一对象嵌入特征、所述每个对象的第二对象嵌入特征、所述每个资源的第一资源嵌入特征及所述每个资源的第二资源嵌入特征,生成所述预测网络的正则损失值;
    根据所述特征泛化损失值、所述第一转化预测损失值、所述第二转化预测损失值和所述正则损失值确定所述预测损失值。
  9. 根据权利要求8所述的方法,其特征在于,所述根据所述每个对象的第一对象嵌入特征、所述每个对象的第二对象嵌入特征、所述每个资源的第一资源嵌入特征及所述每个资源的第二资源嵌入特征,生成所述预测网络的特征泛化损失值,包括:
    根据所述每个对象的第一对象嵌入特征和第二对象嵌入特征,生成针对对象嵌入特征的第一泛化损失值;
    根据所述每个资源的第一资源嵌入特征和第二资源嵌入特征,生成针对资源嵌入特征的第二泛化损失值;
    根据所述第一泛化损失值和所述第二泛化损失值生成所述特征泛化损失值。
  10. 根据权利要求8所述的方法,其特征在于,所述根据所述每个对象的第一对象嵌入特征和所述每个资源的第一资源嵌入特征,生成所述预测网络的第一转化预测损失值,包括:
    根据所述每个对象的第一对象嵌入特征和所述每个资源的第一资源嵌入特征,生成所述每个对象分别针对所述每个资源的第一预测转化指数;
    根据所述每个对象分别针对所述每个资源的第一预测转化指数及所述每个对象分别针对所述每个资源的转化行为,生成所述第一转化预测损失值。
  11. 根据权利要求8所述的方法,其特征在于,所述根据所述每个对象的第二对象嵌入特征和所述每个资源的第二资源嵌入特征,生成所述预测网络的第二转化预测损失值,包括:
    根据所述每个对象的第二对象嵌入特征和所述每个资源的第二资源嵌入特征,生成所述每个对象分别针对所述每个资源的第二预测转化指数;
    根据所述每个对象分别针对所述每个资源的第二预测转化指数及所述每个对象分别针对所述每个资源的转化行为,生成所述第二转化预测损失值。
  12. 根据权利要求1所述的方法,其特征在于,所述方法还包括:
    获取预测对象和预测资源;
    调用所述训练好的预测网络预测所述预测对象针对所述预测资源的转化指数;
    若所述预测对象针对所述预测资源的转化指数大于或等于转化指数阈值,则将所述预测资源推送给所述预测对象。
  13. 一种数据处理装置,其特征在于,所述装置包括:
    第一获取模块,用于获取转化异质图;所述转化异质图包含N个对象节点和M个资源节点,每个对象节点各自表示一个对象,每个资源节点各自表示一个资源,N和M均为正整数;若N个对象中任一对象对M个资源中任一资源具有转化行为,则所述任一对象的对象节点与所述任一资源的资源节点在所述转化异质图中具有连边;
    第二获取模块,用于获取所述N个对象中每个对象分别对应的对象同质图;任一对象同质 图包含多个对象特征节点,任一对象特征节点用于表示对应对象在一个维度上的对象特征;
    第三获取模块,用于获取所述M个资源中每个资源分别对应的资源同质图;任一资源同质图包含多个资源特征节点,任一资源特征节点用于表示对应资源在一个维度上的资源特征;
    训练模块,用于基于所述转化异质图、所述每个对象的对象同质图和所述每个资源的资源同质图训练预测网络,得到训练好的预测网络;所述训练好的预测网络用于预测对象针对资源的转化指数。
  14. 根据权利要求13所述的装置,其特征在于,所述训练模块进一步用于:
    调用所述预测网络基于所述转化异质图生成所述每个对象的第一对象嵌入特征及所述每个资源的第一资源嵌入特征;
    调用所述预测网络基于所述每个对象的对象同质图分别生成所述每个对象的第二对象嵌入特征;
    调用所述预测网络基于所述每个资源的资源同质图分别生成所述每个资源的第二资源嵌入特征;
    根据所述每个对象的第一对象嵌入特征、所述每个对象的第二对象嵌入特征、所述每个资源的第一资源嵌入特征及所述每个资源的第二资源嵌入特征训练所述预测网络,得到所述训练好的预测网络。
  15. 根据权利要求14所述的装置,其特征在于,所述训练模块进一步用于:
    将所述转化异质图表示为关系矩阵;所述关系矩阵用于指示所述转化异质图中资源节点与对象节点之间的连边关系;
    调用所述预测网络获取特征传播矩阵,并基于所述特征传播矩阵和所述关系矩阵对所述N个对象的对象特征和所述M个资源的资源特征进行相互传播,生成所述N个对象和所述M个资源对应的嵌入特征矩阵;
    基于所述嵌入特征矩阵生成所述每个对象的第一对象嵌入特征和所述每个资源的第一资源嵌入特征。
  16. 根据权利要求15所述的装置,其特征在于,所述嵌入特征矩阵有多个;所述训练模块进一步用于:
    对多个嵌入特征矩阵进行拼接,得到拼接后的嵌入特征矩阵;
    对所述拼接后的嵌入特征矩阵进行特征映射处理,得到目标嵌入特征矩阵;
    从所述目标嵌入特征矩阵中提取所述每个对象的第一对象嵌入特征和所述每个资源的第一资源嵌入特征。
  17. 根据权利要求14所述的装置,其特征在于,所述N个对象中的任一个表示为目标对象,所述目标对象的对象同质图中任两个对象特征节点之间具有连边,所述训练模块进一步用于:
    调用所述预测网络对所述目标对象的对象同质图中的连边进行删除处理,得到所述目标对象的对象同质图的第一激活子图;
    基于所述第一激活子图,对所述目标对象的在多个维度上的对象特征进行特征传播处理,得到所述第一激活子图中所述目标对象的每个对象特征节点分别对应的节点特征;
    根据所述目标对象的每个对象特征节点分别对应的节点特征生成所述目标对象的第二对象 嵌入特征。
  18. 一种计算机程序产品,包括计算机程序/指令,该计算机程序/指令被处理器执行时实现权利要求1-12任一项所述方法的步骤。
  19. 一种计算机设备,其特征在于,包括存储器和处理器,所述存储器存储有计算机程序,所述计算机程序被所述处理器执行时,使得所述处理器执行权利要求1-12中任一项所述方法的步骤。
  20. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质存储有计算机程序,所述计算机程序适用于由处理器加载并执行权利要求1-12任一项所述的方法。
PCT/CN2023/084690 2022-05-05 2023-03-29 数据处理方法、装置、程序产品、计算机设备和介质 WO2023213157A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US18/437,118 US20240177006A1 (en) 2022-05-05 2024-02-08 Data processing method and apparatus, program product, computer device, and medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202210479316.8 2022-05-05
CN202210479316.8A CN114580794B (zh) 2022-05-05 2022-05-05 数据处理方法、装置、程序产品、计算机设备和介质

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US18/437,118 Continuation US20240177006A1 (en) 2022-05-05 2024-02-08 Data processing method and apparatus, program product, computer device, and medium

Publications (1)

Publication Number Publication Date
WO2023213157A1 true WO2023213157A1 (zh) 2023-11-09

Family

ID=81784945

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2023/084690 WO2023213157A1 (zh) 2022-05-05 2023-03-29 数据处理方法、装置、程序产品、计算机设备和介质

Country Status (3)

Country Link
US (1) US20240177006A1 (zh)
CN (1) CN114580794B (zh)
WO (1) WO2023213157A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117788122A (zh) * 2024-02-23 2024-03-29 山东科技大学 一种基于异质图神经网络商品推荐方法

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114580794B (zh) * 2022-05-05 2022-07-22 腾讯科技(深圳)有限公司 数据处理方法、装置、程序产品、计算机设备和介质

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160050129A1 (en) * 2014-08-15 2016-02-18 Google Inc. Performance assessment based on analysis of resources
US20190266487A1 (en) * 2016-07-14 2019-08-29 Google Llc Classifying images using machine learning models
CN112766500A (zh) * 2021-02-07 2021-05-07 支付宝(杭州)信息技术有限公司 图神经网络的训练方法及装置
CN113569906A (zh) * 2021-06-10 2021-10-29 重庆大学 基于元路径子图的异质图信息提取方法和装置
CN114330837A (zh) * 2021-12-08 2022-04-12 腾讯科技(深圳)有限公司 对象处理方法、装置、计算机设备和存储介质
CN114580794A (zh) * 2022-05-05 2022-06-03 腾讯科技(深圳)有限公司 数据处理方法、装置、程序产品、计算机设备和介质

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111709493B (zh) * 2020-07-10 2024-02-23 腾讯科技(深圳)有限公司 对象分类方法、训练方法、装置、设备及存储介质
CN112422711B (zh) * 2020-11-06 2021-10-08 北京五八信息技术有限公司 一种资源分配方法、装置、电子设备及存储介质
CN113191838B (zh) * 2021-04-09 2024-01-30 山东师范大学 一种基于异质图神经网络的购物推荐方法及系统
CN114327857A (zh) * 2021-11-02 2022-04-12 腾讯科技(深圳)有限公司 操作数据处理方法、装置、计算机设备和存储介质
CN114428910A (zh) * 2022-01-28 2022-05-03 腾讯科技(深圳)有限公司 资源推荐方法、装置、电子设备、产品及介质

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160050129A1 (en) * 2014-08-15 2016-02-18 Google Inc. Performance assessment based on analysis of resources
US20190266487A1 (en) * 2016-07-14 2019-08-29 Google Llc Classifying images using machine learning models
CN112766500A (zh) * 2021-02-07 2021-05-07 支付宝(杭州)信息技术有限公司 图神经网络的训练方法及装置
CN113569906A (zh) * 2021-06-10 2021-10-29 重庆大学 基于元路径子图的异质图信息提取方法和装置
CN114330837A (zh) * 2021-12-08 2022-04-12 腾讯科技(深圳)有限公司 对象处理方法、装置、计算机设备和存储介质
CN114580794A (zh) * 2022-05-05 2022-06-03 腾讯科技(深圳)有限公司 数据处理方法、装置、程序产品、计算机设备和介质

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117788122A (zh) * 2024-02-23 2024-03-29 山东科技大学 一种基于异质图神经网络商品推荐方法
CN117788122B (zh) * 2024-02-23 2024-05-10 山东科技大学 一种基于异质图神经网络商品推荐方法

Also Published As

Publication number Publication date
CN114580794A (zh) 2022-06-03
US20240177006A1 (en) 2024-05-30
CN114580794B (zh) 2022-07-22

Similar Documents

Publication Publication Date Title
CN111680217B (zh) 内容推荐方法、装置、设备及存储介质
WO2023213157A1 (zh) 数据处理方法、装置、程序产品、计算机设备和介质
WO2021139191A1 (zh) 数据标注的方法以及数据标注的装置
CN111737476A (zh) 文本处理方法、装置、计算机可读存储介质及电子设备
WO2022105117A1 (zh) 一种图像质量评价的方法、装置、计算机设备及存储介质
CN113761153B (zh) 基于图片的问答处理方法、装置、可读介质及电子设备
US20230017667A1 (en) Data recommendation method and apparatus, computer device, and storage medium
CN111666416B (zh) 用于生成语义匹配模型的方法和装置
WO2021155691A1 (zh) 用户画像生成方法、装置、存储介质及设备
CN112989085B (zh) 图像处理方法、装置、计算机设备及存储介质
WO2023024413A1 (zh) 信息的匹配方法、装置、计算机设备及可读存储介质
US20210397942A1 (en) Learning to search user experience designs based on structural similarity
WO2023231753A1 (zh) 一种神经网络的训练方法、数据的处理方法以及设备
WO2023241207A1 (zh) 一种数据处理方法、装置、设备、计算机可读存储介质及计算机程序产品
CN113641797A (zh) 数据处理方法、装置、设备、存储介质及计算机程序产品
CN113128588A (zh) 模型训练方法、装置、计算机设备及计算机存储介质
WO2022222854A1 (zh) 一种数据处理方法及相关设备
WO2024067779A1 (zh) 一种数据处理方法及相关装置
CN112069412B (zh) 信息推荐方法、装置、计算机设备及存储介质
CN111814044A (zh) 一种推荐方法、装置、终端设备及存储介质
WO2023284516A1 (zh) 基于知识图谱的信息推荐方法、装置、设备、介质及产品
CN113568983B (zh) 场景图生成方法、装置、计算机可读介质及电子设备
CN112417260B (zh) 本地化推荐方法、装置及存储介质
CN113821676A (zh) 视频检索方法、装置、设备及存储介质
CN115203516A (zh) 基于人工智能的信息推荐方法、装置、设备及存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 23799144

Country of ref document: EP

Kind code of ref document: A1