|Constructor and Description|
Construct a new user neighborhood finder.
|Modifier and Type||Method and Description|
Get potential neighbors for a particular user.
@Inject public LiveNeighborFinder(UserEventDAO udao, ItemEventDAO idao, UserSimilarity sim, UserVectorNormalizer norm, @UserSimilarityThreshold Threshold thresh)
udao- The user-event DAO.
idao- The item-event DAO.
sim- The similarity function to use.
norm- The normalizer for user rating/preference vectors.
thresh- The threshold for user similarities.
public Iterable<Neighbor> getCandidateNeighbors(UserHistory<? extends Event> user, LongSet items)
user- The user whose neighbors are wanted.
items- The items that the client needs to be able to score or recommend.
user. This collection may include neighbors that are not useful for scoring any item in
items; the item set is just to help the neighbor finder guide its search if relevant.