1 Introduction

Collaborative filtering (CF)—neighborhood-based and model-based approaches—are tools that assist people in making decisions in their daily lives using similarities between users’ ratings and the opinions of others. If users in these systems rate a small number of items, the sparsity of their rating matrix will cause a cold start problem and reduce system performance [1]. To tackle this problem, other data sources should be used to identify users and determine their similarities with other users. One solution is to use the social network and relationships among users.

Social networks have turned into a tool for people to communicate, allowing them to communicate in a way that was previously impossible. Classic recommender systems ignored the social data and interaction among users [2] while social relationships among users always express commonalities between them, hence considering these interactions and data can improve the performance of recommender systems. The study of social network-based recommender systems began with the spread of Web 2.0 [3].

Most of the recommender systems are based on algorithms that are designed on the assumption that users’ feedback are static and that all dataset are always available [3, 4]. However, there is dynamism in users’ behaviors over time. For example, users rate the recommended items or other items of interest. They also connect with new users on social network. This dynamism in the users’ behaviors cannot be modeled via classical algorithms because it will cause data loss and reduce system performance. Therefore, there is a need for a system that considers the data dynamism over time and learns and manages users’ behaviors to increase the accuracy of recommendation [5,6,7].

Deep learning methods and their structures [8] are a powerful framework for learning which are very successful in speech recognition, image classification, natural language processing, and data clustering. Nevertheless, the historical and current datasets should be combined for learning in dynamic networks and for predicting the future is a tough challenge. Despite much attention paid to the deep learning in recommender systems [9,10,11,12], very little effort has been made to take advantage of the temporal deep learning approach for dynamic recommender systems [13]. Among the deep learning structures, the auto-encoder network has a powerful memory function that fully extracts time series changes for future prediction.

On the other hand, since users tend to relate to people who have similar preferences and choices, these tendencies lead to the formation of communities among them which can be identified by clustering; the views of similar users are further used to provide recommendations. However, if the original data are not well-distributed and has large dimension, it is difficult to achieve satisfactory performance via traditional clustering algorithms. To solve this problem, the original data space can be mapped into a new space that is more suitable for clustering. The auto-encoder network is a good candidate to solve this problem. This network provides a nonlinear mapping by continuous learning from the encoder and decoder. Recently, deep clustering, which learns feature representation for clustering tasks using deep neural networks, has attracted increasing attention for various clustering applications.

In this research, the mentioned features are used for deep auto-encoder networks in the recommender system and a hybrid collaborative filtering approach (combining user rating data and social relationships among them) based on a new deep model of semi-supervised auto-encoder networks is presented. It is recommended to learn the interactions between users and their neighbors up to step 2. In this approach, a multi-layered architecture (as the number of timestamps) is designed; each layer is an auto-encoder, with its input being a similarity matrix of users in each timestamp with time decay and its output clusters of users. The weights and clusters of each layer of architecture will be used in the next layer. The proposed approach and architecture take the dynamism in user data in each timestamp and the historical records of their activities into account. In addition to solving the cold start problem, this approach will increase the performance of the recommender system as of its capability to cluster users with high accuracy.

The innovations of this research are as follows:

  • The provision of a dynamic recommender system based on a deep learning approach

  • The use a combination of rating data and social relationship data among users and their neighbors up to step 2 as peripheral information to solve the problem of data sparsity

  • The calculation of the similarity among users by utilizing the existing information and based on users’ activity time

  • The use of a deep network layered approach to manage user data dynamically

  • The semi-supervised clustering of users in order to consider the opinions of the most similar users to solve the problem of cold start, and consequently, enhancing the accuracy and performance of the system compared to the comparable methods.

In what follows in this paper, in the next section, the related studies are given. In the third and fourth sections, the proposed approach and architecture and the results of its implementation on the selected dataset are provided. In the last section, conclusions are presented.

2 Related work

Dynamic and temporal recommender systems are used in a variety of areas, including such websites as movie recommender [14, 15], music recommender [16], news recommender [17, 18], and e-commerce recommender websites [19]. These systems perform better than static systems. In these systems, temporal deep learning techniques can be used to provide a recommendations tailored to users’ rating history at different timestamps. However, despite the benefits of using such techniques, only a few have been used in sequential and dynamic recommender systems. The following are the most important research bodies that have made use of deep learning techniques in presenting temporal recommendations and in dynamic conditions.

