# A New Recommendation Algorithm Based on User’s Dynamic Information in Complex Social Network

Authors: Jiujun Cheng; Yingbo Liu; Huiting Zhang; Xiao Wu; Fuzhen Chen
Journal: Mathematical Problems in Engineering
 (2015)

---

## Abstract

The development of recommendation system comes with the research of data sparsity, cold start, scalability, and privacy protection problems. Even though many papers proposed different improved recommendation algorithms to solve those problems, there is still plenty of room for improvement. In the complex social network, we can take full advantage of dynamic information such as user’s hobby, social relationship, and historical log to improve the performance of recommendation system. In this paper, we proposed a new recommendation algorithm which is based on social user’s dynamic information to solve the cold start problem of traditional collaborative filtering algorithm and also considered the dynamic factors. The algorithm takes user’s response information, dynamic interest, and the classic similar measurement of collaborative filtering algorithm into account. Then, we compared the new proposed recommendation algorithm with the traditional user based collaborative filtering algorithm and also presented some of the findings from experiment. The results of experiment demonstrate that the new proposed algorithm has a better recommended performance than the collaborative filtering algorithm in cold start scenario.


---

## Body

## 1. Introduction

A social network site, such as Facebook, Twitter, and Sina Weibo, has become an indispensable part of Internet users online life. It is also an important way of user information sharing and obtaining. However, with the number of social network users going into explosive growth, the information generated by the user also increases numerously. Therefore, when the user’s ability to process information cannot keep up with the speed of the network information explosion, the user will have the problem of information overload [1]. It will increase the cost of obtaining useful information. Recommendation system [2, 3] as a kind of technology can effectively alleviate the information overload problem and provides users with excellent personalized service.In the traditional personalized recommendation algorithm, collaborative filtering algorithm [4, 5] is undoubtedly the most successful one. The collaborative filtering recommendation algorithm is based on the similarity preference between users of some certain items. More generally speaking, if they have similar interests in some items, it is most possible that they are interested in some other items. The defect of collaborative filtering algorithm is that it does not reflect that the user’s preferences are not immutable but has the feature of the dynamic changes [6–8]. It also did not take the user’s contextual factors into consideration. Therefore, the traditional collaborative filtering algorithm has some defects compared with other algorithms. Recently some published papers show that the improved algorithm will result in better recommendation performance by considering the user dynamic context factors in social network scenario [9, 10].In this paper, we proposed the recommendation algorithm based on user’s dynamic information in complex social network to address the above problems. By considering the dynamic information of user’s response information and time factor to reflect the user’s dynamic preference feature, we proposed an improved recommendation algorithm, combined with a new similarity measurement. Then the experiments show that the new proposed algorithm has better recommendation performance than the traditional collaborative filtering recommendation algorithm.


## 2. Related Work

The collaborative filtering recommendation algorithm is one of the most successful recommendation algorithms. The core idea of it can be divided into three parts: first, to calculate the similarity between users from the user’s historical interest information; then, to select theK nearest neighbors according to the similarity of users to predict the user’s preference for particular items;, finally, to select several items whose prediction score is enough high as a result of recommendation system recommended to the user.


### 2.1. The Traditional Similarity Measurement Method

