Sparse social internet of things interest recommendation method based on graph convolutional network
By using the MARGCN model for feature fusion and adaptive information fusion, the problem of modeling the discriminative relationships of multi-source information in the intelligent Internet of Things is solved, enabling efficient personalized recommendations in sparse social interaction environments and improving the accuracy and flexibility of the recommendation system.
Patent Information
- Application Number
- CN202510973200.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-15
- Publication Date
- 2025-10-31
AI Technical Summary
In the context of the Internet of Things (IoT), existing recommendation systems fail to effectively model the discriminative relationships of multi-source information, resulting in insufficient recommendation accuracy and personalization capabilities in sparse and heterogeneous interaction scenarios. In particular, they lack consideration for differentiated information content in sparse information, especially for new users with sparse user interactions and limited information.
We adopt a sparse social IoT interest recommendation method based on graph convolutional networks. We use the MARGCN model for feature fusion, multi-source relationship perception and adaptive information fusion. We use multi-layer GCN and attention mechanism to dynamically adjust information weights and generate embedded representations of users and items to achieve personalized recommendations.
It improves the accuracy and personalization capabilities of the recommendation system in sparse social interaction environments, enhances the flexibility and robustness of the model in capturing complex relationships and interest diffusion processes, and improves the diversity and accuracy of recommendations.
Smart Images

