A Product Recommendation Method Based on Multi-behavior Meta-path Semantic Mapping

By automatically extracting high-quality meta-path instances and mining a multi-behavioral meta-path semantic mapping model that uncovers potential connections between behaviors, the problems of manual definition of meta-path dependencies and information redundancy in existing methods are solved, thereby improving the accuracy of product recommendations.

CN120996912BActive Publication Date: 2026-03-10NANCHANG HANGKONG UNIVERSITY
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-10-23
Publication Date
2026-03-10

AI Technical Summary

Technical Problem

Existing meta-path-based product recommendation methods suffer from problems such as meta-path dependence on manual pre-definition by domain experts, missing meta-paths, information redundancy, and neglect of connections between different behaviors, resulting in low recommendation accuracy.

Method used

An automatic meta-path extraction algorithm based on combination and screening strategies is adopted. High-quality meta-path instances are screened by cosine similarity, and potential connections between different behaviors are mined through meta-learning and contrastive learning. A multi-behavior meta-path semantic mapping model is constructed for product recommendation.

Benefits of technology

It eliminates the need for domain experts to manually define meta-paths, reducing information redundancy and improving the accuracy of product recommendations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120996912B_ABST
    Figure CN120996912B_ABST
Patent Text Reader

Abstract

This invention discloses a product recommendation method based on multi-behavior meta-path semantic mapping, comprising: constructing an e-commerce heterogeneous network node graph; extracting user meta-paths and corresponding instances using an automatic meta-path extraction algorithm based on combination and filtering strategies; inverting the extracted user meta-paths and their corresponding instances to obtain product meta-paths and their corresponding instances; obtaining user target behavior semantic embedding vectors and mapped auxiliary behavior semantic embedding vectors, initial product embedding vectors, and aggregated product meta-path embedding vectors using a product recommendation model based on multi-behavior meta-path semantic mapping; calculating a product rating function and constructing the final loss function of the recommendation model; and finally outputting a product recommendation list by minimizing the final loss function. This invention can automatically extract meta-paths, extract high-quality meta-path instances, and mine potential connections between different behavioral meta-paths, thereby improving recommendation accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data processing technology, and more specifically to a product recommendation method based on multi-behavior meta-path semantic mapping. Background Technology

[0002] With the rapid development of e-commerce, traditional user-product bipartite graphs are insufficient for modeling the complex relationships of e-commerce platforms. Heterogeneous networks, however, better adapt to the complex relationships in e-commerce scenarios because they support modeling multiple types of nodes and edges. In e-commerce heterogeneous networks, users, products, and categories are abstracted as nodes, while interactive relationships such as purchasing, browsing, favoriting, and belonging are abstracted as edges.

[0003] Existing meta-path-based product recommendation methods suffer from low accuracy and three main problems: First, meta-paths rely on manual pre-definition by domain experts, which can lead to missing meta-paths and insufficient information extraction. Second, most meta-path-based methods extract information by aggregating meta-path instances, but a single meta-path often has multiple instances, resulting in redundancy in node information extraction. Third, most meta-path-based methods ignore the potential connections between different behaviors, meaning that auxiliary behaviors can indirectly deduce target behaviors. For example, if a user favorites a product, they are more likely to purchase it in the future; thus, the act of favorites indirectly indicates the act of purchasing.

[0004] Therefore, there is a need for a product recommendation method that can automatically extract meta-paths, extract high-quality meta-path instances, mine potential connections between different behavioral meta-paths, and achieve high accuracy. Summary of the Invention

[0005] In view of this, the present invention provides a product recommendation method based on multi-behavioral meta-path semantic mapping, which automatically extracts meta-paths, extracts high-quality meta-path instances, and mines potential connections between different behavioral meta-paths to improve recommendation accuracy.

[0006] A product recommendation method based on multi-behavior meta-path semantic mapping includes:

[0007] Step S1: Read the user and product interaction database in the e-commerce platform, construct the e-commerce heterogeneous network node graph, extract the meta-paths using the meta-path automatic extraction algorithm based on combination and filtering strategies, use the extracted meta-paths as user meta-paths, and extract the corresponding instances in the e-commerce heterogeneous network node graph based on the user meta-paths.

[0008] Step S2: Invert the extracted user meta paths and their corresponding instances, use the new meta paths and instances as product meta paths and their corresponding instances, and divide the user meta paths into user target behavior meta paths and user auxiliary behavior meta paths according to the behavior type.