The key point of the collaborative filtering recommendation is the measurement of similarity between different users. The widely adopted method is based on the similarity calculation of users’ common historical ratings data. Among the similarity calculation methods, although each one has its own advantages and disadvantages, the most common method [2, 5, 11–14] is the Pearson similarity [2, 11] and the Cosine similarity [5, 10].(
1
) Pearson similarity method: in the process of Pearson similarity calculation, we can get the similarity between different users based on the common items preference ratings. We give formalized representation here. Let user x,y’s rated common item set be Ix,y; rx,i and ry,i represent the user’s historical rating score of the item; furthermore, in order to eliminate the influence of the user rating score scale problem, we will subtract the user’s average score in the process of calculating user similarity; let rx¯ and ry¯ represent the average rating score of the item of user x and user y, respectively, which comes from the equation rx¯=1/Ix,y∑i∈Ix,yrx,i of user x and the equation ry¯=1/Ix,y∑i∈Ix,yry,i of user y. So the Pearson similarity between user x and user y can be defined as(1)Sim(x,y)=∑i∈Ix,y(rx,i-rx¯)(ry,i-ry¯)∑i∈Ix,yrx,i-rx¯2∑i∈Ix,yry,i-ry¯2.(
2
) Cosine similarity method: in the process of Cosine similarity calculation, we treat user’s historical rating score as an m-dimensional vector. The similarity between two users x and y is defined as the cosine of these two vectors. Let user x and user y’s historical rating vectors be x→ and y→, and the rated item set is Ix, Iy. So the cosine similarity of users is given by(2)Simx,y=cos⁡(x→,y→)=x→·y→x→×y→=∑i∈Ix,yrx,iry,i∑i∈Ixrx,i2∑i∈Iyry,i2.Once we get the set of nearest neighbor users [15] based on the similarity measures, we named the set Nu. Then the prediction rating score on an item i for target user u by using this formula is as follows:(3)Ru,i=ru¯+∑u′∈NuSim(u,u′)×ru′,i-ru′¯∑u′∈NuSim(u,u′),where Sim(u,u′) is the similarity between target user u and one of the nearest neighbor users u′, ru′,i is the interest rating score of user u′ to item i, and ru¯ and ru′¯, respectively, represent the average interest rating score of users u and u′ to item set. Nu is the nearest neighbors set of target user. The recommendation system can predict target user u for its possible interest degree in the item which he or she has not known and then select several high predicted interest degree items as the recommendation result to the target user.


### 2.2. The Traditional Dynamic User Interest Model

For the context of social user and user’s dynamic interest pattern, the traditional collaborative filtering recommendation algorithm did not take them into account. And the already proposed method defined the time weight functionftime_wight(t) to represent user’s dynamic interest pattern and then combined this function with recommendation algorithm [6, 13, 16]. One of the simple ways is to assume that the user’s interest is a monotonic decreasing function with time [16] and combine it with the user interest prediction function, or divide the user’s dynamic interest in more details by different time segments and construct the corresponding time weight function [6]. All these methods improved the recommendation algorithm’s recommended result.


## 2.1. The Traditional Similarity Measurement Method

The key point of the collaborative filtering recommendation is the measurement of similarity between different users. The widely adopted method is based on the similarity calculation of users’ common historical ratings data. Among the similarity calculation methods, although each one has its own advantages and disadvantages, the most common method [2, 5, 11–14] is the Pearson similarity [2, 11] and the Cosine similarity [5, 10].(
1
) Pearson similarity method: in the process of Pearson similarity calculation, we can get the similarity between different users based on the common items preference ratings. We give formalized representation here. Let user x,y’s rated common item set be Ix,y; rx,i and ry,i represent the user’s historical rating score of the item; furthermore, in order to eliminate the influence of the user rating score scale problem, we will subtract the user’s average score in the process of calculating user similarity; let rx¯ and ry¯ represent the average rating score of the item of user x and user y, respectively, which comes from the equation rx¯=1/Ix,y∑i∈Ix,yrx,i of user x and the equation ry¯=1/Ix,y∑i∈Ix,yry,i of user y. So the Pearson similarity between user x and user y can be defined as(1)Sim(x,y)=∑i∈Ix,y(rx,i-rx¯)(ry,i-ry¯)∑i∈Ix,yrx,i-rx¯2∑i∈Ix,yry,i-ry¯2.(
2
) Cosine similarity method: in the process of Cosine similarity calculation, we treat user’s historical rating score as an m-dimensional vector. The similarity between two users x and y is defined as the cosine of these two vectors. Let user x and user y’s historical rating vectors be x→ and y→, and the rated item set is Ix, Iy. So the cosine similarity of users is given by(2)Simx,y=cos⁡(x→,y→)=x→·y→x→×y→=∑i∈Ix,yrx,iry,i∑i∈Ixrx,i2∑i∈Iyry,i2.Once we get the set of nearest neighbor users [15] based on the similarity measures, we named the set Nu. Then the prediction rating score on an item i for target user u by using this formula is as follows:(3)Ru,i=ru¯+∑u′∈NuSim(u,u′)×ru′,i-ru′¯∑u′∈NuSim(u,u′),where Sim(u,u′) is the similarity between target user u and one of the nearest neighbor users u′, ru′,i is the interest rating score of user u′ to item i, and ru¯ and ru′¯, respectively, represent the average interest rating score of users u and u′ to item set. Nu is the nearest neighbors set of target user. The recommendation system can predict target user u for its possible interest degree in the item which he or she has not known and then select several high predicted interest degree items as the recommendation result to the target user.


