Recommendation method based on semantic enhancement and heterogeneous hypergraph network
By constructing a heterogeneous hypergraph network and utilizing LLM encoding to explicitly feed back textual information and perform information propagation alignment, the problems of data sparsity and semantic inconsistency in graph neural network collaborative filtering are solved, and high-quality recommendation results are achieved.
Patent Information
- Application Number
- CN202511331184.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-17
- Publication Date
- 2026-02-10
AI Technical Summary
Existing collaborative filtering methods based on graph neural networks suffer from data sparsity and noise, heavily rely on high-quality interactions, and suffer from information inconsistency issues in the semantic alignment between large language models and recommendation systems, thus limiting the effectiveness of recommendation systems.
By constructing a recommendation method based on semantic enhancement and heterogeneous hypergraph networks, we utilize LLM encoding to explicitly feed back textual information, build item-category associations, design four types of hyperedges to represent complex relationships, and use graph autoencoders and graph convolutional networks for information propagation and alignment to generate high-quality user and item representations.
It effectively solves the degradation problem of LLM representation in the recommendation space, truly restores the information association in the recommendation scenario, avoids information loss or redundancy, and ensures high-quality recommendation results.
Smart Images

Figure CN121504538A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to artificial intelligence technology, and more particularly to a recommendation method based on semantic enhancement and heterogeneous hypergraph networks. Background Technology
[0002] Collaborative filtering (CF) aims to capture user preferences and recommend items of interest based on large-scale interaction histories. Graph-based collaborative filtering has been extensively studied due to the excellent encoding capabilities of graph neural networks for structural information. However, the heavy reliance on high-quality interactions, caused by data sparsity and noise, limits the effectiveness of graph neural network-based collaborative filtering. Recent research has explored using self-supervised learning (SSL) to provide improved interaction information; while some progress has been made, these methods neglect the rich semantics of relationships within the interaction context.
[0003] Given the excellent semantic understanding and reasoning capabilities of large language models (LLMs), researchers have explored their application to various tasks in recommender systems. Since LLMs struggle to leverage collaborative information, recent research has focused on bridging the semantic gap by integrating large language models and recommender models, typically following two technical approaches. The first approach uses collaborative information to assist LLMs, introducing external recommender models into LLMs to utilize collaborative representations. Considering the significant computational overhead of directly using LLMs as recommenders, the second approach leverages LLMs to provide auxiliary semantics to traditional recommender systems, ensuring scalable recommendations. For example, extracting semantic information from descriptive text using LLMs and optimizing user and item representations through alignment has yielded state-of-the-art performance. However, when aligning textual information with collaborative signals, inconsistent semantics between user-item and item-item text pairs can lead to degradation of the alignment model, hindering recommender systems from effectively utilizing heterogeneous information. Summary of the Invention
[0004] The technical problem to be solved by this invention is to provide a recommendation method based on semantic enhancement and heterogeneous hypergraph networks, addressing the shortcomings of existing technologies.
[0005] The technical solution adopted by this invention to solve its technical problem is: a recommendation method based on semantic enhancement and heterogeneous hypergraph networks, comprising the following steps: 1) Encode the semantic information in the explicit feedback text and use it as an auxiliary signal for the recommendation task; Explicit feedback refers to the comments generated during user interaction with items; By leveraging the semantic information of explicit feedback (comments) and aligning it with an LLM encoding and graph autoencoder, text modalities are transformed into auxiliary signals that can be incorporated into the recommendation space. 2) Use LLM to classify items into predefined categories, build item-category associations, and explore potential co-occurrence relationships among items; 2.1) Build an LLM based on item reviews or descriptions. A prompt guides the LLM to categorize items into predefined categories. 2.2) Convert the classification results into an item-category adjacency matrix. ; 3) Initialize user embedding Item embedding Category embedding ; 4) Construct heterogeneous hypergraph networks; After obtaining the initial representations of all nodes, the representations of all heterogeneous nodes and the relationships between them are plotted using a heterogeneous hypergraph. Comprehensive representation; in the figure In the middle, heterogeneous nodes Including users ,thing ,Comment and categories Since the relationships between nodes are not limited to pairs, four types of hyperedges are set. To represent complex relationships; including: (1) Interactive hyperedge It connects users, items, and corresponding comment nodes in the interaction; (2) Observe the hyperedge It consists of an item and each comment node associated with it; (3) Preference for superedges This includes users and the comment nodes they generate; (4) Featured hyperedge It contains an item and all its associated category nodes; in, , , From the adjacency matrix and definition, Then it is given by the LLM-based classifier. Definition; Four types of hyperedges They jointly define the adjacency of nodes in the heterogeneous hypergraph; 5) Hypergraph information dissemination and aggregation; After obtaining the initial representations of all nodes, heterogeneous information is propagated in the hypergraph through three types of aggregators; then, node representations are updated through multi-level propagation; finally, user representations are generated through multi-level representation fusion. and the representation of items ; 6) Semantic alignment and model training 6.1) After information propagation on the heterogeneous hypergraph, the information of the comment node is integrated into the user's representation. and the representation of items In this approach, a Graph Convolution Network (GCN) is used as the graph decoder, based on the user's representation. and the representation of items Reconstructing the semantic representation of comment nodes ; 6.2) Supervise the semantic reconstruction process through a loss function to ensure cross-modal alignment; Cross-modal semantic alignment provides a supervisory signal based on collaborative information, and graph autoencoders use a loss function. Conduct training; 7) End-user-based representation and the representation of items Perform recommendation calculations and output the recommendation results.
[0006] According to the above scheme, step 1) is as follows: 1.1) The comment text T is encoded using LLM to generate an initial semantic representation. ;
[0007] 1.2) Based on the node relationship between the user, comment, and item hops, the adjacency matrix between comment nodes is calculated through relationship sampling;
[0008] in, For sampling probability, An adjacency matrix representing the relationship between comments and items. An adjacency matrix representing the relationship between comments and users. It is the identity matrix; Indicates the probability of sampling Random sampling; 1.3) The Graph Attention Network (GAT) is used as the graph encoder to compress semantic information; Embedding of target comment nodes First, calculate its relationship with neighboring nodes using the attention vector. Attention coefficient Then, the compressed semantic representation is obtained by weighted summation. ; ;
[0009] in, For attention vectors, Indicates a splicing operation; This is the compressed semantic representation; The neighborhood of a node
[0010] The embedding representation of all comment nodes is as follows .
[0011] According to the above scheme, in step 3), the initialization is as follows: The text for each category was obtained through centralized collection of data, making This represents a set of categories, and its corresponding category embedding matrix is represented as follows: The category embedding matrix is obtained through collaborative filtering learning and is updated according to user-item interaction relationships to ensure consistency between category features and the collaborative relationship in the recommendation space. The embedding matrices for users and items are defined as follows: and ; According to the above scheme, in step 5), after obtaining the initial representations of all nodes, the propagation of heterogeneous information in the hypergraph is achieved through three types of aggregators: Depending on the type of node in the hyperedge, information propagation can be categorized into three modes: bidirectional propagation between heterogeneous nodes; unidirectional propagation between heterogeneous nodes; and bidirectional propagation between homogeneous nodes.
[0012] According to the above scheme, in step 5), heterogeneous information is propagated in the hypergraph through three types of aggregators; described as follows: (1) Bidirectional propagation aggregator between heterogeneous nodes ;
[0013] (2) Unidirectional propagation aggregator between heterogeneous nodes ;
[0014] (3) Bidirectional propagation aggregator between homogeneous nodes :
[0015] in, The type is The node, Representation and type are The set of nodes adjacent to the target node. It is an attention vector; Represents the target node In the neighborhood of a certain type Similar nodes; express Any node in the process.
[0016] According to the above scheme, in step 6.1), semantic representation for: ; in, This represents the convolution sum.
[0017] According to the above scheme, in step 6.2), the loss function as follows:
[0018] in, Used to calculate cosine similarity This indicates the selected semantic embedding subset.
[0019] The beneficial effects of this invention are: 1. This invention uses a technical approach of semantic encoding, hypergraph modeling, information propagation, and alignment supervision to align the semantics of LLM-encoded comments to the recommendation space via GAE, effectively solving the degradation problem of LLM representations in the recommendation space; 2. The heterogeneous hypergraph relation modeling of this invention uses four types of hyperedges to fully describe the complex non-paired relationships between users, items, comments, and categories, which can more realistically restore the information association in recommendation scenarios; 3. This invention designs an aggregator to meet the propagation needs of different types of nodes, and combines multi-layer pooling to achieve progressive fusion of heterogeneous information, avoiding information loss or redundancy and ensuring high quality of the final representation. Attached Figure Description
[0020] The present invention will be further described below with reference to the accompanying drawings and embodiments. In the accompanying drawings: Figure 1 This is a flowchart of a method according to an embodiment of the present invention. Detailed Implementation
[0021] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.
[0022] like Figure 1 As shown, 1) Encode the semantic information in the explicit feedback text and use it as an auxiliary signal for the recommendation task; Explicit feedback refers to the comments generated during user interaction with items; By leveraging the semantic information of explicit feedback (comments), and aligning it with an LLM encoding and a graph autoencoder (GAE), text modalities are transformed into auxiliary signals that can be incorporated into the recommendation space. 1.1) The comment text T is encoded using LLM to generate an initial semantic representation. ;
[0023] 1.2) Based on the node relationship between the user, comment, and item hops, the adjacency matrix between comment nodes is calculated through relationship sampling;
[0024] in, For sampling probability, An adjacency matrix representing the relationship between comments and items. An adjacency matrix representing the relationship between comments and users. It is the identity matrix; Indicates the probability of sampling Random sampling; 1.3) The Graph Attention Network (GAT) is used as the graph encoder to compress semantic information; Embedding of target comment nodes First, calculate its relationship with neighboring nodes using the attention vector. Attention coefficient Then, the compressed semantic representation is obtained by weighted summation. ; ;
[0025] in, For attention vectors, Indicates a splicing operation; This is the compressed semantic representation; The neighborhood of a node
[0026] The embedding representation of all comment nodes is as follows ; 2) Use LLM to classify items into predefined categories, build item-category associations, and explore potential co-occurrence relationships among items; 2.1) Build an LLM based on item reviews or descriptions. A prompt guides the LLM to categorize items into predefined categories. 2.2) Convert the classification results into an item-category adjacency matrix. ; 3) Initialize user embedding Item embedding Category embedding ; The text for each category was obtained through centralized collection of data, making This represents a set of categories, and its corresponding category embedding matrix is represented as follows: The category embedding matrix is obtained through collaborative filtering learning and is updated according to user-item interaction relationships to ensure consistency between category features and the collaborative relationship in the recommendation space; the user-item embedding matrix is defined as follows. and ; 4) Construct heterogeneous hypergraph networks; After obtaining the initial representations of all nodes, the representations of all heterogeneous nodes and the relationships between them are plotted using a heterogeneous hypergraph. Comprehensive representation; in the figure In the middle, heterogeneous nodes Including users ,thing ,Comment and categories Since the relationships between nodes are not limited to pairs, this invention designs four types of hyperedges. To represent complex relationships. These include: (1) Interactive hyperedge It connects users, items, and corresponding comment nodes in the interaction; (2) Observe the hyperedge It consists of an item and each comment node associated with it; (3) Preference for superedges This includes users and the comment nodes they generate; (4) Featured hyperedge It contains an item and all its associated category nodes; in, , , From the adjacency matrix and definition, Then it is given by the LLM-based classifier. Definition; Four types of hyperedges They jointly define the adjacency of nodes in the heterogeneous hypergraph; 5) Hypergraph information dissemination and aggregation; After obtaining the initial representations of all nodes, this invention achieves the propagation of heterogeneous information in the hypergraph through three types of aggregators; it updates node representations through multi-layer propagation; and it merges multi-layer representations to generate the user's representation. and the representation of items ; Different node types in a hyperedge require different information propagation scenarios: "heterogeneous bidirectional", "heterogeneous unidirectional", and "homogeneous bidirectional". First, to address the heterogeneity between nodes in each hyperedge, information propagation between nodes in the model can be categorized into three types: (1) Bidirectional propagation between heterogeneous nodes; (2) Unidirectional propagation between heterogeneous nodes; (3) Bidirectional propagation between homogeneous nodes.
[0027] Correspondingly, designing different aggregators for each type of propagation to guide message passing on heterogeneous hypergraphs can be described as follows: (1) Bidirectional propagation between heterogeneous nodes;
[0028] (2) Unidirectional propagation between heterogeneous nodes;
[0029] (3) Bidirectional propagation between homogeneous nodes:
[0030] in, The type is The representation of the nodes, Representation and type are The set of nodes adjacent to the target node. It is an attention vector. Represents heterogeneous nodes. This indicates homogeneous nodes.
[0031] Then, summation pooling is used to update the node representation of each hyperedge:
[0032]
[0033]
[0034] Among them, superscript The first heterogeneous hypergraph represents the... layer. For item nodes in the hypergraph Layer representation, For the first In the layer, the information vector obtained by the item node from the comment node through the heterogeneous propagation aggregator is a semantic supplement to the item representation; For the first In the layer, the information vector obtained by the item node from the comment node through the heterogeneous propagation aggregator is a feature supplement to the item representation; For the first In the layer, the information vector obtained by user nodes from comment nodes through a heterogeneous bidirectional propagation aggregator supplements the user's preference representation; For the first In the layer, the information vector obtained by the category node from the item node through the heterogeneous unidirectional propagation aggregator is a supplement to the item association represented by the category; For the first In the layer, the information vectors obtained by category nodes from other category nodes through the homogeneous bidirectional propagation aggregator are a supplement to the co-occurrence of the same category in the category representation; In interactive hyperedge Above, comment nodes bridge user preferences and item features, enriching the semantics of collaborative relationships. In feature hyperedges... The model aggregates embeddings of items belonging to the same category and further enhances item representation through feature-based co-occurrence semantics.
[0035] Finally, since different levels of node embedding reflect different degrees of fusion of heterogeneous information, average pooling is used to synthesize node representations:
[0036] in It represents the total number of layers in the heterogeneous hypergraph aggregation.
[0037] Through hypergraph information propagation and aggregation, the semantic information and category feature information of comments are gradually transmitted to user and item nodes. The final generated user and item representations retain their core features and integrate key information from heterogeneous nodes, providing a high-quality representation foundation for subsequent recommendation calculations and semantic alignment.
[0038] 6) Semantic alignment and model training; 6.1) After information propagation on the heterogeneous hypergraph, the information of the comment node is integrated into the user's representation. and the representation of items In this approach, a Graph Convolution Network (GCN) is used as the graph decoder, based on the user's representation. and the representation of items Reconstructing the semantic representation of comment nodes ; ; in, Represents convolution sum; 6.2) The semantic reconstruction process is supervised by the loss function L_recon to ensure cross-modal alignment; Cross-modal semantic alignment provides a supervisory signal based on collaborative information. The graph autoencoder is trained using the following loss function:
[0039] in, Used to calculate cosine similarity This indicates the selected semantic embedding subset.
[0040] 7) End-user-based representation and the representation of items Perform recommendation calculations and output the recommendation results.
[0041] To address the issues of feature semantic inconsistency and alignment degradation caused by large language models and collaborative filtering, this invention proposes a method based on semantically enhanced heterogeneous hypergraph networks. In this method, comment semantics extracted by a graph autoencoder and feature-based item relevance mined by an LLM-based classifier enrich the collaborative and co-occurrence relationships of collaborative filtering (CF). Furthermore, this invention designs a heterogeneous hypergraph network to achieve efficient alignment and propagation of heterogeneous information.
[0042] It should be understood that those skilled in the art can make improvements or modifications based on the above description, and all such improvements and modifications should fall within the protection scope of the appended claims.
Claims
1. A recommendation method based on semantic enhancement and heterogeneous hypergraph networks, characterized in that, Includes the following steps: 1) Encode the semantic information in the explicit feedback text and use it as an auxiliary signal for the recommendation task; Explicit feedback refers to the comments generated during user interaction with items; By leveraging the semantic information from explicit feedback and aligning it with an LLM encoding and graph autoencoder, text modalities are transformed into auxiliary signals that can be incorporated into the recommendation space. 2) Use LLM to classify items into predefined categories, build item-category associations, and explore potential co-occurrence relationships among items; 2.1) Build an LLM based on item reviews or descriptions. A prompt guides the LLM to categorize items into predefined categories. 2.2) Convert the classification results into an item-category adjacency matrix. ; 3) Initialize user embedding Item embedding Category embedding ; 4) Construct heterogeneous hypergraph networks; After obtaining the initial representations of all nodes, the representations of all heterogeneous nodes and the relationships between them are plotted using a heterogeneous hypergraph. Comprehensive representation; in the figure In the middle, heterogeneous nodes Including users ,thing ,Comment and categories Since the relationships between nodes are not limited to pairs, four types of hyperedges are set. To represent complex relationships; including: (1) Interactive hyperedge It connects users, items, and corresponding comment nodes in the interaction; (2) Observe the hyperedge It consists of an item and each comment node associated with it; (3) Preference for superedges This includes users and the comment nodes they generate; (4) Featured hyperedge It contains an item and all its associated category nodes; in, , , From the adjacency matrix and definition, Then it is given by the LLM-based classifier. Definition; Four types of hyperedges They jointly define the adjacency of nodes in the heterogeneous hypergraph; 5) Hypergraph information dissemination and aggregation; After obtaining the initial representations of all nodes, heterogeneous information is propagated in the hypergraph through three types of aggregators; then, node representations are updated through multi-level propagation; finally, user representations are generated through multi-level representation fusion. and the representation of items ; 6) Semantic alignment and model training; 6.1) After information propagation on the heterogeneous hypergraph, the information of the comment node is integrated into the user's representation. and the representation of items In this approach, a graph convolutional network is used as the graph decoder, based on the user's representation. and the representation of items Reconstructing the semantic representation of comment nodes ; 6.2) Supervise the semantic reconstruction process through a loss function to ensure cross-modal alignment; Cross-modal semantic alignment provides a supervisory signal based on collaborative information, and graph autoencoders use a loss function. Conduct training; 7) End-user-based representation and the representation of items Perform recommendation calculations and output the recommendation results.
2. The recommendation method based on semantic enhancement and heterogeneous hypergraph networks according to claim 1, characterized in that, Step 1) is as follows: 1.1) The comment text T is encoded using LLM to generate an initial semantic representation. ; 1.2) Based on the node relationship between the user, comment, and item hops, the adjacency matrix between comment nodes is calculated through relationship sampling; in, For sampling probability, An adjacency matrix representing the relationship between comments and items. An adjacency matrix representing the relationship between comments and users. It is the identity matrix; Indicates the probability of sampling Random sampling; 1.3) The Graph Attention Network (GAT) is used as the graph encoder to compress semantic information; Embedding of target comment nodes First, calculate its relationship with neighboring nodes using the attention vector. Attention coefficient Then, the compressed semantic representation is obtained by weighted summation. ; ; in, For attention vectors, Indicates a splicing operation; This is the compressed semantic representation; The neighborhood of a node The embedding representation of all comment nodes is as follows .
3. The recommendation method based on semantic enhancement and heterogeneous hypergraph networks according to claim 1, characterized in that, In step 3), the initialization is as follows: The text for each category was obtained through centralized collection of data, making This represents a set of categories, and its corresponding category embedding matrix is represented as follows: ; The category embedding matrix is obtained through collaborative filtering learning and is updated according to the user-item interaction relationship to ensure that the category features are consistent with the collaborative relationship of the recommendation space. The embedding matrices for users and items are defined as follows: and .
4. The recommendation method based on semantic enhancement and heterogeneous hypergraph networks according to claim 1, characterized in that, In step 5), after obtaining the initial representations of all nodes, heterogeneous information is propagated in the hypergraph through three types of aggregators: Depending on the type of node in the hyperedge, information propagation can be categorized into three modes: bidirectional propagation between heterogeneous nodes; unidirectional propagation between heterogeneous nodes; and bidirectional propagation between homogeneous nodes.
5. The recommendation method based on semantic enhancement and heterogeneous hypergraph networks according to claim 4, characterized in that, In step 5), heterogeneous information is propagated in the hypergraph through three types of aggregators; described as follows: (1) Bidirectional propagation aggregator between heterogeneous nodes ; (2) Unidirectional propagation aggregator between heterogeneous nodes ; (3) Bidirectional propagation aggregator between homogeneous nodes : in, The type is The node, Representation and type are The set of nodes adjacent to the target node. It is an attention vector; Represents the target node In the neighborhood of a certain type Similar nodes; express Any node in the process.
6. The recommendation method based on semantic enhancement and heterogeneous hypergraph networks according to claim 1, characterized in that, In step 6.1), semantic representation for: ; in, This represents the convolution sum.
7. The recommendation method based on semantic enhancement and heterogeneous hypergraph networks according to claim 1, characterized in that, In step 6.2), the loss function as follows: in, Used to calculate cosine similarity This indicates the selected semantic embedding subset.
8. An electronic device, characterized in that, include: One or more processors; as well as Storage device for storing one or more programs. Wherein, when the one or more programs are executed by the one or more processors, the one or more processors perform the method according to any one of claims 1 to 7.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the method described in any one of claims 1 to 7.
Citation Information
Cited By
Educational resource sequence recommendation method and device based on three-view structural distillation, equipment and storage medium
CN121834065A
Education resource sequence recommendation method and device based on three-view structure distillation, equipment and storage medium
CN121834065B