[0009] Step S3: Input the constructed e-commerce heterogeneous network node graph, user target behavior meta-path and its corresponding instance, user auxiliary behavior meta-path and its corresponding instance, product meta-path and its corresponding instance into the product recommendation model based on multi-behavior meta-path semantic mapping to obtain user target behavior semantic embedding vector, mapped auxiliary behavior semantic embedding vector, initial embedding vector of product and aggregated product meta-path embedding vector.

[0010] Step S4: Fuse the user target behavior semantic embedding vector with the mapped auxiliary behavior semantic embedding vector to obtain the final user embedding vector. Fuse the initial product embedding vector with the aggregated product meta-path embedding vector to obtain the final product embedding vector. Based on the final user embedding vector and the final product embedding vector, obtain the product rating function. At the same time, construct the final loss function of the product recommendation model based on the product rating function. By minimizing the final loss function, the product recommendation model finally outputs the product recommendation list.

[0011] The product recommendation method based on multi-behavior meta-path semantic mapping provided by the present invention has the following beneficial effects:

[0012] (1) This invention eliminates the need for domain experts to manually define meta-paths. Most existing meta-path-based product recommendation methods rely on manually pre-defined meta-paths, which not only requires prior knowledge from domain experts but may also result in missing meta-paths. This invention proposes an automatic meta-path extraction algorithm based on combination and filtering strategies. First, the meta-path length is set. Then, nodes and edges are selected based on the set meta-path length. An initial meta-path set is generated through a combination strategy. Then, a filtered meta-path set is obtained through a filtering strategy. Meta-path instances are extracted from heterogeneous networks based on the meta-paths. If an instance exists, the meta-path is retained; otherwise, it is removed, thus achieving the effect of automatic meta-path extraction.

[0013] (2) This invention reduces the redundancy of node information extraction by extracting high-quality meta-path instances. Most existing meta-path-based product recommendation methods extract information by aggregating meta-path instances. However, a single meta-path often has multiple instances, and aggregating all instances will cause redundancy in node information. The method of filtering instances based on the similarity between nodes lacks interpretability. This invention starts from the semantic information represented by the meta-path and realizes the extraction of high-quality meta-path instances based on cosine similarity scores. This not only reduces the redundancy of node information but also has strong interpretability.

[0014] (3) This invention can improve the accuracy of product recommendation by mining the potential connections between different behavioral meta-paths. Most existing meta-path-based product recommendation methods cannot mine the potential connections between different behavioral meta-paths and ignore the inference relationships between different behaviors. This invention concatenates the initial embedding vector of user auxiliary behavior with the semantic embedding vector of user auxiliary behavior, and then maps them through meta-learning to obtain the mapped semantic embedding vector of auxiliary behavior. This can map the semantics of auxiliary behavior meta-paths to the semantic space of target behavior meta-paths, realize the explicit modeling of the potential connections between different behavioral meta-paths, and improve the accuracy of recommendation by optimizing the mapped semantic embedding vector of auxiliary behavior through contrastive learning loss function. Attached Figure Description

[0015] Figure 1 This is a flowchart illustrating the product recommendation method based on multi-behavior meta-path semantic mapping provided in an embodiment of the present invention. Detailed Implementation

[0016] Embodiments of the present invention are described in detail below, examples of which are illustrated in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and intended to explain embodiments of the present invention, and should not be construed as limiting the present invention.

[0017] Please see Figure 1 The embodiments of the present invention provide a product recommendation method based on multi-behavior meta-path semantic mapping, including steps S1-S4:

[0018] Step S1: Read the user and product interaction database in the e-commerce platform, construct the e-commerce heterogeneous network node graph, extract meta-paths using the meta-path automatic extraction algorithm based on combination and filtering strategies, use the extracted meta-paths as user meta-paths, and extract the corresponding instances in the e-commerce heterogeneous network node graph based on the user meta-paths.

[0019] Specifically, step S1 includes:

[0020] Step S11: Construct the node graph of the e-commerce heterogeneous network by reading the user and product interaction dataset from the user and product interaction database of the e-commerce platform. , ,in, Represents a set of nodes. The middle nodes represent nodes such as users and products; This represents a set of edges, where the edges in the set represent the relationships between nodes; This represents a collection of node types, such as user nodes, product nodes, product category nodes, etc. This represents a set of edge types, such as the purchase relationship between a user and a product, the collection relationship between a user and a product, and the membership relationship between a product and a category. For user nodes, this invention only considers the relationship between a user and a product, and does not consider the relationship between users.