Authors in [17] have provided a multivariate temporal deep learning model for predicting news click sequences that combines static long-term and temporary short-term (temporal) user preferences to improve recommending function (TDSSM). This model consists of several components: a deep semantic structural model for modeling the user’s static interests, two LSTM-based temporal models for recording the user’s daily and weekly time patterns, and a temporal LSTM model for recording the user’s overall preferences. These recurrent neural networks are combined using a feed-forward network with complete connections. In paper [20], a model for collaborative filtering sequence based on Gated Recurrent unit networks (C-GRU) is proposed. This model is designed to collect the user's contextual state as a personalized hidden vector from earlier times. In particular, static global hidden factors are used for items, and separate hidden factors are assigned to users depending on their past records. Each event in a user sequence is a unique choice relative to the items set. This research focuses on sequences, regardless of the exact time of the events.

Authors in [21] have provided a recurrent neural network model (DLRec) to predict the likelihood of user feedback on an item at a later time. The proposed neural network consists of two parts: the recurrent part and the non-recurrent part. The recurrent part retains the effect of previous feedback. The non-recurrent part indicates the user's priority. First, information is continuous extracted from the sequences of consumed items. Then, the user-specific features are fed to the feed-forward network independent of the sequence features. Finally, the results of the two methods are combined. In paper [19], a sequential recommender system using recurrent neural networks is presented. These networks have been developed by considering the unique features of the range of recommender systems. This study demonstrates how both user and item features can be integrated into a new architecture of the GRU sequence to suggest next-stage items to individuals.

Authors in [22] have designed an architecture based on a deep learning approach to provide sequential content recommendations (DRNN). To this end, the GRU deep learning technique has been used to map the history of user interaction to a common Euclidean space of user vectors and contents. This mapping makes it possible to recommend the next probable content based on similar patterns. In paper [23] are presented recurrent recommender networks (RRNs) which are able to predict the future behavior. Individuals’ RNNs have been trained to model user and item evolution separately. The outputs of both networks are subsequently accompanied by additional auxiliary parameters in order to predict the user ratings.

In [24], a RNN-based method and attention mechanism for recommending in a dynamic environment are presented (ARSE). In this method, the static and dynamic preferences of users over time are used. Moreover, the power of social influence between users is considered. Authors in [25], have proposed a recommender system based on a dynamic-graph-attention network (DGRec). This system uses the preferences of users in each session and the short-term and long-term preferences of their friends. The preferences of users and those of their friends are modeled by recurrent neural networks (RNNs).They are then combined in a graph-attention network to provide recommendations. In [26], an interactive recommender system based on a combination of knowledge graph (KG) and reinforcement learning (RL) is developed to solve the problem of data sparsity (KGQR). The knowledge graph is used to extract connections between items and find candidate items, and a convolutional network (GCN) graph, based on users’ preferences, is utilized to describe their states. The real-time users’ feedback to the RL network affects the recommended items.

Modeling users’ dynamic behavior improves the accuracy of the recommender systems. Dynamic deep neural networks and mentioned models can model this type of users’ behavior well due to their ability to incorporate users’ short-term and long-term experiences. But despite that these models take into account the sequential users’ information, most of them can only be used to predict their opinions in the one next timestamp and if the stream of data continues and enters the system, the models need to be retrained anew. On the other hand, despite the significance of social network data among users in solving the problem of sparsity of the data matrix and reducing the cold start issue, this data have not been considered in most of these models. The utility of this data, along with users’ rating data, can increase the power of relationships among users. On the basis of these connections, more stable and stronger communities are formed among users. Hence, similar users can be identified, and their opinions can be used.

In this research, multi-layer deep auto-encoder networks have been used to converts large-scale data into smaller dimensions of data and cluster users, with each timestamp containing a layer of deep auto-encoder network. The input of each layer of the network is a similarity matrix among users with time decay, which is obtained by using past data of users’ ratings and their social relationships. At each timestamp, this network input data are updated. Input data are converted to smaller hidden vector, and clusters from the previous layer are updated to find the most similar users in that timestamp. To provide recommendations, then, the focus is shifted to users’ recently-rated items. The use of the proposed method and network has no time limit, and as long as the users’ data continues to generate, a new layer of auto-encoder networks can be used without the need to train the previous layers.

A summary of the relevant research bodies, together with their comparisons with the proposed method, is presented in the table below (Table 1).

Table 1 Comparison of related research with the proposed method

3 The proposed approach

