May 2019
Beginner to intermediate
466 pages
10h 44m
English
Now that we have successfully built and trained our model, we can ask it for recommendations. These are provided by the recommend function, which takes an instance of a recommender, a user ID (from the ones available in the training matrix), the number of recommendations, and an array of books ID from which to make recommendations as its arguments:
julia> recommend(recommender, 1, 20, [1:book_counter...])
With this line of code, we retrieve the recommendations for the user with the recommender ID 1, which corresponds to the UserID 277427 in the original dataset. We're asking for up to 20 recommendations that have been picked from all the available books.
We get back an array of a Pair of book IDs and recommendation ...
Read now
Unlock full access