8.6 Recommendation Algorithm

Recommendation algorithm is an algorithm in computer science, through some mathematical algorithms, suggesting that the user might like something.

  1. Based on the contents of the theoretical basis of the information recommendation method mainly from information retrieval and information filtering. To recommend recommended items the user does not come into contact with the user based on the user's past browsing history.
  2. Based collaborative filtering can recommend any one thing in the world recommendation algorithm theory. Pictures, music, everything you can. Collaborative filtering algorithm mainly by non-scoring items score predicted to achieve.
  3. Association rules based on recommendations (Association Rule-based Recommendation) based on association rules based on the purchased commodities as head rule, rule body is a recommendation object.

A collaborative filtering

  A classic example is the collaborative filtering on the movies. If you do not know which one is your favorite movie or scores relatively high, so the usual practice is to ask friends around to see if there are any good movie recently recommended.

 

  Collaborative filtering algorithm is divided into user-based collaborative filtering algorithm and the collaborative filtering algorithm based project. MLlib currently supports collaborative filtering model, which is expressed by the user, and a commodity group hidden semantic factors, and these factors are also used to predict the missing element.

  Spark MLlib realized alternating least squares (ALS) to learn the semantics of these hidden factors.

1. visualized and implicit feedback

  Dominant behavior including user feedback made it clear that the behavior of the preference item, implicit feedback behavior refers to behavior that is not clear response user preferences.

  In many real life many of the scenes, we often only have access to hidden feedback, such as page tour, click, buy, like, share and so on.

  Standard collaborative filtering method based on the decomposition of the matrix, typically user commodity matrix element as explicit user preferences for goods.

  Method for processing such data as used in MLlib from literature: Collaborative Filtering for Implicit Feedback Datasets. Evaluation is not user-dominant scoring for commodities, but associate with the intensity of the observed user preferences. Then, the model will try to find the hidden semantic factors to estimate a user preference for a commodity.

Two, ALS algorithm

  Get MovieLens data set in which each row contains a user, a movie, a movie that the user's score and a time stamp.

  We use the default ALS.train () method, that is the dominant feedback (default implicitPrefs to false) to build the model recommended to evaluate the model and the model root mean square error of rating prediction.

 

Guess you like

Origin www.cnblogs.com/nxf-rabbit75/p/12049052.html