In this section, we present a dynamic collaborative filtering method using multi-layer deep neural networks (auto-encoders). In this method, a weighted graph with time decay is formed between users in each timestamp. These graphs are formed using users’ common rates to items and the social relationships between them. Each graph is the input of a layer of deep auto-encoding network. The task of each layer of the auto-encoder network is to cluster users. The updated weights and clusters from each network layer are considered as initial parameters and initial clusters in the next layer. Two layers of auto-encoder networks are shown in Fig. 1. These layered networks can reflect changes in user behaviors (users’ interests in rating and their social relationships) in different timestamps in the output, and in each layer and each timestamp, place the most similar users in the same clusters. This is done to offer recommendations to target users so that the latest user opinions in the target cluster can be used.

Fig. 1
figure 1

The proposed framework

3.1 Statement of the problem

3.1.1 Dynamic weighted network

A dynamic weighted network is a set of snapshots {G1, G2,..., GT} in the network that the structure of which is Gt = {V, Et, Wt}, t = 1,….T. In this structure, Et is the network edges, Wt is the weight of the edges at time t, and T is the total number of timestamps.

3.1.2 Community structure (cluster)

A cluster in a dynamic network is a set of nodes that are densely connected; each cluster has a loose connection with other clusters.

3.1.3 Auto-encoder (AE)

An unsupervised model of three layers: input, hidden, output that reconstructs its input data in the output layer. In general, the middle layer is used as the data embedding layer and highlights the characteristics of the input data [8].

3.1.4 Dynamic network embedding

In each timestamp Gt of the dynamic network and d as dimensions, network embedding converts input data to d-dimensional data, and a timed adaptation as F = {F1, F2,…, FT} are obtained where Ft = XtHt and t = 1, 2,…, T. Xt is the input data, and Ht is a representation of input data with dimensions d at time t that are clustered by the auto-encoder.

3.2 Problem formulation

In this research, in each timestamp, a weighted graph is formed between the users; this is given, as an input, to the deep auto-encoder network in that timestamp in order to cluster the users. Figure 2 shows the proposed research algorithm.

Fig. 2
figure 2

General steps of the proposed method

It was mentioned that the input of each auto-encoder in each timestamp is a weighted graph between users. In the graph between users, the weight on the edges is obtained by weighted sum of the values of 4 matrices (the final similarity matrix in each timestamp). These 4 matrices represent the first- and second-rank neighborhoods in common items and social relationships between users. The combination of these 4 matrices represents the global structure of the network between users and the strength of relationship between them. These matrices are described below.

  1. A)

    The first matrix (M1) = (sim1(x, y)m×m) is a weighted matrix between users (m is the number of users) that is obtained based on their rates on common items and using the cosine similarity coefficient (Eq. 1).

    $$ {\text{sim}}1\left( {x,y} \right) = \cos \left( {\vec{x},\vec{y}} \right) = \frac{{\vec{x}.\vec{y}}}{{\left| {\left| {\vec{x}} \right|} \right|_{2} \times \left| {\left| {\vec{y}} \right|} \right|_{2} }} = \frac{{\mathop \sum \nolimits_{{i \in I_{xy} }} r_{x,i} r_{y,i} }}{{\sqrt {\mathop \sum \nolimits_{{i \in I_{xy} }} r_{x,i}^{2} } \sqrt {\mathop \sum \nolimits_{{i \in I_{xy} }} r_{y,i}^{2} } }} $$
    (1)

    where Ixy is the set of rates given by both users x and y; and rx,i is the user’s rating of x to item i.

  2. B)

    The second matrix (M2) = (sim2(x,y)m×m) is a matrix that calculates the similarity between users who have common neighbors. In fact, it obtains the similarity of each user with neighbors with a distance of 2 using the first matrix (M1). The amount of weight between the user and the second-rank neighbors is based on the average weight of the connected edges (Eq. 2).

    $$ {\text{sim}}2\left( {x,y} \right) = \frac{{\mathop \sum \nolimits_{z \in U} w_{{{\text{x}},{\text{z}} }} w_{{{\text{z}},{\text{y}}}} }}{n} $$
    (2)

    where z is the common neighbors between user x and y, wx,z represents the edge weight between users x and z, and n shows the number of common users (or the same number as |z|).

  3. C)

    The third matrix (M3) = (sim3(x,y)m×m) is the matrix obtained from the social relations between users, in which the edge weight is 1 if there is a direct relationship between the two users (Eq. 3).

    $$ {\text{sim}}3\left( {x,\,y} \right) = \left\{ \begin{gathered} 1~~~~~~~if\;x,y~\;{\text{have}}~\;{\text{a}}\;~{\text{social}}\;{\text{~relationship}} \hfill \\ 0\,\,\,\,\,\,\,\,{\text{else}} \hfill \\ \end{gathered} \right. $$
    (3)
  4. D)

    The fourth matrix (M4) = (sim4(x,y)m×m) is acquired from the third matrix (M3) and obtains the social relations between each user and the neighbors up to step 2 (Eq. 4).

    $$ {\text{sim}}4\left( {x,y} \right) = \frac{{\mathop \sum \nolimits_{u \in U} w_{{{\text{x}},{\text{u}} }} w_{{{\text{u}},{\text{y}}}} }}{n} $$
    (4)

