recommendable
recommendable copied to clipboard
Support for item-based similarity
We have similar raters in the gem right now, but i would love to query similar recommendable items(Users who liked x also liked y)?
current_user.common_likes_with(friend)
#=> [#<Movie title: '2001: A Space Odyssey', year: 1968>]
Similarly, you can do common_dislikes_with
Oops, I jumped to conclusions and misread this. However, liked_by
on the recommended item is a public method and returns an array of instances of your User model that liked it.
item.liked_by
#=> [user1, user3, user42, user89, …]
disliked_by
is similarly defined
Sorry, I just now completely wrapped my head around what you were asking, and this is a good feature request. I can take a stab at this later, though I'd prefer to fix the issues that you and the other two are having first. I can look at it soon, or you could always take a stab at it as well and submit a pull request.
No pressure :) Just wanted to put it on the docket.
This would actually be, from what I can tell and as I think about it more, super easy to do and would be useful to boot. Thanks for suggesting!
So I've been thinking about this for a while now, and I'm not sure that this is something I really want to include in the framework. Having recommendable handle both user-based and item-based similarities will really increase the memory footprint of Redis. I could perhaps implement it in a way where the user chooses one or the other (or if they really want to, both), but they'll have to be explicitly chosen. This may be a simpler task after I implement the callbacks feature that another user suggested. Until then, I'm putting this on the backlog.
Hi @davidcelis, how is this going?
@jinzhu See my previous comment
I would love to see this. In the meantime, I may have to run this and recommendify in tandem to get both :)
Would it be possible do to this by having the recommended model recommend itself? So, for example, when a user likes a product, you write a callback that has that product like the other products the user has liked. Then, would the product.recommended_products be the same relationship (or maybe product.similar_products)?
i think what i'd rather do is, with version 3, implement a per-recommendable configuration. i.e. you can pass options to recommends :things
, one of which would allow it to be an item-based similarity as opposed to user-based. version 3 has a lot of good stuff in the works, but i don't have a ton of time to work on it.
+1 item-based recommendations
+1
Recommendify does item-based recommendations and we were getting great results from it, but were scared off from using it in production since the project is not really maintained anymore. I'd love to see that feature in this gem.
@ddgromit I was in the same boat, and ended up going with https://github.com/Pathgather/predictor