mahout-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sean Owen" <>
Subject Re: help for item based recommender
Date Mon, 26 May 2008 16:48:19 GMT
This is up to you. For item-based recommenders, this is an opportunity
to inject more information into the recommender, some external notion
of item-item similarity. For example maybe your items are movies, and
you define some similarity metric on them based on genre. You can
implement an ItemCorrelation to encapsulate this, or if you want to
just pass a fixed list of item-item correlations, use

An alternative here is to not use GenericItemCorrelation at all, and
instead pass a PearsonCorrelation. This will compute item-item
correlations on the fly, based on user preference information.

Isn't that much easier, you ask? yes it's quite easy, and it works.
You're not adding new information, and are essentially just using a
user-based recommender turned on its side. That setup is fine -- this
kind of simple item-based recommender might still be advisable when
you have a lot of users and few items (user-based recommenders are
faster when you have few users and many items).

But one of the "features" of item-based recommenders is this notion of
inserting new information in this way. It's also much faster to use
fixed similarity information rather than compute it on the fly.

AFAIK this is essentially the approach that Amazon takes.

Why is it asymmetric? why couldn't we suggest that people plug in
pre-computed notions of user similarity instead? you could... but I
think that this approach really only makes sense for items. Items are
fixed, and we may know, a priori, a lot about them, while we start by
knowing nothing about users and they might even change. So it perhaps
makes sense that we could reasonably insert external information on
items, but maybe not for users.


On Mon, May 26, 2008 at 7:58 AM, Cam Bazz <> wrote:
> Hello,
> I am going over the documentation and meant to do a item based recomender.
> I understand that the datamodel is fed with triplets in form of:
> userid, itemid, likingscore
> There is a part in the code which says:
> // Construct the list of pre-compted correlations
> Collection<GenericItemCorrelation.ItemItemCorrelation> correlations =
>  ...;
> ItemCorrelation itemCorrelation = new GenericItemCorrelation(correlations);
> and the explanation mentions we have to feed a list of pre-computed
> corelations to the GenericItemCorelation.
> How do we pre-compute corelations?
> Best.
> -C.B.

View raw message