Project recommendation method and apparatus, medium, and computer device
By constructing item sequence transition graphs and item semantic transition graphs, determining conditional signals, and adjusting the diffusion model, the shortcomings of existing recommendation systems in handling noise between and within sequences are addressed, thereby improving the accuracy and personalization of item recommendations.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHANGSHU INSTITUTE OF TECHNOLOGY
- Filing Date
- 2024-11-28
- Publication Date
- 2026-07-21
AI Technical Summary
Existing recommender systems struggle to effectively combine personalized adjacent item transitions and semantically relevant item transition patterns when dealing with inter-sequence and intra-sequence noise in user behavior, resulting in limited recommendation accuracy.
By constructing project sequence transition graphs and project semantic transition graphs, conditional signals are identified, and the diffusion model is adjusted to handle noise issues between and within sequences, thus integrating adjacent project transitions and semantically related project transition patterns.
It significantly improves the accuracy and personalization of project recommendations, effectively handles noise issues between and within sequences, and enhances the performance of the recommendation system.
Smart Images

Figure CN119719486B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of recommendation system technology, and more specifically, to a method, apparatus, medium, and computer equipment for recommending items. Background Technology
[0002] With the increasing prevalence of information overload on the internet, particularly on e-commerce and social media platforms, users face the problem of information overload. Recommender systems (RS) have emerged as a key technology to help users sift through massive amounts of information to find valuable content. By capturing users' dynamic preferences and historical interaction behavior, they significantly alleviate the burden of information searching for users. However, user behavior exhibits complexity over time, including two main patterns: personalized adjacent item transitions and item transitions based on semantic relevance. While many methods have made progress in some aspects, they have not yet been able to effectively combine these two patterns, thus affecting the overall performance of recommender systems in sequence recommendation tasks.
[0003] In related technologies, attention-based recommendation models represent items as fixed point vectors. However, this static representation cannot fully capture the dynamics and uncertainties of user behavior. Generative models, such as variational autoencoders, while optimizing data modeling to some extent, are still limited by representational capabilities and posterior distribution collapse. In recent years, contrastive learning (CL) methods have improved recommendation quality by introducing auxiliary tasks, but still face challenges in noise handling, particularly intra-sequence (e.g., unintentional clicks) and inter-sequence noise. Although existing methods such as FMLP and DLFS can effectively remove intra-sequence noise, the impact of inter-sequence noise is still neglected. Furthermore, while the application of diffusion models in recommendation systems has achieved initial results, better capturing complex data distributions and removing intra-sequence noise, effectively handling inter-sequence noise and modeling semantic relevance remain significant challenges. Summary of the Invention
[0004] This disclosure provides at least one method, apparatus, medium, and computer device for recommending items. By constructing an item sequence transition graph and an item semantic transition graph, it achieves a fusion of adjacent item transitions and semantically related item transition patterns. At the same time, by determining conditional signals based on the item sequence transition graph and the item semantic transition graph and adjusting the diffusion model accordingly, it effectively handles noise problems between and within sequences, thereby significantly improving the accuracy of item recommendations.
[0005] This disclosure provides a project recommendation method, including:
[0006] Obtain a set of user behavior sequences, determine an item set based on the set of user behavior sequences, and construct an item embedding matrix based on the item set; wherein, the set of user behavior sequences includes multiple user behavior sequences; and the item set includes multiple items;
[0007] Based on the item embedding matrix, determine the user-item embedding vector corresponding to each user behavior sequence; construct an item sequence transition graph and an item semantic transition graph based on the user behavior sequence set;
[0008] Based on the project sequence transition graph and the project semantic transition graph, determine the conditional signal corresponding to each user behavior sequence;
[0009] For any user's recommendation needs, the pre-trained diffusion model is adjusted based on the conditional signals corresponding to the user's behavior sequence, and the target recommendation items corresponding to the user are determined based on the adjusted diffusion model.
[0010] This disclosure provides a project recommendation device, including:
[0011] A sequence acquisition module is used to acquire a set of user behavior sequences, determine an item set based on the set of user behavior sequences, and construct an item embedding matrix based on the item set; wherein, the set of user behavior sequences includes multiple user behavior sequences; and the item set includes multiple items;
[0012] The transition graph determination module is used to determine the user-item embedding vector corresponding to each user behavior sequence based on the item embedding matrix; and to construct an item sequence transition graph and an item semantic transition graph based on the user behavior sequence set, respectively.
[0013] The signal determination module is used to determine the conditional signal corresponding to each user behavior sequence based on the item sequence transition graph and the item semantic transition graph.
[0014] The recommendation item determination module is used to adjust a pre-trained diffusion model based on the conditional signals corresponding to the user behavior sequence of any user, and determine the target recommendation items corresponding to any user based on the adjusted diffusion model, in response to the recommendation needs of any user.
[0015] This disclosure provides a computer device including a processor, a memory, and a bus. The memory stores machine-readable instructions executable by the processor. When the computer device is running, the processor communicates with the memory via the bus. When the machine-readable instructions are executed by the processor, they perform the project recommendation method as described in any of the above possible embodiments.
[0016] This disclosure provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the project recommendation method as described in any of the possible embodiments above.
[0017] The project recommendation method, apparatus, medium, and computer equipment provided in this disclosure embodiment achieve the integration of adjacent project transitions and semantically related project transition patterns by constructing project sequence transition graphs and project semantic transition graphs. At the same time, by determining conditional signals based on project sequence transition graphs and project semantic transition graphs and adjusting the diffusion model accordingly, the noise problems between and within sequences are effectively handled, thereby significantly improving the accuracy of project recommendations.
[0018] To make the above-mentioned objects, features and advantages of this disclosure more apparent and understandable, preferred embodiments are described below in detail with reference to the accompanying drawings. Attached Figure Description
[0019] To more clearly illustrate the technical solutions of the embodiments of this disclosure, the accompanying drawings referenced in the embodiments will be briefly described below. These drawings are incorporated in and constitute a part of this specification. They illustrate embodiments conforming to this disclosure and, together with the specification, serve to explain the technical solutions of this disclosure. It should be understood that the following drawings only show some embodiments of this disclosure and should not be considered as limiting the scope. Those skilled in the art can obtain other related drawings based on these drawings without creative effort.
[0020] Figure 1 A flowchart of a project recommendation method provided by an embodiment of this disclosure is shown;
[0021] Figure 2 A flowchart of the condition signal determination method in the project recommendation method provided in this disclosure embodiment is shown;
[0022] Figure 3 A schematic diagram of the condition signal determination method in the project recommendation method provided in this embodiment of the present disclosure is shown;
[0023] Figure 4 A flowchart of the target recommendation project determination method in the project recommendation method provided in the embodiments of this disclosure is shown;
[0024] Figure 5 A schematic diagram of the target recommended project determination method in the project recommendation method provided in the embodiments of this disclosure is shown;
[0025] Figure 6 A schematic diagram of the structure of a project recommendation device provided in an embodiment of this disclosure is shown;
[0026] Figure 7 A schematic diagram of the structure of a computer device provided in an embodiment of this disclosure is shown. Detailed Implementation
[0027] To make the objectives, technical solutions, and advantages of the embodiments of this disclosure clearer, the technical solutions of the embodiments of this disclosure will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this disclosure, and not all of them. The components of the embodiments of this disclosure described and shown in the accompanying drawings can generally be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of this disclosure provided in the accompanying drawings is not intended to limit the scope of the claimed disclosure, but merely represents selected embodiments of this disclosure. All other embodiments obtained by those skilled in the art based on the embodiments of this disclosure without inventive effort are within the scope of protection of this disclosure.
[0028] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.
[0029] In this document, the term "and / or" merely describes a relationship, indicating that three relationships can exist. For example, A and / or B can represent three cases: A alone, A and B simultaneously, and B alone. Furthermore, the term "at least one" in this document means any combination of at least two of any one or more elements. For example, including at least one of A, B, and C can mean including any one or more elements selected from the set consisting of A, B, and C.
[0030] With the increasing severity of information overload on the internet, especially on e-commerce websites and social media platforms, users often feel overwhelmed by massive amounts of data. Against this backdrop, recommender systems (RS) have emerged. By capturing users' dynamic preferences and discovering their interests in historical interactions, they effectively help users filter valuable content from a sea of information. This technology greatly simplifies the process of finding useful information in big data and enhances the user experience.
[0031] Research has revealed that most existing recommender systems analyze time series data of user history, decomposing the evolution of user behavior into adjacent item switching patterns of personalized preferences and semantic switching patterns of items influenced by semantic relevance. While some methods attempt to model semantic relevance, they often fail to simultaneously consider both patterns for sequential recommendation. Furthermore, current attention mechanisms and generative methods, such as those based on variational autoencoders, have limitations in representing the uncertainty of user behavior and are susceptible to information bottleneck theory. Although contrastive learning methods improve the quality of item representations by introducing auxiliary tasks, intra-sequence and inter-sequence noise in user history still negatively impacts recommendation performance. Existing methods such as FMLP and DLFS perform well in removing intra-sequence noise but neglect the impact of inter-sequence noise, limiting recommendation performance. Simultaneously, while diffusion models show great potential in capturing complex distributions, their application in recommender systems remains insufficient, particularly in handling semantic relevance and inter-sequence noise.
[0032] Based on the above research, this disclosure provides a method, apparatus, medium, and computer device for item recommendation. Specifically, it involves: acquiring a set of user behavior sequences; determining an item set based on the set of user behavior sequences; constructing an item embedding matrix based on the item set; determining a user-item embedding vector corresponding to each user behavior sequence based on the item embedding matrix; constructing an item sequence transition graph and an item semantic transition graph based on the set of user behavior sequences; determining a conditional signal corresponding to each user behavior sequence based on the item sequence transition graph and the item semantic transition graph; and adjusting a pre-trained diffusion model based on the conditional signal corresponding to the user behavior sequence of any user for any recommendation request, and determining the target recommendation item corresponding to any user based on the adjusted diffusion model.
[0033] In this embodiment of the disclosure, by constructing an item sequence transition graph and an item semantic transition graph, a pattern of integrating adjacent item transitions and semantically related item transitions is realized. At the same time, by determining conditional signals based on the item sequence transition graph and the item semantic transition graph and adjusting the diffusion model accordingly, the noise problem between and within sequences is effectively handled, thereby significantly improving the accuracy of item recommendations.
[0034] To facilitate understanding of this embodiment, the executing entity of the project recommendation method provided in this disclosure will first be described in detail. The executing entity of the project recommendation method provided in this disclosure is a computer device. This computer device can be a terminal device or a server. The terminal device can also be a mobile device, a user terminal, a terminal, a handheld device, a computing device, an in-vehicle device, a wearable device, etc. The server can be an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud storage, big data, and artificial intelligence platforms. Optionally, this method can also be applied to an implementation environment composed of computer devices and servers.
[0035] The project recommendation method provided in the embodiments of this application will be described in detail below with reference to the accompanying drawings. See also Figure 1 The diagram shown is a flowchart of a project recommendation method provided in an embodiment of this disclosure. The method includes the following steps S101 to S104:
[0036] S101, Obtain a set of user behavior sequences, determine an item set based on the set of user behavior sequences, and construct an item embedding matrix based on the item set.
[0037] It's understandable that a user behavior sequence set includes multiple user behavior sequences. A user behavior sequence refers to a series of item interaction behaviors of each user during their interaction with the system or platform. These behaviors can include various types such as clicking on an item and browsing an item. The user behavior sequence set covers the item interaction behaviors of all users on the platform. An item set refers to the collection of all items that have appeared in user behavior; it contains all items that the user has interacted with on the platform. Here, to construct an item set, one can iterate through the entire user behavior sequence set, examine each item in each sequence, extract them, and remove duplicates to obtain the aforementioned item set. Specifically, the "items" in the item set can be various entities, including but not limited to goods, items, or movies. On an e-commerce platform, an item set might contain all the items that the user has browsed, purchased, or added to their shopping cart; on a content sharing platform, it might include all the videos or articles that the user has watched, liked, commented on, or shared; and in a movie streaming service, an item set might represent all the movies that the user has watched, added to their watchlist, or rated.
[0038] For example, after determining an itemset based on a set of user behavior sequences, an itemset embedding matrix can be constructed based on this itemset. This matrix is a lookup table that maps items to low-dimensional embedding representations. Specifically, each item in this itemset can be assigned a unique index, which will serve as the row labels of the itemset embedding matrix. The columns of the matrix correspond to the dimensions of the embedding vector; these dimensions are the coordinate axes in the low-dimensional embedding space, and together they define the embedding representation of the item. Here, each row of the itemset embedding matrix represents an item, and each column represents a feature dimension of that item in the embedding space. The element values (usually real numbers) in the matrix represent the weights of the item on each feature dimension, and these weights together constitute the low-dimensional embedding vector of the item.
[0039] S102, determine the user-item embedding vector corresponding to each user behavior sequence based on the item embedding matrix; construct the item sequence transition graph and the item semantic transition graph based on the user behavior sequence set.
[0040] Understandably, after constructing the item embedding matrix, a corresponding user-item embedding vector can be generated for each user behavior sequence based on the constructed item embedding matrix. Specifically, for each user behavior sequence, each item needs to be examined individually. The item embedding matrix serves as an indexing tool, used to find the low-dimensional embedding vectors corresponding to these items. Since user behavior sequences often contain interaction data between the user and multiple items, for each user behavior sequence, each item in the sequence is examined individually, and the low-dimensional embedding vectors corresponding to these items are found using the item embedding matrix. Because user behavior sequences typically contain interaction data with multiple items, by mapping each item in the sequence and its interaction behavior to a low-dimensional embedding space, these embedding vectors can be integrated to generate a user-item embedding vector that represents the overall characteristics of the user behavior sequence. This vector not only integrates the specific information of all the items the user has interacted with, but also implicitly expresses the correlation between these items and the user's preferences and interests through low-dimensional embedding.
[0041] Specifically, when constructing the item sequence transition graph and the item semantic transition graph based on the user behavior sequence set, the following (1) to (2) can be included:
[0042] (1) Determine the order of events between each item based on the user behavior sequence set, and construct an event sequence transition diagram based on the order of events between each item;
[0043] (2) Determine the common interaction frequency between each item based on the user behavior sequence set, calculate the semantic similarity between each item based on the common interaction frequency between each item, and construct the item semantic transfer graph based on the calculation results.
[0044] Specifically, when constructing a project sequence transition graph, we can analyze the order in which items are accessed by users in consecutive behaviors based on each user behavior sequence in the user behavior sequence set, thereby determining the order in which items occur between them. Essentially, this involves mining the project sequence dependencies in user behavior, i.e., which items users tend to access first and which next. Subsequently, a project sequence transition graph can be constructed based on these orderings. In this graph, nodes represent different items, while edges represent the transition relationships between items.
[0045] In some other embodiments, to refine the granularity of transfer relationships, an item-to-item sequential transfer matrix can be introduced, where each element indicates whether a transfer relationship exists between items within n steps. This matrix reflects not only direct transfers between items but also indirect transfers mediated by other items, thus providing a more comprehensive depiction of item transfer patterns in user behavior sequences.
[0046] Specifically, when constructing the semantic transition graph of items, the common interaction frequency between items can be calculated based on each user behavior sequence in the user behavior sequence set, that is, the number of users who simultaneously interacted with two items can be counted. This indicator reflects the co-occurrence of items in user behavior and is the basis for evaluating the potential semantic connections between items. Next, the semantic similarity between items is calculated using the common interaction frequency. Here, since the cosine similarity function can effectively measure the proximity of two vectors in a direction and is suitable for similarity evaluation in embedded vector spaces, this disclosure uses the cosine similarity function for calculation, including: for each item i, calculating its semantic similarity with all other items, and selecting the k items with the highest semantic similarity as edges to construct the item semantic transition graph. In this graph, the edge weights reflect the semantic similarity strength between items, while the k value can reflect the sparsity and information richness of the graph. Here, the k value can be set to 10, 20, etc., without specific limitation.
[0047] In some other embodiments, to further improve the accuracy of the semantic transition graph, a weight matrix that is redistributed based on semantic relevance can be introduced. This matrix fine-tunes the direct similarity between items by considering the global semantic structure between items, ensuring that the potential connections between items are more accurately reflected when constructing the semantic transition graph.
[0048] In this embodiment, by constructing an item sequence transition graph and an item semantic transition graph, a fusion of adjacent item transitions and semantically related item transition patterns is achieved. Specifically, the item sequence transition graph captures the order in which users access items in continuous behavior, revealing direct and indirect transition relationships between items, thus reflecting the flow characteristics of user behavior. Simultaneously, the item semantic transition graph constructs a semantic connection network between items based on their common interaction frequency and semantic similarity, highlighting the intrinsic semantic connections between items. The fusion of these two transition patterns not only enriches the understanding of user-item interaction behavior but also provides complementary perspectives from two different angles: item access order and item semantic relevance. This provides more accurate and comprehensive data support for user recommendation algorithms, helping to improve the personalization and accuracy of recommendations.
[0049] S103, determine the condition signal corresponding to each user behavior sequence based on the item sequence transition graph and the item semantic transition graph.
[0050] For example, refer to Figure 2 As shown, determining the conditional signal corresponding to each user behavior sequence may include the following steps S201 to S203:
[0051] S201, Based on LightGCN, according to the item sequence transition graph and the user-item embedding vector corresponding to each user behavior sequence, a first user-item embedding vector corresponding to each user behavior sequence is obtained.
[0052] As is understandable, a graph convolutional neural network (GNN) is a type of neural network used to process graph-structured data. It extends convolution operations from traditional data (such as images or grids) to graph data, capturing the complex relationships between nodes in graph data. In a GNN, each node updates its feature representation by aggregating the feature information of its neighboring nodes. Here, in this embodiment, a lightweight variant of the GNN, LightGCN, is used as the processing network. LightGCN focuses on the interaction information between users and items and updates the node's feature representation through multi-layer neighbor aggregation. Specifically, in each layer of neighbor aggregation, a residual-like linking formula is used to update the node's feature representation. This formula aims to retain some original information while introducing new neighbor information, thereby mitigating the information loss problem in deep networks.
[0053] Specifically, for each user's behavior sequence, its corresponding user-item embedding vector is input into LightGCN. The network uses multi-layer neighbor aggregation, guided by an item sequence transition graph, to fuse the neighbor information (i.e., the items that interact with each sub-vector) of the user-item embedding vector into the feature representation of the current node. In this way, a first user-item embedding vector corresponding to each user's behavior sequence can be obtained. These first user-item embedding vectors not only contain the potential relationship between users and items but also incorporate detailed information about the user's behavior sequence.
[0054] S202, based on LightGCN, according to the item semantic transition graph and the first user-item embedding vector corresponding to each user behavior sequence, a second user-item embedding vector corresponding to each user behavior sequence is obtained.
[0055] Understandably, the first user-item embedding vector corresponding to each user behavior sequence is taken as input and processed again using LightGCN. In each layer of the network, the neighbor aggregation process is guided by the item semantic transition graph. Specifically, LightGCN takes the first user-item embedding vector as input and performs multi-layer neighbor aggregation, i.e., the item semantic transition graph guides the aggregation process. By finding items that are semantically related or similar to each user-item embedding vector, the feature information of these neighbor nodes is fused to obtain the second user-item embedding vector corresponding to each user behavior sequence. These embedding vectors not only contain direct interaction information between users and items but also incorporate semantic relationships between items, providing a more comprehensive and in-depth interpretation of user behavior. This not only enhances the expressiveness of node features but also enables the feature representation of nodes to reflect broader contextual information.
[0056] S203, using a self-attention learning mechanism based on the class residual linking formula, determine the conditional signal corresponding to each user behavior sequence according to the first user-item embedding vector corresponding to each user behavior sequence and the second user-item embedding vector corresponding to each user behavior sequence.
[0057] Self-attention is a deep learning technique particularly well-suited for processing sequential data. It dynamically assesses the importance of each element in a sequence (in this case, items in a user behavior sequence) and integrates information based on weighted importance scores. Through self-attention, the scheme can identify key behaviors or patterns in user behavior sequences that are crucial for predicting future user behavior or preferences.
[0058] Specifically, the self-attention mechanism is first used to calculate the attention score between each user-item embedding vector, reflecting the degree of correlation between the vectors. Then, the vectors are weighted and summed based on these scores to obtain a new representation that integrates information from all elements in the sequence but emphasizes important elements; that is, the result removes redundant information and highlights the parts valuable for predicting future user behavior. Simultaneously, this disclosure proposes a residual-like connection method to connect the first and second user-embedded vectors in a manner similar to a residual connection process, using a self-attention function as the readout function to achieve stability in message passing of the embedding vectors across different graphs. Since propagation on the item semantic transfer graph smooths out the differences between item embeddings, which may lead to the loss or distortion of personalized user preference information, the residual-like connection process mitigates this problem by retaining some original information and combining it with the second user-embedded vector. Thus, even with multiple message aggregations of the embedding vectors across different graphs, the integrity and accuracy of the information can be maintained. Finally, through the combined effect of the self-attention learning mechanism and the residual-like connection formula, the conditional signal corresponding to each user behavior sequence can be determined. This conditional signal not only contains detailed information about the user's behavior sequence but also incorporates the order and semantic relationships between items, providing strong support for user behavior prediction. In this way, embodiments of this disclosure can more accurately capture user behavior patterns, improving the accuracy and personalization of the recommendation system.
[0059] Here, the residual linkage formula includes:
[0060]
[0061] in, Represented as user-item embedding vector e i The item embedding representation of item i in the l-th convolution on the item sequence transition graph is obtained through LightGCN; i Represented as the user-item embedding vector corresponding to item i in the user behavior sequence; Represented as user-item embedding vector e i The item embedding representation of item i in the (l+1)th convolutional layer on the item sequence transition graph using LightGCN; N i Let i be the set of one-hop neighbors of project i in the project transition graph; Let e be the user-item embedding vector corresponding to item i in the user behavior sequence. i A neighbor's jump i' The project embedding representation; L represents the number of network layers in LightGCN; The first user-item embedding vector is represented as the user-item embedding vector corresponding to item i in the user behavior sequence. Represented as the first user-item embedding vector Item embedding representation in the l-th convolutional layer on the item semantic transition graph; Represented as the first user-item embedding vector The item embedding representation of item i in the (l+1)th convolutional layer on the item semantic transfer graph is obtained through LightGCN; Represented as the first user-item embedding vector A neighbor Project embedding representation; It is represented as the second user-item embedding vector corresponding to item i in the user behavior sequence.
[0062] For example, in order to understand this embodiment, refer to Figure 3 As shown, the user-item embedding vector e corresponding to a certain user behavior sequence is... i Taking the conditional signal determination process as an example, the conditional signal determination method proposed in this scheme is explained. First, the user-item embedding vector e is... i The input is fed into LightGCN, and then the network utilizes the item order transfer graph G through multi-layer neighbor aggregation. s Guide the neighbor aggregation process by embedding the user-item embedding vector e i The neighbor information (i.e., the items that have interacted with each sub-vector) is fused into its feature representation. In this way, the first user-item embedding vector corresponding to each user behavior sequence can be obtained. Here, the project sequence transition diagram G s =(I,ε), Where I represents the total number of projects, p and q represent the project numbers, and there is a transition relationship between project p and project q within n steps. After obtaining the first user-project embedding vector Then, it is used as input and processed again using LightGCN. The project semantic transition graph G is utilized. u By guiding the neighbor aggregation process and iteratively applying multi-level neighbor aggregation, a second user-item embedding vector corresponding to each user behavior sequence can be obtained. Here, the project semantic transition graph G u =(I,ε',R), where, After obtaining the first user-project embedding vector and the second user-item embedding vector Then, the two types of vectors are processed using a self-attention learning mechanism and a class residual formula to obtain the conditional signal cond corresponding to each user behavior sequence (including the item order transition conditional signal cond).s and project semantic transition condition signal cond u ).
[0063] S104, for any user's recommendation needs, adjust the pre-trained diffusion model based on the conditional signal corresponding to the user behavior sequence of the user, and determine the target recommendation item corresponding to the user based on the adjusted diffusion model.
[0064] Here, the proposed method aims to recover noisy item representations to their original state given conditional inputs. This process involves the concept of a diffusion model, where noise is gradually added to the item representation at different time steps (or diffusion steps) until the original information is almost unrecognizable. The task of the denoising network is to reverse this process and recover the original information from the noisy data. The key here is the use of a unique temporal-semantic attention mechanism that adaptively denoises based on different transition patterns of items.
[0065] For example, training the diffusion model may include: after obtaining the conditional signal corresponding to each user behavior sequence, calculating the attention weights in the diffusion model at different diffusion steps using the attention selection weight formula based on the conditional signals (i.e., item sequence transition conditional signals and item semantic transition conditional signals). The attention selection weight formula is expressed as:
[0066] α = Softmax(W) a Concat(cond s ,cond u ,e t )+b a );
[0067] Where α represents the attention weight; W a and b a Represented as learnable parameters; e t This is represented as the embedded representation of the diffusion step at time t.
[0068] Specifically, for each step in the denoising process, the conditional denoising network determines the value predicted in the previous step. Generating denoised representations x from different perspectives s,i and x u,i Each layer of the conditional denoising network is constructed according to the following formula:
[0069]
[0070] Where σ represents the ReLU activation function, and the original target embedding is ultimately predicted based on the attention weights α at different transition modes in the current diffusion step.
[0071] Understandably, by gradually learning the data distribution after adding noise through diffusion and conditional denoising processes, the target item can be embedded... Gradually from Gaussian noise The recovery process includes: The reconstruction process is defined as using cond s ,cond u From the condition arrive A series of denoising iterations, the conditional denoising process calculates the probability p(e=e) i |cond s ,cond u Recommend projects that users may be interested in, including:
[0072]
[0073] in, This can be further interpreted as sim(·) is the similarity function;
[0074]
[0075] Where, β t For noise scheduling, control the noise added during diffusion step t. It is a representation of random items sampled from a standard Gaussian distribution.
[0076] Specifically, according to The intensity of conditional and unconditional guidance is controlled by the hyperparameter γ, where x θ For conditional denoising networks.
[0077] Specifically, according to the diffusion process A through reconstruction The conditional denoising process can be represented as: The predicted value from step t-1 will serve as the input for the next iteration of the conditional denoising process, with each denoising step following the same structure. Through a series of denoising iterations, the data distribution is captured more precisely, resulting in higher-quality target item embeddings. To enable the training of the diffusion model.
[0078] Here, during the update process, this disclosure also uses a pairwise ranking-based loss function, Adam, for optimization. This function is widely used in implicit feedback, thereby enabling the model to better fit the data and make the prediction results more accurate. User sequence Lu Each subsequence in the , covers the entire length |L u | is considered as training data, that is, The cross-entropy loss function is used to calculate the optimization objective of the recommendation task:
[0079]
[0080] in, This represents the output of the diffusion model, while It is a negative sample randomly sampled for the k-th interactive item.
[0081] In this embodiment, the diffusion model is constructed using the PyTorch framework, which optimizes all models using the Adam optimizer. The batch size is 512, the embedding and hidden layer sizes are set to {16, 32, 64}, the learning rate is searched within [0.001, 0.005, 0.01, 0.05], and the maximum sequence length n is set to 50. The number of LightGCN layers is set within [1, 2, 3], the number of attention layers is set to 2 with 4 heads for multidimensional representation, and the dropout rate is set within [0.1, 0.3, 0.5, 0.7]. The total diffusion steps T are searched within [5, 10, 20, 50, 100, 200, 500], and the conditional guidance strength γ is searched within [0, 2, 4, 6]. User-free and item-free embeddings and weight parameters are randomly initialized using a Gaussian distribution.
[0082] Specifically, adjusting the pre-trained diffusion model using conditional signals corresponding to the user's behavior sequence involves inputting these conditional signals into the pre-trained diffusion model. Through this process, the model can gradually reconstruct the potential real data—that is, the recommended items that the user might be interested in—from noisy data, guided by the conditional signals. (See reference...) Figure 4 As shown, when determining the target recommended item corresponding to any user based on the adjusted diffusion model, the following steps S401 to S407 may be included:
[0083] S401, Obtain Gaussian noise and set the Gaussian noise as the initial item representation.
[0084] Here, Gaussian noise is a standard Gaussian distribution. This is obtained through sampling. By sampling a standard Gaussian distribution, a Gaussian noise is obtained and set as the initial item representation. This initial item representation is the starting point for the subsequent denoising process, representing the recommender system's preliminary guess of the user's potential interests.
[0085] S402, conditionally guide denoising is performed on the initial item representation based on the conditional guidance formula and the conditional signal corresponding to the user behavior sequence of any user, to obtain the first guidance result.
[0086] Specifically, after obtaining the initial item representation, conditional guided denoising is performed on the initial item representation using a conditional guidance formula and a conditional signal corresponding to the user behavior sequence. By incorporating the conditional signal into the denoising process, the model can be guided to more accurately capture the user's latent needs, thereby generating the first guidance result.
[0087] Here, the conditionally guided formulas include:
[0088]
[0089] in, The initial item represents the calculated probability of the first guiding outcome in the t-th diffusion process in the diffusion model; cond s The first parameter of the conditional signal is represented as cond. u This is represented as the second parameter of the conditional signal; The initial project represents the first guiding result obtained in the t-th step of the diffusion model; The initial project represents the first guiding result obtained in the (t-1)th step of the diffusion model; This represents the mean of a conditionally guided normal distribution; Represented as a conditional denoising network; β t This represents noise scheduling; I represents the identity matrix.
[0090] S403, perform unconditional guided denoising on the initial item representation based on the unconditional guided formula to obtain the second guided result.
[0091] For example, to improve recommendation accuracy, this disclosure also performs unconditionally guided denoising on the initial item representation to obtain a second guided result. Here, unconditionally guided denoising does not rely on any specific conditional signal, but rather infers the user's potential interests based on the model's own prior knowledge and structure. This step helps increase the diversity and generalization ability of the recommendation system because it can explore interests that are not explicitly reflected in the user's historical behavior.
[0092] Here, unconditional guidance formulas include:
[0093]
[0094] in, The initial item represents the calculated probability of the second guiding outcome in the t-th diffusion process in the diffusion model; It is represented as the mean of an unconditionally guided normal distribution.
[0095] S404: Determine the updated item representation based on the first guidance result and the second guidance result.
[0096] Understandably, after obtaining the first and second guidance results, the diffusion process can be used as a basis. pass (Feature representation at time step t) Reconstruction (The item representation state obtained from the previous time step through the denoising process), that is, determining the updated item representation, where the conditional denoising process can be represented as:
[0097]
[0098] in, These are model parameters used for weighting the diffusion process; t is the time step; z s It is represented as a Gaussian noise term.
[0099] S405, determine whether the updated item meets the requirements; if yes, proceed to step S407; if no, proceed to step S406.
[0100] Specifically, after obtaining the updated item representation, it needs to be judged to determine whether it meets the requirements. Here, the requirement usually refers to whether the updated item representation is close enough to the true representation of the user's latent interests. That is, by judging whether the superscript t (actually t-1) of the updated item representation is 0. In the context of the diffusion model, t=0 usually represents the beginning of the diffusion process, which is the true state of the user's latent interests. If t is not 0, it means that not all denoising steps have been completed. Therefore, the updated item representation (i.e., the updated item representation with superscript t-1) needs to be used as the new initial item representation, and the process returns to step S402 for the next round of denoising. If t is 0, it means that all denoising steps have been completed, and an approximate representation of the user's latent interests has been obtained. At this time, it can be considered that the updated item representation meets the requirements, and the subsequent step S407 is executed.
[0101] S406, use the updated item representation as the initial item representation, and return to step S402.
[0102] S407, Based on the updated item representation, determine the target recommended item corresponding to any user.
[0103] Specifically, the updated item representation represents the potential recommendation result calculated by the model for the current user. However, this prediction is not directly associated with a specific item ID, nor is it clear which specific item ID it is most similar to. Therefore, to determine the target item to be recommended to the user, it is necessary to calculate the similarity between the updated item representation and the features of each item in the item embedding matrix to find the closest target item and recommend it to the user. Therefore, determining the target recommendation item for any user based on the updated item representation may include the following steps (a) to (c):
[0104] (a) Determine whether the updated item represents a user behavior sequence of any of the users;
[0105] (b) If the updated item representation belongs to the user behavior sequence of any of the users, delete the items in the item sequence corresponding to the updated item representation in the item embedding matrix, and calculate the similarity between the updated item representation and each item in the deleted item embedding matrix respectively, and determine the target recommended item based on the calculation results;
[0106] (c) If the updated item representation does not belong to the user behavior sequence of any of the users, calculate the similarity between the updated item representation and each item in the item embedding matrix, and determine the target recommended item based on the calculation results.
[0107] Understandably, to avoid recommending items that are the same as items previously visited by the user, it's necessary to determine whether the updated item representation is already included in the user's historical behavior sequence before calculation. If the updated item representation belongs to the user's behavior sequence (i.e., the user has already interacted with a certain item), then that item is no longer a recommended item, and the item embedding matrix can be modified accordingly. Specifically, the item in the sequence corresponding to the updated item representation is removed from the item embedding matrix. After removing the items corresponding to the updated item representation, the similarity between the updated item representation and the remaining items is calculated. Based on the similarity calculation results, the target recommended item set (which may include one or more items) can be determined.
[0108] For example, when the updated item representation does not belong to the user's behavior sequence (i.e., the user has not interacted with the item before), the recommendation system will not need to delete any items. In this case, the recommendation algorithm will directly calculate the similarity between the updated item representation and each item in the all-item embedding matrix. Similar to the previous steps, the system will select the item that best matches the user's interests and needs for recommendation based on the calculated similarity value.
[0109] Reference Figure 5As shown, the recommendation system algorithm of this disclosure uses the dot product method as the basic calculation method when calculating the similarity between the updated item representation and each item sequence in the deleted item embedding matrix. Specifically, this method first updates the item representation... A dot product is performed with each item sequence in the item embedding matrix E. The dot product is a mathematical inner product operation that measures the similarity or relevance between two vectors, achieved by summing the products of their corresponding elements. Here, to further improve the accuracy and robustness of the recommendations, these initially calculated dot products are input into a multilayer perceptron (MLP) for further processing. An MLP is a feedforward artificial neural network with powerful nonlinear mapping and feature learning capabilities. Through the combination of multiple hidden layers, the MLP can capture complex patterns and associations in the data, thereby performing nonlinear transformations and combinations on the input dot products to extract more abstract and higher-level feature information. This process not only enhances the model's understanding of the input data but also improves the final output—the target recommended item score. It can more accurately reflect users' potential needs and preferences.
[0110] In some other embodiments, a binary weighted community network discovery method can be introduced to optimize the target recommended items in the target recommended item sequence set. This method identifies potential associations and community structures between items, providing the recommendation system with deeper information on item relationships. By utilizing this information, the recommendation system can more accurately evaluate the similarity between the updated item representation and each item, further optimizing the recommendation results. This approach not only improves the accuracy of recommendations but also enhances the interpretability of the results, making the recommended items easier for users to understand and accept.
[0111] In some other embodiments, similarity can be calculated using methods such as cosine similarity and Euclidean distance to evaluate the similarity between the predicted value and other items, without being specifically limited here.
[0112] The project recommendation method, apparatus, medium, and computer equipment provided in this disclosure embodiment achieve the integration of adjacent project transitions and semantically related project transition patterns by constructing project sequence transition graphs and project semantic transition graphs. At the same time, by determining conditional signals based on project sequence transition graphs and project semantic transition graphs and adjusting the diffusion model accordingly, the noise problems between and within sequences are effectively handled, thereby significantly improving the accuracy of project recommendations.
[0113] Those skilled in the art will understand that, in the above-described method of the specific implementation, the order in which each step is written does not imply a strict execution order and does not constitute any limitation on the implementation process. The specific execution order of each step should be determined by its function and possible internal logic.
[0114] Based on the same inventive concept, this disclosure also provides a project recommendation device corresponding to the project recommendation method. Since the principle of the device in this disclosure for solving the problem is similar to that of the project recommendation method described above, the implementation of the device can refer to the implementation of the method, and the repeated parts will not be described again.
[0115] Reference Figure 6 The diagram shown is a schematic representation of a project recommendation device 600 provided in an embodiment of this disclosure. The device includes:
[0116] The sequence acquisition module 601 is used to acquire a set of user behavior sequences, determine an item set based on the set of user behavior sequences, and construct an item embedding matrix based on the item set; wherein, the set of user behavior sequences includes multiple user behavior sequences; and the item set includes multiple items.
[0117] The transition graph determination module 602 is used to determine the user-item embedding vector corresponding to each user behavior sequence based on the item embedding matrix; and to construct an item sequence transition graph and an item semantic transition graph based on the user behavior sequence set.
[0118] The signal determination module 603 is used to determine the condition signal corresponding to each user behavior sequence based on the item sequence transition graph and the item semantic transition graph.
[0119] The recommendation item determination module 604 is used to adjust a pre-trained diffusion model based on the conditional signal corresponding to the user behavior sequence of any user, and determine the target recommendation item corresponding to any user based on the adjusted diffusion model, in response to the recommendation needs of any user.
[0120] In some possible embodiments, the transition map determination module 602 is specifically used for:
[0121] The order of events among the projects is determined based on the user behavior sequence set, and a project sequence transition graph is constructed based on the order of events among the projects.
[0122] Based on the user behavior sequence set, the common interaction frequency between each item is determined, and the semantic similarity between each item is calculated based on the common interaction frequency between each item. Based on the calculation results, a semantic transfer graph of the items is constructed.
[0123] In some possible embodiments, the signal determination module 603 is specifically used for:
[0124] Based on LightGCN, the first user-item embedding vector corresponding to each user behavior sequence is obtained according to the item sequence transition graph and the user-item embedding vector corresponding to each user behavior sequence.
[0125] Based on LightGCN, a second user-item embedding vector corresponding to each user behavior sequence is obtained according to the item semantic transition graph and the first user-item embedding vector corresponding to each user behavior sequence;
[0126] Using a self-attention learning mechanism based on a class residual linking formula, the conditional signal corresponding to each user behavior sequence is determined according to the first user-item embedding vector and the second user-item embedding vector corresponding to each user behavior sequence.
[0127] In some possible embodiments, the residual linkage formula includes:
[0128]
[0129] in, Represented as user-item embedding vector e i The item embedding representation of item i in the l-th convolution on the item sequence transition graph is obtained through LightGCN; i Represented as the user-item embedding vector corresponding to item i in the user behavior sequence; Represented as user-item embedding vector e i The item embedding representation of item i in the (l+1)th convolutional layer on the item sequence transition graph using LightGCN; N i Let i be the set of one-hop neighbors of project i in the project transition graph; Let e be the user-item embedding vector corresponding to item i in the user behavior sequence. i A neighbor's jump i' The project embedding representation; L represents the number of network layers in LightGCN; The first user-item embedding vector is represented as the user-item embedding vector corresponding to item i in the user behavior sequence. Represented as the first user-item embedding vector Item embedding representation in the l-th convolutional layer on the item semantic transition graph; Represented as the first user-item embedding vector The item embedding representation of item i in the (l+1)th convolutional layer on the item semantic transfer graph is obtained through LightGCN; Represented as the first user-item embedding vector A neighbor Project embedding representation; It is represented as the second user-item embedding vector corresponding to item i in the user behavior sequence.
[0130] In some possible embodiments, the recommended item determination module 604 is specifically used to perform:
[0131] Step 1: Obtain Gaussian noise and set the Gaussian noise as the initial item representation;
[0132] Step 2: Based on the conditional guidance formula and the conditional signal corresponding to the user behavior sequence of any user, perform conditional guidance denoising on the initial item representation to obtain the first guidance result;
[0133] Step 3: Perform unconditional guided denoising on the initial item representation based on the unconditional guided formula to obtain the second guided result;
[0134] Step 4: Determine the updated project representation based on the first guidance result and the second guidance result, and determine whether the updated project representation meets the requirements; if yes, proceed to step 5; if no, use the updated project representation as the initial project representation and return to step 2;
[0135] Step 5: Determine the target recommended item corresponding to any user based on the updated item representation.
[0136] In some possible embodiments, the recommended item determination module 604 is specifically used for:
[0137] Determine whether the updated item represents a user behavior sequence of any of the users;
[0138] If the updated item representation belongs to the user behavior sequence of any of the users, delete the items in the item sequence corresponding to the updated item representation in the item embedding matrix, and calculate the similarity between the updated item representation and each item in the deleted item embedding matrix. Based on the calculation results, determine the target recommended item.
[0139] If the updated item representation does not belong to any user behavior sequence of the user, the similarity between the updated item representation and each item in the item embedding matrix is calculated, and the target recommended item is determined based on the calculation results.
[0140] In some possible embodiments,
[0141] The conditional guidance formulas include:
[0142]
[0143] in, The initial item represents the calculated probability of the first guiding outcome in the t-th diffusion process in the diffusion model; cond s The first parameter of the conditional signal is represented as cond. u This is represented as the second parameter of the conditional signal; The initial project represents the first guiding result obtained in the t-th step of the diffusion model; The initial project represents the first guiding result obtained in the (t-1)th step of the diffusion model; This represents the mean of a conditionally guided normal distribution; Represented as a conditional denoising network; β t Represented as noise scheduling; I represents the identity matrix;
[0144] The unconditional guidance formula includes:
[0145]
[0146] in, The initial item represents the calculated probability of the second guiding outcome in the t-th diffusion process in the diffusion model; It is represented as the mean of an unconditionally guided normal distribution.
[0147] Based on the same technical concept, this disclosure also provides a computer device. (See also...) Figure 7 The diagram shows the structure of a computer device 700 provided in this embodiment of the present disclosure, including a processor 701, a memory 702, and a bus 703. The memory 702 stores execution instructions and includes a main memory 7021 and an external memory 7022. The main memory 7021, also called internal memory, is used to temporarily store computational data in the processor 701, as well as data exchanged with external memory 7022 such as a hard disk. The processor 701 exchanges data with the external memory 7022 through the main memory 7021.
[0148] In this embodiment, the memory 702 is specifically used to store application code that executes the solution of this application, and its execution is controlled by the processor 701. That is, when the computer device 700 is running, the processor 701 communicates with the memory 702 through the bus 703, so that the processor 701 executes the application code stored in the memory 702, and then executes the method described in any of the foregoing embodiments.
[0149] The memory 702 may be, but is not limited to, random access memory (RAM), read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), etc.
[0150] Processor 701 may be an integrated circuit chip with signal processing capabilities. The aforementioned processor can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this invention. The general-purpose processor can be a microprocessor or any conventional processor.
[0151] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the computer device 700. In other embodiments of this application, the computer device 700 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
[0152] This disclosure also provides a computer-readable storage medium storing a computer program that, when executed by a processor, performs the steps of the project recommendation method described in the above-described method embodiments. The storage medium may be a volatile or non-volatile computer-readable storage medium.
[0153] This disclosure also provides a computer program product carrying program code. The program code includes instructions that can be used to execute the steps of the project recommendation method described in the above method embodiments. For details, please refer to the above method embodiments, which will not be repeated here.
[0154] The aforementioned computer program product can be implemented through hardware, software, or a combination thereof. In one optional embodiment, the computer program product is specifically embodied in a computer storage medium; in another optional embodiment, the computer program product is specifically embodied in a software product, such as a software development kit (SDK), etc.
[0155] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems and devices described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here. In the several embodiments provided in this disclosure, it should be understood that the disclosed systems and methods can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of units is only a logical functional division; in actual implementation, there may be other division methods. Furthermore, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Another point is that the displayed or discussed mutual coupling or direct coupling or communication connection may be through some communication interfaces; the indirect coupling or communication connection of devices or units may be electrical, mechanical, or other forms.
[0156] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0157] In addition, the functional units in the various embodiments of this disclosure can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0158] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a processor-executable, non-volatile, computer-readable storage medium. Based on this understanding, the technical solution of this disclosure, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this disclosure. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0159] Finally, it should be noted that the above-described embodiments are merely specific implementations of this disclosure, used to illustrate the technical solutions of this disclosure, and not to limit it. The protection scope of this disclosure is not limited thereto. Although this disclosure has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can still modify or easily conceive of changes to the technical solutions described in the foregoing embodiments, or make equivalent substitutions for some of the technical features, within the scope of the technology disclosed in this disclosure. Such modifications, changes, or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this disclosure, and should all be covered within the protection scope of this disclosure. Therefore, the protection scope of this disclosure should be determined by the protection scope of the claims.
Claims
1. A project recommendation method, characterized in that, include: Obtain a set of user behavior sequences, determine an item set based on the set of user behavior sequences, and construct an item embedding matrix based on the item set; wherein, the set of user behavior sequences includes multiple user behavior sequences; and the item set includes multiple items; Based on the item embedding matrix, determine the user-item embedding vector corresponding to each user behavior sequence; based on the user behavior sequence set, determine the order of item occurrence among items, and construct an item sequence transition graph based on the order of item occurrence among items; and based on the user behavior sequence set, determine the common interaction frequency among items, calculate the semantic similarity among items based on the common interaction frequency among items, and construct an item semantic transition graph based on the calculation results. Based on LightGCN, a first user-item embedding vector corresponding to each user behavior sequence is obtained according to the item sequence transition graph and the user-item embedding vector corresponding to each user behavior sequence; and a second user-item embedding vector corresponding to each user behavior sequence is obtained according to LightGCN, the item semantic transition graph and the first user-item embedding vector corresponding to each user behavior sequence; and a conditional signal corresponding to each user behavior sequence is determined using a self-attention learning mechanism based on a class residual linking formula according to the first user-item embedding vector corresponding to each user behavior sequence and the second user-item embedding vector corresponding to each user behavior sequence. For any user's recommendation needs, the pre-trained diffusion model is adjusted based on the conditional signals corresponding to the user's behavior sequence, and the target recommendation items corresponding to the user are determined based on the adjusted diffusion model.
2. The method according to claim 1, characterized in that, The residual linkage formula includes: , , ; , , ; in, Represented as user-item embedding vector The item embedding representation of item i in the l-th convolution on the item sequence transition graph is obtained through LightGCN; Represented as the user-item embedding vector corresponding to item i in the user behavior sequence; Represented as user-item embedding vector The item embedding representation of item i in the (l+1)th layer convolution on the item sequence transition graph is obtained through LightGCN; Let i be the set of one-hop neighbors of project i in the project transition graph; Represented as the user-item embedding vector corresponding to item i in the user behavior sequence. A neighbor The project embedding representation; L represents the number of network layers in LightGCN; The first user-item embedding vector is represented as the user-item embedding vector corresponding to item i in the user behavior sequence. Represented as the first user-item embedding vector Item embedding representation in the l-th convolutional layer on the item semantic transition graph; Represented as the first user-item embedding vector The item embedding representation of item i in the (l+1)th convolutional layer on the item semantic transfer graph is obtained through LightGCN; Represented as the first user-item embedding vector A neighbor Project embedding representation; It is represented as the second user-item embedding vector corresponding to item i in the user behavior sequence.
3. The method according to claim 1, characterized in that, The step of determining the target recommended item corresponding to any user based on the adjusted diffusion model includes: Step 1: Obtain Gaussian noise and set the Gaussian noise as the initial item representation; Step 2: Based on the conditional guidance formula and the conditional signal corresponding to the user behavior sequence of any user, perform conditional guidance denoising on the initial item representation to obtain the first guidance result; Step 3: Perform unconditional guided denoising on the initial item representation based on the unconditional guided formula to obtain the second guided result; Step 4: Determine the updated project representation based on the first guidance result and the second guidance result, and determine whether the updated project representation meets the requirements; if yes, proceed to step 5; if no, use the updated project representation as the initial project representation and return to step 2; Step 5: Determine the target recommended item corresponding to any user based on the updated item representation.
4. The method according to claim 3, characterized in that, The step of determining the target recommended item corresponding to any user based on the updated item representation includes: Determine whether the updated item represents a user behavior sequence of any of the users; If the updated item representation belongs to the user behavior sequence of any of the users, delete the items in the item sequence corresponding to the updated item representation in the item embedding matrix, and calculate the similarity between the updated item representation and each item in the deleted item embedding matrix. Based on the calculation results, determine the target recommended item. If the updated item representation does not belong to any user behavior sequence of the user, the similarity between the updated item representation and each item in the item embedding matrix is calculated, and the target recommended item is determined based on the calculation results.
5. The method according to claim 3, characterized in that, The conditional guidance formulas include: ; in, The initial item represents the calculated probability of the first guiding outcome in the t-th diffusion process in the diffusion model; This is represented as the first parameter of the conditional signal; This is represented as the second parameter of the conditional signal; The initial project represents the first guiding result obtained in the t-th step of the diffusion model; The initial project represents the first guiding result obtained in the (t-1)th step of the diffusion model; This represents the mean of the conditionally guided normal distribution; This is represented as a conditional denoising network; Represented as noise scheduling; Represents the identity matrix; The unconditional guidance formula includes: ; in, The initial item represents the calculated probability of the second guiding outcome in the t-th diffusion process in the diffusion model; It is represented as the mean of an unconditionally guided normal distribution.
6. A project recommendation device, characterized in that, include: A sequence acquisition module is used to acquire a set of user behavior sequences, determine an item set based on the set of user behavior sequences, and construct an item embedding matrix based on the item set; wherein, the set of user behavior sequences includes multiple user behavior sequences; and the item set includes multiple items; The transition graph determination module is used to determine the user-item embedding vector corresponding to each user behavior sequence based on the item embedding matrix; determine the order of item occurrence among items based on the user behavior sequence set, and construct an item sequence transition graph based on the order of item occurrence among items; and determine the common interaction frequency among items based on the user behavior sequence set, calculate the semantic similarity among items based on the common interaction frequency among items, and construct an item semantic transition graph based on the calculation results. The signal determination module is configured to: obtain a first user-item embedding vector corresponding to each user behavior sequence based on LightGCN, the item sequence transition graph, and the user-item embedding vector corresponding to each user behavior sequence; obtain a second user-item embedding vector corresponding to each user behavior sequence based on LightGCN, the item semantic transition graph, and the first user-item embedding vector corresponding to each user behavior sequence; and determine the conditional signal corresponding to each user behavior sequence based on a self-attention learning mechanism and a class residual linking formula, according to the first user-item embedding vector and the second user-item embedding vector corresponding to each user behavior sequence. The recommendation item determination module is used to adjust a pre-trained diffusion model based on the conditional signals corresponding to the user behavior sequence of any user, and determine the target recommendation items corresponding to any user based on the adjusted diffusion model, in response to the recommendation needs of any user.
7. A storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the method of any one of claims 1 to 5.
8. A computer device, comprising a storage medium, a processor, and a computer program stored on the storage medium and executable on the processor, characterized in that, When the processor executes the computer program, it implements the method of any one of claims 1 to 5.