Thanks, Sebastian.

To get around this problem, I was just reading about the
PlusAnonymousUserDataModel. Would that be appropriate to use with boolean
preferences?

My whole motivation here is that I want to train a recommender on a large
data model, and then get recommendations for a bunch of users who were not
in the original data model, without having to completely rebuild the
original model for each user. I don't care if these new users don't persist
in the current model. (Actually I would prefer that they did not influence
the model at this point) I just need to quickly generate recommendations
for them.

Can I accomplish that by wrapping PlusAnonymousUserDataModel around a
GenericBooleanPrefDataModel?
Are there any performance implications to using the
PlusAnonymousUserDataModel? I know I can only have one anonymous user at at
time. That's ok.

Thanks again!
Matt


On Thu, Aug 8, 2013 at 6:08 PM, Sebastian Schelter <[email protected]> wrote:

> This is a design flaw unfortunately, because we don't support online
> recommenders. You have to add the data to the underlying DataModel and call
> refresh on the Recommender.
>
> A common practice is for example to save new interactions in a database and
> load them into memory from time to time.
>
> 2013/8/8 Matt Molek <[email protected]>
>
> > Ok, having implemented a recommender that tried to call
> setPreference(...)
> > on a GenericBooleanPrefUserBasedRec
> > ommender with a GenericBooleanPrefDataModel, I see this isn't the way.
> > GenericBooleanPrefDataModel throws an UnsupportedOperationException.
> >
> >
> > I don't see any other way to add new user-item associations to the model
> > though. Is this just no possible? That seems weird. I thought all of the
> > in-memory models supported having new data added on the fly. Am I missing
> > something?
> >
> > Thanks for the help,
> > Matt
> >
> >
> > On Thu, Aug 8, 2013 at 12:31 PM, Matt Molek <[email protected]> wrote:
> >
> > > I'm using a GenericBooleanPrefUserBasedRecommender with a
> > > GenericBooleanPrefDataModel.
> > >
> > > When I load the historical user/item associations from a file, they're
> > > just in the format of userid, itemid, and as I understand it, the
> > > GenericBooleanPrefDataModel does not store any 'rating' data.
> > >
> > > I'd like to add new preferences (and users) to the recommender on the
> > fly,
> > > but the only method to add new preferences on
> > > GenericBooleanPrefUserBasedRecommender is* setPreference*(long userID,
> > > long itemID, float value). Is 1.0 the correct value to be using? Will
> the
> > > GenericBooleanPrefDataModel just ignore that 1.0 value that I pass to
> it,
> > > since it wasn't storing any other preferences?
> > >
> > > Also, is the right way to add a user on the fly just to  set all their
> > > preferences one at a time with setPreference(...) and then ask for
> > > recommendations for them?
> > >
> > > Thanks!
> > > Matt
> > >
> >
>

Reply via email to