## 2.2. The Traditional Dynamic User Interest Model

For the context of social user and user’s dynamic interest pattern, the traditional collaborative filtering recommendation algorithm did not take them into account. And the already proposed method defined the time weight functionftime_wight(t) to represent user’s dynamic interest pattern and then combined this function with recommendation algorithm [6, 13, 16]. One of the simple ways is to assume that the user’s interest is a monotonic decreasing function with time [16] and combine it with the user interest prediction function, or divide the user’s dynamic interest in more details by different time segments and construct the corresponding time weight function [6]. All these methods improved the recommendation algorithm’s recommended result.


## 3. The New Method

### 3.1. The Similarity Based on Social User’s Dynamic Information

In the social network, the most common way to construct the relationship of users is the graph constructionG=(V,E). The V represents the set of vertices corresponding to users or items. Using the edge e to connect the different vertices, E is the set of edges which means the friendship of different users or user’s social behavior historical relationship between user and item. In this paper, the exact means of set E is the relationship of user’s interest response information to item. We take into account of user’s the different types of response information and the time factor to propose a new recommendation algorithm.In social network, we can regard the behavior of information forwarding, collection, and other actions as the positive response type. So when the useru is at timestamp t, the number of positive responses can be defined as (4)R+(u,t)={ik∣tu,ik<t,(u,ik)∈G},where G represents the relationship graph of user u; U represents the set of social users U={u1,u2,…,un}, where u∈U; I is the set of items I={i1,i2,…,in} and ik∈I; the k means the number of items and k={1,2,…,n}; tu,i is the timestamp when user u gives the response information to item i.Similarly, if user did not show any interest in the item or even take actions such as shielding, cancelling the attention, and so on we can regard those actions as the negative response information. So when useru is at timestamp t, the amount of negative response information can be defined as(5)R-(u,t)={ik∣tu,ik<t,(u,ik)∈G}.Based on the above response type definition, at the same time, considering the time effect of user interest preferences and the drawback of traditional collaborative filtering algorithm to this aspect, this paper put forward the new type of user similarity measurement.We defined the user similarity by considering the user response information and the benefits of only considering the user’s response information without paying too much attention to the content of the response information are that it can ensure the diversity of the recommendation results compared with the traditional collaborative filtering recommendation algorithm [6]. Due to the time of different user response to the same item is different, it means the interest degree in this item of different user is also not the same, so after being considered to give the response of time weight, it can more accurately reflect the dynamic feature of user’s interest pattern. The user similarity measurement based on users’ positive response can be defined as(6)Sim+(u,u′)=R+(u,t)∩R+(u′,t)R+(u,t)R+(u′,t)·∑k=1nftime(t),where R+(u,t) and R+(u′,t), respectively, represent the set of items which users u and u′ gave their positive response to and R+(u,t)∩R+(u′,t) is the common set of items the users u and u′ responded to. The value of n is the common item set size. The ftime(t) is used to reflect the dynamic interest of use and detailed information of it will be discussed later.Similarly, we can get the user similarity measurement based on user negative response from this formula:(7)Sim-(u,u′)=R-(u,t′)∩R-(u′,t′)R-(u,t′)R-(u′,t′)·∑k=1mftime(t′).The meanings of sets are similar with the situation of positive response; m is the size of the common item set which users u and u′ responded to with their negative feedback or ignored.To take the dynamic interest and response information of social user into consideration, we design a decreasing time function to model the user’s dynamic interest feature in social network sites and then combine it with the new proposed similarity measurement. Theftime(t) function shows in the part of formulas (6) and (7). The definition of this time weight function is given by(8)ftimet=Ru,tΔtλ,where Δt=tu,ik-tu′,ik means the interval time of two users that give the same type response information. We can tune the parameter λ to determine the decay rate of user’s dynamic interest. The default value of λ is 1.8, but you can also change the value to make the recommendation system have the best performance according to your application environment. The R(u,t) represents the number of common items users gave their positive response to, which equals the number of the common sets R+(u,t)∩R+(u′,t).Then, we will use the regulatory factorα to combine with these two types of different similarity measurements, so the combination similarity calculation method can be defined as (9)Sim′u,u′=αSim+u,u′+1-αSim-u,u′,where the value of regulatory factor α∈[0,1] and α and (1-α), respectively, represent the weight of positive response and negative response in the equation. We can adopt the optimal weight value to optimize the recommendation result.Finally, we try to combine the similarity measurement based on social user response with the similarity calculation process of traditional collaborative filtering recommendation algorithm. On the one hand, in the early stage of the new register user, the traditional recommendation system cannot give a good recommendation result, due to the fact that no available user historical data can be used. But once the recommendation got enough user preference historical data, the performance of it will be much better. But it takes time to collect user useful time.By combination with the user’s response information, we can alleviate the cold start problem of recommendation system. It collects the response information more quickly by just some user clicks and gives the preliminary recommendation to user. On the other hand, it can also guarantee a certain diversity of the recommendation result by only focusing on the amount of response information not the content. The formalized user Pearson similarity method can be defined as(10)Simu,u′=∑i∈Ix,yrx,i-rx¯ry,i-ry¯∑i∈Ix,yrx,i-rx¯2∑i∈Ix,yry,i-ry¯2·Sim′(u,u′).And the Cosine similarity method is(11)Sim(u,u′)=∑i∈Ix,yrx,iry,i∑i∈Ixrx,i2∑i∈Iyry,i2·Sim′(u,u′).


