Next Article in Journal
Less Is More: Principled Diversity in Heterogeneous Anomaly Detection Ensembles
Previous Article in Journal
Non-Invasive Blood Glucose Estimation from Exhaled Breath: Patient-Level Validation of a Compact Electronic Nose Approach
Previous Article in Special Issue
MoHyNet: Enhancing Session-Based Recommendations via Hypergraph Motifs and Contrastive Learning
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Knowledge-Aware Recommendation Based on Hypergraph and Knowledge Graph

School of Information and Communication Engineering, Hainan University, Haikou 570228, China
*
Author to whom correspondence should be addressed.
AI 2026, 7(6), 215; https://doi.org/10.3390/ai7060215
Submission received: 22 April 2026 / Revised: 7 June 2026 / Accepted: 8 June 2026 / Published: 11 June 2026
(This article belongs to the Special Issue AI for Recommendation Systems and Their Applications)

Abstract

Conventional recommender systems often rely on shallow collaborative signals, which limits their performance under sparse and popularity-skewed conditions. To address this, we propose a knowledge-aware framework that combines an item hypergraph induced by user interaction histories, a top-k user similarity graph, and one-hop, relation-aware knowledge-graph aggregation. The hypergraph branch learns high-order item co-occurrence representations, which are aggregated into initial user vectors and then refined through user similarity propagation. On the item side, user-conditioned relation attention aggregates one-hop KG neighbors to produce semantic item representations. User and item representations are fused by an MLP scorer, and a lightweight popularity-aware post-scoring adjustment can optionally be applied to moderate head-item dominance. Experiments on MovieLens-1M, Last.FM and Book-Crossing show strong performance among the compared baselines in AUC, ACC, and Recall@K.

1. Introduction

Recommender systems are essential for connecting users with massive information resources. Recently, with the rapid emergence of multi-modal and cross-domain applications, capturing diverse and complex user intents has become increasingly critical. However, user–item interactions in these real-world scenarios are often highly sparse and unevenly distributed, making it exceedingly difficult for traditional collaborative filtering to accurately capture user preferences [1]. Methods like Matrix Factorization (MF) learn each interaction independently, overlooking the shared dependencies and underlying semantic structures between users and items [2]. To mitigate sparsity and cold-start issues, knowledge graphs (KGs) have been widely used to inject multi-source, rich semantic information into user and item modeling [3].
Nevertheless, many KG-enhanced methods still rely mainly on binary interactions and fail to exploit high-order collaborative structures within user groups, limiting the effectiveness of user representations [4]. Recent studies show that high-order interaction patterns encode richer signals than pairwise similarity, and ignoring them can lead to biased, suboptimal recommendations [4]. Meanwhile, although KGs provide abundant semantic relations, multihop propagation often accumulates noise and makes it difficult to differentiate relation importance, especially in long-tail scenarios [5,6].
To address these limitations, hypergraphs have been introduced to model high-order collaborative structure through group-wise co-occurrence patterns [4]. In parallel, KG-enhanced methods leverage relational semantics to enrich sparse item representations [5]. However, a unified framework that explicitly couples high-order collaborative modeling, user similarity refinement, and relation-aware KG semantics remains underexplored.
Motivated by this, we propose a knowledge-aware recommendation framework that integrates hypergraph modeling with KG semantic enhancement. We first build an item hypergraph induced by user interaction histories and apply hypergraph convolution to capture group-wise item co-occurrence patterns. We then aggregate interacted item embeddings into initial user vectors, construct a sparsified user similarity graph, and apply graph convolution to refine user representations. On the item side, we aggregate one-hop KG neighbors with a user-conditioned relation-preference mechanism to obtain semantically enhanced item representations. The main contributions are:
  • A two-stage user representation pipeline that first aggregates item-hypergraph embeddings into initial user vectors and then refines them with a top-k user similarity graph;
  • A user-conditioned one-hop KG aggregation mechanism for semantically enhanced item representations;
  • A revised experimental protocol with clearer implementation details, dataset statistics, and more cautious conclusions under the reported comparison settings.
The remainder of this paper is organized as follows: Section 2 reviews related work; Section 3 presents the proposed method; Section 4 reports the experimental settings and results; Section 5 discusses findings and limitations; and Section 6 concludes the paper.

2. Related Work

2.1. KG-Aware Recommendation

Existing knowledge-aware recommendation methods generally fall into two categories: KG-based approaches and graph-structured interaction modeling approaches.
KG-based methods inject external knowledge into recommender systems via entity–relation networks to alleviate sparsity and cold-start issues [3]. They typically propagate user preferences through network embeddings, attention, or multi-hop aggregation to enrich item representations. However, most focus on pairwise user–item relations and struggle to capture high-order interaction structures within user groups, limiting user representation expressiveness [7]. Moreover, the effectiveness of these methods often depends on neighborhood sampling strategies, where deterministic approaches based on node importance have shown promise in heterogeneous graph neural networks [8].

2.2. Hypergraph Recommendation

Graph and hypergraph-based methods model complex interaction patterns using graphs or hypergraphs. Graph convolutional methods propagate preferences over user–item bipartite graphs but are limited to pairwise relations [9]. Hypergraphs overcome this by modeling multi-user–multi-item interactions and capturing shared high-order collaborative patterns, enabling finer-grained user representations [4]. Nevertheless, most hypergraph-based models lack deep semantic modeling on the item side, making it difficult to effectively incorporate external knowledge.

2.3. User Similarity and High-Order Collaborative Modeling