Where u is the common neighbors (with n numbers) between x and y in the M3 matrix, and wx,u indicates the edge weight value (number 1) between users x and u.

In each timestamp, the weighted sum of the values of the mentioned matrices (Eq. 5) is given to the auto-encoder of that layer (timestamp) as the final matrix of relationship between users (M-final matrix) so that the users can be clustered. Matrix coefficients are parameters that control the weight of the overall similarity between users among different similarity matrices.

$$ M - {\text{final}} = M_{1} + \alpha *M_{2} + \beta *M_{3} + \gamma *M_{4} $$
(5)

One of the problems with conventional clustering methods (e.g., k-means) is that if the data have numerous dimensions, they are usually significantly distant from the normal distribution, and it is not possible to obtain suitable initial centers from them. Therefore, these methods cannot properly cluster the data. The use of deep auto-encoder networks results in reduction of data dimensions and better clustering performance [27]. Also, due to the use of each auto-encoder in each timestamp and the use of clusters from the previous step as initial centers in the auto-encoder, the problem of initial centers will also be solved.

Each auto-encoder has one input layer and several hidden layers to convert large-dimensional input data to smaller-sized data. The output of the middle hidden layer is used to cluster the data using the k-means method. Figure 3 shows the structure of each auto-encoder.

Fig. 3
figure 3

The structure of each auto-encoder for data clustering [27]

In this structure, tansig function [27] is used to map the data of each layer to the next layer (Eq. 6).

$$ h_{{\text{i}}} = f\left( {x_{{\text{i}}} } \right) = \frac{{1 - e^{{ - (W_{{\text{i}}} x_{{\text{i}}} + b_{{\text{i}}} )}} }}{{1 + e^{{ - (W_{{\text{i}}} x_{{\text{i}}} + b_{{\text{i}}} )}} }} $$
(6)

Moreover, the network output error (e1) and the clustering error (e2) are reduced simultaneously (Eq. 7) [27]. The output error of the network is the difference between the input and output of the network (which is the same as the input), and the clustering error is the difference between the output and the nearest center of the cluster (similarity within the cluster).

$$ \begin{gathered} e_{\min } = e_{1} + e_{2} = \frac{1}{N}\mathop \sum \limits_{i = 1}^{N} \left\| {x_{i} - x_{i}^{\prime } } \right\|^{2} + \lambda . \mathop \sum \limits_{i = 1}^{N} \left\| {f^{t} \left( {x_{i} } \right) - c_{i}^{*} } \right\|^{2} \hfill \\ \,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,c_{i}^{*} = \min_{{c_{j}^{p - 1} }} \left\| {f^{t} \left( {x_{i} } \right) - c_{j}^{p - 1} } \right\|^{2} \hfill \\ \end{gathered} $$
(7)

Accordingly, N is the number of train data, \(f^{{\text{t}}} \left( {x_{{\text{i}}} } \right)\) represents the map function in the p iteration, \(c_{j}^{p - 1}\) shows the center of the cluster j in the p-1 iteration of the training loop, and \(c_{{\text{i}}}^{*}\) is the closest center of cluster to the data that is in the most-inner middle hidden layer.

The initial centers of the clusters in the first auto-encoder are randomly selected from the data at time 1 and updated in the data training process. However, in subsequent timestamps, the clusters obtained in the previous timestamps (middle layer output of the previous auto-encoder) will be used as initial centers.

After clustering the users, the latest opinions of other users in the target user cluster are used to provide a recommendation to the target user via the similarity weight between the target user and others (Eq. 8).

$$ p_{{{\text{u}},{\text{i}}}} = \frac{{\mathop \sum \nolimits_{v = 1}^{k} w_{u,v} * r_{v,i} }}{{\mathop \sum \nolimits_{v = 1}^{k} w_{u,v} }} $$
(8)