### 3.2. The Predication Score Based on Social User’s Dynamic Information

After calculating the user similarity, the highestK nearest neighbor to target user will be selected as the base set, in order to ensure the recommendation system recommend effect. Let the target user u rated item set be Iu; the prediction score of any item i(i∉Iu), which user u may give, can be obtained by calculation of the user u′ one of the K nearest neighbor’s historical rating scores of the item i. The calculation method shows below: (12)Ru,i=ru¯+∑i=1nSimu,u′ru′,i-ru′¯∑i=1nSimu,u′,where Sim(u,u′) is the similarity between the target user u and the nearest neighbor user u′; ru′,i represents the historical rating score of user u′ to the item i; the sign of ru¯ and ru′¯, respectively, means the average rating score value of users u and u′. We can obtain the target user’s prediction rating of the item and then generate the recommended list to target user by using certain strategies to deal with.


### 3.3. The Time Complexity Analysis of Algorithm

In the process of recommendation algorithm, the algorithm involves a big part of user similarity computation. In particular when faced with the large data level of processing historical data, the performance of recommendation algorithm becomes extremely important. Here, we will analyze the time complexity of new proposed recommendation algorithm. The user similarity computation mainly involves two parts: one is the traditional similarity measure like Pearson similarity or Cosine similarity and other one is the similarity measure based on social user’s dynamic response information. The collaborative filtering algorithm mainly includes user similarity calculation and forecasts the target user’s rating scores.According to Algorithms1 and 2 process, we can know that the main factors which impact the time complexity of algorithm are the size of social user set U and item set I, while calculating the similarity. Let the size of user set be U and the size of item set I. According to the traditional user similarity measurement formulas (1) and (2), the time complexity of computing one pair of users’ similarity is O(I); then, the time complexity of computing any two different users’ similarity is U×(U-1)/2×O(I)=O(U2·I). Considering the time complexity of traditional similarity calculation, we proposed selecting the K nearest neighbor user set and then computing those K users’ similarity. Let the time complexity of similarity measurement based on user’s positive response be O(R+) and the time complexity of similarity measurement based on user’s negative response O(R-); then we can simplify the formula and get the time complexity of the integrated similarity measurement as O(I)·O(αR++(1-α)R-)=O(I·R). Then the time complexity of new proposed user similarity of any two users is K×(K-1)/2×OI·R=O(K2·I·R). In the part of user prediction score computation, the main factors influencing the time complexity of algorithm are the size of nearest neighbor set K and the size of item set I.Algorithm 1:The traditional user similarity measurement.
Input: User set U, Item set I, Rating Matrix RU×I
Output: Users Similarity Sim(u,u′)
Step  1. let ku=0;
Step  2. when ku<|U|, go to Step3; otherwise, end;
Step  3. let ki=ku+1; when ki<|I|, compute to get the
users similarity according to formula (1) or (2); otherwise,
++ku, go back to Step  2.Algorithm 2:The user similarity measurement based on social user dynamic information and prediction score calculation.
Input: Target User u, Target Item i, Nearest Neighbor
SetK, Item Set I, Timestamp t, Decay Rate Parameter
λ, Regulatory Factor α;
Output: the prediction score R(u,i) of target user u for
the itemi;
Step  1. let ku=0;
Step  2. when ku<|K|, go to Step  3; otherwise, go to
Step  4;
Step  3. when ki<|I|, get the number of user positive and
negative responseR+(u,t) and R-(u,t) according to
formula (4) and (5); otherwise, ++ku, go back to Step  2;
Step  4. when u,u′∈U, compute the Sim+(u,u′),
Si
m
-
(
u
,
u
′
) of user u and u′ according to (6), (7);
Step  5. get the user similarity according to formula (9);
Step  6. get the integrated user similarity by (10) or (11);
Step  7. finally, get the predication score R(u,i) of user u
to itemi according to (12).