[0021] Step S12: A meta-path is a semantic relation template in a heterogeneous graph, defining an abstract order of node and edge types. Essentially, it's a sequence of alternating node and edge types. A meta-path instance is a concrete implementation of the meta-path, containing actual nodes and edges. This invention proposes an automatic meta-path extraction algorithm based on a combination and filtering strategy. First, the meta-path length is set to... Select Each node and The edges are then combined to generate an initial meta-path set, and then a filtered meta-path set is obtained through a filtering strategy. The combination strategy is to first determine the order of the meta-path edges, and then add valid nodes to both ends of the edges, that is, the edges must match the connected nodes. The filtering strategy is to select meta-paths with user and product nodes as the head and tail nodes, respectively, and select meta-paths with the most node and edge types.

[0022] Step S13: Extract meta-path instances from the heterogeneous network node graph of e-commerce based on the meta-path. If the instance does not exist, remove the meta-path; otherwise, retain the meta-path and use it as the final extracted user meta-path. Use the extracted instance as the instance corresponding to the user meta-path.

[0023] Step S2: Invert the extracted user meta paths and their corresponding instances, use the resulting new meta paths and instances as product meta paths and their corresponding instances, and divide the user meta paths into user target behavior meta paths and user auxiliary behavior meta paths according to the behavior type.

[0024] Specifically, step S2 includes:

[0025] Step S21, will the user The original metapath is reversed, and the resulting new metapath is used as the product. Product metapath The head node of the product metapath is the product node, and the tail node is the user node; for users... The instance corresponding to the meta path is reversed, and the resulting new meta path instance is used as the product. Metapath instance The inverse formula is:

[0026]

[0027]

[0028] in, Indicates user metapath, Indicates user The instance corresponding to the metapath, Indicates the reverse operation;

[0029] Step S22: Based on the type of the first edge in the user meta-path, the user meta-path is divided into user target behavior meta-path and user auxiliary behavior meta-path. Since this invention is for product purchase recommendation, the purchase behavior meta-path is used as the user target behavior meta-path. Indicates user The target behavior meta-path will treat other behaviors besides purchasing (such as adding to favorites, adding to cart, etc.) as user auxiliary behavior meta-paths. Indicates user The A type of auxiliary behavior metapath, in which, An index representing the types of auxiliary behaviors. , This indicates the number of types of auxiliary behaviors.

[0030] Step S3: Input the constructed e-commerce heterogeneous network node graph, user target behavior meta-path and its corresponding instance, user auxiliary behavior meta-path and its corresponding instance, and product meta-path and its corresponding instance into the product recommendation model based on multi-behavior meta-path semantic mapping to obtain the user target behavior semantic embedding vector, the mapped auxiliary behavior semantic embedding vector, the initial embedding vector of the product, and the aggregated product meta-path embedding vector.

[0031] The product recommendation model includes a high-quality user meta-path instance extraction module, an initial embedding extraction module, a user and product embedding extraction module, a user auxiliary behavior semantic mapping module, and a contrastive learning module.

[0032] Step S3 specifically includes:

[0033] Step S31: In the high-quality user metapath instance extraction module, high-quality user metapath instances are extracted based on the instance embedding vector and the metapath embedding vector.

[0034] Step S32: In the initial embedding extraction module, the initial embedding vectors of user auxiliary behavior and products are extracted using the FunkSVD matrix factorization algorithm.

[0035] Step S33: In the user and product embedding extraction module, based on high-quality user meta-path instances, the user target behavior semantic embedding vector, user auxiliary behavior semantic embedding vector, and aggregated product meta-path embedding vector are obtained by aggregating meta-path embedding vectors.

[0036] Step S34: In the user-assisted behavior semantic mapping module, the initial embedding vector of user-assisted behavior and the semantic embedding vector of user-assisted behavior are concatenated and then mapped through meta-learning to obtain the mapped semantic embedding vector of assisted behavior.

[0037] Step S35: In the contrastive learning module, the mapped auxiliary behavior semantic embedding vector is optimized by the contrastive learning loss function.

[0038] In this embodiment, step S31 specifically includes:

