views:

95

answers:

1

Hello all,

I want to get some suggestions for my "find similar people" algorithm :). I have one database where I store the following entities: Person, article, keywords. So for each person I have a collection of keywords (with the number of mentions by the person) that have been compiled from person's articles keywords. So I need to get similar people by looking at their relevant keywords, the simple solution would be to get x keywords from a person y and find all people that share similar keyword scores (not equal), but seems that is not the best way. Thoughts?

Thanks!

+7  A: 

It sounds like your case is close enough to normal information retrieval system "similarity" queries that you could use the same vector space model.

For each person, count the number of occurrences of each keyword. Treat each keyword as a dimension, and the number of occurrences as the magnitude of a vector in that dimension. Normally, each dimension is treated the same, but if you found that some keywords are better predictors of compatibility, you could scale each occurrence in that dimension by some factor.

Then, the dot product of the vectors of different people gives you a score of how similar they are. Or, you can input your own keywords and find people whose interests are closest.

erickson