Recent studies have attempted to integrate user-structure modeling with KGs to jointly leverage collaborative structures and semantic relations [10]. However, two challenges remain: (1) many models do not explicitly distinguish the effects of user structures under diverse interaction patterns, limiting preference modeling; and (2) relation weights in KG propagation are often not personalized to user characteristics, which can amplify noise and degrade recommendation quality [11]. These issues are especially critical in domains with complex user behaviors, such as insurance [12].

2.4. Personalized KG Aggregation, Popularity Bias, and Recent Extensions

Relation-aware and personalized KG aggregation methods aim to suppress irrelevant semantic paths while preserving informative user-item context. In parallel, popularity bias and long-tail recommendation studies emphasize the need to avoid over-exposing head items. Recent recommendation research has also expanded toward self-supervised representation learning, transformer-based sequential modeling, and LLM-enhanced semantic recommendation. Self-supervised hypergraph learning improves representation robustness from unlabeled interaction structure [13], while transformer-based recommenders such as SASRec [14] and BERT4Rec [15] use self-attention to capture long-range behavioral dependencies, and LLM-enhanced frameworks broaden semantic understanding and user-intent interpretation [5]. These advances highlight the importance of combining structural signals with richer semantic modeling.
Knowledge-enhanced interactive and sequential recommendation has also benefited from reinforcement-learning formulations. Shi et al. proposed a knowledge-enhanced multi-level session graph model that couples session graph reasoning with deep reinforcement learning for interactive recommendation [16]. Nie et al. developed a knowledge-enhanced causal reinforcement learning model to improve interactive recommendation by incorporating causal effects into decision making [17]. Wang et al. introduced KERL, a knowledge-guided reinforcement learning framework for sequential recommendation [18]. These studies further show that knowledge signals can guide long-horizon preference modeling, whereas our work focuses on static offline recommendation by combining item-hypergraph collaborative structure, user-similarity refinement, and one-hop KG aggregation.
To address these challenges, we propose a knowledge-aware approach that fuses hypergraph structures with KG semantics to better capture user-item interactions, high-order collaborative structure, and semantic item relations, thereby improving recommendation accuracy and robustness under sparse settings.
Compared with HMKRec [4], which mainly emphasizes motif-based multi-user representation within a knowledge-aware hypergraph framework, our method introduces a more explicit dual-user modeling pipeline: global high-order collaborative signals are captured by the item hypergraph induced by user interaction histories and then complemented by a dedicated user similarity graph for localized preference diffusion. In addition, we couple this dual-user representation with user-conditioned relation-preference attention on the KG and an optional popularity-aware post-scoring calibration that moderates head-item dominance in ranked lists.

3. Proposed Method

The proposed framework integrates item-hypergraph collaborative modeling, top-k user similarity refinement, and knowledge graph (KG) semantic enhancement. The end-to-end pipeline is as follows: (1) construct an item hypergraph induced by user interaction histories; (2) propagate item features on the hypergraph to obtain high-order item embeddings; (3) aggregate interacted item embeddings to form initial user vectors; (4) build a sparsified user similarity graph and refine user embeddings; (5) align items with KG entities and aggregate one-hop semantic neighbors with user-conditioned relation attention to obtain user-specific item representations; (6) score user-item pairs with an MLP predictor; and (7) optionally apply a lightweight popularity-aware post-scoring adjustment to the ranked list. The overall architecture of the proposed model is illustrated in Figure 1.

3.1. Item Hypergraph Construction and High-Order Collaborative Modeling

Traditional bipartite graph models (e.g., MF or GCN) [1,9] fail to capture high-order co-occurrence patterns critical for user interest modeling [4,13,19,20]. To address this, we employ a hypergraph where hyperedges connect multiple nodes to represent collective behaviors [13,19,20]. Let U and V denote the user and item sets. For each user u with the interacted item subset I u V , we define a hyperedge e u = I u .
e u = v v I u
We define an item hypergraph induced by user interaction histories as G h = ( V , E h ) , where V is the item set and each hyperedge e u in E h corresponds to the interacted item subset I u of user u . In this formulation, users act as hyperedges rather than hypergraph nodes. Let H R | V | × | E h | denote the incidence matrix of the item hypergraph, whose entries are defined in Equation (2).
H v , e u = 1 ,                         v e u 0 ,                 o t h e r w i s e
Let H denote the incidence matrix of G h , D v the item-degree matrix, and D e the hyperedge-degree matrix. Hypergraph propagation follows a node-to-hyperedge and hyperedge-to-node scheme. In Equation (3), l denotes the layer index.
X l + 1 = σ D v 1 2 H D e 1 H D v 1 2 X l W l
Equation (3) gives the l -th item-hypergraph propagation layer, where X ( l ) R | V | × d denotes the item embedding matrix at layer l , W ( l ) is the trainable weight matrix, and σ ( · ) is the activation function. After L h hypergraph layers, the initial user feature is obtained by mean pooling over interacted items: h u ( 0 ) = 1 | I u | v I u x v ( L h ) . This makes explicit that the hypergraph first learns item embeddings and user embeddings are subsequently aggregated from item histories.
In this study, the hypergraph is constructed from historical interactions and treated as a static snapshot during training. This assumption is consistent with standard offline recommendation benchmarks, where the goal is to learn stable high-order collaborative structure from a fixed interaction log before evaluation on held-out data. We acknowledge that user preferences may evolve over time, especially in movies, music, and books, and therefore discuss dynamic hypergraph extension in Section 5.

3.2. User Similarity Graph Construction and User Representation Learning

