Method, device, equipment and storage medium for determining object attribute labels
By using local subgraphs in heterogeneous information networks to generate embedded representations of objects and determine attribute labels, the flexibility problem when heterogeneous information networks change is solved, and the generation speed and lightweight update capability of embedded representations are improved.
Patent Information
- Application Number
- CN202310305937.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-24
- Publication Date
- 2025-09-23
- Estimated Expiration
- 2043-03-24
AI Technical Summary
Existing technologies have low flexibility in determining object attribute labels when heterogeneous information networks change, and require generating new node sequences to update the embedded representations of all objects, resulting in large computational complexity and waste of storage space.
By obtaining the local subgraph in the heterogeneous information network, the embedded representation of the object is generated, and the attribute label of the object is determined according to the correlation between the embedded representation and the candidate attribute label, the number of nodes is reduced, and the embedded representation is updated using the local subgraph to avoid updating the embedded representation of all objects.
The flexibility and generation speed of object embedding representation are improved, the computational complexity and storage space consumption are reduced, and a lightweight embedding representation update method is implemented.
Smart Images

Figure CN118690090B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of artificial intelligence technology, and in particular to a method, apparatus, device, and storage medium for determining an object attribute label. Background Art
[0002] In order to improve the recommendation effect of network resources, attribute tags can be set for objects, and the network resources recommended to the objects can be determined based on the attribute tags of the objects.
[0003] In related technologies, by traversing heterogeneous network information, a node sequence including each node in the heterogeneous information network is generated. The determined node sequence is processed by a deep learning model to obtain the embedding representation corresponding to each object node included in the heterogeneous network node. According to the embedding representation corresponding to the object, the attribute label of the object can be determined.
[0004] However, this method has low flexibility in determining the attribute labels of objects. When the heterogeneous information network changes, it is necessary to generate a new node sequence and update the embedding representations corresponding to all objects through the new node sequence. Summary of the Invention
[0005] The present invention provides a method, apparatus, device, and storage medium for determining object attribute labels. This method utilizes structural information in heterogeneous information networks to determine the corresponding embedded representation of an object, thereby improving the flexibility of determining the corresponding embedded representation of an object in a heterogeneous information network. The technical solution is as follows:
[0006] According to one aspect of an embodiment of the present application, a method for determining an object attribute label is provided, the method comprising:
[0007] Obtaining a heterogeneous information network for use in a recommendation service; wherein the recommendation service is used to provide a network resource recommendation service for an object, the heterogeneous information network comprising: an object node corresponding to at least one object, a resource node corresponding to at least one network resource, and a first association edge between the object node and the resource node, the first association edge being used to represent an interaction between the object corresponding to the object node and the network resource corresponding to the resource node;
[0008] generating an embedded representation corresponding to a first object according to a local subgraph corresponding to the first object in the heterogeneous information network; wherein the local subgraph corresponding to the first object includes: a first object node corresponding to the first object, and at least one resource node having a first associated edge with the first object node; and the embedded representation corresponding to the first object is used to represent feature information of the first object;
[0009] Determine at least one attribute tag that matches the first object based on the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to at least one candidate attribute tag; wherein the embedded representation corresponding to the attribute tag is used to represent semantic feature information of the attribute tag.
[0010] According to one aspect of an embodiment of the present application, a device for determining an object attribute label is provided, the device comprising:
[0011] a network acquisition module, configured to acquire a heterogeneous information network for use by a recommendation service; wherein the recommendation service is configured to provide a network resource recommendation service for an object, the heterogeneous information network comprising: an object node corresponding to at least one object, a resource node corresponding to at least one network resource, and a first association edge between the object node and the resource node, the first association edge being configured to represent an interaction between the object corresponding to the object node and the network resource corresponding to the resource node;
[0012] a representation determination module, configured to generate an embedded representation corresponding to the first object based on a local subgraph corresponding to the first object in the heterogeneous information network; wherein the local subgraph corresponding to the first object includes: a first object node corresponding to the first object, and at least one resource node having a first associated edge with the first object node; and the embedded representation corresponding to the first object is used to represent feature information of the first object;
[0013] A label determination module is used to determine at least one attribute label that matches the first object based on the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to at least one candidate attribute label; wherein the embedded representation corresponding to the attribute label is used to represent the semantic feature information of the attribute label.
[0014] According to one aspect of an embodiment of the present application, a computer device is provided, comprising a processor and a memory, wherein a computer program is stored in the memory, and the computer program is loaded and executed by the processor to implement the above-mentioned method for determining an object attribute label.
[0015] According to one aspect of an embodiment of the present application, a computer-readable storage medium is provided, in which a computer program is stored. The computer program is loaded and executed by a processor to implement the above-mentioned method for determining an object attribute label.
[0016] According to one aspect of an embodiment of the present application, a computer program product is provided, comprising a computer program stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium and executes the computer program, causing the computer device to perform the above-described method for determining an object attribute label.
[0017] The technical solutions provided by the embodiments of the present application may have the following beneficial effects:
[0018] This method specifically determines the embedding representation of each object based on the local subgraph corresponding to that object in a heterogeneous information network. Compared to related techniques that randomly walk the network to determine a node sequence and then process that node sequence to generate embedding representations corresponding to all the object nodes in the heterogeneous information network, this method leverages the structural information in the recommender system's heterogeneous information network to independently determine the embedding information corresponding to each object.
[0019] On the one hand, this method reduces the number of nodes of the heterogeneous information network required in the process of determining the embedded representation corresponding to the object, which helps to reduce the amount of computation in the process of determining the embedded representation corresponding to the object and improve the speed of generating the embedded representation corresponding to the object.
[0020] On the other hand, the flexibility of determining the embedded representation corresponding to the object is improved. When the heterogeneous information network changes, the local subgraphs corresponding to some objects in the heterogeneous information network can be used to update the embedded representation corresponding to some objects, thereby avoiding the situation where the embedded representation corresponding to all objects included in the heterogeneous information network is updated, reducing the situation where the embedded representation corresponding to the object consumes a large amount of storage space, and making the method of determining the embedded representation corresponding to the object more lightweight. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 It is a schematic diagram of an implementation environment of a solution provided by an exemplary embodiment of the present application;
[0022] Figure 2 is a flowchart of a method for determining an object attribute label provided by an exemplary embodiment of the present application;
[0023] Figure 3 is a schematic diagram of a correlation model structure provided by an exemplary embodiment of the present application;
[0024] Figure 4 is a schematic diagram of a heterogeneous information network provided by an exemplary embodiment of the present application;
[0025] Figure 5 is a schematic diagram of a local subgraph corresponding to a first object provided by an exemplary embodiment of the present application;
[0026] Figure 6 is a schematic diagram of an object-side semantic tower structure provided by an exemplary embodiment of the present application;
[0027] Figure 7 is a schematic diagram of a tag-side semantic tower structure provided by an exemplary embodiment of the present application;
[0028] Figure 8 is a block diagram of a device for determining an object attribute label provided by an exemplary embodiment of the present application;
[0029] Figure 9 It is a structural block diagram of a computer device provided by an exemplary embodiment of the present application. DETAILED DESCRIPTION
[0030] In order to make the objectives, technical solutions and advantages of this application clearer, the implementation methods of this application will be further described in detail below with reference to the accompanying drawings.
[0031] Before introducing the embodiments of the present application, in order to facilitate understanding of the present solution, the following explanations are given for the terms appearing in the present solution.
[0032] Artificial Intelligence (AI) is the theory, methods, techniques, and application systems that use digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, to perceive the environment, acquire knowledge, and use that knowledge to achieve optimal results. In other words, AI is a comprehensive technology within computer science that seeks to understand the essence of intelligence and produce new intelligent machines that can respond in a manner similar to human intelligence. AI also studies the design principles and implementation methods of various intelligent machines, enabling them to possess the capabilities of perception, reasoning, and decision-making.
[0033] Artificial intelligence (AI) technology is a comprehensive discipline encompassing a wide range of fields, encompassing both hardware and software technologies. Foundational AI technologies generally include sensors, specialized AI chips, cloud computing, distributed storage, big data processing, operating / interaction systems, and mechatronics. AI software technologies primarily encompass computer vision, speech processing, natural language processing, and machine learning / deep learning.
[0034] ML (Machine Learning) is a multidisciplinary field that encompasses probability theory, statistics, approximation theory, convex analysis, and algorithmic complexity theory. It specifically studies how computers can simulate or implement human learning behaviors to acquire new knowledge or skills and reorganize existing knowledge structures to continuously improve their performance. Machine learning is at the core of artificial intelligence and the fundamental way to make computers intelligent. Its applications span all areas of artificial intelligence. Machine learning and deep learning typically include techniques such as artificial neural networks, belief networks, reinforcement learning, transfer learning, and inductive learning.
[0035] With the research and advancement of artificial intelligence technology, artificial intelligence technology has been studied and applied in many fields, such as common intelligent marketing and intelligent recommendations. I believe that with the development of technology, artificial intelligence technology will be applied in more fields and play an increasingly important role.
[0036] Multi-Label Classification (MLC) refers to the process of assigning one or more labels to a piece of data during the classification process. For example, in the multi-classification of interest dimensions, an object may be assigned multiple labels, such as music enthusiast, sports enthusiast, and high-purchasing-power group.
[0037] A Heterogeneous Information Network (HIN) is a directed graph containing multiple types of nodes or edges. Different nodes in a directed graph can be connected by edges. A HIN has at least one node type and at least one edge type. Each node in the HIN belongs to a node type, and each edge in the HIN belongs to an edge type.
[0038] Embedding Representation (ER): refers to the generation of a distributed representation of an input "object" based on a neural network model. The main function of an embedded representation is to convert the original high-dimensional, sparse vector of the input object into a low-dimensional, dense vector, allowing these low-dimensional, dense vectors to express certain characteristics of the object. Furthermore, the distance between vectors can reflect the similarity between objects, facilitating processing by downstream models, particularly deep learning models.
[0039] Vertex Representation Learning (VRL) is the process of capturing the topological structure of a graph, such as the relationships between nodes, subgraphs, and edges. Node representation learning is also known as graph embedding representation.
[0040] Graph embedding is a method that maps nodes in a graph into low-dimensional, dense embedding representations. Graph embedding algorithms can be roughly divided into three categories: matrix factorization, random walk-based methods, and deep learning-based methods.
[0041] Among them, the graph embedding method based on random walk includes the following steps: first, a node sequence is obtained through random walk, and then the embedding representation corresponding to each node in the node sequence is determined.
[0042] The graph embedding method based on deep learning refers to the method of applying graph data to deep learning models, also known as GNN (Graph Neural Networks), which is a method of learning node embedding representations through deep learning models.
[0043] Semantic tags: Semantic tags are generally discrete text labels such as entities, word segments, topics, keywords, concepts, and categories. Semantic tags are the attribute tags in claims. They contain meaningful text to represent the attribute category of an object. Semantic tags correspond to the attribute tags in claims.
[0044] Please refer to Figure 1 , which shows a schematic diagram of a solution implementation environment provided by an exemplary embodiment of the present application. The solution implementation environment may include: a terminal device 10, a server 20 and a computer device 30.
[0045] The terminal device 10 includes but is not limited to mobile phones, tablet computers, intelligent voice interaction devices, game consoles, wearable devices, multimedia playback devices, personal computers (PCs), vehicle-mounted terminals, smart home appliances, and other electronic devices. The client of the target application can be installed in the terminal device 10.
[0046] The target application type includes, but is not limited to, at least one of the following: video applications, social applications, shopping applications, gaming applications, utility applications, and other applications used for business services. The type of target business service depends on the specific business of the target application and is not defined here. Network resources include, but are not limited to, at least one of the following: video resources, product resources, audio resources, image resources, and text resources. For example, if the target application is a video application, it can provide services such as video playback, video search, and video recommendations to the target.
[0047] In the embodiment of the present application, the target application has a data transceiver function. For example, the object interacts with the target application, causing the target application to request video resources or request recommended video resources from the server 20.
[0048] The server 20 is used to provide background services for the client of the target application in the terminal device 10. For example, the server 20 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms, but is not limited thereto.
[0049] Server 20 has at least data reception and processing capabilities. This data reception capability enables communication between terminal device 10 and server 20 via a network. This network can be either a wired or wireless network. Server 20 receives a resource recommendation request from terminal device 10 and sends the recommended network resources to terminal device 10.
[0050] Computer device 30 includes, but is not limited to, personal computers, mobile phones, tablet computers, intelligent voice interaction devices, game consoles, wearable devices, multimedia playback devices, in-vehicle terminals, smart home appliances, and other devices. Computer device 30 is used to determine the attribute tags of the objects corresponding to terminal device 10. Optionally, a correlation model runs on computer device 30. The computer device uses the correlation model to determine the degree of match between the object and the candidate attribute tags. Specifically, computer device 30 uses the correlation model to determine the attribute tags that match at least one object.
[0051] Computer device 30 sends the object's matching tag to server 20. Server 20 then recommends appropriate network resources for the object based on the object's matching attribute tag. For example, if server 20 receives a network resource recommendation request from a target application client on terminal device 10, server 20 selects at least one recommended network resource from at least one candidate network resource based on the object's matching attribute tag. Server 20 then sends the recommended network resource to terminal device 10.
[0052] In some embodiments, the computer device 30 may be the server 20 , or may be other devices.
[0053] In one example, computer device 30 predetermines a matching attribute tag for an object and sends the matching attribute tag to server 20, which then stores the matching attribute tag. Upon receiving a network resource recommendation request from terminal device 10, server 20 determines at least one recommended network resource based on the stored matching attribute tag of the object.
[0054] In another example, upon receiving a network resource recommendation request from terminal device 10, server 20 sends a request to computer device 30 to determine an object's attribute tags. Computer device 30 responds to the request and determines the object's matching attribute tags. Computer device 30 sends the object's matching attribute tags to server 20. Based on the received object's matching attribute tags, server 20 determines at least one recommended network resource and sends the at least one recommended network resource to terminal device 10.
[0055] Figure 3 It is a schematic diagram of a correlation model structure provided by an exemplary embodiment of the present application.
[0056] The correlation model includes an object-side semantic tower, a label-side semantic tower, and a matching layer; the object-side semantic tower is used to determine the embedded representation corresponding to the object, the label-side semantic tower is used to determine the embedded representation corresponding to at least one candidate label, and the matching layer is used to calculate the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to at least one candidate label.
[0057] The application scenarios of the solution provided in this application include at least one of the following:
[0058] Web resource recommendation scenarios. By identifying matching attribute tags for objects in the client, the server can recommend appropriate web resources based on these matching attribute tags. This method helps objects efficiently select highly relevant web resources from a vast array of web resources. Web resource recommendations include, but are not limited to, video recommendations, product recommendations, audio recommendations, and news recommendations.
[0059] Please refer to Figure 2 , which shows a flow chart of a method for determining an object attribute label provided by an embodiment of the present application. The execution subject of each step of the method can be Figure 1 The computer device 30 in the implementation environment of the solution shown. The method may include at least one of the following steps (210-230):
[0060] Step 210: Obtain a heterogeneous information network required for the recommendation service; wherein the recommendation service is used to provide network resource recommendation services for objects, and the heterogeneous information network includes: an object node corresponding to at least one object, a resource node corresponding to at least one network resource, and a first association edge between the object node and the resource node, wherein the first association edge is used to represent the existence of an interaction between the object corresponding to the object node and the network resource corresponding to the resource node.
[0061] In some embodiments, the heterogeneous information network utilized by the recommendation service is used to record the interaction behavior of at least one object with network resources. For ease of description, the term "heterogeneous information network" will be used below to represent the heterogeneous information network utilized by the recommendation service. Optionally, the heterogeneous information network is constructed based on the interaction behavior between multiple objects corresponding to the target application and network resources. For a detailed description of this process, please refer to the following examples.
[0062] In some embodiments, the interaction between an object and a network resource can be understood as the object performing a click operation, a play operation, a download operation, etc. on a certain network resource.
[0063] In some embodiments, an object refers to a user of a target application in a terminal device. It should be noted that in this embodiment, the object and the user have the same meaning, and the two terms can be interchanged under common conditions. In some embodiments, a network resource refers to a resource that a recommendation service can recommend to an object. The types of network resources include, but are not limited to, at least one of the following: multimedia resources such as video resources, music resources, image resources, and text resources. For example, if a recommendation service is used to recommend music to an object, the network resources may include multiple music resources.
[0064] In some embodiments, the heterogeneous information network includes at least two types of nodes and an associated edge for connecting any two nodes. Optionally, the heterogeneous information network includes object nodes, resource nodes, and a first associated edge between the object and resource nodes.
[0065] In some embodiments, the object node corresponds to the object of the recommendation service; the resource node corresponds to the network resource in the recommendation service. Optionally, one object node corresponds to one object, and one resource node corresponds to one network resource. The heterogeneous information network does not include repeated object nodes or resource nodes.
[0066] In some embodiments, a first association edge is used to connect an object node and a resource node. Optionally, the first association edge can represent an interactive relationship between an object and a first network resource; wherein the first object refers to the object corresponding to the object node connected by the first association edge, and the first network resource refers to the network resource corresponding to the resource node connected by the first association edge. Optionally, the interactive relationship can be understood as the process of an object accessing a network resource, that is, the process of an object clicking and the network resource responding.
[0067] In some embodiments, there is only one first association edge between the same object node and the same resource node. If there is no interaction relationship between an object and a network resource, there is no first association edge between the object node corresponding to the object and the resource node corresponding to the network resource.
[0068] In some embodiments, the first association edge records an interaction time, which refers to the time when an object interacts with a network resource. For example, a first association edge 1 connects object node 1 and resource node 1. The interaction time recorded on first association edge 1 indicates when the object corresponding to object node 1 accesses the network resource corresponding to resource node 1.
[0069] Optionally, if an object interacts with the same network resource multiple times (such as the object watches a video multiple times), the first association edge between the object node of the object and the resource node of the network resource records the time when the object interacted with the network resource most recently (that is, the maximum value of the interaction times corresponding to the multiple visits).
[0070] Figure 4 It is a schematic diagram of a heterogeneous information network provided by an exemplary embodiment of the present application.
[0071] The heterogeneous information network 400 includes an object node 410 , a resource node 420 , and a first association edge 430 between the object node 410 and the resource node 420 .
[0072] In some embodiments, in addition to object nodes and resource nodes, the heterogeneous information network also includes: other types of nodes, and other types of associated edges except the first associated edge. Please refer to the following description for related content.
[0073] In some embodiments, the computer device constructs a heterogeneous information network based on the interactive behavior of at least one object. Among them, U represents the object node set, V represents the resource node set, and E∈U×V represents the interaction relationship between the object and the network resource. (u, v)∈E, where nodes u∈U and v∈V, represent an interaction relationship between object u and video node v, that is, (u, v)∈E represents the first association edge between object node u and resource node v. Continuously, the heterogeneous information network also includes the following types of nodes: node set A i , i∈{1,…,n} represents the i-th resource attribute category of network resources. Node set B i , i∈{1,…,m} represents the i-th object attribute category of the object. Edge set Represents the resource node set V and the i-th resource attribute category A i The associated edge set. Represents the object node set U and the i-th object attribute category B i The set of associated edges. For details not described above, please refer to the following introduction.
[0074] Step 220: Generate an embedded representation corresponding to the first object based on the local subgraph corresponding to the first object in the heterogeneous information network; wherein the local subgraph corresponding to the first object includes: a first object node corresponding to the first object, and at least one resource node having a first associated edge with the first object node; the embedded representation corresponding to the first object is used to represent feature information of the first object.
[0075] In some embodiments, the first object in the heterogeneous information network is an object for which an attribute label needs to be determined. The heterogeneous information network includes a first object node corresponding to the first object. Optionally, a first association edge exists between the first object node and at least one resource node in the heterogeneous information network.
[0076] Optionally, the computer device needs to generate a matching attribute label for an object corresponding to an object node newly added to the heterogeneous information network, or the computer device needs to regularly update the attribute labels of objects corresponding to object nodes in the heterogeneous information network.
[0077] In some embodiments, the first object node corresponding to the first object refers to an object node representing the first object in a heterogeneous information network.
[0078] In some embodiments, the local subgraph corresponding to the first object refers to a partial network structure related to the first object in the heterogeneous information network. Optionally, the local subgraph corresponding to the first object includes all nodes and associated edges related to the first object in the heterogeneous information network. All nodes related to the first object can be understood as all nodes in the heterogeneous information network that have associated edges (e.g., first associated edges) with the first object node, as well as nodes indirectly related to the first object node. For example, for a resource node a with a first associated edge for the first object node, nodes with associated edges with the resource node a can be understood as nodes related to the first object node.
[0079] In some embodiments, the local subgraph corresponding to the first object is part of a heterogeneous information network. Optionally, the heterogeneous information network includes: a first object node, at least one first association edge connected to the first object node, and at least one resource node having a first association edge with the first object node.
[0080] Figure 5 This is a schematic diagram of a local subgraph corresponding to a first object provided by an exemplary embodiment of the present application.
[0081] The local subgraph 500 corresponding to the first object includes a first object node 510 , a first resource node 521 and a second resource node 523 .
[0082] In some embodiments, the embedded representation corresponding to the first object is used to represent feature information of the first object. Optionally, the embedded representation corresponding to the first object is used to represent attribute features of the first object. Optionally, the embedded representation corresponding to the first object is used to represent resource features of network resources historically accessed by the first object. Optionally, the embedded representation corresponding to the first object is used to represent mixed features of at least one information related to the first object. Optionally, the feature information is related to the node type in the local subgraph corresponding to the first object used in the process of determining the embedded representation corresponding to the first object. For details of this process, please refer to the embodiments below.
[0083] The embedded representation corresponding to the first object can represent the first object's preference for selecting network resources, thereby assigning an appropriate attribute label to the first object using the embedded representation corresponding to the first object. The specific steps for the computer device to determine the embedded representation corresponding to the first object based on the local subgraph are described below.
[0084] Step 230: Determine at least one attribute tag that matches the first object based on the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to at least one candidate attribute tag; wherein the embedded representation corresponding to the attribute tag is used to represent the semantic feature information of the attribute tag.
[0085] In some embodiments, the attribute tag is used to briefly summarize the attributes of the object. Optionally, the attribute tag type is pre-set. Optionally, at least one candidate attribute tag belongs to the same attribute category, and the first object can match multiple candidate attribute tags.
[0086] For example, attribute labels are obtained by dividing the object's interest dimension, attribute label 1 is "music lover", attribute label 2 is "sports enthusiast", and attribute label 3 is "high-spending people"; a first object corresponds to multiple attribute labels, and the attribute labels matched by the first object include: attribute label 1 and attribute label 2.
[0087] In some embodiments, the embedded representation corresponding to the candidate attribute tag is used to represent the feature information of the candidate attribute tag. The embedded representations corresponding to different candidate attribute tags are not exactly the same. Please refer to the following embodiments for the method of determining the embedded representation corresponding to the candidate attribute tag.
[0088] In some embodiments, the embedded representation corresponding to the candidate attribute label and the embedded representation corresponding to the first object belong to the same embedding space, that is, the dimension of the embedded representation corresponding to the candidate attribute label is the same as the dimension of the embedded representation corresponding to the first object. The correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to the candidate attribute label can be determined based on the spatial similarity between the embedded representation corresponding to the first object and the embedded representation corresponding to the candidate attribute label.
[0089] Optionally, the correlation model includes a dual-tower structure, which can ensure that the embedded representation corresponding to the object and the embedded representation corresponding to the attribute label belong to the same embedding space. In some embodiments, the correlation is used to reflect the similarity between the two embedded representations.
[0090] In some embodiments, a higher correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to the candidate attribute tag indicates a better match between the first object and the candidate attribute tag, i.e., the candidate attribute tag is capable of representing the first object's preference. A lower correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to the candidate attribute tag indicates a worse match between the first object and the candidate attribute tag.
[0091] In some embodiments, the computer device determines the correlation between the first object and the attribute label based on the embedded representation corresponding to the first object and the embedded representation of the attribute label, including: calculating a cosine value between the embedded representation corresponding to the first object and the embedded representation of the attribute label; and determining the correlation between the first object and the attribute label based on the cosine value. Optionally, a larger cosine value indicates a greater correlation between the first object and the attribute label, and a smaller cosine value indicates a greater difference between the first object and the attribute label.
[0092] In some embodiments, the computer device determines at least one attribute label that matches the first object based on the correlation between the embedded representation corresponding to the first object and the embedded representations corresponding to at least one candidate attribute label, including: if the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to the candidate attribute label is greater than or equal to a correlation threshold, then determining the candidate attribute label as the attribute label that matches the first object.
[0093] The relevance threshold is used to filter the attribute tag that matches the object from at least one candidate attribute tag. Optionally, the value of the relevance threshold is pre-set. The specific value of the relevance threshold is set according to the actual situation and is not limited in this application.
[0094] In some embodiments, the computer device determines at least one attribute tag matching the first object based on a correlation between an embedded representation corresponding to the first object and an embedded representation corresponding to at least one candidate attribute tag, including: the computer device selects, from the at least one candidate attribute tag, top n candidate attribute tags having the highest correlation between their embedded representation and the embedded representation corresponding to the first object, and determines the n candidate attribute tags as matching attribute tags for the first object, where n is a positive integer. For example, n is equal to 3.
[0095] The goal of this method is to select candidate attribute labels from the set L = {l1,…,l k}, a series of related attribute labels l∈{l1,…,l k Specifically, this method establishes an object node u∈U and a semantic label l∈{l1,…,l k} correlation model to achieve this goal.
[0096] In some embodiments, the computer device determines an embedded representation corresponding to the first object using a correlation model and calculates the correlation between the embedded representation corresponding to the first object and the embedded representation of at least one candidate attribute tag. Optionally, the correlation model further includes a matching layer for determining the correlation similarity between the embedded representation corresponding to the object and the embedded representation corresponding to the at least one candidate attribute tag.
[0097] In some embodiments, the matching layer object in the correlation model retrieves an embedded representation that has a higher correlation with the embedded representation corresponding to the first object from the embedded representations corresponding to at least one candidate attribute label. Optionally, the matching layer includes a vector retrieval tool (such as Annoy), which determines the embedded representations corresponding to at least one candidate attribute label adjacent to the embedded representation corresponding to the first object in the embedding space through the vector retrieval tool, and calculates the correlation between the embedded representations corresponding to the first object and the at least one candidate attribute label. The embedding space can be understood as a matrix space or a vector space corresponding to the embedded representation.
[0098] By mapping the embedding representation corresponding to the object and the embedding representation corresponding to at least one candidate attribute label into the same embedding space, it helps to reduce the computational complexity of the process of determining the attribute label matching the object.
[0099] In one example, for a video recommendation service, a computer device obtains a heterogeneous information network for the video recommendation service. Optionally, the heterogeneous information network includes: object nodes, nodes corresponding to video resources, and a first association edge for representing the interactive relationship between the object node and the resource node; the computer device determines an embedded representation corresponding to the first object based on a local subgraph corresponding to the first object in the heterogeneous information network; and the computer device determines at least one matching attribute tag for the first object based on the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to at least one candidate attribute tag. This allows the video recommendation service to subsequently recommend corresponding video resources for the first object based on the matching attribute tags of the first object.
[0100] In summary, the embedding representation of an object is determined based on the local subgraph corresponding to the object in a heterogeneous information network. Compared to related techniques that randomly walk the heterogeneous information network to determine the node sequence and then process the node sequence to generate the embedding representation corresponding to all objects in the heterogeneous information network, this method utilizes the structural information in the heterogeneous information network of the recommendation system to determine the embedding information corresponding to the object.
[0101] On the one hand, in the process of determining the embedded representation corresponding to an object, fewer nodes are required, which helps to reduce the amount of computation required to determine the embedded representation corresponding to the object and improve the speed of determining the embedded representation corresponding to the object.
[0102] Furthermore, when a heterogeneous information network undergoes transformation, the computer device can re-determine the embedded representations corresponding to some objects based on their corresponding local subgraphs, eliminating the need to update the embedded representations for all objects. This improves the flexibility of determining the embedded representations corresponding to objects, alleviates the problem of large storage space consumption during the process, and makes the method for determining the embedded representations corresponding to objects more lightweight.
[0103] The following describes a method for determining the embedded representation corresponding to the first object through several implementations.
[0104] First, several methods for determining the embedded representation corresponding to the first object are briefly described.
[0105] Example 1: A computer device determines an embedded representation corresponding to a first object based on a resource node in a local subgraph.
[0106] Example 2: The computer device determines the embedded representation corresponding to the first object based on the resource nodes and resource attribute nodes in the local subgraph.
[0107] Example 3: The computer device determines the embedded representation corresponding to the first object based on the resource nodes and the object attribute nodes in the local subgraph.
[0108] Example 4: The computer device determines an embedded representation corresponding to the first object based on the resource nodes, resource attribute nodes, and object attribute nodes in the local subgraph.
[0109] The following describes the above four methods for determining the embedded representation corresponding to the first object through several embodiments. For details of the terms not explained and the processes not introduced in detail in the above four examples, please refer to the embodiments below.
[0110] Example 1: Determine the embedded representation corresponding to the first object based on the resource nodes in the local subgraph.
[0111] In some embodiments, a computer device generates an embedded representation corresponding to the first object based on a local subgraph corresponding to the first object in a heterogeneous information network, including: the computer device generates a resource sequence based on at least one resource node in the local subgraph that has a first associated edge with the first object node; the computer device generates an embedded representation corresponding to the resource sequence; wherein the embedded representation corresponding to the resource sequence is used to represent feature information of at least one network resource that interacts with the first object; the computer device generates an embedded representation corresponding to the first object based on the embedded representation corresponding to the resource sequence.
[0112] In some embodiments, the resource sequence includes: at least one resource node in the local subgraph that has an associated edge with the first object node. Alternatively, the local subgraph includes all nodes in the heterogeneous information network that have an associated edge with the first object node, that is, the local subgraph includes all resource nodes that have a first associated edge with the first object node. In this case, the resource sequence can be understood as including all resource nodes in the local subgraph.
[0113] In some embodiments, to reduce the computational burden of the correlation model, the resource sequence can include at most y resource nodes, where y is a positive integer. If the total number of resource nodes in the local subgraph is greater than y, the computer device selects y resource nodes from the plurality of resource nodes included in the local subgraph.
[0114] Optionally, y is a positive integer. For example, y is equal to any integer between [10, 20]. It should be noted that the specific value of y is determined according to business needs and is not limited in this application.
[0115] Optionally, the computer device determines y resource nodes included in the resource subsequence based on the first association edges corresponding to the plurality of resource nodes in the local subgraph. For example, the computer device determines y first association edges from the plurality of first association edges based on the interaction moments recorded by the plurality of first association edges corresponding to the first object node; the computer device uses the resource nodes connected by the y first association edges as the y resource nodes, and generates a resource sequence based on the y resource nodes.
[0116] In some embodiments, the computer device determines y first associated edges based on the interaction moments recorded by multiple first associated edges included in the local subgraph, including: the computer device takes the first y first associated edges whose interaction moments are closest to the first moment as the y first associated edges.
[0117] In some embodiments, the first moment is any moment in the process of determining the embedded representation corresponding to the first object, and the first moment can be understood as the current moment. That is, in the above method, resource nodes corresponding to the y network resources most recently accessed by the first object are selected, and a resource sequence is generated based on the y resource nodes.
[0118] In some embodiments, there is an arrangement order between the multiple resource nodes included in the resource sequence. Optionally, the arrangement order between the multiple resource nodes included in the resource sequence is related to the interactive behavior of the first object. For details of this process, please refer to the following embodiments.
[0119] In some embodiments, a computer device determines an embedded representation of a resource sequence through a machine learning model. For details of this process, please refer to the embodiments below.
[0120] It should be understood that a heterogeneous information network refers to a directed graph with different node types. Computer devices obtain resource sequences based on local subgraphs. This can be achieved by extracting local subgraphs from the heterogeneous information network and searching for resource nodes in the local subgraphs.
[0121] It can also be implemented by a computer device accessing the behavior information of the first object. In some embodiments, the computer device determines to generate a resource sequence based on the behavior information of the object. The behavior information of the object includes at least one network resource that the object has accessed. For example, in the case where the network resource is a video resource, the behavior information can be extracted from the historical playback record of the object. Optionally, the computer device determines the resource node corresponding to the at least one network resource in the heterogeneous information network based on the at least one network resource included in the behavior information, and generates a resource sequence based on the at least one resource node obtained.
[0122] Through the above method, the local subgraph corresponding to the object is used to determine the resource sequence, and the resource sequence is used to participate in the embedded representation corresponding to the object; on the one hand, in the process of determining the embedded representation corresponding to the object, only the resource nodes corresponding to the network resources that interact with the object are used, and the number of resource nodes can also be controlled, which reduces the computational complexity of determining the embedded representation corresponding to the object, and reduces the interference of other irrelevant network nodes in the heterogeneous information network in the process of determining the embedded representation, which helps to improve the accuracy of determining the embedded representation corresponding to the object.
[0123] On the other hand, the object's corresponding embedded representation is determined based on its historical access resources (obtained through interaction), allowing the same object to have different embedded representations at different times. This approach allows the attribute labels matched to the object, determined based on its corresponding embedded representation, to be updated promptly as the object's interaction with network resources changes, thereby improving the real-time performance of the recommended network resources determined based on the attribute labels matched to the object.
[0124] The following describes a method for determining a resource sequence through several embodiments.
[0125] Because an object's interests and hobbies are not fixed, the types and properties of the network resources accessed by the object at different times may not be exactly the same. The order of multiple network resources in the resource sequence is determined based on the order in which the object interacts with at least one network resource, so that the resource sequence can reflect the changes in the object's interests.
[0126] In some embodiments, a computer device generates a resource sequence based on at least one resource node having a first association edge with a first object node in a local subgraph, including: the computer device determines, for each resource node in the at least one resource node having a first association edge with the first object node, an arrangement order of the resource nodes in the resource sequence based on the interaction time recorded on the first association edge between the resource node and the first object node; the computer device arranges the at least one resource node having a first association edge with the first object node according to their respective corresponding arrangement orders to generate a resource sequence.
[0127] In some embodiments, a first association edge between a first object node and a resource node included in a local subgraph records the time of interaction between the first object and a resource corresponding to the resource node. If the first object node interacts with a resource node multiple times, the first association edge between the first object node and the first resource node records the time of the most recent interaction.
[0128] In some embodiments, a computer device determines the arrangement order of resource nodes in a resource sequence based on the interaction time recorded on the first association edge between the resource node and the first object node, including: the computer device obtains the interaction time recorded on each first association edge connected to the first object node, and sorts at least one resource node according to the interaction time recorded on the first association edge.
[0129] Optionally, the computer device sorts at least one resource node according to interaction time from earliest to latest to obtain a resource sequence. For example, if the interaction time corresponding to resource node 1 is 12:00:01, the interaction time corresponding to resource node 2 is 12:05:03, and the interaction time corresponding to resource node 3 is 11:30:45, resource node 1, resource node 2, and resource node 3 are sorted according to interaction time from earliest to latest to obtain a resource sequence of (resource node 3, resource node 1, resource node 2).
[0130] Optionally, the computer device sorts at least one resource node according to interaction time from latest to earliest to obtain a resource sequence. For example, the interaction time corresponding to resource node 4 is 10:00:10, the interaction time corresponding to resource node 2 is 10:11:03, and the interaction time corresponding to resource node 3 is 10:30:45. Resource nodes 1, 2, and 3 are sorted according to interaction time from latest to earliest to obtain a resource sequence of (resource node 3, resource node 2, resource node 1).
[0131] Optionally, the network result used in the process of determining the embedded representation corresponding to the first object through the resource sequence has an attention mechanism, which can arrange the order of different resource nodes in the resource sequence, determine the connection between each resource node, or affect the weight of each resource node in the process of determining the embedded representation corresponding to the first object. For a detailed introduction to this process, please refer to the next embodiment.
[0132] By determining the order of resource nodes in the resource sequence at the interaction moment, the resource nodes corresponding to different interaction moments play different roles in determining the embedded representation corresponding to the resource sequence, which helps to improve the expressive power of the embedded representation corresponding to the determined resource sequence for the network resources recently accessed by the object.
[0133] In some embodiments, after determining the resource sequence, the computer device generates an embedded representation of the resource sequence through the semantic tower on the object side. The following describes the generation process of the embedded representation corresponding to the resource sequence through several embodiments.
[0134] In some embodiments, a computer device generates an embedded representation corresponding to a resource sequence, including: the computer device determines identification information corresponding to at least one resource node included in the resource sequence; wherein the identification information corresponding to the resource node is used to identify the network resource corresponding to the resource node; the computer device inputs the identification information corresponding to at least one resource node into the object-side semantic tower; wherein the object-side semantic tower is a neural network for generating an embedded representation corresponding to the first object; the computer device encodes the identification information corresponding to at least one resource node through the resource embedding layer of the object-side semantic tower to obtain a vector representation of the resource sequence; the computer device encodes the vector representation of the resource sequence through the neural network layer in the object-side semantic tower to obtain an embedded representation corresponding to the resource sequence.
[0135] In some embodiments, different network resources have different registration codes in the registration table, and the registration codes can be used as identification information of the resource node corresponding to the network resource. Optionally, different resource nodes correspond to different identification information.
[0136] For the specific structure of the object-side semantic tower, please refer to the above introduction and will not be elaborated here.
[0137] In some embodiments, the dimensions of the identification information corresponding to at least one resource node in the resource sequence are the same, so the object-side semantic tower may have only one resource input layer. The computer device transmits the identification information corresponding to at least one resource node included in the resource sequence to the resource input layer of the object-side semantic tower.
[0138] In some embodiments, the computer device determines the vector representation of the resource sequence according to the identification information corresponding to each resource node through the resource embedding layer of the object-side semantic tower; the computer device encodes the vector representation of the resource sequence through the neural network layer in the object-side semantic tower to obtain the embedding representation corresponding to the resource sequence.
[0139] In some embodiments, the computer device uses a resource embedding layer of the object-side semantic tower to determine an embedded representation of a resource node based on identification information of the resource node. The neural network layer of the object-side semantic tower encodes the embedded representation of at least one resource node to obtain an embedded representation corresponding to the resource sequence.
[0140] Optionally, the neural network layer of the object-side semantic tower arranges the embedded representations corresponding to at least one resource node according to their order in the resource sequence, and encodes the embedded representations corresponding to each arranged resource node to obtain an embedded representation corresponding to the resource sequence. Specifically, when the resource embedding layer generates the embedded representation corresponding to the resource sequence, in addition to considering the embedded representations corresponding to each resource node, it also considers the spatial position of each resource node in the resource sequence. This approach helps improve the expressive power of the embedded representation corresponding to the resource sequence.
[0141] In some embodiments, the neural network layer in the object-side semantic tower is a neural network with memory capability, such as an RNN (Recurrent Neural Network). Optionally, the neural network layer in the object-side semantic tower includes, but is not limited to, at least one of the following: an LSTM (Long Short Term Memory) layer, a BiLSTM (Bi-directional Long Short-Term Memory) layer, or a GRU (Gate Recurrent Unit) layer.
[0142] Optionally, the neural network layer in the object-side semantic tower can determine the influence of each resource node in the resource sequence on the embedded representation corresponding to the resource sequence according to the arrangement order of different resource nodes in the resource sequence, so that the resource node most recently accessed by the first object in the resource sequence has a greater influence on the embedded representation generation process corresponding to the resource sequence, and the resource node corresponding to the resource node accessed earlier by the first object in the resource sequence has a smaller influence on the embedded representation generation process corresponding to the resource sequence.
[0143] In one example, the network resource is a video resource. The computer device generates a video resource sequence based on the local subgraph, wherein the video resource sequence includes a resource node corresponding to at least one video resource. The computer device transmits identification information corresponding to each video resource in the video resource sequence to the object-side semantic tower via the resource input layer of the object-side semantic tower. The computer device determines the embedded representation corresponding to each video resource node in the video resource sequence via the resource embedding layer of the object-side semantic tower. The computer device encodes the embedded representations corresponding to different video resource nodes via the neural network layer in the object-side semantic tower to obtain an embedded representation of the video resource sequence. Optionally, the computer device uses the embedded representation determined as the video resource sequence as the embedded representation of the first object.
[0144] Example 2: The computer device determines the embedded representation corresponding to the first object based on the resource nodes and resource attribute nodes in the local subgraph.
[0145] In some embodiments, the local subgraph also includes: at least one resource attribute node connected to at least one resource node in the local subgraph through a second association edge; wherein, the at least one resource node in the local subgraph refers to a resource node connected to the first object node through a first association edge, and the second association edge is used to characterize that the network resource corresponding to the resource node has the resource attribute corresponding to the resource attribute node; the method also includes: the computer device generates a resource attribute sequence corresponding to at least one resource attribute category according to the local subgraph; wherein the resource attribute sequence includes a resource attribute node having a second association edge with at least one resource node in the resource sequence; the computer device generates an embedded representation corresponding to the resource attribute according to the resource attribute sequence corresponding to at least one resource attribute category; the computer device generates an embedded representation corresponding to the first object according to the embedded representation corresponding to the resource sequence, including: the computer device generates an embedded representation corresponding to the first object according to the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute.
[0146] In some embodiments, resource attributes are used to represent attribute information of network resources.
[0147] In order to improve the ability of resource attributes to describe network resources, different resource attribute types can be set, and each resource attribute category includes at least one resource attribute. Optionally, the resource attributes included in the same resource attribute category are obtained by dividing them according to a certain dimension.
[0148] For example, if network resources are audio resources, they can be divided into the following categories from the audio style dimension: pure music attributes, pop music attributes, rock music attributes, and metal music attributes, etc.; from the audio source dimension, they can be divided into the following categories: film and television soundtrack attributes, independent music attributes, etc.; from the soundtrack instrument dimension, they can be divided into the following categories: string music attributes, wind music attributes, etc.
[0149] In some embodiments, a network resource may have multiple resource attributes. Optionally, at least two resource attributes may belong to the same resource category. For example, in the previous example, an audio resource may have both a string instrument attribute and a wind instrument attribute.
[0150] For example, consider a video resource. By categorizing the video's cast, we can obtain the following attributes: actor a's cast attributes, actor b's cast attributes, and actor c's cast attributes. If a video resource includes actors a and c, then the video resource will have actor a's cast attributes and actor c's cast attributes in the video cast dimension.
[0151] Optionally, the resource attributes of the network resource are pre-set. For example, when the version provider lists the network resource, it will upload the resource attributes of the network resource. In the process of building a heterogeneous information network, the computer device obtains the resource attributes corresponding to each network resource; the computer device improves the heterogeneous information network based on the resource attributes of the network resources. For example, based on resource attribute 1 corresponding to network resource 1, the computer device generates a second association edge between the resource node corresponding to network resource 1 and the resource attribute node corresponding to resource attribute 1.
[0152] In some embodiments, the heterogeneous information network further includes a resource attribute node corresponding to a resource attribute and a second association edge, wherein different resource attribute nodes correspond to different resource attributes. The second association edge is used to connect resource attribute nodes corresponding to at least one resource attribute of the network resource corresponding to the resource node.
[0153] In some embodiments, the local subgraph includes: a first object node, a first association edge, a resource node having the first association edge with the first object node, a second association edge, and at least one resource attribute node connected to at least one resource node having the first association edge with the first object node via the second association edge. In other words, the local subgraph corresponding to the first object is used not only to record the network resources accessed by the first object, but also to record at least one resource attribute corresponding to the network resources accessed by the first object.
[0154] In some embodiments, a second association edge is used to connect a resource node and a resource attribute node. Optionally, one second association edge is used to connect one resource node and one resource attribute node. Optionally, only one second association edge exists between one resource node and one resource attribute node; a resource node can have second association edges with multiple resource attribute nodes, meaning that the network resources corresponding to the resource node can have different resource attributes.
[0155] In some embodiments, the resource attribute sequences corresponding to the resource attribute categories include at least one resource attribute node, and a second association edge exists between the resource attribute node included in the resource attribute sequence and at least one resource node included in the resource sequence.
[0156] In some embodiments, the computer device generates a resource attribute sequence corresponding to at least one resource attribute category based on the local subgraph; and the computer device determines the corresponding embedded representation of the resource attribute using the object-side semantic tower. For details on this process, please refer to the following examples.
[0157] In some embodiments, the dimension of the embedded representation corresponding to the resource sequence is the same as the dimension of the embedded representation corresponding to the resource attribute. In this way, the processing logic of the computer device according to the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute can be simplified, thereby improving the speed of generating the embedded representation corresponding to the first object.
[0158] It should be noted that this application does not limit the order of determining the embedded representations corresponding to the resource sequence and the embedded representations corresponding to the resource attributes.
[0159] In one example, the computer device first determines the embedded representation corresponding to the resource sequence, and then determines the embedded representation corresponding to the resource attribute. In another example, the computer device first determines the embedded representation corresponding to the resource attribute, and then determines the embedded representation corresponding to the resource sequence. In another example, the computer device simultaneously determines the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute.
[0160] Optionally, the computer device generates an object-side embedded representation based on the local subgraph via an object-side semantic tower. The computer device transmits the local subgraph to the object-side semantic tower, which generates an embedded representation corresponding to the resource sequence and an embedded representation corresponding to the resource attribute sequence based on the local subgraph. Furthermore, the object-side semantic tower generates an embedded representation corresponding to the first object based on the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute sequence. For details on this process, please refer to the following embodiments.
[0161] Using resource attributes from multiple resource attribute categories to describe network resources allows for a more comprehensive description of network resources. The resource attributes of network resources can be understood as auxiliary information used in determining the embedded representation of an object. The local subgraph corresponding to the object includes nodes corresponding to the network resource and resource attributes, respectively. This provides more auxiliary information when determining the embedded representation corresponding to the object based on the local subgraph, helping to improve the ability of the embedded representation corresponding to the object to describe the object's interests and hobbies, increase the richness of the embedded representation corresponding to the object, and enhance the effectiveness of the recommendation service's network resource recommendation.
[0162] The following describes a method for generating a resource attribute sequence through several embodiments.
[0163] In some embodiments, the computer device generates a resource attribute sequence corresponding to at least one resource attribute category based on a local subgraph, including: the computer device determines, for a first resource attribute category in at least one resource attribute category, at least one first resource attribute node corresponding to each resource node in the resource sequence in the first resource attribute category based on a second association edge in the local subgraph; the computer device generates a resource attribute sequence corresponding to the first resource attribute category based on at least one first resource attribute node corresponding to each resource node in the resource sequence.
[0164] In some embodiments, for the first resource node in a resource sequence, the computer device determines at least one first resource attribute node that belongs to the first resource attribute category and has a second association edge with the first resource node; the computer device obtains a first resource attribute subsequence corresponding to the first resource node based on the at least one first resource attribute node; the computer device uses the first resource subsequence to replace the first resource node in the resource sequence; after the computer device uses the first resource attribute subsequences corresponding to each resource node to replace the corresponding resource nodes in the resource sequence, a resource attribute sequence belonging to the first resource attribute category is obtained.
[0165] In the case where the resource sequence includes all object nodes that have a first association edge between the local subgraph and the first object node, the above process can be understood as the computer device obtaining all resource attribute nodes included in the local subgraph; the computer device classifies all attribute nodes in the local subgraph to obtain a resource attribute sequence corresponding to at least one resource attribute category.
[0166] Optionally, the resource attribute sequence corresponding to the resource attribute category does not include repeated resource attribute nodes. For example, the resource attribute sequence corresponding to a resource attribute category includes: resource attribute node 1 and resource attribute node 2, and resource attribute node 1 and resource attribute node 2 are different resource attribute nodes.
[0167] Optionally, the resource attribute sequence corresponding to a resource attribute category includes repeated resource attribute nodes. For example, the resource attribute sequence corresponding to a resource attribute category includes: resource attribute node 1, resource attribute node 3, and resource attribute node 1, where resource attribute node 1 and resource attribute node 3 are different resource attribute nodes. Including multiple identical resource attribute nodes in the resource attribute sequence is equivalent to assigning independent weights to different resource attribute nodes. This method enables different resource attribute nodes to have different degrees of influence on the generation process of the embedded representation corresponding to the resource attribute.
[0168] Since the resource attributes corresponding to the resource attribute nodes of different resource attribute categories are expressed in different ways, resource attribute sequences corresponding to different resource attribute categories are generated, so that subsequent steps can select appropriate methods to encode the resource attribute sequences corresponding to different resource attribute categories according to the characteristics of different resource attribute types, which helps to improve the accuracy of the embedded representations corresponding to different resource attribute categories.
[0169] The following describes the process of determining the embedded representation of resource attributes through several implementations.
[0170] In some embodiments, a computer device generates an embedded representation corresponding to a resource attribute based on a resource attribute sequence corresponding to at least one resource attribute category, including: for a first resource attribute category in at least one resource attribute category, the computer device determines identification information corresponding to at least one resource attribute node included in the resource attribute sequence corresponding to the first resource attribute category; wherein the identification information corresponding to the resource attribute node is used to identify the resource attribute corresponding to the resource attribute node; the computer device encodes the identification information corresponding to at least one resource attribute node included in the resource attribute sequence corresponding to the first resource attribute category through a resource attribute embedding layer corresponding to the first resource attribute category in an object-side semantic tower, and obtains an embedded representation corresponding to the first resource attribute category; wherein the object-side semantic tower is used to generate an embedded representation corresponding to the first object; the computer device encodes the embedded representation corresponding to at least one resource attribute class through a resource attribute pooling layer in the object-side semantic tower, and obtains an embedded representation corresponding to the resource attribute.
[0171] In some embodiments, the resource attribute corresponding to the resource attribute node is represented in text form. The identification information corresponding to each resource attribute node is composed of an identity identifier corresponding to at least one independent character obtained by splitting the textual resource attribute. Optionally, the identity identifier corresponding to each independent character includes at least one character (e.g., a binary character).
[0172] In some embodiments, the object-side semantic tower includes a network layer for generating embedded representations corresponding to resource attributes. Optionally, the network layer for generating embedded representations corresponding to resource attributes includes at least one input layer corresponding to each attribute resource category, at least one resource attribute embedding layer for determining the embedded representation corresponding to each attribute resource category, and a resource attribute pooling layer for processing the embedded representations corresponding to different resource attribute categories.
[0173] As mentioned above, resource attributes are in textual form, and their identification information is related to at least one of the word segments that make up the resource attribute. The identification information corresponding to resource attribute nodes of different resource attribute categories is represented differently. The object-side semantic tower includes resource attribute input layers corresponding to different resource attribute categories to accommodate the representation of identification information in different resource attribute categories. For example, resource attribute category 1 corresponds to resource attribute input layer 1, and resource attribute category 2 corresponds to resource attribute input layer 2.
[0174] In some embodiments, data is transmitted between the resource attribute input layer corresponding to each resource attribute category and the resource attribute embedding layer corresponding to each resource attribute category.
[0175] For example, the computer device inputs the identification information corresponding to at least one resource attribute node included in the resource attribute sequence corresponding to attribute resource category 1 into the resource attribute input layer 1 corresponding to attribute resource category 1, and the resource attribute input layer 1 passes the identification information corresponding to the above-mentioned at least one resource attribute node to the resource attribute embedding layer 1 corresponding to resource attribute category 1; the resource attribute embedding layer 1 encodes the identification information corresponding to the above-mentioned at least one resource attribute node to obtain the embedded representation corresponding to attribute resource category 1.
[0176] In one embodiment, data is transmitted between the resource attribute embedding layer corresponding to each resource attribute category and the global pooling layer used to generate the embedding representation corresponding to the resource attribute. Optionally, the global pooling layer is a global average pooling layer.
[0177] Optionally, the global pooling layer includes at least one fully connected layer, and the embedded representations corresponding to multiple resource attribute categories are processed by the at least one fully connected layer to obtain embedded representations corresponding to the resource attributes.
[0178] For example, network resources have k resource attribute categories, where k is a positive integer. The k resource attribute categories are respectively corresponding to k resource attribute embedding layers, and the embedded representations of the resource attribute categories obtained by encoding them are passed to the global pooling layer. The global pooling layer processes the embedded representations corresponding to the k resource attribute categories to obtain the embedded representations of the resource attributes.
[0179] If the resource attribute sequence corresponding to a certain resource attribute category includes a large number of resource attribute nodes, in order to reduce the amount of computation in the process of generating the embedded representation corresponding to the resource attribute, the computer device uses a random sampling method to select x resource attribute nodes from the resource attribute sequence corresponding to the resource attribute category; the computer device inputs the identification information corresponding to the x resource attribute nodes into the resource attribute input layer corresponding to the resource attribute category in the object-side semantic tower, where x is a positive integer.
[0180] This method reduces the amount of identification information corresponding to resource attribute nodes that the object-side semantic tower needs to process, which helps to improve the speed of determining the embedded representation corresponding to the resource attribute, and further improves the speed of determining the attribute label matching the object.
[0181] In some embodiments, in order to further reduce the amount of computation in the process of determining the embedded representation corresponding to the resource attribute, the computer device selects at least one resource attribute category from multiple resource attribute categories, and the computer device uses the object-side semantic tower to determine the embedded representation corresponding to the at least one selected resource category, and encodes the embedded representation corresponding to the at least one selected resource category through the global pooling layer to obtain the embedded representation corresponding to the resource attribute.
[0182] Optionally, the computer device selects a resource attribute sequence corresponding to at least one resource attribute category based on the number of resource attribute nodes included in the resource attribute sequences corresponding to the resource attribute categories. For example, the computer device uses the resource attribute sequence containing the first t resource attribute sequences with the smallest resource attribute nodes as the target resource attribute sequence; the computer device selects the resource attribute categories corresponding to the t target resource attribute sequences, where t is a positive integer. In this case, the computer device uses the object-side semantic tower to determine the embedded representation corresponding to the resource attribute based on the t target resource attribute sequences.
[0183] The resource attribute sequence contains a small number of resource attribute nodes, which to a certain extent can indicate that the object has a high degree of concentration of interest in the resource attributes of interest in this resource attribute category, that is, multiple resource nodes in the local subgraph correspond to the same resource attribute nodes in the resource attribute sequence.
[0184] Using a resource attribute sequence containing a small number of resource attribute nodes to determine the embedding representation corresponding to the resource attribute helps improve the description ability of the embedding representation corresponding to the resource attribute for the object to which the object is more interested, and improves the relevance of the object's matching label with the resource attributes that these objects are more interested in, thereby helping to improve the recommendation effect of the recommendation service.
[0185] By setting different input layers and embedding layers for different resource attribute categories in the object-side semantic tower in the above manner, it is possible to determine the embedding representations corresponding to each resource attribute category based on the characteristics of the identification information corresponding to the resource attribute nodes in different resource attribute categories, thereby improving the accuracy of the embedding representations corresponding to each resource attribute category.
[0186] The following describes the process of generating the embedded representation corresponding to the first object through several embodiments.
[0187] In some embodiments, a computer device generates an embedded representation corresponding to a first object based on the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute, including: the computer device splices the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute through the splicing layer of the object-side semantic tower to obtain a first spliced embedded representation; the computer device encodes the first spliced embedded representation through the representation layer in the object-side semantic tower to obtain the embedded representation corresponding to the first object.
[0188] When the local subgraph includes resource nodes and resource attribute nodes, the computer device can determine the embedded representations corresponding to the resource nodes and resource attribute nodes, respectively, and generate the embedded representation corresponding to the first object using the embedded representations corresponding to the resource nodes and resource attribute nodes. This method provides more reference information for the generation process of the embedded representation corresponding to the first object, helping to improve the accuracy of the determined embedded representation corresponding to the first object.
[0189] In some embodiments, the object-side semantic tower includes: a network layer for generating embedded representations corresponding to resource sequences and a network layer for generating embedded representations corresponding to resource attributes.
[0190] Optionally, the network layer for generating the embedded representation corresponding to the resource sequence includes: a resource input layer, an embedding layer for determining the embedded representation corresponding to the resource node, and a neural network layer for determining the embedded representation corresponding to the resource sequence.
[0191] Optionally, the network layer for generating embedded representations corresponding to resource attributes includes: a resource attribute input layer corresponding to at least one resource attribute category, at least one embedding layer for determining the embedded representations corresponding to the resource attribute categories, and a global pooling layer (of resource attributes) for encoding the embedded representations corresponding to at least one resource attribute category.
[0192] In some embodiments, the object-side semantic tower further includes a splicing layer and a representation layer, wherein the splicing layer of the object-side semantics is used to splice different types of embedded representations. Optionally, the different types of embedded representations include: embedded representations corresponding to resource sequences and embedded representations corresponding to resource attributes.
[0193] In some embodiments, data is transferred between the splicing layer and the neural network layer of the object-side semantic tower, and between the splicing layer and the fully connected layer of resource attributes. The neural network layer transfers the embedded representation corresponding to the resource sequence to the splicing layer of the object-side semantic tower; the fully connected layer of resource attributes transfers the embedded representation corresponding to the resource attributes to the splicing layer of the object-side semantic tower.
[0194] In some embodiments, the computer device splices the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute through the splicing layer of the object-side semantic tower to obtain a first spliced embedded representation; the computer device encodes the first spliced embedded representation through the representation layer in the object-side semantic tower to obtain the embedded representation corresponding to the first object.
[0195] Optionally, the first concatenated embedded representation includes an embedded representation corresponding to the source sequence and an embedded representation corresponding to the resource attribute.
[0196] The computer device determines at least one resource node corresponding to a network resource that interacts with the object, and at least one resource attribute node corresponding to each of the above resource nodes; the computer device determines the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute, and generates an embedded representation corresponding to the object through the above two embedded representations. This method helps to improve the ability of the embedded representation corresponding to the object to describe the interaction between the object and the network resource. In the actual business process, the attribute label of the object is determined by the above method, so that the attribute label of the object can be flexibly changed according to the change of the interactive behavior between the object and the network resource, helping the recommendation service to adaptively select the network resource recommended to the object according to the attribute label corresponding to the object.
[0197] Example 3: The computer device determines the embedded representation corresponding to the first object based on the resource nodes and the object attribute nodes in the local subgraph.
[0198] In some embodiments, the local subgraph also includes object attribute nodes, which are also needed in the process of determining the corresponding embedded representation of the object. The following describes this process through several embodiments.
[0199] In some embodiments, the local subgraph also includes: at least one object attribute node having a third association edge with the first object node; wherein the third association edge is used to represent that the object corresponding to the object node has the object attribute corresponding to the object attribute node; the method also includes: the computer device generates, according to the local subgraph, object attribute nodes corresponding to at least one object attribute category; wherein the object attribute sequence includes at least one resource attribute node having a third association edge with the first object node; the computer device generates an embedded representation corresponding to the object attribute according to the object attribute sequence corresponding to at least one object attribute category; the computer device generates an embedded representation corresponding to the first object according to the embedded representation corresponding to the resource sequence, including: the computer device generates an embedded representation corresponding to the first object according to the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the object attribute.
[0200] In some embodiments, object attributes refer to attribute information possessed by an object. Optionally, object attributes can be categorized into multiple object attribute categories. For example, object attribute categories include at least one of the following: object age, object gender, object region, and object interests. In some embodiments, object attributes are obtained by the subject's voluntary selection and entry. Optionally, the object attributes are entered by the subject when registering an account or editing personal information in the target application.
[0201] It should be noted that the object attributes used in this application are obtained with full authorization of the object, and the object attributes are only used to determine the embedded representation corresponding to the object and are not used for other purposes.
[0202] In some embodiments, the heterogeneous information network corresponding to the first object includes an object attribute node, and the object attribute node corresponds to an object attribute. Optionally, a third association edge may exist between the object attribute node and the object node, and the third association edge indicates that the object corresponding to the object node has the object attribute corresponding to the object attribute node.
[0203] Since the local subgraph includes all nodes related to the first object node, the local subgraph includes all object attribute nodes that have a third association edge with the first object node.
[0204] The object attribute sequences corresponding to the object attribute categories are similar to the introduction of the resource attribute sequences corresponding to the resource attribute categories in the above text. Please refer to the above embodiment for details and will not be described in detail here.
[0205] By including object nodal attributes in the local subgraph, auxiliary information is added to the process of determining the object's corresponding embedded representation, which helps to improve the richness of the determined object's corresponding embedded representation. Furthermore, through this method, the object's corresponding embedded representation is not only related to the object's interaction behavior with the network resources it accesses, but also to the object's own characteristics, which helps to improve the object's corresponding embedded representation's descriptive power and enrich the diversity of attribute labels derived from the object's corresponding embedded representation.
[0206] The following describes a method for determining an embedded representation corresponding to an object attribute sequence through several embodiments.
[0207] In some embodiments, a computer device generates an embedded representation corresponding to an object attribute based on an object attribute sequence corresponding to at least one object attribute category, including: for a first object attribute category in at least one object attribute category, the computer device determines identification information corresponding to at least one object attribute node included in the object attribute sequence corresponding to the first object attribute category; the identification information corresponding to the object attribute node is used to identify the object attribute corresponding to the object attribute node; the computer device encodes the identity identifier of at least one object attribute node through the object attribute embedding layer corresponding to the first object attribute category in the object-side semantic tower to obtain an embedding vector for the first object attribute category; wherein the object-side semantic tower is used to generate the embedded representation corresponding to the first object attribute category; the computer device encodes the embedded representation corresponding to at least one object attribute category through the object attribute pooling layer in the object-side semantic tower to obtain the embedded representation corresponding to the object attribute.
[0208] In some embodiments, the computer device processes the corresponding object attribute sequences for at least one object attribute category through a feature learning network to obtain embedding representations corresponding to different object attribute categories. Optionally, the object-side semantic tower includes an input layer corresponding to at least one object attribute category, an embedding layer corresponding to at least one object attribute category, and a global pooling layer (for object attributes).
[0209] The computer device encodes the embedded representations corresponding to different object attribute categories through the global pooling layer of the object attributes in the object-side semantic tower to obtain the embedded representations corresponding to the object attributes.
[0210] Determining the embedded representation of object attributes through the embedded representations corresponding to different object attribute categories helps to improve the expressive power of the embedded representation of object attributes for each object attribute category.
[0211] In some embodiments, a computer device generates an embedded representation corresponding to a first object based on the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the object attribute, including: the computer device splices the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the object attribute through the splicing layer of the object-side semantic tower to obtain a second spliced embedded representation; the computer device encodes the second spliced embedded representation through the representation layer in the object-side semantic tower to obtain the embedded representation corresponding to the first object.
[0212] The specific steps of this process are similar to the steps of “generating an embedded representation corresponding to the first object according to the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute” in the above embodiment.
[0213] In some embodiments, the object-side semantic tower further includes a splicing layer and a representation layer, wherein the splicing layer of the object-side semantics is used to splice different types of embedded representations. Optionally, the different types of embedded representations include: embedded representations corresponding to resource sequences and embedded representations corresponding to object attributes.
[0214] Figure 6 It is a schematic diagram of an object-side semantic tower structure provided by an exemplary embodiment of the present application.
[0215] The object-side semantic tower includes input layers corresponding to different types of nodes in the local subgraph, including a node sequence input layer, an input layer corresponding to different resource attribute categories, and an input layer corresponding to different object attribute categories; at least one embedding layer for generating embedding representations corresponding to different types of nodes, including a resource embedding layer, a resource attribute embedding layer, and an object attribute embedding layer; a resource attribute pooling layer for processing the embedding representation corresponding to at least one resource attribute category, and an object attribute pooling layer for processing the embedding representation corresponding to at least one object attribute category. And a splicing layer for splicing different types of embedded representations and a representation layer for generating embedded representations corresponding to objects. For the specific content of this aspect, please refer to the above embodiment and will not be repeated here.
[0216] The embedded representation corresponding to the object is determined based on different types of embedded representations to improve the accuracy of the embedded representation corresponding to the object.
[0217] Example 4: The computer device determines the embedded representation corresponding to the first object based on the resource nodes, resource attribute nodes, and object attribute nodes in the local subgraph. For details not described in this example, please refer to the above embodiments and will not be repeated here.
[0218] In some embodiments, the local subgraph includes a first object node, a resource node having a first association edge with the first object node, an object attribute node having a third association edge with the first object node, and a resource attribute node having at least one second association edge with at least one resource node in the local subgraph. The computer device inputs the local subgraph into the object-side semantic tower and obtains an embedded representation corresponding to the first object output by the object-side semantic tower.
[0219] The computer device determines the embedded representation corresponding to the resource sequence in the local subgraph through the resource network layer of the object-side semantic tower, determines the embedded representation corresponding to the resource attribute through the resource attribute network layer of the object-side semantic tower, and determines the embedded representation corresponding to the object attribute through the object attribute network layer of the object-side semantic tower; splices the embedded representation corresponding to the resource sequence, the embedded representation corresponding to the resource attribute, and the embedded representation corresponding to the object attribute through the splicing layer of the object-side semantic tower to obtain a third spliced representation; and processes the third spliced representation through the object attribute network layer of the object-side semantic tower to obtain the embedded representation corresponding to the first object. For the specific content of this process, please refer to the above embodiment and will not be repeated here.
[0220] Compared with related technologies, which rely on walking heterogeneous information networks to generate complete node sequences and using deep learning models to process the complete node sequences to obtain the embedded representations corresponding to each object, this method only uses the local subgraph related to the object in the heterogeneous information network to determine the embedded representation corresponding to the object, which helps to reduce the amount of computation in the process of determining the embedded representation of the household and speed up the determination of the embedded representation of the household.
[0221] This method also makes it easier to update the embedded representations of objects in a heterogeneous information network. When the heterogeneous information network changes, there's no need to synchronously update the embedded representations of all objects in the network, making the model used to determine the embedded representations of objects more lightweight.
[0222] The following describes several examples of embedding representations corresponding to attribute tags.
[0223] In some embodiments, a computer device determines at least one attribute label that matches the first object based on the correlation between the embedded representation corresponding to the first object and the embedded representations corresponding to at least one candidate attribute label, including: the computer device determines the embedded representations corresponding to at least one candidate attribute label; the computer device calculates the spatial similarity between the embedded representation corresponding to the first object and the embedded representation of the first attribute label for the first attribute label in the at least one candidate attribute label, and determines the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to the first attribute label; the computer device selects the top n candidate attribute labels with the highest correlation from the at least one candidate attribute label as the attribute labels that match the first object, where n is a positive integer.
[0224] In some embodiments, spatial similarity is used to characterize the similarity between two or more vectors (matrices) in a vector space.
[0225] In some embodiments, the computing device calculates the spatial similarity between the embedded representation corresponding to the first object and the embedded representation of the first attribute label, including: calculating a cosine value between the embedded representation corresponding to the first object and the embedded representation corresponding to the first attribute label; the computing device represents the spatial similarity between the embedded representation corresponding to the first object and the embedded representation corresponding to the first attribute label using the cosine value. Optionally, the cosine value is between [-1, 1].
[0226] Optionally, the computer device uses the spatial similarity between the embedded representation corresponding to the first object and the embedded representation corresponding to the first attribute label as the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to the first attribute label.
[0227] In some embodiments, the embedded representation corresponding to each of the at least one candidate attribute tags can be predetermined. The computer device stores the embedded representation corresponding to each of the at least one candidate attribute tags; when determining the attribute tag matching the first object, the computer device reads the embedded representation corresponding to each of the at least one candidate attribute tags.
[0228] Optionally, the computer device periodically updates the embedded representation corresponding to at least one candidate attribute tag and stores the updated embedded representation corresponding to at least one candidate attribute tag. This method helps to increase the speed at which the computer device determines a matching attribute tag for the first object.
[0229] In other embodiments, the computer device generates an embedding representation corresponding to at least one candidate attribute label only when determining the attribute label that matches the first object.
[0230] For a specific method in which a computer device determines an embedded representation corresponding to a candidate attribute tag, please refer to the next embodiment.
[0231] By comparing the spatial similarity between the embedded representation corresponding to the first object and the embedded representations corresponding to at least one candidate attribute tag, at least one embedded representation matching the object is determined, helping to match at least one attribute tag that fits the first object. Matching multiple attribute tags to an object helps to enrich the recommendations of network resources based on attribute tags.
[0232] The following describes a method for determining the embedded representation of an attribute tag through several embodiments.
[0233] In some embodiments, a computer device determines an embedded representation corresponding to at least one candidate attribute tag, including: the computer device obtains at least one related entity tag corresponding to the first attribute tag for the first attribute tag in the at least one candidate attribute tag; wherein the related entity tag has semantic similarity with the first attribute tag; the computer device determines the embedded representation corresponding to the first attribute tag based on the first attribute tag and the at least one related entity tag corresponding to the first attribute tag.
[0234] In some embodiments, the first attribute tag is any one of at least one candidate attribute tag. In some embodiments, the related entity tag corresponding to the first attribute tag is text having a similar literal meaning to the first attribute tag. Optionally, the first attribute tag corresponds to at least one related entity tag.
[0235] In some embodiments, the first attribute tag is in text form, that is, the first attribute tag includes one character. Optionally, the computer device inputs the first attribute tag into a search engine to obtain at least one search result (which may be in document form) corresponding to the first attribute tag.
[0236] Optionally, the computer device crawls business tags used in other recommendation services through a data collection method such as a crawler, and uses at least one crawled business tag as at least one search result.
[0237] In some embodiments, the computer device determines y search results from the at least one search result, where y is a positive integer, for example, y is equal to 50. Optionally, the computer device selects the top y search results from the at least one search result based on the order of the search results.
[0238] In some embodiments, the computer device obtains at least one entity tag from each of the y search results and generates an entity tag set based on the at least one entity tag. Optionally, the computer device obtains entity tags from the search results using the following methods: a template method, an RNN-based entity extraction model, or a Transformer-based entity extraction model.
[0239] In some embodiments, the computer device divides and sorts the entity tag set and selects the first p entity tags with the greatest semantic similarity to the first attribute tag, where p is a positive integer, for example, p=20.
[0240] Optionally, the computer device segments and sorts the entity tag set using a TF-IDF (Term Frequency-Inverse Document Frequency) method.
[0241] In some embodiments, the computer device determines an embedded representation of the first attribute tag based on the first attribute tag and at least one related entity tag corresponding to the first attribute tag through a tag-side semantic tower.
[0242] Attribute tags typically used in recommendation services are short, predefined texts. This means that the text descriptions of attribute tags are short and lack sufficient information expression. By identifying at least one related entity tag corresponding to an attribute tag, using the related entity tag as supplementary information for the attribute tag, and using the attribute tag and its corresponding entity tag to determine the corresponding embedded representation of the attribute tag, the embedded representation of the attribute tag can be enriched. Furthermore, by finding entity tags with similar semantics to the attribute tag, the accuracy of the embedded representation of the determined attribute tag is minimally affected.
[0243] In some embodiments, a computer device determines an embedded representation of a first attribute tag based on the first attribute tag and at least one related entity tag corresponding to the first attribute tag, including: the computer device encodes identification information corresponding to at least one word in the first attribute tag through the attribute tag embedding layer of the tag-side semantic tower to obtain a feature vector corresponding to the first attribute tag; wherein the tag-side semantic tower is used to determine the embedded representation corresponding to the first attribute tag; the computer device encodes identification information corresponding to at least one word respectively included in at least one related entity tag through the entity tag network of the tag-side semantic tower to obtain a feature vector corresponding to the related entity tag; the computer device splices the feature vector corresponding to the first attribute tag and the feature vector corresponding to the entity tag through the splicing layer of the tag-side semantic tower to obtain a tag splicing representation; the computer device encodes the tag splicing representation through the representation layer of the tag-side semantic tower to determine the embedded representation corresponding to the first attribute tag.
[0244] In some embodiments, the tag-side semantic tower includes an entity tag network and an attribute tag network. The entity tag network is used to determine the feature vector of the entity tag, and the attribute tag network is used to determine the feature vector corresponding to the attribute tag. The feature vector can also be understood as an embedded representation.
[0245] In some embodiments, the entity tag network includes an entity tag input layer and an entity tag embedding layer.
[0246] Figure 7 It is a schematic diagram of a tag-side semantic tower structure provided by an exemplary embodiment of the present application.
[0247] In some embodiments, the computer device determines identification information corresponding to at least one entity tag, and inputs the identification information corresponding to the at least one entity tag into the entity tag input layer. Optionally, the identification information corresponding to the entity tag is the identification information corresponding to the complete entity tag.
[0248] Optionally, the identification information corresponding to the entity tag is identification information corresponding to at least one word obtained by segmenting the entity tag. Determining the identification information corresponding to each word in the entity tag to form the identification information corresponding to the entity tag facilitates subsequent entity tag embedding layer encoding the identification information and performing operations such as full-connection based on feature information.
[0249] In some embodiments, the entity tag embedding layer includes at least one of the following: an RNN layer (including an LSTM layer, a BiLSTM layer, a GRU, etc.), an attention layer (including a self-attention layer, a transformer layer, etc.). Optionally, the entity tag embedding layer is referred to as an embedding representation encoder.
[0250] In some embodiments, the computer device encodes the identification information corresponding to the entity tag through the entity tag embedding layer to obtain a feature vector corresponding to the entity tag. Specifically, the entity tag embedding layer maps the identification information corresponding to the entity tag passed from the entity tag input layer into a low-dimensional, dense feature vector.
[0251] In some embodiments, the structure and working mode of the attribute tag network are similar to those of the entity tag network. Please refer to the above embodiments for details and will not be repeated here.
[0252] In some embodiments, the label-side semantic tower also includes a label splicing layer, which is used to splice the feature training corresponding to the attribute label with the feature vector corresponding to the entity label to obtain a label splicing representation. This method helps to improve the richness of the embedded representation corresponding to the determined attribute label.
[0253] In some embodiments, the tag-side semantic tower further includes a tag representation layer, which is used to further cross-represent the tag concatenation representations in the tag concatenation layer to obtain an embedded representation corresponding to the attribute tag. Optionally, the tag representation layer is implemented by stacking multiple fully connected layers.
[0254] Using entity labels and attribute labels to jointly determine the embedding representation corresponding to the attribute label helps to enrich the corresponding attribute label and improves the representation ability of the embedding representation corresponding to the attribute label.
[0255] In some embodiments, the label classification model used in the method for determining object attribute labels is a dual-tower structure, and the label classification model includes an object-side language tower and a label-side semantic tower, wherein the object-side language tower is used to determine the embedded representation corresponding to the first object, and the label-side semantic tower is used to determine the embedded representation of at least one attribute label. Optionally, by training the dual-tower label classification model, the embedded representation corresponding to the first object and the embedded representation of the attribute label are in the same embedding space (semantic space), making the method for determining the embedded representation corresponding to the first object and the embedded representation of the attribute label more convenient.
[0256] In some embodiments, after the computer device determines at least one attribute tag matching the first object based on the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to at least one candidate attribute tag, the method further includes: the computer device determines at least one recommended network resource from the network resource pool corresponding to the recommended service based on the at least one attribute tag matching the first object; and the computer device sends the recommended network resource to the client corresponding to the first object.
[0257] In some implementations, recommended network resources refer to network resources that have a high degree of similarity with at least one attribute tag. For example, if the recommendation service is a video recommendation service, the recommended network resources are video resources. For example, if the recommendation service is a product recommendation service, the recommended network resources are product resources. It should be noted that the resource type of recommended network resources is determined based on actual needs and is not limited in this application.
[0258] The following describes the training process of the label classification model.
[0259] In some embodiments, a computer device obtains a training sample set; wherein the training sample set includes training samples, and the training samples include training objects, training labels and training sample identifiers; wherein the identification information of the training samples is used to characterize whether the training objects and the training labels are related; the computer device determines the local subgraph corresponding to the training objects in the heterogeneous information network; the computer device determines the embedding representation corresponding to the training objects according to the local subgraph corresponding to the training objects through the object-side semantic tower in the correlation model; the computer device determines the embedding representation corresponding to the training labels through the label-side semantic tower in the correlation model, the computer device calculates the correlation between the embedding representation corresponding to the training objects and the embedding representation corresponding to the training labels, and predicts the results according to the correlation device; the computer device determines the training loss according to the prediction results and the training sample identifier, and adjusts the model parameters of the correlation model; when the training loss reaches convergence, the computer device obtains the trained correlation model.
[0260] In some embodiments, the training sample set used to train the correlation model is obtained from a heterogeneous information network used during the training process. Optionally, the heterogeneous information network used during the training process includes at least one object node corresponding to an object with an attribute label. The attribute label corresponding to the object can be manually annotated or obtained through other machine models, which is not limited in this application. Optionally, each training object in the training sample corresponds to one attribute label.
[0261] In some embodiments, the training sample identifier is used to indicate whether the sample is a positive sample or a negative sample.
[0262] In some embodiments, positive samples are generated by object nodes corresponding to objects with attribute labels in the heterogeneous information network. These object nodes constitute the object node set U label ∈U already has attribute labels. The computer device has attribute label set T for each u ∈L object node u∈U label , for the training samples annotated with a single attribute label of the object node u, the positive samples can be expressed as {(X u ,l)|l∈T u}. Among them, X u represents the training object, and l represents the training label.
[0263] Optionally, the sample ratio between positive samples and negative samples in the sample set is not exactly the same, for example, the sample ratio between positive samples and negative samples is 1:5.
[0264] In some embodiments, negative samples are obtained by negative sampling. For example, a computer device randomly extracts five attribute labels and training objects from the positive samples to generate negative samples.
[0265] Optionally, the sample ratio between positive samples and negative samples in the sample set is not exactly the same, for example, the sample ratio between positive samples and negative samples is 1:5.
[0266] The computer device determines the embedded representation corresponding to the training object according to the local subgraph corresponding to the training object through the object-side semantic tower in the correlation model; for the specific process of the computer device determining the embedded representation corresponding to the training label through the label-side semantic tower in the correlation model, please refer to the above embodiment, and this application will not go into details here.
[0267] In some embodiments, the training loss is calculated using binary cross entropy.
[0268] The following describes a method for determining an object attribute label using an embodiment. This method mainly includes the following steps:
[0269] Step 1: Computer equipment builds a heterogeneous information network Please refer to the above introduction for the explanation of various parameters in heterogeneous information networks.
[0270] Step 2: The computer device determines that the heterogeneous information network includes: resource nodes, resource attribute nodes, and object attribute nodes, and their corresponding embedded representations.
[0271] Specifically, for a resource node, for any object node u∈U in a heterogeneous information network: the computer device constructs the resource sequence s of the object node u u ∈s,s u In a heterogeneous information network, this refers to the sequence of resource nodes that have a first-association edge with an object node u. The resource nodes in the resource sequence of object node u are arranged in the order of interaction between the object and the network resources corresponding to the resource nodes. The computer device merges the resource sequences corresponding to each object node to obtain a node sequence set for resource node V.
[0272] For resource attribute nodes, the computer device determines that each resource node included in the resource sequence set is in resource attribute category A. i The associated resource attribute node in the resource attribute category A is used by the computer device. i In the associated resource attribute node, replace the resource node to get the resource category attribute A i The corresponding resource attribute sequence.
[0273] For resource attribute category A i , the computer device merges the resource attribute sequences corresponding to each object node to obtain the resource attribute category A i A sequence of resource attributes.
[0274] The computer device performs the node sequence set of the resource node V, the resource attribute sequence set of the resource attribute category A1, the resource attribute sequence set of the resource attribute category A2, ..., the resource attribute category A m The word vector is calculated based on the resource attribute sequence set to obtain the embedded representation of each video node and the embedded representation of each video attribute node.
[0275] For an object attribute node, the computer device determines an object attribute sequence corresponding to the object node u, and the computer device uses a machine learning model to determine an embedding representation corresponding to each object attribute node.
[0276] In step 3, the computer device determines the embedding representations corresponding to the candidate attribute labels.
[0277] For each attribute label l∈{l1,…,l k}, the computer device determines at least one entity tag corresponding to the attribute tag 1. Optionally, the computer device determines N documents related to the attribute tag 1 through a search engine. N is a positive integer. The computer device obtains a set of document titles of the N documents, and the document title set is recorded as {D1,…,D N}.
[0278] The computer device extracts entity words from the document title set, sorts and truncates the documents composed of entity words, and obtains the entity word sequence {e1,…,e M}, e i is an entity tag for the attribute tag l.
[0279] In step 4, the computer constructs training samples based on the heterogeneous information network and trains the correlation model to obtain a trained correlation model. For details about this step, please refer to the above embodiment. This training ensures that the embedded representations corresponding to the objects and the embedded representations corresponding to the attribute labels belong to the same mapping space, facilitating subsequent correlation calculations.
[0280] In step 5, the computer device uses the trained correlation model to determine an embedded representation corresponding to the first object, and determines at least one label that matches the first object based on the embedded representation corresponding to the first object.
[0281] To address the problem of excessive computational complexity caused by an overly large set of attribute labels in multi-label classification, the present invention maps the embedded representation towers corresponding to the object and the embedded representation towers corresponding to the attribute labels into the same semantic space through object-side semantics and label-side semantics. This allows for multi-label correlation determination by only calculating the correlation between the object and the closest label, significantly reducing the computational complexity of the model. Furthermore, by determining the entity labels corresponding to the attribute labels, it helps to enrich the embedded representations of the attribute labels.
[0282] The following are device embodiments of the present application, which can be used to implement the method embodiments of the present application. For details not disclosed in the device embodiments of the present application, please refer to the method embodiments of the present application.
[0283] Please refer to Figure 8 , which shows a block diagram of an apparatus for determining an object attribute label provided by an embodiment of the present application. The apparatus has the function of implementing the above-mentioned method for determining an object attribute label, and the function can be implemented by hardware or by hardware executing corresponding software. Figure 8 As shown, the apparatus 800 may include: a network acquisition module 810 , a characterization determination module 820 and a tag determination module 830 .
[0284] The network acquisition module 810 is used to obtain the heterogeneous information network required for the recommendation service; wherein the recommendation service is used to provide network resource recommendation services for objects, and the heterogeneous information network includes: an object node corresponding to at least one object, a resource node corresponding to at least one network resource, and a first association edge between the object node and the resource node, wherein the first association edge is used to represent the existence of an interaction between the object corresponding to the object node and the network resource corresponding to the resource node.
[0285] The representation determination module 820 is used to generate an embedded representation corresponding to the first object based on the local subgraph corresponding to the first object in the heterogeneous information network; wherein the local subgraph corresponding to the first object includes: a first object node corresponding to the first object, and at least one resource node having a first association edge with the first object node; the embedded representation corresponding to the first object is used to represent the feature information of the first object.
[0286] The label determination module 830 is used to determine at least one attribute label that matches the first object based on the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to at least one candidate attribute label; wherein the embedded representation corresponding to the attribute label is used to represent the semantic feature information of the attribute label.
[0287] In some embodiments, the label determination module 830 includes: a first sequence generation unit, used to generate a resource sequence based on at least one resource node in the local subgraph that has a first associated edge with the first object node; a first representation generation unit, used to generate an embedded representation corresponding to the resource sequence; wherein the embedded representation corresponding to the resource sequence is used to represent feature information of at least one network resource that interacts with the first object; and an embedded representation generation unit, used to generate an embedded representation corresponding to the first object based on the embedded representation corresponding to the resource sequence.
[0288] In some embodiments, the first sequence generation unit is used to: for each resource node of at least one resource node having a first association edge with the first object node, determine the arrangement order of the resource node in the resource sequence according to the interaction time recorded on the first association edge between the resource node and the first object node; and arrange the at least one resource node having a first association edge with the first object node according to their respective corresponding arrangement orders to generate the resource sequence.
[0289] In some embodiments, a first representation generation unit is used to determine identification information corresponding to at least one resource node included in the resource sequence; wherein the identification information corresponding to the resource node is used to identify the network resource corresponding to the resource node; the identification information corresponding to the at least one resource node is input into the object-side semantic tower; wherein the object-side semantic tower is a neural network for generating an embedded representation corresponding to the first object; the identification information corresponding to the at least one resource node is encoded through the resource embedding layer of the object-side semantic tower to obtain a vector representation of the resource sequence; the vector representation of the resource sequence is encoded through the neural network layer in the object-side semantic tower to obtain an embedded representation corresponding to the resource sequence.
[0290] In some embodiments, the local subgraph further includes: at least one resource attribute node connected to at least one resource node in the local subgraph via a second association edge; wherein, at least one resource node in the local subgraph refers to a resource node connected to the first object node via the first association edge, and the second association edge is used to represent that the network resource corresponding to the resource node has the resource attribute corresponding to the resource attribute node; the device 800 further includes a second sequence generation module, which is used to generate a resource attribute sequence corresponding to at least one resource attribute category according to the local subgraph; wherein, the resource attribute sequence includes a resource attribute node having a second association edge with at least one resource node in the resource sequence; a second representation generation unit, which is used to generate an embedded representation corresponding to the resource attribute according to the resource attribute sequence corresponding to the at least one resource attribute category; the embedded representation generation unit is also used to generate an embedded representation corresponding to the first object according to the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute.
[0291] In some embodiments, the second sequence generating unit is used to determine, for a first resource attribute category in the at least one resource attribute category, at least one first resource attribute node corresponding to each resource node in the resource sequence in the first resource attribute category according to the second association edge in the local subgraph; and generate a resource attribute sequence corresponding to the first resource attribute category according to the at least one first resource attribute node corresponding to each resource node in the resource sequence.
[0292] In some embodiments, the second sequence generation unit is used to determine, for a first resource attribute category in the at least one resource attribute category, identification information corresponding to at least one resource attribute node included in the resource attribute sequence corresponding to the first resource attribute category; wherein the identification information corresponding to the resource attribute nodes is used to identify the resource attributes corresponding to the resource attribute nodes; through the resource attribute embedding layer corresponding to the first resource attribute category in the object-side semantic tower, the identification information corresponding to at least one resource attribute node included in the resource attribute sequence corresponding to the first resource attribute category is encoded to obtain an embedded representation corresponding to the first resource attribute category; wherein the object-side semantic tower is used to generate an embedded representation corresponding to the first object; through the resource attribute pooling layer in the object-side semantic tower, the embedded representation corresponding to the at least one resource attribute class is encoded to obtain an embedded representation corresponding to the resource attribute.
[0293] In some embodiments, the embedding representation generation unit is further used to splice the embedding representation corresponding to the resource sequence and the embedding representation corresponding to the resource attribute through the splicing layer of the object-side semantic tower to obtain a first spliced embedding representation; and encode the first spliced embedding representation through the representation layer in the object-side semantic tower to obtain the embedding representation corresponding to the first object.
[0294] In some embodiments, the local subgraph also includes: at least one object attribute node having a third association edge with the first object node; wherein the third association edge is used to represent that the object corresponding to the object node has the object attribute corresponding to the object attribute node; the device 800 also includes: a third sequence generation module, used to generate object attribute nodes corresponding to at least one object attribute category according to the local subgraph; wherein the object attribute sequence includes at least one resource attribute node having a third association edge with the first object node; a third representation generation unit, used to generate an embedded representation corresponding to the object attribute according to the object attribute sequence corresponding to at least one object attribute category; the embedded representation generation unit is used to generate an embedded representation corresponding to the first object according to the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the object attribute.
[0295] In some embodiments, the third sequence generation module is used to determine, for a first object attribute category in the at least one object attribute category, identification information corresponding to at least one object attribute node included in the object attribute sequence corresponding to the first object attribute category; the identification information corresponding to the object attribute nodes is used to identify the object attributes corresponding to the object attribute nodes; the identity identifier of the at least one object attribute node is encoded through the object attribute embedding layer corresponding to the first object attribute category in the object-side semantic tower to obtain an embedding vector of the first object attribute category; wherein the object-side semantic tower is used to generate an embedding representation corresponding to the first object attribute category; the embedding representation corresponding to the at least one object attribute category is encoded through the object attribute pooling layer in the object-side semantic tower to obtain an embedding representation corresponding to the object attribute.
[0296] In some embodiments, the label determination module 830 includes: a label representation acquisition unit, used to determine the embedded representations corresponding to at least one candidate attribute label; a similarity determination unit, used to calculate the spatial similarity between the embedded representation corresponding to the first object and the embedded representation of the first attribute label for the first attribute label in at least one candidate attribute label, and determine the correlation between the embedded representation corresponding to the first object and the embedded representation of the first attribute label; a label determination unit, used to select the top n candidate attribute labels with the highest correlation from the at least one candidate attribute label as the attribute labels matching the first object, where n is a positive integer.
[0297] In some embodiments, the label representation acquisition unit includes: an entity label acquisition subunit, which is used to obtain at least one related entity label corresponding to a first attribute label in at least one candidate attribute label; wherein the related entity label has semantic similarity with the first attribute label; and a label representation generation subunit, which is used to determine the embedded representation corresponding to the first attribute label based on the first attribute label and at least one related entity label corresponding to the first attribute label.
[0298] In some embodiments, the label representation generation subunit is used to encode the identification information corresponding to at least one word in the first attribute label through the attribute label embedding layer of the label side semantic tower to obtain the embedded representation of the first attribute label; wherein the label side semantic tower is used to determine the embedded representation of the first attribute label; through the entity label network of the label side semantic tower, the identification information corresponding to at least one word respectively included in the at least one related entity label is encoded to obtain the embedded representation of the related entity label; through the splicing layer of the label side semantic tower, the embedded representation of the first attribute label and the embedded representation of the related entity label are spliced to obtain the label splicing representation; through the representation layer of the label side semantic tower, the label splicing representation is encoded to determine the embedded representation of the first attribute label.
[0299] In some embodiments, the device 800 further includes: a resource determination module, configured to determine at least one recommended network resource from a network resource pool corresponding to the recommended service based on at least one attribute tag matched by the first object; and send the recommended network resource to a client corresponding to the first object.
[0300] It should be noted that the apparatus provided in the above embodiments, when implementing its functions, is only illustrated by the division of the above functional modules. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the apparatus and method embodiments provided in the above embodiments are based on the same concept. The specific implementation process is detailed in the method embodiment and will not be repeated here.
[0301] Please refer to Figure 9 It shows a structural block diagram of a computer device 900 provided in one embodiment of the present application.
[0302] Typically, the computer device 900 includes a processor 901 and a memory 902 .
[0303] The processor 901 may include one or more processing cores, such as a 4-core processor, an 8-core processor, and the like. The processor 901 may be implemented in at least one hardware form of DSP (Digital Signal Processing), FPGA (Field Programmable Gate Array), or PLA (Programmable Logic Array). The processor 901 may also include a main processor and a coprocessor. The main processor is a processor for processing data in an awake state, also known as a CPU (Central Processing Unit); the coprocessor is a low-power processor for processing data in a standby state. In some embodiments, the processor 901 may be integrated with a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, the processor 901 may also include an AI processor for processing computing operations related to machine learning.
[0304] The memory 902 may include one or more computer-readable storage media, which may be non-transitory. The memory 902 may also include high-speed random access memory and non-volatile memory, such as one or more magnetic disk storage devices or flash memory storage devices. In some embodiments, the non-transitory computer-readable storage medium in the memory 902 is used to store a computer program, which is configured to be executed by one or more processors to implement the above-mentioned method for determining object attribute labels.
[0305] Those skilled in the art will understand that Figure 9 The structure shown in the figure does not constitute a limitation on the computer device 900, and the computer device 900 may include more or fewer components than shown in the figure, or combine some components, or adopt a different component arrangement.
[0306] In an exemplary embodiment, a computer-readable storage medium is further provided, wherein a computer program is stored in the storage medium. When the computer program is executed by a processor, the method for determining an object attribute label is implemented.
[0307] Optionally, the computer-readable storage medium may include: ROM (Read-Only Memory), RAM (Random Access Memory), SSD (Solid State Drives), or an optical disk, etc. Among them, the random access memory may include ReRAM (Resistance Random Access Memory) and DRAM (Dynamic Random Access Memory).
[0308] In an exemplary embodiment, a computer program product is also provided, comprising a computer program stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium and executes the computer program, causing the computer device to perform the above-described method for determining an object attribute label.
[0309] It should be understood that the "multiple" mentioned in this article refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent three situations: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the previous and subsequent associated objects are in an "or" relationship. In addition, the step numbers described in this article only illustrate a possible execution sequence between the steps. In some other embodiments, the above steps may not be executed in the order of the numbers, such as two steps with different numbers are executed at the same time, or two steps with different numbers are executed in the opposite order to the diagram. The embodiments of the present application do not limit this.
[0310] It should be noted that, before collecting the relevant data of the object and during the process of collecting the relevant data of the object, this application can display a prompt interface, pop-up window or output voice prompt information, and the prompt interface, pop-up window or voice prompt information is used to prompt the object that its relevant data is currently being collected, so that this application only starts to execute the relevant steps of obtaining the relevant data of the object after obtaining the confirmation operation issued by the object on the prompt interface or pop-up window, otherwise (that is, when the confirmation operation issued by the object on the prompt interface or pop-up window is not obtained), the relevant steps of obtaining the relevant data of the object are terminated, that is, the relevant data of the object is not obtained. In other words, the information involved in this application (including but not limited to object device information, object personal information, etc., object attributes), data (including but not limited to data used for analysis, stored data, displayed data, etc.) and signals are all authorized by the object or fully authorized by all parties, and the collection, use and processing of relevant data need to comply with the relevant laws, regulations and standards of the relevant countries and regions. For example, the information involved in this application is obtained with full authorization.
[0311] The above description is merely an exemplary embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included in the scope of protection of the present application.
Claims
1. A method for determining an object attribute label, characterized in that: The method comprises: Obtaining a heterogeneous information network for use in a recommendation service; wherein the recommendation service is used to provide a network resource recommendation service for an object, the heterogeneous information network comprising: an object node corresponding to at least one object, a resource node corresponding to at least one network resource, and a first association edge between the object node and the resource node, the first association edge being used to represent an interaction between the object corresponding to the object node and the network resource corresponding to the resource node; generating an embedded representation corresponding to a first object according to a local subgraph corresponding to the first object in the heterogeneous information network; wherein the local subgraph corresponding to the first object includes: a first object node corresponding to the first object, and at least one resource node having a first associated edge with the first object node; and the embedded representation corresponding to the first object is used to represent feature information of the first object; Determining at least one attribute tag that matches the first object based on a correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to at least one candidate attribute tag; wherein the embedded representation corresponding to the attribute tag is used to represent semantic feature information of the attribute tag; The step of generating an embedded representation corresponding to the first object according to the local subgraph corresponding to the first object in the heterogeneous information network includes: Generate a resource sequence according to at least one resource node in the local subgraph that has a first associated edge with the first object node; Generate an embedded representation corresponding to the resource sequence; wherein the embedded representation corresponding to the resource sequence is used to represent feature information of at least one network resource that interacts with the first object; An embedded representation corresponding to the first object is generated according to the embedded representation corresponding to the resource sequence.
2. The method according to claim 1, characterized in that Generating a resource sequence according to at least one resource node in the local subgraph having a first associated edge with the first object node includes: For each resource node among at least one resource node having a first association edge with the first object node, determining an arrangement order of the resource node in the resource sequence according to an interaction time recorded on the first association edge between the resource node and the first object node; Arrange at least one resource node having a first associated edge with the first object node according to their respective corresponding arrangement orders to generate the resource sequence.
3. The method according to claim 2, characterized in that Generating the embedded representation corresponding to the resource sequence includes: Determine identification information corresponding to at least one resource node included in the resource sequence; wherein the identification information corresponding to the resource node is used to identify the network resource corresponding to the resource node; Inputting identification information corresponding to the at least one resource node into an object-side semantic tower; wherein the object-side semantic tower is a neural network for generating an embedded representation corresponding to the first object; encoding the identification information corresponding to the at least one resource node through the resource embedding layer of the object-side semantic tower to obtain a vector representation of the resource sequence; The vector representation of the resource sequence is encoded through the neural network layer in the object-side semantic tower to obtain an embedded representation corresponding to the resource sequence.
4. The method according to claim 1, wherein The local subgraph further includes: at least one resource attribute node connected to at least one resource node in the local subgraph via a second association edge; wherein the at least one resource node in the local subgraph is a resource node connected to the first object node via the first association edge, and the second association edge is used to represent that the network resource corresponding to the resource node has the resource attribute corresponding to the resource attribute node; the method further includes: Generate a resource attribute sequence corresponding to at least one resource attribute category according to the local subgraph; wherein the resource attribute sequence includes a resource attribute node having a second association edge with at least one resource node in the resource sequence; generating, according to the resource attribute sequences respectively corresponding to the at least one resource attribute category, embedded representations corresponding to the resource attributes; Generating the embedded representation corresponding to the first object according to the embedded representation corresponding to the resource sequence includes: An embedded representation corresponding to the first object is generated according to the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute.
5. The method according to claim 4, characterized in that Generating a resource attribute sequence corresponding to at least one resource attribute category according to the local subgraph includes: For a first resource attribute category in the at least one resource attribute category, determining, according to a second associated edge in the local subgraph, at least one first resource attribute node corresponding to each resource node in the resource sequence in the first resource attribute category; A resource attribute sequence corresponding to the first resource attribute category is generated according to the at least one first resource attribute node corresponding to each resource node in the resource sequence.
6. The method according to claim 4, characterized in that Generating the embedded representation corresponding to the resource attribute according to the resource attribute sequence corresponding to the at least one resource attribute category includes: For a first resource attribute category among the at least one resource attribute category, determining identification information corresponding to at least one resource attribute node included in a resource attribute sequence corresponding to the first resource attribute category; wherein the identification information corresponding to the resource attribute node is used to identify the resource attribute corresponding to the resource attribute node; encoding identification information corresponding to at least one resource attribute node included in a resource attribute sequence corresponding to the first resource attribute category through a resource attribute embedding layer corresponding to the first resource attribute category in an object-side semantic tower to obtain an embedded representation corresponding to the first resource attribute category; wherein the object-side semantic tower is used to generate the embedded representation corresponding to the first object; The embedded representations corresponding to the at least one resource attribute class are encoded through the resource attribute pooling layer in the object-side semantic tower to obtain the embedded representations corresponding to the resource attributes.
7. The method according to claim 4, characterized in that Generating the embedded representation corresponding to the first object according to the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute includes: splicing the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the resource attribute through the splicing layer of the object-side semantic tower to obtain a first spliced embedded representation; The first concatenated embedded representation is encoded through a representation layer in the object-side semantic tower to obtain an embedded representation corresponding to the first object.
8. The method according to claim 1, characterized in that The local subgraph further includes: at least one object attribute node having a third association edge with the first object node; wherein the third association edge is used to represent that the object corresponding to the object node has the object attribute corresponding to the object attribute node; the method further includes: generating, based on the local subgraph, an object attribute sequence corresponding to at least one object attribute category; wherein the object attribute sequence includes at least one resource attribute node having a third association edge with the first object node; generating an embedding representation corresponding to the object attribute according to the object attribute sequences corresponding to at least one object attribute category; Generating the embedded representation corresponding to the first object according to the embedded representation corresponding to the resource sequence includes: An embedded representation corresponding to the first object is generated according to the embedded representation corresponding to the resource sequence and the embedded representation corresponding to the object attribute.
9. The method according to claim 8, characterized in that Generating an embedded representation corresponding to the object attribute according to the object attribute sequence corresponding to at least one object attribute category includes: For a first object attribute category in the at least one object attribute category, determining identification information corresponding to at least one object attribute node included in an object attribute sequence corresponding to the first object attribute category; the identification information corresponding to the object attribute node is used to identify the object attribute corresponding to the object attribute node; encoding the identity of the at least one object attribute node through an object attribute embedding layer corresponding to the first object attribute category in an object-side semantic tower to obtain an embedding vector for the first object attribute category; wherein the object-side semantic tower is used to generate an embedding representation corresponding to the first object attribute category; The object attribute pooling layer in the object-side semantic tower encodes the embedded representations corresponding to the at least one object attribute category to obtain the embedded representations corresponding to the object attributes.
10. The method according to claim 1, characterized in that The determining, based on the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to at least one candidate attribute label, at least one attribute label matching the first object includes: Determine an embedding representation corresponding to at least one candidate attribute label; For a first attribute label in at least one candidate attribute label, calculating a spatial similarity between an embedded representation corresponding to the first object and an embedded representation of the first attribute label, and determining a correlation between the embedded representation corresponding to the first object and the embedded representation of the first attribute label; From the at least one candidate attribute tag, a candidate attribute tag whose correlation is greater than or equal to a correlation threshold is selected as the attribute tag matched by the first object.
11. The method according to claim 10, characterized in that Determining the embedding representation corresponding to at least one candidate attribute label includes: For a first attribute tag among at least one candidate attribute tag, obtaining at least one related entity tag corresponding to the first attribute tag; wherein the related entity tag has semantic similarity with the first attribute tag; Determine an embedded representation corresponding to the first attribute tag according to the first attribute tag and at least one related entity tag corresponding to the first attribute tag.
12. The method according to claim 11, characterized in that The determining, based on the first attribute tag and at least one related entity tag corresponding to the first attribute tag, an embedded representation corresponding to the first attribute tag includes: encoding identification information corresponding to at least one word in the first attribute label through the attribute label embedding layer of the tag-side semantic tower to obtain a feature vector corresponding to the first attribute label; wherein the tag-side semantic tower is used to determine the embedding representation corresponding to the first attribute label; encoding identification information corresponding to at least one word included in each of the at least one related entity tags through an entity tag network of a semantic tower on the tag side to obtain a feature vector corresponding to the related entity tag; Through the splicing layer of the semantic tower on the label side, the feature vector corresponding to the first attribute label and the feature vector corresponding to the related entity label are spliced to obtain a label splicing representation; The tag concatenation representation is encoded through the representation layer of the tag-side semantic tower to determine the embedded representation corresponding to the first attribute tag.
13. The method according to claim 1, wherein After determining at least one attribute label that matches the first object based on the correlation between the embedded representation corresponding to the first object and the embedded representation corresponding to at least one candidate attribute label, the method further includes: determining, according to at least one attribute tag matched by the first object, at least one recommended network resource from a network resource pool corresponding to the recommended service; The recommended network resource is sent to a client corresponding to the first object.
14. A training device for a determination model of an object attribute label, characterized in that: The device comprises: a network acquisition module, configured to acquire a heterogeneous information network for use by a recommendation service; wherein the recommendation service is configured to provide a network resource recommendation service for an object, the heterogeneous information network comprising: an object node corresponding to at least one object, a resource node corresponding to at least one network resource, and a first association edge between the object node and the resource node, the first association edge being configured to represent an interaction between the object corresponding to the object node and the network resource corresponding to the resource node; a representation determination module, configured to generate an embedded representation corresponding to the first object based on a local subgraph corresponding to the first object in the heterogeneous information network; wherein the local subgraph corresponding to the first object includes: a first object node corresponding to the first object, and at least one resource node having a first associated edge with the first object node; and the embedded representation corresponding to the first object is used to represent feature information of the first object; a label determination module, configured to determine at least one attribute label that matches the first object based on a correlation between an embedded representation corresponding to the first object and an embedded representation corresponding to at least one candidate attribute label; wherein the embedded representation corresponding to the attribute label is used to represent semantic feature information of the attribute label; Among them, the representation determination module is specifically used to generate a resource sequence based on at least one resource node in the local subgraph that has a first associated edge with the first object node; generate an embedded representation corresponding to the resource sequence; wherein the embedded representation corresponding to the resource sequence is used to represent the characteristic information of at least one network resource that interacts with the first object; based on the embedded representation corresponding to the resource sequence, generate an embedded representation corresponding to the first object.
15. A computer device, characterized in that: The computer device includes a processor and a memory, wherein a computer program is stored in the memory, and the computer program is loaded and executed by the processor to implement the method according to any one of claims 1 to 13.
16. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, which is loaded and executed by a processor to implement the method according to any one of claims 1 to 13.
17. A computer program product, characterized in that The computer program product includes a computer program, which is stored in a computer-readable storage medium. A processor reads and executes the computer program from the computer-readable storage medium to implement the method according to any one of claims 1 to 13.
Citation Information
Patent Citations
Sequence recommendation method based on meta-path neighborhood target generalization
CN114841765A
Heterogeneous graph clustering using inter-point mutual information criteria
CN115280305A