[0039] In the high-quality user metapath instance extraction module, high-quality metapath instances are extracted based on user feature preference similarity. The embedding vector of a metapath instance can represent the semantic information of the metapath, and since metapaths are extracted through user behavior, the semantic information of the metapath can represent the user's feature preferences under that behavior. However, there may be multiple instances extracted from the metapath, and different instances may contain common nodes. Using the embedding vector obtained by aggregating all instances as the semantic information of the metapath would cause redundancy in node information extraction. Therefore, instances containing redundant information should be filtered out before using metapath instances, i.e., high-quality metapath instances should be extracted.

[0040] The high-quality user metapath instance extraction module extracts high-quality metapath instances only for instances obtained from the same user metapath. Specifically, it first extracts the embedding vector of each instance of a single user metapath using a convolutional neural network, with the expression as follows:

[0041]

[0042] in, Indicates user The The first element of the path The embedding vector of each instance, It is a convolutional neural network. For the first The encoding matrix of the instances, These are the parameters of the convolutional neural network;

[0043] Then, by aggregating the embedding vectors of each instance on average, we obtain the embedding vector of the metapath, expressed as:

[0044]

[0045] in, For users The Embedding vector of element path, For users The The total number of instances of a single path;

[0046] Next, remove the first metapath. The embedding vectors of the remaining instances are re-aggregated by average to obtain the result after removing the first instance. Metapath embedding vector after each instance and calculate and cosine similarity score The expression is:

[0047]

[0048] in, The cosine similarity function;

[0049] A high cosine similarity score indicates that the deleted instance has little impact on the user preferences reflected in the metapath, meaning the instance is of lower quality. Conversely, a low score indicates a higher quality instance. Therefore, instances are sorted in ascending order of cosine similarity score, and the top instances are selected. Each instance serves as a high-quality user metapath instance extracted from the data.

[0050] Step S32 specifically includes:

[0051] In the initial embedding extraction module, bipartite graphs of different behaviors are extracted from the heterogeneous network node graph of e-commerce. The bipartite graphs are then transformed into interaction matrices corresponding to the behaviors, which are the target behavior interaction matrices. and auxiliary behavior interaction matrix The interaction matrix is ​​decomposed using the FunkSVD matrix factorization algorithm to obtain the initial embedding vectors of user-assisted behaviors and products.

[0052] Step S33 specifically includes:

[0053] In the user and product embedding extraction module, based on high-quality user meta-path instances, the embedding vectors of similar behavior meta-path instances are aggregated through an attention mechanism, expressed as:

[0054]

[0055]

[0056]

[0057] in, For the first Item path instance for user Importance score For activation function, This represents the parameter matrix of the feedforward neural network. For users The The first element of the path Embedding vectors of high-quality instances, For the first The weight of a single path instance. Indicates the first The attention mechanism of the size calculates the first The weight of a single path instance. For normalization function, It is a mathematical constant The index, It is a user that aggregates high-quality instance embedding vectors using an attention mechanism. The Embedding vector of element path, For averaging operations;

[0058] There may be multiple meta-paths for the same behavior. Therefore, an attention mechanism is used to aggregate the embedding vectors of all meta-paths for the same behavior, thus obtaining the user's behavior semantic embedding vector, expressed as:

[0059]

[0060]

[0061]

[0062] in, For users The first of the same behaviors Path pairs Importance score It is the feature vector of the attention parameters. User The first of the same behaviors Embedding vector of element path, It is the first The weight of each element path; User The behavioral semantic embedding vectors are divided into target behavioral semantic embedding vectors and auxiliary behavioral semantic embedding vectors according to the behavioral type.

[0063] Then, a convolutional neural network is used to extract the embedding vectors of the product metapath instances. Then, the embedding vectors of the product metapath instances are aggregated through an attention mechanism to obtain the embedding vector of the product metapath. Finally, the embedding vectors of the product metapath are aggregated through an attention mechanism to obtain the aggregated product metapath embedding vector.

[0064] Step S34 specifically includes:

[0065] In the user-assisted behavior semantic mapping module, the auxiliary behavior can indirectly deduce the target behavior. In order to measure this derivation relationship, the module uses meta-learning to map the semantic embedding of the user's auxiliary behavior onto the semantic embedding space of the target behavior.