To mine the underutilized user-side structure, we construct a user similarity graph from the initial user vectors h u ( 0 ) . The pairwise similarity between users u and j is measured by cosine similarity on their pooled history embeddings.
S u i , u j = h u i h u j h u i h u j
For scalability, the similarity graph is sparsified by retaining the top- k = 50 neighbors for each user and then symmetrically normalized with A ~ = A + I . To make the layer-wise user-graph notation explicit, we denote the hidden states in this branch by H U ( l ) , with H U ( 0 ) = [ h u ( 0 ) ] for all users. Under the present single-layer implementation, Equation (5) can be interpreted as the corresponding update H U ( l + 1 ) , where W g is the graph transformation matrix.
Z u = D ~ 1 2 A ~ D ~ 1 2 H W g
In the current formulation, one graph propagation layer is used in this branch to avoid over-smoothing, so H U ( 1 ) directly yields the final user embedding z u . The similarity graph is built once from the pooled user vectors and kept fixed during training.

3.3. KG Semantic Item Representation Learning

To enrich sparse items with semantic side information, each item v is aligned to a KG entity e v and associated with a fixed-size one-hop neighbor set N ( e v ) = { ( r , e j ) } sampled from the aligned KG. The current manuscript therefore describes a one-hop relation-aware KG encoder rather than a multi-hop propagation model.
α u , r = exp z u r r R u exp z u r
Entity and relation embeddings are initialized by lightweight DistMult pretraining on the aligned KG and then fine-tuned in the recommender. For a target user u , the user-conditioned relation preference coefficient α u , r is computed by Equation (6). Because these coefficients depend on the user u , the resulting KG-enhanced item embedding is user-specific. Although Equation (7) writes the compact symbol z v (equivalently e v ), in the following text and Algorithm 1, we denote this user-conditioned semantic item representation by z u , v . In experiments, 16 neighbors are retained per item, and relation direction is not modeled by separate inverse-relation transformations in the current implementation.
Z v = e v = σ W e e v + r , e j N e v α u , r e j
This formulation fuses external knowledge structures with user-conditioned relation preferences. In Equation (7), the compact KG-enhanced item representation is written as z v = e v ; in the following text and Algorithm 1, the corresponding user-conditioned semantic representation is denoted by z u , v for downstream prediction.
Algorithm 1: Knowledge-Aware Recommendation with Item Hypergraph and KG
Input: user set U, item set V, interaction histories { I u } , aligned KG G k g
Output: recommendation function f ( u , v ) and optional reranked scores
1.Initialize trainable parameters and aligned item/entity/relation embeddings.
2.Construct the item hypergraph G h from user interaction histories { I u } .
3.Build the top-k user similarity graph from pooled initial user vectors.
4.while training do
5.   // (1) User-side representation on the item hypergraph and user graph
6.   Propagate item features on: G h to obtain high-order item embeddings.
7.   For each user u, aggregate interacted item embeddings to obtain h u ( 0 ) .
8.   Apply the user-graph update H U ( l + 1 ) to refine H U ( 0 ) and obtain the final user embedding z u .
9.   // (2) Item-side semantic representation on the knowledge graph
10.   for each candidate item v do
11.       Retrieve the aligned one-hop KG neighbor set N ( v ) of entity e v .
12.       Compute the user-conditioned relation preference coefficients α u , r  over N ( v ) .
13.       Aggregate KG neighbors to obtain the user-specific semantic item embedding z u , v .
14.       Construct the interaction feature x u , v   from   z u ,   z u , v ,  element-wise interaction terms, and | z u z u , v | .
15   end for
16.   // (3) Prediction, post-scoring adjustment, and parameter update
17.   for each training pair ( u , v ) do
18.       Compute the predicted score y ^ u , v with the MLP scorer.
19.       Optionally apply the popularity-aware post-scoring adjustment s u , v .
20.       Compute the BCE loss on sampled pairs and update parameters θ .
21.   end for
22.end while
23. return   f ( u , v ) and optional reranked scores.

3.4. Prediction Module and Popularity-Aware Re-Ranking

Given the refined user embedding z u and the user-specific KG-enhanced item embedding z u , v , we construct the interaction feature x u , v for prediction.
x u v = z u z v z u z v
Equation (8) keeps the compact core interaction form using z v . In the algorithmic description, x u , v denotes the full interaction descriptor passed to the MLP scorer; correspondingly, the user-conditioned item vector is written as z u , v , and the descriptor is described using z u , z u , v , their element-wise interaction terms, and the absolute-difference term | z u z u , v | . The final score is computed by Equation (9); the MLP uses ReLU activations and dropout, and the hidden dimensions are reported in the implementation details.
After the base relevance score is obtained, a lightweight popularity-aware post-scoring calibration can optionally be applied: s u , v = y ^ u , v λ l o g ( 1 + p o p ( v ) ) , where p o p ( v ) is the training interaction count of item v and λ is tuned on the validation protocol. In the revised manuscript, we describe this step as an optional post-processing adjustment that moderates head-item dominance rather than as the sole source of long-tail improvement.
y ^ u v = σ W 2 ϕ W 1 x u v + b 1 + b 2

3.5. Loss Function and Training Objective

Training uses the pointwise binary cross-entropy objective defined in Equation (10), where Y + and Y denote observed positive and sampled negative pairs, respectively.
L = u , v Y + log y ^ u v u , v Y log 1 y ^ u v
Negative items are sampled from the unobserved item set of the same user, and the detailed sampling ratios are reported in Section 4.1.

3.6. Evaluation Metrics