pu,i is the value of the predicted user’s rate to item i, k represents the number of users in the target user cluster, and wu,v is the similarity weight between the target user and another user (v) in the cluster.

Due to the importance of user rating time for items as well as the time it takes to make social relationships, the similarities between users should diminish over time. Therefore, after passing each timestamp and entering the next one, the values of the mentioned similarity matrices (matrices M1M4) are multiplied by a time decay (Eq. 9 [14]).

$$ M = M .* e^{{\left( { - 1*\Phi } \right)}} $$
(9)

where ф is the amount of time decay parameter considered for user activity data. Then in the next timestamp, if there is another similarity based on new rating data and new social relationships between both users, it is added to the decayed values of these matrices. In fact, the matrices are updated to enter the next auto-encoder. Creating a time decay in the similarity values between users and updating them with new data in each timestamp cause the short-term preferences of users to have more weight in the similarity values between them. Thus, the amount of similarity of target users enjoys a higher value with users who have rated similar items or established social relationships at almost the same time. Also, when using their opinions and recommending items to target users, items that other users have rated in more recent times will be selected. These steps are repeated for each auto-encoder in each timestamp. This process continues as long as there is a stream of user data.

4 Results and analysis

In this section, experiments are conducted on a selected dataset, and the performance of the proposed method is evaluated in comparison with a number of common dynamic methods.

4.1 Selected dataset

In this study, Epinions dataset was used. The features of this dataset are as follows (Table 2):

Table 2 Features of the selected dataset

The dataset is divided into three parts. In each timestamp, the first and major part of the data, including 70% of it, is used as auto-encoder network training data. The second part is to validate and prevent the auto-encoder network from overfitting; it comprises 10% of the data. The third part is to test and measure the performance of the network in data clustering and provide recommendations to the target users. As it is common in deep network research, the training section is filtered from the validation and testing sections.

4.2 Comparable methods

Comparable methods are: User-based CF with exponentially decaying, Deep-learning-based CF with exponentially decaying, Standard GRU-based CF, and DGRec [25].

4.2.1 User-based CF with exponentially decaying

In user-based CF with exponential decaying [28], users’ rates will gradually decrease exponentially from the first timestamp (Eq. 10) so that the items that users have recently rated have higher values. In this equation, rateT is the user rate at time T, ratet is the user rate at each time 1,… T-1, and ф shows the decay factor.

$$ {\text{rate}}_{{\text{T}}} = {\text{rate}} _{{\text{t}}} .* e^{{\left( { - 1*\Phi } \right)*\left( {T - t} \right)}} $$
(10)

After that, the similarity between users is calculated based on their decayed ratings. Then, based on the opinions of the most similar users to the target users, items are recommended to them, and the target users’ rates are predicted for time T.

4.2.2 Deep-learning-based CF with exponentially decaying

This method is simplified version (sample) of the proposed method in the present paper and is implemented in order to draw comparisons with it. In this sample, using deep neural network, the collaborative filtering method is implemented. To this end, user rating data is multiplied and reduced over time in accordance with Eq. (10) by a decay coefficient. Based on the data obtained, the similarities between users at time T-1 are calculated and placed in a matrix. This matrix is an auto-encoder network input in which users are clustered. Then, the closest cluster to the target user is selected as the target cluster; and by using the ratings of other users in that cluster, the target user’s rating values is achieved for the recommended items.

4.2.3 Standard GRU-based CF

Based on the standard Gate Recurrent Unit [29], the collaborative filtering method, with clustering technique, is implemented. In the standard GRU method, T-1 number of GRU are used. In this method, user rating data are given to the GRUs as input from times 1 to T-1, respectively. GRUs outputs are aggregated as a code space for user communication. These code spaces are then clustered, and users are placed in different clusters. To provide recommendations to the target users, the opinions of other users in their clusters are used. Next for the recommended items, rates are predicted and compared with the users’ rating matrix at time T.

4.3 Evaluation metrics

To evaluate the algorithms of recommender systems, two evaluation metrics, namely, precision and recall are used. Precision is the fraction of relevant items (TP) among all recommended items (TP + FP). Recall is the fraction of relevant items (TP) to rated items (TP + FN).

Given these values, the precision is calculated as Eq. (11):

$$ {\text{precision}} = \frac{1}{n}\mathop \sum \limits_{i = 1}^{n} \frac{{{\text{TP}}}}{{{\text{TP}} + {\text{FP}}}} $$
(11)

The recall criterion is also calculated as Eq. (12):