[0066] In this embodiment, the user-assisted behavior semantic embedding vector obtained in step S33 and the initial user-assisted behavior embedding vector obtained in step S32 are first concatenated. Then, the concatenated embedding vector is input into the multilayer perceptron. Next, the embedding vector output by the multilayer perceptron is sliced ​​and reshaped to obtain a learnable parameter matrix and a bias parameter vector. Finally, the mapped auxiliary behavior semantic embedding vector is obtained through a mapping function, the expression of which is:

[0067]

[0068]

[0069]

[0070]

[0071] in, It is the embedding vector processed by a multilayer perceptron. It is a multilayer perceptron. User The Semantic embedding vectors of auxiliary behaviors, User The The initial embedding vector for each auxiliary behavior. This indicates a splicing operation. User The The learnable mapping parameter matrix of the auxiliary behaviors. This represents a vector reshaping operation; This indicates a slicing operation, before extraction. One component; User The A learnable mapping bias parameter vector for each auxiliary behavior; This indicates a slicing operation, extracting the first slice. The final portion; The mapped user The Auxiliary behavior semantic embedding vector, Represents a non-linear activation function. This represents the normalization function.

[0072] In step S35, positive samples consist of embedding pairs consisting of the target behavior semantic embedding vector of the same user and the auxiliary behavior semantic embedding vector after each mapping, while negative samples consist of embedding pairs consisting of the target behavior semantic embedding vectors of different users.

[0073] In this embodiment, the contrastive learning loss function The expression is:

[0074]

[0075]

[0076] in, For the first Auxiliary behavior loss function Indicates the number of user nodes. For users Target behavior semantic embedding vector Indicates the temperature coefficient. For users Target behavior semantic embedding vector.

[0077] Step S4: Fuse the user target behavior semantic embedding vector with the mapped auxiliary behavior semantic embedding vector to obtain the final user embedding vector. Fuse the initial product embedding vector with the aggregated product meta-path embedding vector to obtain the final product embedding vector. Based on the final user embedding vector and the final product embedding vector, obtain the product rating function. At the same time, construct the final loss function of the product recommendation model based on the product rating function. By minimizing the final loss function, the product recommendation model finally outputs the product recommendation list.

[0078] Specifically, step S4 includes:

[0079] Step S41: Fuse the user target behavior semantic embedding vector with the mapped auxiliary behavior semantic embedding vector to obtain the final user embedding vector, expressed as:

[0080]

[0081] in, For users The corresponding final user embedding vector;

[0082] Step S42: Merge the initial embedding vector of the product with the aggregated product metapath embedding vector to obtain the final product embedding vector, expressed as:

[0083]

[0084] in, For goods The corresponding final product embedding vector, For the goods Initial embedding vector, For goods The corresponding aggregated product metapath embedding vector;

[0085] Step S43: Based on the final user embedding vector and the final product embedding vector, the product rating function is obtained, expressed as:

[0086]

[0087] in, Indicates user Purchase goods The predicted score Indicates transpose;

[0088] Step S44: Set the items that the user has purchased as positive samples and the items that have not been purchased as negative samples, and randomly sample from the positive and negative samples respectively. Each sample combination consists of positive and negative sample pairs. The objective is optimized using a pairwise marginal loss function, expressed as:

[0089]

[0090] in, The pairwise marginal loss function for the product purchase recommendation task. For users Purchase the Positive samples The predicted score For users Purchase the negative samples The predicted score This indicates taking the maximum value;

[0091] The final loss function of the product recommendation model is obtained by weighted fusion of the contrastive learning loss function and the pairwise marginal loss function. The expression is:

[0092]

[0093] in, It is a hyperparameter that controls the intensity of contrastive learning. It is a hyperparameter that controls the intensity of weight decay. These are the parameters of the product recommendation model. The square of the Frobenius norm of the parameter matrix is ​​used to implement... Regularization prevents the model from overfitting;

[0094] By minimizing the final loss function, the product recommendation model ultimately outputs a list of recommended products, which displays the products that the user is most likely to buy.

[0095] In summary, the product recommendation method based on multi-beginner path semantic mapping according to the above embodiments has the following beneficial effects:

[0096] (1) This invention eliminates the need for domain experts to manually define meta-paths. Most existing meta-path-based product recommendation methods rely on manually pre-defined meta-paths, which not only requires prior knowledge from domain experts but may also result in missing meta-paths. This invention proposes an automatic meta-path extraction algorithm based on combination and filtering strategies. First, the meta-path length is set. Then, nodes and edges are selected based on the set meta-path length. An initial meta-path set is generated through a combination strategy. Then, a filtered meta-path set is obtained through a filtering strategy. Meta-path instances are extracted from heterogeneous networks based on the meta-paths. If an instance exists, the meta-path is retained; otherwise, it is removed, thus achieving the effect of automatic meta-path extraction.