To evaluate the model’s performance, we report Accuracy (ACC) and Area Under the ROC Curve (AUC) for link prediction and Recall@K for top-K recommendation.
For link prediction, ACC measures the overall correctness of the interaction predictions:
ACC = TP + TN TP + TN + FP + FN
where TP ,   TN ,   FP , and FN denote true positives, true negatives, false positives, and false negatives, respectively. AUC evaluates the model’s discriminative ranking capability by measuring the probability that a randomly chosen positive interaction is scored higher than a negative one.
For the T o p K recommendation, R e c a l l @ K assesses the quality of the personalized ranked lists. To ensure methodological rigor, R e c a l l @ K is computed independently for each user and then macro-averaged. For an individual user u , it is formulated as:
Recall @ K u = R u K T u T u
where R u K denotes the set of top K recommended items generated for user u , and T u represents the set of ground-truth items that user u has interacted with in the test set. The final system-level metric is obtained by averaging the individual recall values across all evaluated users U test :
Recall @ K = 1 U test u U test Recall @ K u

3.7. Pseudocode

Algorithm 1 summarizes the main training and inference workflow: the model constructs the item hypergraph, propagates high-order item signals, pools interacted item embeddings into initial user representations, refines users through the top-k similarity graph, aggregates one-hop KG neighbors with user-conditioned relation attention, optimizes the binary cross-entropy objective, and outputs recommendation scores with optional popularity-aware post-scoring.

3.8. Complexity Analysis

The computational efficiency of the proposed model is analyzed using the following quantities: | U | users, | V | items, n n z ( H ) nonzero entries in the hypergraph incidence matrix, | V k g | KG entities, | E k g | KG triples, | R | relation types, K sampled KG neighbors per item, embedding dimension d , hypergraph depth L h , user-graph depth L g , and batch size B .
The main training-time costs are: item-hypergraph propagation O ( L h · n n z ( H ) · d ) ; top-k user similarity graph construction O ( | U | 2 d ) before sparsification, followed by graph propagation O ( L g · | E u | · d ) on the retained similarity edges | E u | ; one-hop KG aggregation O ( B · K · d ) for user-item pairs in a batch; and MLP scoring O ( B · d 2 ) . In the current implementation, the similarity graph is constructed once from the pooled user vectors rather than recomputed at every epoch.
The space cost is dominated by user/item embeddings O ( ( | U | + | V | ) d ) , KG entity and relation embeddings O ( ( | V k g | + | R | ) d ) , the sparse item-hypergraph incidence matrix O ( n n z ( H ) ) , the retained user-similarity edges O ( | E u | ) , and the aligned KG triples O ( | E k g | ) . This complexity analysis corresponds to the present one-hop, top-k-sparsified implementation.

4. Experiments

4.1. Datasets and Preprocessing