Figure CN120873284A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of IoT interest recommendation, specifically relating to a sparse social IoT interest recommendation method based on graph convolutional networks. Background Technology
[0002] The Internet of Things (IoT) refers to the interconnection of physical objects with networks through information sensors, enabling intelligent functions such as identification, tracking, and location. A significant advancement in this field is the emergence of the Social Internet of Things (SIoT), which integrates the principles of social networks into the IoT framework. Unlike traditional IoT systems that primarily focus on machine-to-machine (M2M) communication, the Social IoT emphasizes the social relationships between users and objects, thereby promoting more dynamic and personalized interactions.
[0003] The rise of the Social Internet of Things (SIoT) has led to a significant increase in the number and variety of interconnected objects participating in social interactions. Consequently, the vast network of social interaction objects creates an environment of information overload, making it difficult for users to discover products relevant to their specific interests and needs. There is an urgent need to provide social recommendations to help social users choose suitable products. Traditional recommendation systems typically rely on single factors, such as user ratings or behavior. However, these systems often suffer from data sparsity, leading to reduced accuracy in recommendation results. In recent years, recommendation systems incorporating social relationships have received widespread attention and become an important research direction in the field of recommendation systems. This is because social relationships can not only alleviate the data sparsity problem caused by limited user interactions and sparse rating matrices, but also significantly improve recommendation quality by introducing social relationships as an important factor influencing user behavior into the system.
[0004] Traditional recommender systems can be broadly categorized into content-based recommendation methods, collaborative filtering-based recommendation methods, and hybrid recommendation methods. To more effectively model social relationships and address the problem of data sparsity, Graph Neural Networks (GNNs) leverage their superior graph-structured data representation capabilities to provide robust support for multi-relationship modeling and high-order information fusion in social recommender systems. GNNs operate through an iterative process, aggregating feature information from graph topology and local neighborhoods into the model.
[0005] In the context of the Internet of Things (IoT), existing research on recommender systems largely focuses on modeling complex social relationships and integrating heterogeneous information sources. However, research on recommender systems in sparse social interaction scenarios with differentiated relationships among multiple information sources has received little attention in the context of the IoT. In the IoT environment, users typically exhibit low interaction frequency and sparse behavioral data, especially new users with limited information. Furthermore, interactions between users and items are also relatively sparse. For example, despite a large selection of movies, users usually only interact with a small portion of them. Therefore, the lack of consideration for differentiated information content within sparse information becomes a key factor limiting the accuracy of recommendation services. Moreover, current recommender systems typically process all collected multi-source interaction data uniformly, failing to distinguish their inherent heterogeneity. Assuming all types of interaction data have the same information weight can lead to problems. When popular services or products exist on the platform, almost all users are likely to interact with them, generating high-frequency but low-discrimination signals. If these interactions are aggregated into the recommendation model without considering their relative information content, the system may produce homogeneous recommendations. This problem is particularly acute in environments with sparse user interactions, as indiscriminate aggregation methods weaken the system's ability to identify potential user preferences, thereby reducing the overall effectiveness and personalization capabilities of the recommendation system. Therefore, there is an urgent need to introduce an information discrimination evaluation mechanism, which is crucial for improving the diversity and accuracy of personalized recommendations in sparse, heterogeneous interactive data environments. In the Smart Internet of Things (SIoT) scenario, effectively modeling the discriminative relationships of multi-source information and perceiving the different importance of information under sparse social interactions remains a key challenge that urgently needs to be addressed. Summary of the Invention
[0006] In view of this, the purpose of this invention is to provide a sparse social IoT interest recommendation method based on graph convolutional networks.
[0007] The objective of this invention is achieved through the following technical solution:
[0008] A sparse social IoT interest recommendation method based on graph convolutional networks includes:
[0009] Step 1: Obtain the user set U, item set V, and rating matrix R. There may or may not be a social relationship between two users in the user set. The rating matrix R = {r ai} M×N r ai Let M represent the interest rating of user a in user set for item i in item set; M represents the total number of users in user set; and N represents the total number of items in item set.
[0010] Step 2: Determine the user - the user's social graph G s User-item interest graph Gc Among them, social graph G s The nodes in the social graph G represent users who are concentrated in a single user group. s The edges in the graph represent whether social relationships exist between users; interest graph G c The nodes in the interest graph G include all users in the user set and all items in the item set. c The edges in the matrix are elements of the rating matrix R;
[0011] Step 3: Determine the free embedding matrix of users based on user set U and item set V. and the project's free embedding matrix Where D represents the embedding dimension, each row of the user's free embedding matrix represents a user's free embedding vector, and each row of the item's free embedding matrix represents an item's free embedding vector.
[0012] Step 4: Obtain the feature vector for each user and the feature vector for each project;
[0013] Step 5: Use the MARGCN model to generate predicted ratings for each user's preferences for each item;
[0014] Step 6: Train the MARGCN model by minimizing the regression loss function, and then use the trained MARGCN model to recommend items to users; among which,
[0015] The MARGCN model includes a feature fusion module, a multi-source relationship perception module, an adaptive information fusion module, and a preference prediction module.
[0016] The feature fusion module combines the user's free embedding vector and the user's feature vector to generate an initial user representation; and combines the item's free embedding vector and the item's feature vector to generate an initial item representation.
[0017] The multi-source relationship perception module utilizes an attention mechanism in the user-user social graph G. s User-Project Interest Graph G c Extract relation weights from the top;
[0018] The adaptive information fusion module is based on a multi-layer GCN and generates the embedded representation of the user and the embedded representation of the item at each propagation layer through a gating mechanism.
[0019] The preference prediction module generates the final embedding representations of users and items by concatenating the embedding representations of users and items across all propagation layers, respectively. Then, it uses a dot product operation to calculate the predicted preference score between users and items.
[0020] Furthermore, for user a and project i, the multi-source relationship awareness module performs the following operations:
[0021] In the h-th attention head of the l-th propagation layer, the attention weights of user a for social neighbor b and interactive item i are determined and denoted as follows: and
[0022] In the h-th attention head of the l-th propagation layer, the attention weights of item i to its interacting user a and the self-loop of item i are determined and denoted as follows: and
[0023] At each propagation layer, for all attention heads and The attention weights are obtained by averaging the values of each value separately. and
[0024] Furthermore, attention weights and They are respectively:
[0025]
[0026] in, Let W represent the embeddings of user a, user a's neighbor b, and item i at the l-th propagation layer, respectively; [·||·] denotes vector concatenation operation; h It is the feature mapping matrix of the h-th attention head, used to map the concatenated vectors to the new feature space; a h b h c h and d h It is the attention vector of the h-th attention head corresponding to each attention weight; σ is the non-linear activation function; c s and c i These are the bias terms for social graphs and interest graphs, respectively, d i and d s These are the interaction bias terms of item i with neighboring users and its own bias terms in the interest graph.
[0027] Furthermore, the adaptive information fusion module specifically performs the following operations:
[0028] A dynamic gating mechanism is used to generate gating values at each propagation layer. and
[0029] Utilizing the gating value of each propagation layer and and the corresponding aggregated attention weights and Generate gated attention weights respectively. and
[0030] The attention weights after gating are normalized to obtain the final attention weights for each propagation layer. and
[0031] Utilizing the final attention weights of the l-th propagation layer and Embedded representation of the user in the l-th propagation layer and the embedded representation of the item in the l-th propagation layer Update the user embedding representations of user a and item i at the (l+1)th propagation layer. and project embedding representation
[0032] Furthermore, gating value and They are respectively:
[0033]
[0034] in, and σ represents the weight matrix of the l-th gated layer. g It is a non-linear activation function in the gating mechanism. and It is the average of all user-to-user attention weights, the average of all user-to-item attention weights, the average of all item-to-user attention weights, and the average of all item-to-self-loop attention weights corresponding to the l-th propagation layer.
[0035] Furthermore, the final attention weights for each propagation layer and They are respectively:
[0036]
[0037] in, This represents the set of all users who have a social dependency on user a. This represents the set of all items from which user a has engaged in interactive behavior. This represents the set of all users who have engaged in interactive behavior with item i.
[0038] Furthermore, user-embedded representation and project embedding representation They are respectively:
[0039]
[0040] Where l∈{0,1,2,...,L-1}, and L represents the total number of layers in the multi-layer graph convolutional network. It is an adaptive fusion parameter of the user's own representation in the l-th propagation layer, which controls the fusion ratio of the user's own information and the neighbor's information; It is an adaptive fusion parameter representing the l-th propagation layer project itself, which controls the fusion ratio of the project's own information and the interactive user information.
[0041] Furthermore, the regression loss function is a mean squared error loss function with an L2 regularization term, wherein the regularization term constrains the initial user embedding matrix, the initial item embedding matrix, and all learnable parameters in the model other than the initial embeddings.
[0042] The present invention also provides a sparse social IoT interest recommendation system based on graph convolutional networks, characterized in that it includes: an access layer, a data interaction layer, a MARGCN recommendation layer, and an application layer;
[0043] The access layer is used to acquire user behavior data and user interaction data;
[0044] The data interaction layer is used to receive user behavior data and user interaction data, generate structured data input to the MARGCN recommendation layer, receive recommendation results generated by the MARGCN recommendation layer, and feed the recommendation results back to the application layer;
[0045] The MARGCN recommendation layer performs the sparse social IoT interest recommendation method based on graph convolutional networks as described above.
[0046] The application layer receives recommendation results through the data interaction layer and feeds them back to the terminal device, thereby pushing them to the user.
[0047] The present invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the sparse social IoT interest recommendation method based on graph convolutional networks as described above.
[0048] The beneficial effects of this invention are:
[0049] The model in this invention includes a multi-source relationship-aware module, which learns information from different representation subspaces, thereby enhancing the model's ability to capture complex relationships and improving the accuracy of recommendations;
[0050] The model of this invention also includes an adaptive information fusion module, which can dynamically adjust the weights of different types of information according to the needs of information dissemination, thereby enhancing the model's flexibility and robustness in capturing social interaction and interest diffusion processes.
[0051] Moreover, this invention constructs a graph diffusion model based on GCN to realize multi-level information propagation in sparse interactive social networks in SIoT.
[0052] Other advantages, objectives, and features of the invention will be set forth in part in the description which follows, and in part will be apparent to those skilled in the art from the following examination, or may be learned from practice of the invention. The objectives and other advantages of the invention can be realized and obtained through the following description. Attached Figure Description
[0053] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will now be described in further detail with reference to the accompanying drawings, wherein:
[0054] Figure 1 It is a recommendation system framework for sparse social interaction SIOT environments;
[0055] Figure 2 This is a block diagram of the MARGCN model;
[0056] Figure 3 These are simulation results showing the relationship between hit rate and propagation layer number for different recommendation list lengths;
[0057] Figure 4 These are simulation results showing the relationship between the normalized discount cumulative gain and the number of propagation layers for different recommendation list lengths.
[0058] Figure 5 This is a simulation comparison of the hit rate of the method of this invention with other models;
[0059] Figure 6 This is a simulation comparison of the normalized discount cumulative gain of the method of this invention with other models;
[0060] Figure 7 These are simulation results of the hit rate under different recommendation list lengths with different numbers of attention heads when using the method of the present invention;
[0061] Figure 8 These are simulation results of the normalized discount cumulative gain under different recommendation list lengths with different numbers of attention heads when using the method of this invention. Detailed Implementation
[0062] The preferred embodiments of the present invention will now be described in detail with reference to the accompanying drawings. It should be understood that the preferred embodiments are for illustrative purposes only and are not intended to limit the scope of protection of the present invention.
[0063] With the emergence of information overload in the Social Internet of Things (SIoT), personalized recommendation systems have become a key component for users to locate the items they need. However, how to effectively model the differentiated relationships of multi-source information and perceive the importance of multi-source information in the sparse social interaction of SIoT is a critical problem that urgently needs to be solved. In view of the above considerations, this invention proposes a multi-source adaptive relational graph convolutional network framework (i.e., the MARGCN model) for recommendation systems. The feature spaces of user-user and user-item are abstracted into two graph networks, and the embedded features are aggregated based on the GCN method. First, multi-source relation perception enables dynamic perception and measurement of the importance of various relationships in the graph structure, enhancing the model's ability to identify heterogeneous information. Second, this invention uses adaptive information fusion, employing a learnable fusion strategy to dynamically integrate representations from different sources, avoiding information loss or redundancy caused by simple weighting, and uses GCN to aggregate and update embeddings to represent users and items.
[0064] like Figure 1 As shown, the recommendation system framework in a sparse social interaction SIoT environment comprises four layers: the access layer, the data interaction layer, the MARGCN recommendation layer, and the application layer. The access layer represents the interaction scenario between users and the physical world within the SIoT network. Users communicate with various interconnected devices in the city through smart terminals such as smartphones. In daily activities, users access various items (also known as "goods" or "items") through mobile applications or web browsers, generating behavioral data such as purchasing, browsing, liking, commenting, and saving. However, due to the diversity of user interests, explicit interactions between users and goods, as well as between users themselves, are often sparse. Although social connections can be established based on interest similarity, the frequency of interactions is often uneven, resulting in equally sparse social relationships and increasing modeling complexity. All user behavior and social interaction data are collected in real-time by local devices and transmitted to the network base station via wireless communication links, ultimately entering the data interaction layer. The data interaction layer processes the sparse multi-source data (i.e., user behavior data and user interaction data) from the access layer, generating structured data and forwarding it to the MARGCN recommendation layer. The MARGCN recommendation layer, as the core of the system, combines multi-source relationship awareness and adaptive fusion mechanisms with personalized recommendation algorithms. It simulates user interests and preferences to implement personalized recommendation strategies and generates Top-k recommendation results, which are then fed back to the data interaction center. Subsequently, the data interaction center sends the feedback results to the application layer's terminal devices and pushes them to the user. Finally, user feedback on recommended entities triggers MARGCN to perform a new round of training on the recommendation module.
[0065] A typical social recommendation framework models two sets of entities: a user set U and an item set V, where |U| = M and |V| = N, meaning there are a total of M users and N items.
[0066] A sparse social IoT interest recommendation method based on graph convolutional networks includes the following steps:
[0067] Step 1: Obtain the user set U, item set V, and rating matrix R. There may or may not be a social relationship between two users in the user set. The rating matrix R = {r ai} M×N r ai Let M represent the interest rating of the a-th user in the user set (also called user a) for the i-th item in the item set; M represents the total number of users in the user set; and N represents the total number of items in the item set.
[0068] Step 2: Determine the user - the user's social graph G s User-item interest graph G c Among them, social graph G s The nodes in the social graph G represent users who are concentrated in a single user group. s The edges in the graph represent whether social relationships exist between users; interest graph G c The nodes in the interest graph G include all users in the user set and all items in the item set. c The edges in the matrix are elements of the rating matrix R;
[0069] Step 3: Determine the free embedding matrix of users based on user set U and item set V. and the project's free embedding matrix Where D represents the embedding dimension, each row of the user's free embedding matrix represents a user's free embedding vector, and each row of the item's free embedding matrix represents an item's free embedding vector; for example, for user a and item i, the free embedding vector p of user a is obtained by searching in the user embedding matrix and item matrix respectively. a And the free embedding of project i into project q i .
[0070] Step 4: Obtain the feature vector for each user and the feature vector for each project;
[0071] Step 5: Use the MARGCN model to generate predicted ratings for each user's preferences for each item;
[0072] Step 6: Train the MARGCN model by minimizing the regression loss function, and use the trained MARGCN model to recommend items to users.
[0073] The MARGCN model includes a feature fusion module, a multi-source relationship perception module, an adaptive information fusion module, and a preference prediction module.
[0074] The feature fusion module combines the user's free embedding vector and the user's feature vector to generate an initial user representation; and combines the item's free embedding item and the item's feature vector to generate an initial item representation.
[0075] For example, such as Figure 2 As shown, for user a and item i, the feature vector x of user a is obtained. a and the feature vector y of project i i Then, by using the free embedding vector p of user a a and eigenvector x a The components are combined to generate the initial user representation (i.e., the initial user embedding representation). And freely embed project i into project q i and eigenvector y i The items are then combined to generate an initial item representation (i.e., an initial item embedding representation). By combining the user's or item's free embedding vector and feature vector, it is possible to capture the user's initial preferences and the semantic features of the item (i.e., the item).
[0076] To address the challenges of multi-source information fusion, limited high-order relation representations, and social sparsity, this invention proposes a heterogeneous representation learning method based on attention and gating fusion mechanisms. This method can accurately model user interest diffusion paths and the impact of multi-dimensional relationships on user preferences. Specifically, the multi-source relation perception module utilizes attention mechanisms in the user-user social graph G. s User-Project Interest Graph G c The module extracts relation weights; the adaptive information fusion module is based on multi-layer GCN and generates the embedded representation of users and the embedded representation of items on each propagation layer (also known as the "diffusion layer") through a gating mechanism.
[0077] The preference prediction module (also known as the "preference prediction and optimization module") generates final user and item embeddings by concatenating the user embeddings across all propagation layers and the item embeddings across all propagation layers, respectively. It then uses a dot product operation to calculate the predicted preference score between the user and the item. The model is trained by minimizing the loss between the predicted score and the actual interaction. Finally, the optimized user and item representations are passed to the recommendation service system to generate personalized item recommendations for the end user.
[0078] The following is a detailed description of the multi-source relationship perception module. For example... Figure 2As shown, in order to characterize user preference patterns in a multi-source graph structure, this invention is based on a social graph G. s and interest graph G c A dual-channel attention mechanism was constructed. The social graph contains trust relationships and information dissemination potential, while the interest graph reflects individual user preferences and content orientation. Simultaneously, the semantic expression of a project node is jointly shaped by its interacting user group, demonstrating potential semantic aggregation characteristics. This invention introduces a multi-head attention mechanism for the two paths, adaptively allocating importance weights to adjacent entities.
[0079] In the h-th attention head of the l-th propagation layer, the attention weights of user a for social neighbor b (i.e., user a's social neighbors) and interaction item i (i.e., user a's interaction item) are denoted as follows: and
[0080]
[0081] in, It is the weight of user a's h-th attention head on its neighbor b in the l-th layer (i.e., the l-th propagation layer); It is the weight of user a's h-th attention head on item i that is of interest in the l-th layer; Let [·||·] represent the embeddings of user a, neighbor b, and item i at layer l, respectively; [·||·] represents the vector concatenation operation; W h It is the feature mapping matrix of the h-th attention head, used to map the concatenated vectors to the new feature space; a h and b h Is with and The attention vectors corresponding to the h-th attention head are used to calculate the attention score, i.e., the learnable parameters for calculating the attention weights; σ is a non-linear activation function, typically LeakyReLU; furthermore, c s and c i These are the bias terms for the social graph and interest graph, respectively, used to control the minimum response of basic attention and enhance the model's robustness to weak ties or weak preference information.
[0082] The importance of neighboring nodes is modeled from multiple perspectives using multiple independent attention heads. However, to obtain a final consistent attention representation, the outputs of these attention heads need to be aggregated. This invention employs an aggregation method that averages the outputs of all attention heads, and the aggregated attention weights are defined as follows:
[0083]
[0084] Where H represents the total number of long positions in the long-term attention.
[0085] From the perspective of product i, the interaction between user a and product i not only reflects the user's preferences but also reveals the content characteristics and popularity of product i itself. Product node i forms its propagation path in the interest space through connections with neighboring user nodes a. In particular, this invention sets an independent self-loop weight for product i to control the contribution of product information itself to the aggregation of neighbor information.
[0086] In the h-th attention head of the l-th propagation layer, the attention weights of item i to its interacting user a and the self-loop of item i are denoted as follows: and
[0087]
[0088] Among them, c h and d h Is with and The attention vectors corresponding to the h-th attention head are used to calculate the attention score, i.e., to calculate the learnable parameters of the attention weights; d i and d s These are the interaction bias terms of item i with neighboring users and its own bias terms in the interest graph.
[0089] Then, by averaging all the attention heads, the aggregated attention weights are obtained as follows:
[0090]
[0091] Targeting information perception sources and social graph G s and interest map G c In order to achieve social graph G s and interest map G c To achieve adaptive control and fusion of information, this invention designs a dynamic gating mechanism. During each layer of information propagation, the contribution ratio of the two graph structures can be dynamically allocated based on the relative strength of social attention and interest attention. Each propagation layer corresponds to an independent gating layer. Information propagates layer by layer through the social and interest graphs. After each layer of propagation, the model needs to decide how to fuse information from both social and interest aspects to prepare for the next layer of propagation. Therefore, each layer has its own set of gating layers, which are independently learnable weights. Specifically, the adaptive information fusion module performs the following operations:
[0092] First, a dynamic gating mechanism is used to generate gating values at each propagation layer. and
[0093]
[0094] in, and σ represents the weight matrix of the l-th gated layer. g It is a non-linear activation function in the gating mechanism, used to restrict the gate value to the range (0,1). [·,·] represents the vector concatenation operation, and the result of the vector concatenation is used as the input of the gating unit. and It corresponds to the attention weights of all users in the l-th propagation layer (i.e., all...). The average of all user-item attention weights (i.e., all...) The average of all items - user attention weights (i.e., all...) The average of ) and the final self-loop attention weights of all items (i.e., all The average value of ). Through formula (7), the model calculates a gating value for the user's social information and interest information respectively, which is used to dynamically adjust the weight of the two parts of information when they are aggregated; through formula (8), the model calculates a gating value for the interaction information between the project and its neighboring users and the project's own attributes respectively, which is used to balance the influence of the project's own attributes and user interaction information.
[0095] Then, using the gating value of each propagation layer and and the corresponding aggregated attention weights and Generate gated attention weights respectively. and
[0096]
[0097] Next, the attention weights after gating are normalized to obtain the final attention weights for each propagation layer. and
[0098]
[0099]
[0100] in, This represents the set of all users who have a social dependency on user a. This represents the set of all items from which user a has engaged in interactive behavior. This represents the set of all users who have engaged in interactive behavior with item i.
[0101] Then, for each user a and item i, the final attention weights of the l-th propagation layer are utilized. and Embedded representation of the user in the l-th propagation layer and the embedded representation of the item in the l-th propagation layer Use multi-layer graph convolution with diffusion to update the user embedding representations of user a and item i in the (l+1)th propagation layer. and project embedding representation Expressed as a formula:
[0102]
[0103] Where l∈{0,1,2,...,L-1}, and L represents the total number of layers in the multi-layer graph convolutional network. It is an adaptive fusion parameter of the user's own representation in the l-th propagation layer, which controls the fusion ratio of the user's own information and the neighbor's information; It is an adaptive fusion parameter representing the l-th propagation layer project itself, which controls the fusion ratio of the project's own information and the interactive user information.
[0104] In the prediction phase of the model, for any user a and item i, after propagation through an L-layer graph neural network, the final embedding vector is obtained. User's predicted rating for this product It is calculated from the inner product of these two embedding vectors, that is:
[0105]
[0106] This inner product operation essentially reflects the similarity between the user preference vector and the item representation vector in the latent semantic space. To accommodate specific numerical range requirements in certain application scenarios (such as click-through rate prediction or rating normalization), the predicted rating can also be mapped using an activation function (e.g., the Sigmoid function), thereby compressing the predicted value into the interval [0,1].
[0107] During model training, mean squared error (MSE) serves as the primary regression loss function. This loss function measures the error between the model's predicted score and the actual score, and is calculated as the average of the squared differences between the predicted and actual values across all training samples. Let the training dataset be... The loss function is then expressed as:
[0108]
[0109] Where D0 represents the amount of data in the training dataset, r a,i It is user A's actual rating of product i. It is the model's predicted score.
[0110] To prevent overfitting during model training, especially when the embedding parameters are highly dimensional or the training data is sparse, this invention introduces an L2 regularization term into the loss function. This regularization term primarily constrains the initial user embedding matrix U. (0) Initial product embedding matrix V (0) , as well as the other learnable parameters in the model.
[0111]
[0112] Among them, ||·|| F Let θ represent the Frobenius norm, Θ represent all learnable parameters of the model other than the embeddings, and λ1, λ2, and λ3 are the corresponding regularization coefficients. Therefore, the final loss function of the model is the sum of the basic loss term and the regularization term, specifically in the form:
[0113]
[0114] Where λ represents the weight coefficient of the regularization term.
[0115] The present invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the sparse social IoT interest recommendation method based on graph convolutional networks as described above.
[0116] The model's structural design requires embedding user nodes and product nodes, while maintaining the edge structure in the social graph and interaction graph. Therefore, its overall space complexity can be expressed as:
[0117] O(M×d+N×d+|E s |+|E r |) (21)
[0118] Where M represents the number of users, N represents the number of products, d represents the dimension of node embedding, and |E s | represents the number of edges in the social network, |E r | represents the number of interactions between a user and a product. The first two terms, M×d and N×d, correspond to the low-dimensional representation vector storage space allocated for each user and each product, which is one of the most basic overheads in a neural recommendation system; while |E s |and|E r | Closely related to the sparsity of graph structures, it represents the adjacency information that the model needs to maintain.
[0119] In each diffusion layer, the model needs to perform message passing and embedding update operations on all edges in the social graph and interaction graph. Therefore, the overall time complexity can be formalized as:
[0120] O(L×(|E s|+|E r |)×d) (22)
[0121] This complexity indicates that the computational amount has a linear relationship with the number of edges in the graph and the number of network layers. In actual deployment, due to the high sparsity of social relationships and user-item interactions, |E s | << M 2 , |E r | << M×N, and the overall computational overhead of the model is much lower than the worst-case complexity in the case of a fully connected graph, with good running efficiency.
[0122] The scalability of the model depends largely on the sparsity of the graph, the embedding dimension d, and the diffusion depth L. In actual recommendation systems, social behaviors and interaction behaviors are usually sparse, the embedding dimension is often set to a constant value (such as 64 or 128), and the number of diffusion layers is also limited to 2 to 3 layers. Therefore, while ensuring the expressive ability, this model has good scalability and efficiency, and can meet the actual deployment requirements of large-scale recommendation tasks.
[0123] The following uses specific experiments to verify the effectiveness of the MARGCN model proposed in this invention.
[0124] The experiments are based on the publicly available Yelp dataset, which contains user rating and social relationship information. We follow the preprocessing strategy in [reference], and enhance the reliability of the dataset by discarding users who lack at least two ratings or social relationships, and eliminating items with less than two ratings. Subsequently, 10% is randomly selected from the entire dataset as the test set, and 10% is selected from the remaining training data as the validation set. The statistical data of the experimental dataset is shown in Table 1.
[0125] Table 1 Statistical data of the experimental dataset
[0126]
[0127] The model of this invention uses the Adam optimizer and conducts experimental analysis on different training batch sizes and learning rates. Table 2 shows the settings of the experimental parameters.
[0128] Table 2 Experimental parameter settings
[0129]
[0130] To measure the accuracy of different recommendation models, this experiment uses two widely used metrics: Hit Ratio (HR) and Normalized Discounted Cumulative Gain (NDCG).
[0131] To model higher-order relationships between users and items, this invention models interaction relationships by aggregating neighborhood information. The number of information diffusion layers (i.e., the L value) is a key factor affecting model performance: too few layers make it difficult to capture higher-order information, while too many layers easily introduce noise and lead to overfitting. Therefore, experimental analysis was conducted on the number of diffusion layers to determine the optimal setting and improve recommendation performance. Figure 3 Simulation results showing the relationship between hit rate (HR@K) and propagation layer number for different recommendation list lengths (i.e., K=5, 10, 15); Figure 4 These are simulation results showing the relationship between the normalized discount cumulative gain and the number of propagation layers for different recommendation list lengths.
[0132] according to Figure 3 and Figure 4 The model performance does not monotonically improve with increasing layer count. From L=0 to L=1, the model performance decreases slightly, likely due to the introduction of early noise before capturing sufficient higher-order signals. At L=2, HR@K and NDCG@K peak, indicating effective propagation of the user-item relationship. Performance decreases slightly at L=3 and L=4, suggesting that deeper propagation may lead to noise accumulation and overfitting. Therefore, the diffusion layer count can be set to L=2.
[0133] To verify the effectiveness of the proposed method, this experiment also compared the MARGCN model proposed in this invention with several representative baseline models, including the collaborative filtering representative model BPR, the recommendation model SocialMF which incorporates social relationships, and the graph structure modeling method CNSR.
[0134] Figure 5 This is a simulation comparison of the hit rate of the method of this invention with other models; Figure 6 This is a simulation comparison of the normalized discount cumulative gain of the method of this invention with other models.
[0135] Figure 5 and Figure 6Experimental results on the Yelp dataset demonstrate that the proposed MARGCN model achieves superior performance on both evaluation metrics compared to the three baseline methods. Compared to the traditional collaborative filtering method BPR, MARGCN achieves a higher hit rate on the HR@K metric, especially with increasing top-K recommendation list length. This indicates that MARGCN can more effectively capture the potential associations between users and items, thereby improving recommendation coverage. Compared to SocialMF, which incorporates social relationship modeling, MARGCN exhibits stronger stability and generalization ability across all K values, highlighting its advantages in fusing multi-source heterogeneous information and the effectiveness of jointly utilizing social relationships and graph convolutional network-based representations in improving recommendation accuracy. Compared to CNSR, the proposed MARGCN model achieves relative improvements of 2.66%, 0.52%, and 3.93% on HR@5, HR@10, and HR@15, respectively. In all NDCG metrics, its performance is also superior to CNSR by 1.58%, 1.32%, and 3.14%, respectively, demonstrating the effectiveness of the multi-source relationship perception and adaptive information fusion proposed in this invention.
[0136] To investigate the impact of the number of attention heads on recommendation performance in the attention mechanism, this experiment set up different numbers of attention heads (H=1, 2, 4, 8) on the Yelp dataset for comparative experiments, and analyzed the changing trends of the model on metrics such as HR@K and NDCG@K with H=1 as the baseline. Figure 7 These are simulation results of the hit rate under different recommendation list lengths with different numbers of attention heads when using the method of the present invention; Figure 8 These are simulation results of the normalized discount cumulative gain under different recommendation list lengths with different numbers of attention heads when using the method of this invention.
[0137] like Figure 7 As shown, when the number of attention points increases from 1 to 2, HR@5, HR@10, and HR@15 increase slightly by 0.0006, 0.0009, and 0.0067, respectively. Figure 8As shown, the NDCG metric also improved slightly, indicating that even with only one attention head, the model can learn richer user-item relationships. The performance improvement was even more significant when the number of attention heads was further set to 4. Specifically, HR@5 improved by 0.0037 compared to H=1, and NDCG@5 improved by 0.0032, demonstrating that the enhanced representational ability of the multi-head mechanism significantly promotes recommendation performance. When H=8, HR@5 and HR@10 improved to 0.1927 and 0.2919 respectively, improvements of 0.0065 and 0.0097 compared to H=1; NDCG@5 also improved to 0.1411, an improvement of 0.0055, achieving optimal overall ranking performance. However, it should be noted that HR@15 decreased slightly (from 0.3614 to 0.3594), which may be due to information redundancy or feature fusion conflicts caused by an excessive number of attention heads.
[0138] Therefore, appropriately increasing the number of attention heads can enhance the model's ability to model interaction features from multiple perspectives, effectively improving recommendation accuracy and ranking quality. In particular, when H=8, the model achieves optimal performance on most metrics, demonstrating that the proposed attention mechanism has significant performance advantages in recommendation tasks.
[0139] In summary, this invention proposes a multi-source adaptive relational graph convolutional network framework for recommender systems to address the challenge of heterogeneity in multi-source information and capture the varying importance of information in sparse social interactions within SIoT scenarios. We construct social and interaction graphs and recursively learn user embeddings from social neighbors and interest-based neighbors through convolutional aggregation. In this way, high-order social structures and high-order interest networks are explicitly injected into the user modeling process. Furthermore, this invention designs a multi-source relation-aware and adaptive fusion module to enhance node-level and graph-level representation learning, thereby improving user preference modeling and recommendation performance. Extensive experiments on real-world datasets clearly demonstrate the effectiveness and superiority of the proposed method.
[0140] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.
Claims
1. A sparse social IoT interest recommendation method based on graph convolutional networks, characterized in that, include: Step 1: Obtain the user set U, item set V, and rating matrix R. There may or may not be a social relationship between two users in the user set. The rating matrix R = {r ai } M×N r ai Let M represent the interest rating of user a in user set for item i in item set; M represents the total number of users in user set; and N represents the total number of items in item set. Step 2: Determine the user - the user's social graph G s User-item interest graph G c Among them, social graph G s The nodes in the social graph G represent users who are concentrated in a single user group. s The edges in the graph represent whether social relationships exist between users; interest graph G c The nodes in the interest graph G include all users in the user set and all items in the item set. c The edges in the matrix are elements of the rating matrix R; Step 3: Determine the free embedding matrix of users based on user set U and item set V. and the project's free embedding matrix Where D represents the embedding dimension, each row of the user's free embedding matrix represents a user's free embedding vector, and each row of the item's free embedding matrix represents an item's free embedding vector. Step 4: Obtain the feature vector for each user and the feature vector for each project; Step 5: Use the MARGCN model to generate predicted ratings for each user's preferences for each item; Step 6: Train the MARGCN model by minimizing the regression loss function, and then use the trained MARGCN model to recommend items to users; among which, The MARGCN model includes a feature fusion module, a multi-source relationship perception module, an adaptive information fusion module, and a preference prediction module. The feature fusion module combines the user's free embedding vector and the user's feature vector to generate an initial user representation; and combines the item's free embedding vector and the item's feature vector to generate an initial item representation. The multi-source relationship perception module utilizes an attention mechanism in the user-user social graph G. s User-Project Interest Graph G c Extract relation weights from the top; The adaptive information fusion module is based on a multi-layer GCN and generates the embedded representation of the user and the embedded representation of the item at each propagation layer through a gating mechanism. The preference prediction module generates the final embedding representations of users and items by concatenating the embedding representations of users and items across all propagation layers, respectively. Then, it uses a dot product operation to calculate the predicted preference score between users and items.
2. The sparse social IoT interest recommendation method based on graph convolutional networks according to claim 1, characterized in that, For user a and project i, the multi-source relationship awareness module performs the following operations: In the h-th attention head of the l-th propagation layer, the attention weights of user a for social neighbor b and interactive item i are determined and denoted as follows: and In the h-th attention head of the l-th propagation layer, the attention weights of item i to its interacting user a and the self-loop of item i are determined and denoted as follows: and At each propagation layer, for all attention heads and The attention weights are obtained by averaging the values of each value separately. and 3. The sparse social IoT interest recommendation method based on graph convolutional networks according to claim 2, characterized in that, Attention weight and They are respectively: in, Let W represent the embeddings of user a, user a's neighbor b, and item i at the l-th propagation layer, respectively; [·||·] denotes vector concatenation operation; h It is the feature mapping matrix of the h-th attention head, used to map the concatenated vectors to the new feature space; a h b h c h and d h It is the attention vector of the h-th attention head corresponding to each attention weight; σ is the non-linear activation function; c s and c i These are the user's biases in the social graph and interest graph, respectively. i and d s These are the interaction bias terms of item i with neighboring users and its own bias terms in the interest graph.
4. The sparse social IoT interest recommendation method based on graph convolutional networks according to claim 2, characterized in that, The adaptive information fusion module performs the following operations: A dynamic gating mechanism is used to generate gating values at each propagation layer. and Utilizing the gating value of each propagation layer and and the corresponding aggregated attention weights and Generate gated attention weights respectively. and The attention weights after gating are normalized to obtain the final attention weights for each propagation layer. and Utilizing the final attention weights of the l-th propagation layer and Embedded representation of the user in the l-th propagation layer and the embedded representation of the item in the l-th propagation layer Update the user embedding representations of user a and item i at the (l+1)th propagation layer. and project embedding representation 5. The sparse social IoT interest recommendation method based on graph convolutional networks according to claim 4, characterized in that, Gating value and They are respectively: in, and σ represents the weight matrix of the l-th gated layer. g It is a non-linear activation function in the gating mechanism. and Let represent the average user-to-user attention weight, the average user-to-item attention weight, the average item-to-user attention weight, and the average self-loop attention weight of all items in the l-th propagation layer, respectively.
6. The sparse social IoT interest recommendation method based on graph convolutional networks according to claim 4, characterized in that, Final attention weight for each propagation layer and They are respectively: in, This represents the set of all users who have a social dependency on user a. This represents the set of all items from which user a has engaged in interactive behavior. This represents the set of all users who have engaged in interactive behavior with item i.
7. The sparse social IoT interest recommendation method based on graph convolutional networks according to claim 4, characterized in that, User Embedded Representation and project embedding representation They are respectively: Where l∈{0,1,2,...,L-1}, and L represents the total number of layers in the multi-layer graph convolutional network. It is an adaptive fusion parameter of the user's own representation in the l-th propagation layer, which controls the fusion ratio of the user's own information and the neighbor's information; β i (l) It is an adaptive fusion parameter representing the l-th propagation layer project itself, which controls the fusion ratio of the project's own information and the interactive user information.
8. The sparse social IoT interest recommendation method based on graph convolutional networks according to claim 1, characterized in that, The regression loss function is a mean squared error loss function with an L2 regularization term, wherein the regularization term constrains the initial user embedding matrix, the initial item embedding matrix, and all learnable parameters in the model other than the initial embeddings.
9. A sparse social IoT interest recommendation system based on graph convolutional networks, characterized in that, include: Access layer, data interaction layer, MARGCN recommendation layer, and application layer; The access layer is used to acquire user behavior data and user interaction data; The data interaction layer is used to receive user behavior data and user interaction data, generate structured data input to the MARGCN recommendation layer, receive recommendation results generated by the MARGCN recommendation layer, and feed the recommendation results back to the application layer; The MARGCN recommendation layer implements the sparse social IoT interest recommendation method based on graph convolutional networks as described in any one of claims 1-8; The application layer receives recommendation results through the data interaction layer and feeds them back to the terminal device, thereby pushing them to the user.
10. 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 sparse social IoT interest recommendation method based on graph convolutional networks as described in any one of claims 1 to 8.
Citation Information
Cited By
Side information fusion recommendation method based on double-end multi-expert network and group balance routing
CN121210773A