[0097] (2) This invention reduces the redundancy of node information extraction by extracting high-quality meta-path instances. Most existing meta-path-based product recommendation methods extract information by aggregating meta-path instances. However, a single meta-path often has multiple instances, and aggregating all instances will cause redundancy in node information. The method of filtering instances based on the similarity between nodes lacks interpretability. This invention starts from the semantic information represented by the meta-path and realizes the extraction of high-quality meta-path instances based on cosine similarity scores. This not only reduces the redundancy of node information but also has strong interpretability.

[0098] (3) This invention can improve the accuracy of product recommendation by mining the potential connections between different behavioral meta-paths. Most existing meta-path-based product recommendation methods cannot mine the potential connections between different behavioral meta-paths and ignore the inference relationships between different behaviors. This invention concatenates the initial embedding vector of user auxiliary behavior with the semantic embedding vector of user auxiliary behavior, and then maps them through meta-learning to obtain the mapped semantic embedding vector of auxiliary behavior. This can map the semantics of auxiliary behavior meta-paths to the semantic space of target behavior meta-paths, realize the explicit modeling of the potential connections between different behavioral meta-paths, and improve the accuracy of recommendation by optimizing the mapped semantic embedding vector of auxiliary behavior through contrastive learning loss function.

[0099] The embodiments described above are merely illustrative of several implementations of the present invention, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the invention patent. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of the present invention, and these all fall within the protection scope of the present invention. Therefore, the protection scope of this invention patent should be determined by the appended claims.

Claims