## 3.1. The Similarity Based on Social User’s Dynamic Information

In the social network, the most common way to construct the relationship of users is the graph constructionG=(V,E). The V represents the set of vertices corresponding to users or items. Using the edge e to connect the different vertices, E is the set of edges which means the friendship of different users or user’s social behavior historical relationship between user and item. In this paper, the exact means of set E is the relationship of user’s interest response information to item. We take into account of user’s the different types of response information and the time factor to propose a new recommendation algorithm.In social network, we can regard the behavior of information forwarding, collection, and other actions as the positive response type. So when the useru is at timestamp t, the number of positive responses can be defined as (4)R+(u,t)={ik∣tu,ik<t,(u,ik)∈G},where G represents the relationship graph of user u; U represents the set of social users U={u1,u2,…,un}, where u∈U; I is the set of items I={i1,i2,…,in} and ik∈I; the k means the number of items and k={1,2,…,n}; tu,i is the timestamp when user u gives the response information to item i.Similarly, if user did not show any interest in the item or even take actions such as shielding, cancelling the attention, and so on we can regard those actions as the negative response information. So when useru is at timestamp t, the amount of negative response information can be defined as(5)R-(u,t)={ik∣tu,ik<t,(u,ik)∈G}.Based on the above response type definition, at the same time, considering the time effect of user interest preferences and the drawback of traditional collaborative filtering algorithm to this aspect, this paper put forward the new type of user similarity measurement.We defined the user similarity by considering the user response information and the benefits of only considering the user’s response information without paying too much attention to the content of the response information are that it can ensure the diversity of the recommendation results compared with the traditional collaborative filtering recommendation algorithm [6]. Due to the time of different user response to the same item is different, it means the interest degree in this item of different user is also not the same, so after being considered to give the response of time weight, it can more accurately reflect the dynamic feature of user’s interest pattern. The user similarity measurement based on users’ positive response can be defined as(6)Sim+(u,u′)=R+(u,t)∩R+(u′,t)R+(u,t)R+(u′,t)·∑k=1nftime(t),where R+(u,t) and R+(u′,t), respectively, represent the set of items which users u and u′ gave their positive response to and R+(u,t)∩R+(u′,t) is the common set of items the users u and u′ responded to. The value of n is the common item set size. The ftime(t) is used to reflect the dynamic interest of use and detailed information of it will be discussed later.Similarly, we can get the user similarity measurement based on user negative response from this formula:(7)Sim-(u,u′)=R-(u,t′)∩R-(u′,t′)R-(u,t′)R-(u′,t′)·∑k=1mftime(t′).The meanings of sets are similar with the situation of positive response; m is the size of the common item set which users u and u′ responded to with their negative feedback or ignored.To take the dynamic interest and response information of social user into consideration, we design a decreasing time function to model the user’s dynamic interest feature in social network sites and then combine it with the new proposed similarity measurement. Theftime(t) function shows in the part of formulas (6) and (7). The definition of this time weight function is given by(8)ftimet=Ru,tΔtλ,where Δt=tu,ik-tu′,ik means the interval time of two users that give the same type response information. We can tune the parameter λ to determine the decay rate of user’s dynamic interest. The default value of λ is 1.8, but you can also change the value to make the recommendation system have the best performance according to your application environment. The R(u,t) represents the number of common items users gave their positive response to, which equals the number of the common sets R+(u,t)∩R+(u′,t).Then, we will use the regulatory factorα to combine with these two types of different similarity measurements, so the combination similarity calculation method can be defined as (9)Sim′u,u′=αSim+u,u′+1-αSim-u,u′,where the value of regulatory factor α∈[0,1] and α and (1-α), respectively, represent the weight of positive response and negative response in the equation. We can adopt the optimal weight value to optimize the recommendation result.Finally, we try to combine the similarity measurement based on social user response with the similarity calculation process of traditional collaborative filtering recommendation algorithm. On the one hand, in the early stage of the new register user, the traditional recommendation system cannot give a good recommendation result, due to the fact that no available user historical data can be used. But once the recommendation got enough user preference historical data, the performance of it will be much better. But it takes time to collect user useful time.By combination with the user’s response information, we can alleviate the cold start problem of recommendation system. It collects the response information more quickly by just some user clicks and gives the preliminary recommendation to user. On the other hand, it can also guarantee a certain diversity of the recommendation result by only focusing on the amount of response information not the content. The formalized user Pearson similarity method can be defined as(10)Simu,u′=∑i∈Ix,yrx,i-rx¯ry,i-ry¯∑i∈Ix,yrx,i-rx¯2∑i∈Ix,yry,i-ry¯2·Sim′(u,u′).And the Cosine similarity method is(11)Sim(u,u′)=∑i∈Ix,yrx,iry,i∑i∈Ixrx,i2∑i∈Iyry,i2·Sim′(u,u′).