To evaluate the proposed model across diverse domains and sparsity levels, we utilize three public benchmark datasets consistent with [4]: MovieLens-1M, Last.FM, and Book-Crossing. Covering movies, music, and books, these datasets differ notably in structure and sparsity and are widely adopted for KG-enhanced recommendation. They are publicly accessible via their respective repositories: MovieLens-1M (https://grouplens.org/datasets/movielens/1m/ accessed on 7 June 2026), Last.FM (https://grouplens.org/datasets/hetrec-2011/ accessed on 7 June 2026), and Book-Crossing (https://www.kaggle.com/datasets/somnambwl/bookcrossing-dataset accessed on 7 June 2026). Furthermore, for the knowledge graph construction, we followed the same data preprocessing protocol as [4]. The knowledge graphs for Movielens-1M and Book-Crossing were originally established by Wang et al. [11], while the KG for Last.FM was provided by Wang et al. [21]. All three KGs are built upon the Microsoft commercial knowledge graph Satori, ensuring the reliability of the semantic triples.
To ensure experimental reproducibility, the comprehensive data preprocessing workflow strictly follows the protocol in [4], and is detailed as follows. First, for implicit feedback transformation, we converted the explicit ratings into binary implicit feedback to fit the link prediction scenario. Specifically, for MovieLens-1M, items with a rating of 4 or higher are marked as positive feedback (1), while unobserved or low-rated interactions are treated as negative [4]. Due to the extreme sparsity of Book-Crossing, and the implicit-feedback nature of Last.FM, any retained historical interaction is treated as positive feedback. Second, for data filtering, we apply the same minimum-support preprocessing used in the project experiments: 20 interactions for MovieLens-1M and Last.FM, and 3 interactions for Book-Crossing after adaptive fallback. Accordingly, the final experimental datasets contain 5148 users/2380 items/553,277 interactions for MovieLens-1M, 1265 users/606 items/41,879 interactions for Last.FM, and 8380 users/12,634 items/91,810 interactions for Book-Crossing. Finally, for entity alignment and pruning, items are mapped to their corresponding entities in the constructed KG, and only triples linked to retained items are preserved. Based on these final filtered datasets, the sparsity values are 95.48%, 94.54%, and 99.91%, respectively. To quantify long-tail characteristics, we sort items by interaction frequency and define the head as the minimum item set covering 80% of interactions; the resulting long-tail ratios are 63.36%, 49.01%, and 45.27%, respectively. In addition, the top 20% most popular items account for 61.79%, 52.58%, and 53.73% of interactions, with Gini coefficients of 0.581, 0.449, and 0.441, respectively. Detailed dataset statistics are reported in Table 1, and the item-popularity distribution is discussed later in Section 5.
After preprocessing, the train/test interaction counts are 387,228/166,049 for MovieLens-1M, 29,317/12,562 for Last.FM, and 64,640/27,170 for Book-Crossing. The average interactions per user/item are 107.47/232.47, 33.11/69.11, and 10.96/7.27, respectively. Accordingly, the statistics in Table 1 should be interpreted as post-filtering and post-alignment counts rather than raw corpus sizes.
Implementation details are summarized as follows. Unless otherwise stated, the embedding dimension is set to 128. The KG-side DistMult pretraining uses Adam with learning rate 1 × 10−3, weight decay 1 × 10−5, batch size 2048, and 5 epochs. For the main recommendation model, Adam is also adopted; in the benchmark comparison, the proposed model is trained for 30 epochs with a learning rate of 5 × 10−4, weight decay of 5 × 10−5, batch size 2048, KG neighbor size 16, and a three-hidden-layer MLP predictor scaled with the embedding dimension. The LightGCN baseline uses two propagation layers, and the HMKRec-style motif propagation uses two layers. Negative sampling uses four negatives per positive on MovieLens-1M and Last.FM, eight negatives per positive on the more sparse Book-Crossing dataset, and six negatives per positive in the repeated ablation setting; for AUC/ACC evaluation, one sampled negative is paired with each positive. Validation is used to select the ACC threshold, and Recall@K is evaluated by sampled ranking with 100 candidate items per user in the current benchmark pipeline. All experiments were implemented in Python 3.12 and PyTorch 2.5.1 on Windows 11 (Microsoft Corporation, Redmond, WA, USA); data processing and figure generation used NumPy 2.3.5, pandas 3.0.1, and Pillow 12.2.0. Computation was performed on an Intel Core i7-12800HX CPU (Intel Corporation, Santa Clara, CA, USA) and an NVIDIA GeForce RTX 4070 Laptop GPU (NVIDIA Corporation, Santa Clara, CA, USA).

4.2. Baselines and Comparison Settings

To systematically evaluate the effectiveness of the proposed recommendation method, we compare the proposed model against four baselines: LightGCN [9], ENMF [22], NeuMF [23], and HMKRec [4]. All baseline results are reproduced under the same data split and evaluation protocol rather than copied from prior literature. Among the compared methods, HMKRec is the only KG-aware baseline available in our unified implementation, while LightGCN, ENMF, and NeuMF serve as strong interaction-only references. Accordingly, the conclusions in this paper are stated as strongest among the compared baselines rather than universal state-of-the-art claims.
More specifically, for each observed user-item interaction, the positive pair is retained, and negative items are randomly sampled from the unobserved item set of the same user, excluding items already interacted with by that user and the current positive item. In the main benchmark comparison, the ratio is four negatives per positive on MovieLens-1M and Last.FM, whereas Book-Crossing uses eight negatives because of its more severe sparsity. In the repeated ablation setting, six training negatives are sampled per positive; for AUC/ACC evaluation, one negative is paired with each positive under the same rule. The same split, sampling, and Top-K protocol are applied across the compared methods to reduce evaluation bias and improve reproducibility.
As observed from the AUC and ACC results in Figure 2, the proposed method achieves the strongest overall benchmark performance among the compared baselines. These results suggest that explicitly combining item-hypergraph structure, user similarity refinement, and KG semantics can enhance both discriminative power and ranking quality under the reported evaluation protocol.
Exact benchmark values are as follows. On MovieLens-1M, the proposed method achieves AUC/ACC = 0.8737/0.7202, compared with 0.8384/0.6565 for HMKRec, 0.8085/0.6489 for LightGCN, 0.7722/0.6081 for ENMF, and 0.8650/0.7057 for NeuMF. On Last.FM, the proposed method achieves 0.8620/0.6954, compared with 0.7891/0.5917, 0.8549/0.6885, 0.7809/0.6009, and 0.8249/0.6593, respectively. On Book-Crossing, the proposed method achieves 0.7287/0.5623, compared with 0.6887/0.5360, 0.6797/0.5587, 0.5528/0.5388, and 0.6611/0.5375, respectively.
The Recall@K results in Figure 3 further corroborate the advantage of our model for broad-coverage recommendation. As K increases, the proposed method consistently outperforms the compared baselines on all three datasets. However, in the revised manuscript, we interpret Recall@K as evidence of ranking quality under the sampled candidate protocol rather than as a standalone proof of long-tail exposure improvement.
For the proposed method, Recall@10/20/50 equals 0.3584/0.5597/0.8455 on MovieLens-1M, 0.4665/0.6569/0.9233 on Last.FM, and 0.3817/0.4996/0.7541 on Book-Crossing. These exact values complement the plotted curves and make the fixed K values explicit.

4.3. Ablation Study

To verify the effectiveness of the core structural components in our proposed framework, we conduct an ablation study by comparing the full model with two degraded variants: (1) No Similarity (Hypergraph+KG), which removes the user similarity graph branch, and (2) Graph+KG (No Hypergraph), which removes the item-hypergraph branch. The present ablation therefore focuses on the two main structural modules emphasized in the current implementation.
To ensure rigorous empirical validation and to eliminate the influence of random model initialization, all variants were independently trained five times using different random seeds. The reported results in Figure 4 present the mean values along with their standard deviations. Furthermore, paired t-tests were conducted to evaluate the statistical significance of the performance differences between the full model and its variants. Unless otherwise specified, the statistical significance analysis uses paired t-tests with a significance level of alpha = 0.05, and the interpretations in this subsection are based on the repeated-run mean results rather than any single isolated run.
The repeated-seed ablation results show that the full model achieves the best AUC on all three datasets: 0.8398 on MovieLens-1M, 0.7205 on Book-Crossing, and 0.8210 on Last.FM. The No Similarity variant drops to 0.7980, 0.6893, and 0.8012, while the No Hypergraph variant yields 0.8255, 0.6896, and 0.8048, respectively. These results indicate that both structural branches contribute to ranking robustness, with the user similarity branch producing the largest AUC degradation when removed.
For ACC, the full model achieves 0.6210 on MovieLens-1M, 0.5581 on Book-Crossing, and 0.6102 on Last.FM. On MovieLens-1M, the No Hypergraph variant attains a slightly higher ACC of 0.6353, so the revised manuscript no longer claims that the full model is uniformly best on every single metric in every dataset. Instead, we interpret the ablation evidence as showing that the full model provides the strongest overall multi-metric balance, particularly for AUC and across the three datasets as a whole.
Note that Figure 2 reports the final fixed-protocol benchmark comparison, whereas Figure 4 reports repeated-seed ablation means under the dedicated ablation protocol. For this reason, the full-model values are not numerically identical across the two figures.

5. Discussion

As quantified in Section 4.1 on the final experimental datasets, MovieLens-1M, Last.FM, and Book-Crossing exhibit sparsity levels of 95.48%, 94.54%, and 99.91%, respectively. Their long-tail item ratios are 63.36%, 49.01%, and 45.27%, while the top 20% most popular items account for 61.79%, 52.58%, and 53.73% of all interactions. Together with the cumulative popularity curves in Figure 5, these results confirm that the evaluated datasets remain sparse and popularity-skewed after the exact preprocessing used by our project pipeline. Within this context, the superior performance on Book-Crossing is consistent with the role of hypergraph structure, user similarity propagation, and KG semantic enrichment in compensating for limited collaborative evidence. More specifically, the hypergraph contributes stable group-level co-occurrence signals, the user similarity graph refines user-local preference diffusion, and KG semantics compensate for sparse evidence on low-frequency items; hence, the three modules play distinct but cooperative roles.
From the perspective of previous studies, while graph-based models like LightGCN successfully simplify convolution operations, they remain constrained by standard bipartite structures and often struggle to capture complex, multi-node co-participation signals. Similarly, many KG-enhanced recommendation models suffer from noisy semantic aggregation. In the present one-hop formulation, the introduced relation-aware attention mechanism mitigates this issue by adaptively weighting neighboring semantic information and down-weighting semantically irrelevant relations.
Beyond the current recommender-system experiments, the structural ideas explored here may be investigated in other relational domains in future work. However, such cross-domain applications were not evaluated in this study, so the present discussion remains centered on the recommendation tasks actually reported in the paper.
Under the reported experimental setting, the proposed framework achieves the strongest performance among the compared baselines, but several limitations remain. First, the user similarity graph is constructed once and sparsified by a top-k rule, which may become expensive for larger user universes. Second, the current KG encoder is one-hop and depends on the quality of item-to-entity alignment. Third, the lightweight popularity-aware post-scoring calibration is formalized in the revised manuscript, but its isolated effect is not yet evaluated by a dedicated ablation. These issues define the most important directions for future work.
Within the present experiments, the static-hypergraph assumption remains appropriate because each dataset is evaluated as a fixed offline snapshot after preprocessing. This allows the model to focus on a stable collaborative structure extracted from historical interactions, while temporal preference drift is left for future dynamic extensions.

6. Conclusions

We proposed a knowledge-aware recommendation framework that combines an item hypergraph induced by user histories, a sparsified user similarity graph, and one-hop relation-aware KG semantic aggregation. The revised manuscript clarifies that the hypergraph branch first learns item embeddings, the user branch aggregates and refines user representations, and the KG branch provides user-conditioned semantic item features. Under the reported comparison protocol, the model achieves the strongest overall performance among the compared baselines, while the repeated-seed ablation study shows that both the hypergraph and user-similarity branches are important for overall ranking robustness. At the same time, the current study remains limited by one-hop KG aggregation, the scalability of the user similarity graph, and the absence of an isolated re-ranking ablation. Future work will therefore focus on more scalable user-graph construction, deeper yet stable KG reasoning, and more targeted evaluation of popularity-aware post-processing.

Author Contributions

Conceptualization, K.C. and S.N.; methodology, S.N.; software, S.N.; validation, T.S., Y.Y. and J.G.; formal analysis, S.N.; investigation, S.N.; resources, K.C.; data curation, S.N.; writing—original draft preparation, S.N.; writing—review and editing, K.C.; visualization, S.N.; supervision, K.C.; project administration, K.C.; funding acquisition, K.C. All authors have read and agreed to the published version of the manuscript.

Funding

This work was supported in part by the Hainan Provincial Natural Science Foundation under Grant 625MS053, in part by the Hainan Province Key Research and Development Program under Grant ZDYF2026GXJS021, in part by the National Natural Science Foundation of China (Ye Qisun Program) under Grant U2441228, and in part by the Hainan Province Key Research and Development Program under Grants ZDYF2023GXJS166, ZDYF2025GXJS014, and ZDYF2024GXJS313.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

The datasets analyzed in this study (MovieLens-1M, Last.FM, and Book-Crossing) are publicly available benchmark datasets.

Conflicts of Interest

The authors declare no conflicts of interest. The funders had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript; or in the decision to publish the results.

Abbreviations

The following abbreviations are used in this manuscript:
KGKnowledge Graph
MFMatrix Factorization
GCNGraph Convolutional Network
MLPMulti-Layer Perceptron
AUCArea Under the ROC Curve
ACCAccuracy
HGCNHypergraph Convolutional Network

References

  1. Ricci, F.; Rokach, L.; Shapira, B. Recommender systems: Introduction and challenges. In Recommender Systems Handbook; Ricci, F., Rokach, L., Shapira, B., Eds.; Springer: Berlin/Heidelberg, Germany, 2015; pp. 1–34. [Google Scholar]
  2. Sugahara, M.; Okamoto, K. Hierarchical matrix factorization for interpretable collaborative filtering. Pattern Recognit. Lett. 2024, 180, 99–106. [Google Scholar] [CrossRef]
  3. Wang, X.; He, X.; Cao, Y.; Liu, M.; Chua, T.S. KGAT: Knowledge graph attention network for recommendation. In Proceedings of the 25th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining, Anchorage, AK, USA, 4–8 August 2019; pp. 950–958. [Google Scholar]
  4. Wu, D.; Tang, M.; Zhang, S.; Gao, W. HMKRec: Optimize multi-user representation by hypergraph motifs for knowledge-aware recommendation. Eng. Appl. Artif. Intell. 2025, 149, 110441. [Google Scholar]
  5. Cui, Y.; Wang, K.; Yu, H.; Guo, X.; Cao, H. KLLMs4Rec: Knowledge graph-enhanced LLMs sentiment extraction for personalized recommendations. Expert Syst. Appl. 2025, 282, 127430. [Google Scholar]
  6. Tiong, A.M.H.; Li, J.; Lin, G.; Li, B.; Xiong, C.; Hoi, S.C.H. Improving tail-class representation with centroid contrastive learning. Pattern Recognit. Lett. 2023, 168, 123–130. [Google Scholar] [CrossRef]
  7. Sun, Z.; Deng, Z.H.; Nie, J.Y.; Tang, J. RotatE: Knowledge graph embedding by relational rotation in complex space. arXiv 2019, arXiv:1902.10197. [Google Scholar]
  8. Ansarizadeh, F.; Tay, D.B.; Thiruvady, D.; Tyagi, S.K.S. Deterministic sampling in heterogeneous graph neural networks. Pattern Recognit. Lett. 2023, 172, 74–81. [Google Scholar] [CrossRef]
  9. He, X.; Deng, K.; Wang, X.; Li, Y.; Zhang, Y.; Wang, M. LightGCN: Simplifying and powering graph convolution network for recommendation. In Proceedings of the 43rd International ACM SIGIR Conference on Research and Development in Information Retrieval, Virtual Event, 25–30 July 2020; pp. 639–648. [Google Scholar]
  10. Xu, M.; Wei, W.; Yang, P.; Wu, H. Semantic enhanced heterogeneous hypergraph network for collaborative filtering. In Proceedings of the AAAI Conference on Artificial Intelligence, Philadelphia, PA, USA, 25 February–4 March 2025; pp. 12936–12944. [Google Scholar]
  11. Wang, H.; Zhang, F.; Wang, J.; Zhao, M.; Li, W.; Xie, X.; Guo, M. RippleNet: Propagating user preferences on the knowledge graph for recommender systems. In Proceedings of the 27th ACM International Conference on Information and Knowledge Management, Torino, Italy, 22–26 October 2018; pp. 417–426. [Google Scholar]
  12. Kong, H.; Yun, W.; Joo, W.; Kim, J.H.; Kim, K.K.; Moon, I.C.; Kim, W.C. Constructing a personalized recommender system for life insurance products with machine-learning techniques. Pattern Recognit. Lett. 2025, 196, 148–155. [Google Scholar]
  13. Xia, X.; Yin, H.; Yu, J.; Wang, Q.; Cui, L.; Hung, N.Q.V. Self-supervised hypergraph convolutional networks for session-based recommendation. In Proceedings of the AAAI Conference on Artificial Intelligence, Virtual Event, 2–9 February 2021; pp. 4503–4511. [Google Scholar]
  14. Kang, W.-C.; McAuley, J. Self-Attentive Sequential Recommendation. In Proceedings of the 2018 IEEE International Conference on Data Mining, Singapore, 17–20 November 2018; pp. 197–206. [Google Scholar]
  15. Sun, F.; Liu, J.; Wu, J.; Pei, C.; Lin, X.; Ou, W.; Jiang, P.S. BERT4Rec: Sequential Recommendation with Bidirectional Encoder Representations from Transformer. In Proceedings of the 28th ACM International Conference on Information and Knowledge Management, Beijing, China, 3–7 November 2019; pp. 1441–1450. [Google Scholar]
  16. Shi, L.; Hu, R.; Zhang, Z.; Wang, S.; Li, S. Knowledge-Enhanced Multi-Level Session Graph Model for Interactive Recommendation through Deep Reinforcement Learning. ACM Trans. Knowl. Discov. Data 2026, 20, 84. [Google Scholar] [CrossRef]
  17. Nie, W.; Wen, X.; Liu, J.; Chen, J.; Wu, J.; Jin, G.; Lu, J.; Liu, A.-A. Knowledge-Enhanced Causal Reinforcement Learning Model for Interactive Recommendation. IEEE Trans. Multimed. 2024, 26, 1129–1142. [Google Scholar] [CrossRef]
  18. Wang, P.; Fan, Y.; Xia, L.; Zhao, W.X.; Niu, S.; Huang, J. KERL: A Knowledge-Guided Reinforcement Learning Model for Sequential Recommendation. In Proceedings of the 43rd International ACM SIGIR Conference on Research and Development in Information Retrieval, Virtual Event, 25–30 July 2020; pp. 209–218. [Google Scholar] [CrossRef]
  19. Feng, Y.; You, H.; Zhang, Z.; Ji, R.; Gao, Y. Hypergraph neural networks. In Proceedings of the AAAI Conference on Artificial Intelligence, Honolulu, HI, USA, 27 January–1 February 2019; pp. 3558–3565. [Google Scholar]
  20. Ji, S.; Feng, Y.; Ji, R.; You, H.; Pan, J.; Chen, T.; Gao, Y. Dual channel hypergraph collaborative filtering. In Proceedings of the 26th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining, Virtual Event, 23–27 August 2020; pp. 2020–2029. [Google Scholar]
  21. Wang, H.; Zhao, M.; Xie, X.; Li, W.; Guo, M. Knowledge graph convolutional networks for recommender systems. In Proceedings of the World Wide Web Conference, San Francisco, CA, USA, 13–17 May 2019; pp. 3307–3313. [Google Scholar]
  22. Chen, C.; Zhang, M.; Zhang, Y.; Liu, Y.; Ma, S. Efficient neural matrix factorization without sampling for recommendation. ACM Trans. Inf. Syst. 2020, 38, 14. [Google Scholar] [CrossRef]
  23. He, X.; Liao, L.; Zhang, H.; Nie, L.; Hu, X.; Chua, T.S. Neural collaborative filtering. In Proceedings of the 26th International Conference on World Wide Web, Perth, Australia, 3–7 April 2017; pp. 173–182. [Google Scholar]
Figure 1. End-to-end pipeline of the proposed framework. User interaction histories induce an item hypergraph; hypergraph item embeddings are aggregated into initial user vectors; a top-k user similarity graph refines user embeddings; one-hop KG neighbors provide user-conditioned semantic item representations; and an optional popularity-aware post-scoring adjustment can be applied to the final ranked list. Directed arrows denote the information flow among modules, and the color grouping distinguishes collaborative hypergraph/user-similarity processing, KG semantic aggregation, and final prediction/post-scoring components.
Figure 1. End-to-end pipeline of the proposed framework. User interaction histories induce an item hypergraph; hypergraph item embeddings are aggregated into initial user vectors; a top-k user similarity graph refines user embeddings; one-hop KG neighbors provide user-conditioned semantic item representations; and an optional popularity-aware post-scoring adjustment can be applied to the final ranked list. Directed arrows denote the information flow among modules, and the color grouping distinguishes collaborative hypergraph/user-similarity processing, KG semantic aggregation, and final prediction/post-scoring components.
Ai 07 00215 g001
Figure 2. Benchmark comparison of the proposed method and four baselines on MovieLens-1M, Last.FM, and Book-Crossing. Bars report AUC and ACC under the fixed comparison protocol; higher values indicate better performance.
Figure 2. Benchmark comparison of the proposed method and four baselines on MovieLens-1M, Last.FM, and Book-Crossing. Bars report AUC and ACC under the fixed comparison protocol; higher values indicate better performance.
Ai 07 00215 g002
Figure 3. Recall@K curves of the proposed method and four baselines on MovieLens-1M, Last.FM, and Book-Crossing under the fixed comparison protocol; higher values indicate better ranking performance.
Figure 3. Recall@K curves of the proposed method and four baselines on MovieLens-1M, Last.FM, and Book-Crossing under the fixed comparison protocol; higher values indicate better ranking performance.
Ai 07 00215 g003
Figure 4. Repeated-seed ablation results for the full model, No Similarity, and No Hypergraph variants on MovieLens-1M, Last.FM, and Book-Crossing. Bars correspond to mean AUC and ACC over five runs; error bars denote standard deviations.
Figure 4. Repeated-seed ablation results for the full model, No Similarity, and No Hypergraph variants on MovieLens-1M, Last.FM, and Book-Crossing. Bars correspond to mean AUC and ACC over five runs; error bars denote standard deviations.
Ai 07 00215 g004
Figure 5. Cumulative item-popularity distribution of the final experimental datasets.
Figure 5. Cumulative item-popularity distribution of the final experimental datasets.
Ai 07 00215 g005
Table 1. Core dataset statistics after preprocessing and KG alignment.
Table 1. Core dataset statistics after preprocessing and KG alignment.
DatasetUsersItemsInteractionsRelationsEntitiesKG Triples
MovieLens-1M51482380553,2772966706
Last.FM126560641,8791974928,383
Book-Crossing838012,63491,8103521336,375
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Niu, S.; Chi, K.; Su, T.; Yang, Y.; Gao, J. Knowledge-Aware Recommendation Based on Hypergraph and Knowledge Graph. AI 2026, 7, 215. https://doi.org/10.3390/ai7060215

AMA Style

Niu S, Chi K, Su T, Yang Y, Gao J. Knowledge-Aware Recommendation Based on Hypergraph and Knowledge Graph. AI. 2026; 7(6):215. https://doi.org/10.3390/ai7060215

Chicago/Turabian Style

Niu, Shunping, Kuo Chi, Ting Su, Yongqin Yang, and Jiabao Gao. 2026. "Knowledge-Aware Recommendation Based on Hypergraph and Knowledge Graph" AI 7, no. 6: 215. https://doi.org/10.3390/ai7060215

APA Style

Niu, S., Chi, K., Su, T., Yang, Y., & Gao, J. (2026). Knowledge-Aware Recommendation Based on Hypergraph and Knowledge Graph. AI, 7(6), 215. https://doi.org/10.3390/ai7060215

Article Metrics

Back to TopTop