1.A commodity recommendation method based on multi-behavior element path semantic mapping, characterized in that, The method comprises the following steps: Step S1, reading the interaction database of users and goods in the e-commerce platform, constructing an e-commerce heterogeneous network node graph, automatically extracting meta-paths based on a combination and screening strategy, extracting the meta-paths as user meta-paths, and extracting corresponding instances in the e-commerce heterogeneous network node graph according to the user meta-paths; Step S2, reversing the extracted user meta-paths and corresponding instances, taking the obtained new meta-paths and instances as product meta-paths and corresponding instances, and dividing the user meta-paths into user target behavior meta-paths and user auxiliary behavior meta-paths according to the behavior type; Step S3, inputting the constructed e-commerce heterogeneous network node graph, user target behavior meta-paths and corresponding instances, user auxiliary behavior meta-paths and corresponding instances, and product meta-paths and corresponding instances into a product recommendation model based on multi-behavior meta-path semantic mapping, obtaining user target behavior semantic embedding vectors and mapped auxiliary behavior semantic embedding vectors, initial product embedding vectors, and aggregated product meta-path embedding vectors; Step S4, fusing the user target behavior semantic embedding vectors and the mapped auxiliary behavior semantic embedding vectors to obtain final user embedding vectors, fusing the initial product embedding vectors and the aggregated product meta-path embedding vectors to obtain final product embedding vectors, obtaining a product scoring function based on the final user embedding vectors and the final product embedding vectors, constructing a final loss function of the product recommendation model based on the product scoring function, and minimizing the final loss function to finally output a product recommendation list by the product recommendation model. Step S1 specifically comprises: Step S11, constructing a node graph of the e-commerce heterogeneous network by reading a user and commodity interaction dataset from a user and commodity interaction database of the e-commerce platform , wherein, denotes a set of nodes, denotes a set of edges, denotes a set of node types, denotes a set of edge types; Step S12, a meta-path automatic extraction algorithm based on combination and screening strategy is proposed, the length of the meta-path is set as , the number of nodes and edges are selected as and , the initial meta-path set is generated through the combination strategy, and the screened meta-path set is obtained through the screening strategy, wherein the combination strategy is to determine the order of the edges of the meta-path first, and then add legal nodes at both ends of the edges, so that the edges match the connected nodes; the screening strategy is to select the meta-path with the user and commodity nodes as the head and tail nodes, and to select the meta-path with the most nodes and edge types. Step S13, extracting meta-path instances according to the meta-paths in the e-commerce heterogeneous network node graph, if the instances do not exist, eliminating the meta-path, otherwise, retaining the meta-path, and taking the meta-path as the final extracted user meta-path, and taking the extracted instances as the corresponding instances of the user meta-path. 2.The method of claim 1, wherein, Step S2 specifically comprises: Step S21, will the user The original metapath is reversed, and the resulting new metapath is used as the product. Product metapath The head node of the product metapath is the product node, and the tail node is the user node; for users... The instance corresponding to the meta path is reversed, and the resulting new meta path instance is used as the product. Metapath instance The inverse formula is: wherein, represents a meta-path of a user , represents a meta-path pair of a user , represents an inverse operation; Step S22, dividing the user meta path into a user target behavior meta path and a user auxiliary behavior meta path according to the type of the first edge in the user meta path, wherein the purchase behavior meta path is taken as the user target behavior meta path, representing the target behavior meta path of the user , representing the first auxiliary behavior meta path of the user , , representing the category index of the auxiliary behavior, , representing the number of categories of auxiliary behaviors. 3.The method of claim 2, wherein, The product recommendation model comprises a high-quality user meta-path instance extraction module, an initial embedding extraction module, a user and product embedding extraction module, a user auxiliary behavior semantic mapping module, and a contrast learning module. Step S3 specifically comprises: Step S31, in the high-quality user meta-path instance extraction module, based on the embedding vector of the instance and the embedding vector of the meta-path, high-quality user meta-path instances are extracted, wherein each instance is sorted in order of increasing cosine similarity score, and the first K instances are selected as the extracted high-quality user meta-path instances. ​ Step S32, in the initial embedding extraction module, extracting user auxiliary behavior initial embedding vectors and product initial embedding vectors by a FunkSVD matrix decomposition algorithm; Step S33, in the user and product embedding extraction module, based on high-quality user meta-path instances, obtaining user target behavior semantic embedding vectors, user auxiliary behavior semantic embedding vectors, and aggregated product meta-path embedding vectors by aggregating meta-path embedding vectors; Step S34, in the user auxiliary behavior semantic mapping module, concatenating the user auxiliary behavior initial embedding vectors and the user auxiliary behavior semantic embedding vectors, and then mapping by meta-learning to obtain the mapped auxiliary behavior semantic embedding vectors; Step S35, in the contrast learning module, optimizing the mapped auxiliary behavior semantic embedding vectors by a contrast learning loss function. 4.The method of claim 3, wherein, Step S31 specifically comprises: In the high-quality user meta-path instance extraction module, the embedding vector of each instance of a single user meta-path is extracted through a convolutional neural network, and the expression is: wherein, representing a user the first instance of the first embedding vector of the first is a convolutional neural network, is an encoding matrix of the first instance, is a convolutional neural network parameter; The embedding vectors of each instance are averaged and aggregated to obtain the embedding vector of the meta-path, and the expression is: wherein, the embedding vector of the first meta-path, the embedding vector of the first meta-path, the embedding vector of the first meta-path, the embedding vector of the first meta-path, the embedding vector of the first meta-path,​ Then remove the first instances, re-average the embedding vectors of the remaining instances, and obtain the embedding vectors of the meta-path after removing the first instances , and calculate the cosine similarity score of and , the expression is: wherein, is a cosine similarity function; The instances are ranked in ascending order of cosine similarity scores, and the top instances are selected as the extracted high-quality user meta-path instances. 5.The method of claim 4, wherein, Step S32 specifically includes: In the initial embedding extraction module, the bipartite graph of different behaviors is extracted from the e-commerce heterogeneous network node graph, the bipartite graph is converted into the interaction matrix corresponding to the behavior, and the target behavior interaction matrix and the auxiliary behavior interaction matrix are obtained. The interaction matrix is decomposed by the FunkSVD matrix decomposition algorithm to obtain the initial embedding vector of the user auxiliary behavior and the initial embedding vector of the commodity. 6.The method of claim 5, wherein, Step S33 specifically includes: In the user and commodity embedding extraction module, based on the high-quality user meta-path instance, the embedding vectors of the same behavior meta-path instance are aggregated through an attention mechanism, and the expression is: wherein, is the th element path instance of the user , is an activation function, denotes a parameter matrix of the feedforward neural network, is the th high-quality instance embedding vector of the th element path of the user , is the weight of the th element path instance, denotes the weight of the th element path instance computed by the attention mechanism of the th head, is a normalization function, is the exponent of the mathematical constant , is the embedding vector of the th element path of the user after aggregating the high-quality instance embedding vectors using the attention mechanism, is an averaging operation; The embedding vectors of all behavior meta-path instances are aggregated through an attention mechanism to obtain the behavior semantic embedding vector of the user, and the expression is: in, For users The first of the same behaviors Path pairs Importance score It is the feature vector of the attention parameters. User The first of the same behaviors Embedding vector of element path, It is the first The weight of each element path; User The behavioral semantic embedding vectors are divided into target behavioral semantic embedding vectors and auxiliary behavioral semantic embedding vectors according to the behavioral type. The embedding vectors of the commodity meta-path instances are extracted using a convolutional neural network, and then the embedding vectors of the commodity meta-path instances are aggregated through an attention mechanism to obtain the embedding vector of the commodity meta-path. Finally, the aggregated commodity meta-path embedding vector is obtained by aggregating the embedding vectors of the commodity meta-paths through an attention mechanism. 7.The method of claim 6, wherein, Step S34 specifically includes: In the user auxiliary behavior semantic mapping module, the user auxiliary behavior semantic embedding vector obtained in step S33 and the user auxiliary behavior initial embedding vector obtained in step S32 are spliced, and then the spliced embedding vector is input into a multilayer perception machine. Then, the embedding vector output by the multilayer perception machine is sliced and reshaped to obtain a learnable parameter matrix and a bias parameter vector. Finally, the mapped auxiliary behavior semantic embedding vector is obtained through a mapping function, and the expression is: wherein, is the embedding vector after being processed by the multi-layer perceptron, is the multi-layer perceptron, is the user s semantic embedding vector of the th auxiliary behavior, is the user s initial embedding vector of the th auxiliary behavior, represents a concatenation operation, is the learnable mapping parameter matrix of the user s th auxiliary behavior, represents a vector reshaping operation; represents a slicing operation, extracting the first components; is the learnable mapping bias parameter vector of the user s th auxiliary behavior; represents a slicing operation, extracting the th to last components; is the semantic embedding vector of the user s th auxiliary behavior after mapping, represents a nonlinear activation function, represents a normalization function. 8.The method of claim 7, wherein, In step S35, the contrastive learning loss function is expressed as: wherein, is a first auxiliary behavior loss function, represents a number of user nodes, a target behavior semantic embedding vector for a user, represents a temperature coefficient, a target behavior semantic embedding vector for a user.​​​ 9.The commodity recommendation method based on multi-behavior element path semantic mapping according to claim 8, characterized in that, Step S4 specifically includes: Step S41, the user target behavior semantic embedding vector and the mapped auxiliary behavior semantic embedding vector are fused to obtain the final user embedding vector, and the expression is: wherein, for a user a corresponding final user embedding vector; Step S42, the initial embedding vector of the commodity and the aggregated commodity meta-path embedding vector are fused to obtain the final commodity embedding vector, and the expression is: wherein, is a product corresponding final product embedding vector, is a product initial embedding vector, is a product corresponding aggregated product meta-path embedding vector; Step S43, based on the final user embedding vector and the final commodity embedding vector, a commodity score function is obtained, and the expression is: wherein, representing a user purchasing a good a predicted score, denotes a transpose; Step S44, setting the purchased goods of the user as positive samples and the non-purchased goods as negative samples, and randomly sampling from the positive samples and the negative samples respectively The sample combination is a positive-negative sample pair, and a pair-wise marginal loss function is used for target optimization, and the expression is as follows: in, The pairwise marginal loss function for the product purchase recommendation task. For users Purchase the Positive samples The predicted score For users Purchase the negative samples The predicted score This indicates taking the maximum value; The contrast learning loss function and the pair-wise margin loss function are weighted and fused to obtain a final loss function of the commodity recommendation model , and the expression is: wherein, is a hyperparameter controlling the strength of contrastive learning, is a hyperparameter controlling the strength of weight decay, are parameters of the item recommendation model, denotes the square of the Frobenius norm of the parameter matrix; By minimizing the final loss function, the commodity recommendation model finally outputs a commodity recommendation list.

Citation Information

Patent Citations

  • Recommendation method and system fusing meta-path semantics

    CN112861006A

  • Semantic recommendation method based on reinforcement learning and weighted meta path

    CN113935804A