## 3.2. The Predication Score Based on Social User’s Dynamic Information

After calculating the user similarity, the highestK nearest neighbor to target user will be selected as the base set, in order to ensure the recommendation system recommend effect. Let the target user u rated item set be Iu; the prediction score of any item i(i∉Iu), which user u may give, can be obtained by calculation of the user u′ one of the K nearest neighbor’s historical rating scores of the item i. The calculation method shows below: (12)Ru,i=ru¯+∑i=1nSimu,u′ru′,i-ru′¯∑i=1nSimu,u′,where Sim(u,u′) is the similarity between the target user u and the nearest neighbor user u′; ru′,i represents the historical rating score of user u′ to the item i; the sign of ru¯ and ru′¯, respectively, means the average rating score value of users u and u′. We can obtain the target user’s prediction rating of the item and then generate the recommended list to target user by using certain strategies to deal with.


## 3.3. The Time Complexity Analysis of Algorithm

In the process of recommendation algorithm, the algorithm involves a big part of user similarity computation. In particular when faced with the large data level of processing historical data, the performance of recommendation algorithm becomes extremely important. Here, we will analyze the time complexity of new proposed recommendation algorithm. The user similarity computation mainly involves two parts: one is the traditional similarity measure like Pearson similarity or Cosine similarity and other one is the similarity measure based on social user’s dynamic response information. The collaborative filtering algorithm mainly includes user similarity calculation and forecasts the target user’s rating scores.According to Algorithms1 and 2 process, we can know that the main factors which impact the time complexity of algorithm are the size of social user set U and item set I, while calculating the similarity. Let the size of user set be U and the size of item set I. According to the traditional user similarity measurement formulas (1) and (2), the time complexity of computing one pair of users’ similarity is O(I); then, the time complexity of computing any two different users’ similarity is U×(U-1)/2×O(I)=O(U2·I). Considering the time complexity of traditional similarity calculation, we proposed selecting the K nearest neighbor user set and then computing those K users’ similarity. Let the time complexity of similarity measurement based on user’s positive response be O(R+) and the time complexity of similarity measurement based on user’s negative response O(R-); then we can simplify the formula and get the time complexity of the integrated similarity measurement as O(I)·O(αR++(1-α)R-)=O(I·R). Then the time complexity of new proposed user similarity of any two users is K×(K-1)/2×OI·R=O(K2·I·R). In the part of user prediction score computation, the main factors influencing the time complexity of algorithm are the size of nearest neighbor set K and the size of item set I.Algorithm 1:The traditional user similarity measurement.
Input: User set U, Item set I, Rating Matrix RU×I
Output: Users Similarity Sim(u,u′)
Step  1. let ku=0;
Step  2. when ku<|U|, go to Step3; otherwise, end;
Step  3. let ki=ku+1; when ki<|I|, compute to get the
users similarity according to formula (1) or (2); otherwise,
++ku, go back to Step  2.Algorithm 2:The user similarity measurement based on social user dynamic information and prediction score calculation.
Input: Target User u, Target Item i, Nearest Neighbor
SetK, Item Set I, Timestamp t, Decay Rate Parameter
λ, Regulatory Factor α;
Output: the prediction score R(u,i) of target user u for
the itemi;
Step  1. let ku=0;
Step  2. when ku<|K|, go to Step  3; otherwise, go to
Step  4;
Step  3. when ki<|I|, get the number of user positive and
negative responseR+(u,t) and R-(u,t) according to
formula (4) and (5); otherwise, ++ku, go back to Step  2;
Step  4. when u,u′∈U, compute the Sim+(u,u′),
Si
m
-
(
u
,
u
′
) of user u and u′ according to (6), (7);
Step  5. get the user similarity according to formula (9);
Step  6. get the integrated user similarity by (10) or (11);
Step  7. finally, get the predication score R(u,i) of user u
to itemi according to (12).


