|
Algorithm 3 Collaborative filtering-based personalized recommendation algorithm |
-
Require:
User historical behavior; Results of the food public opinion prediction model
-
Ensure:
Personalized recommendation list
-
1.
Calculate the similarity matrix between user u and other users based on the historical ratings of all users for different news items.
-
2.
Select the user most similar to user u, and based on the most similar user’s preference for the target news, predict and calculate the specific rating value of user u for the target news item.
-
3.
Calculate the early warning index for all news items based on the sentiment prediction model, and compute the final user recommendation matrix.
-
4.
Recommend news based on the rating values from highest to lowest.
|