$$ {\text{recall}} = \frac{1}{n}\mathop \sum \limits_{i = 1}^{n} \frac{{{\text{TP}}}}{{{\text{TP}} + {\text{FN}}}} $$
(12)

Mean Average Error (MAE) criterion is used to calculate the amount of error between predicted rates and their actual values. MAE refers to the average of all values of the deviation from the ratings and is calculated as Eq. (13):

$$ {\text{MAE}} = \frac{{\mathop \sum \nolimits_{i = 1}^{N} \left| {r_{i} - p_{i} } \right|}}{N} $$
(13)

where pi and ri are the actual and predicted values of ratings for item i, and N is the total number of predicted rates.

4.4 Implementation results

In this research, in the first experiment, the ratings of 2000 users to 200 items, together with the social relations of these users in 11 timestamps, have been used.

The proposed method is compared with the methods mentioned in Sect. 4.2. The results of these comparisons in the evaluation metrics and the number of clusters 2 to 30 are shown in Table 3. Both methods User-based CF with exponentially decaying and DGRec do not have clustering; therefore, their results have the same values for different clusters. The decay coefficient is considered to be 0.01, and each auto-encoder also has 3 nested layers, which the clustering is done in the most-inner hidden layer. The values of MAE, precision, and recall in the proposed method are their average in different timestamps.

Table 3 The implementation results of the proposed method and the comparable methods (2000 users and 200 items)

The results of the table reveal that the 3 methods based on deep learning in different clusters have better performance than the user-based CF with exponentially decaying. This is because the user-based CF with exponentially decaying method suffers from the problem of sparsity of the rating matrix and uses only the opinions of users which bear the most similarity to the target users.

The deep-learning-based CF method clusters users based on their similarity in the T-1 timestamp. In this method, a network of users with common items are placed in each cluster. The advantage of this method over the previous method (user-based CF method with exponential decaying) is that users who have common neighbors are also clustered, and their opinions can be used. In the user-based method, however, the only factor is the opinions of other users with common items (direct neighbors) which are used. Therefore, deep-learning-based CF accuracy is higher than the first method. However, since the data are not considered in different timestamps and also due to the sparsity of the rating matrix, users are not clustered properly. Its accuracy, therefore, is less compared to the other three methods.

The standard GRU-based CF, DGRec, and the proposed method have processed user data in different timestamps. The standard GRU-based CF method, like the previous methods, use only rating data and clusters the users based on them (problem of sparsity of the rating matrix). However, both DGRec and the proposed methods does this based on both the rating data and social relationship data (hence addressing the problem of sparsity of the rating matrix). DGRec method uses the opinions of direct friends of the users. In the proposed method, however, the values of similarity between users (based on both common rates and social relations) with direct neighbors and those of up to step 2 are obtained, and strong communication networks between users are recognized. Thus, in users clustering and with the appropriate number of clusters, opinions of more similar users are used. Moreover, due to the use of the timestamp parameter in ratings and user relationships, items that have recently been rated by other users are recommended to target users. In result, the accuracy and validity of the proposed method are higher than the other methods. Also, the most considerable advantage of the proposed method over the other comparable methods is the ability to consider the stream of users’ data.

In addition to the above experiments, a series of experiments was performed on bigger data sets (second experiments). The data include 20,000 users (with relationships between them) and 2000 items. Table 4 shows the results of comparison between the proposed method and other methods with respect to the number of mentioned clusters.

Table 4 The implementation results of the proposed method and the comparable methods (20,000 users and 2000 items)

Also, on the basis of these results, the accuracy and validity of the proposed method are higher than the other methods.

5 Conclusion

In this paper, a combination of rating data and users’ social relationships is used to determine the similarities between them in different timestamps. To this end, a weighted graph is formed between users, in which there is an edge between users who have either given rates to shared items, or there is a social relationship between them, or have common neighbors through the two mentioned cases. After a similarity graph between users is created, the auto-encoder network is used to cluster similar users and provide them with a time-based recommendation. There is an auto-encoder in each timestamp, and each has 3 nested layers to reduce the dimensions of the input data and to cluster users. The results of the comparison showed that the proposed method performs better and more accurately in providing personalized recommendations to users than other state-of-the-art methods, and that as long as there is a stream of data, this method can be used in any timestamp via graph updates.

One of the future research areas in this field is to use other sorts of information, such as user demographic data, to determine the similarity between users and provide them with recommendations. Items can also be clustered based on their features, and similar items can be used when presenting a recommendation to the user.