## 4. Experimental Evaluation

In order to validate the fact that the new proposed recommendation algorithm has better performance than the traditional user based collaborative filtering recommendation algorithm, we have collected the data of domestic mainstream social network site called Sina Weibo to complete the relevant experiments.Since the grabbed data from the original Sina Weibo site has a lot of redundant information, therefore, it needs to extract and transform the raw data, commonly known as the process of ETL, eliminate the irrelevant information, and get the exact information we need. The data has about 6040 Sina users with about 3682 pieces of Weibo information, and 100 thousand response information logs. Considering the scenario in Sina Weibo, the negative response information of user is very difficult to define. The situation of without the user’s browsing, no forwarding, no comments, and so forth often denotes the user has no interest in this information. So consider that the new similarity measurement regulatory factorα is set as α=1, which means only social user’s positive response information be considered. We regard this situation of user collection, forwarding, and comment microblog information as positive response type.For the existing data set, the data set is equally divided into 10 subsets by way of random selection, of which nine were randomly selected as the training set and the remaining one was selected as the test set. Due to the presence of the decreasing function parameterλ, which characterizes the dynamic of user interest, to get the optimization value of parameter λ will have a great influence on the final recommendation results. So we will get the optimal parameter before we do the further experiments. We use the average absolute deviation MAE [6, 11, 17, 18] as the evaluation metric to evaluate the performance of recommendation algorithm. The lower the MAE is, the more accurately recommended result the recommendation can give. We can obtain the evaluation metric MAE data of the improved recommendation algorithm by changing the parameter λ as 1.0, 1.5, 1.8, and 2.1. Then, we can also get Figure 1.Figure 1
The impact of the user interest decay rateλ to recommendation algorithm results.We can draw a conclusion that the improved algorithm has the best performance from Figure1, when the decay rate parameter λ is 1.8. But the optimal value of parameter λ may be different from this value; it should be tuned according to your specific environmental factors. One of the main factors influencing recommendation algorithm performances is the feature of data set.Once we determined the parameterλ, we designed the comparative experiment between the new recommendation algorithm based on social user’s dynamic information and the user based collaborative filtering recommendation algorithm. The collaborative filtering algorithm is one of the classic and most successful recommendation algorithms; so as a comparison basis, it will have some convincing. Under the same experiment conditions, the data set is also equally divided into 10 equal subsets by way of random selection, of which nine were randomly selected as the training set and the remaining one was selected as the test set; then the average MAE value of 10 experiments was the MAE evaluation metric result of the recommendation algorithm. We can get the following figure by changing the number of nearest neighbors to 5, 10, 15, 20, and 25. The experiment result shows in Figure 2.Figure 2
Comparative experiment results of two algorithms.From Figure2, the improved algorithm outperforms better recommendation result than the traditional user based collaborative filtering algorithm at the same number of nearest neighbors. Further, from the same type of algorithm, but with different number of nearest neighbors, we can see that as the number of nearest neighbor users increases, the recommendation algorithm gets better results; namely, the value of MAE presents a descending trend, but not infinite decline. It will become one kind of steady state. Therefore, the contrast experiment gives us a lesson that how to select the optimal set of parameters will have a great effect on the recommended result of recommendation algorithm in the specific personalized recommendation system application environment. It also can involve some optimization and method to get the best recommendation performance.


## 5. Conclusion

In this paper, the theory of collaborative filtering recommendation algorithm is briefly introduced. The collaborative filtering recommendation algorithm is a kind of widely used and more mature algorithms and has a good recommended effect of recommendation algorithm. However, the collaborative filtering recommendation algorithm is a flawed one, in some aspects. For example, the traditional collaborative filtering algorithm did not take into account the temporal characteristics of user’s interest while computing the similarity, so it will lose a part of the recommendation accuracy and diversity. Meanwhile, with the rise of social network, the social network user surged, so the users are faced with the problem of information overload on social network sites. But the social user contains rich contextual information; therefore, this paper takes the dynamic information of social user into account to propose the improved algorithm to alleviate the problem and validates the fact that the new improved algorithm has the improvement of recommended effect by contrast experiment. However, the social network user’s dynamic information not just only the response information and time factor; there are also geographical information, social relationship information, and other context information. We will continually optimize the current deficiency of the proposed algorithm and also try to do the work of how to better model social user’s dynamic information, dig deeper into the user’s behavior patterns, and combine them into recommendation algorithm to improve the recommendation algorithm performance in our next step of research.



---

*Source: 281629-2015-03-29.xml*