title: Recommendation algorithm (and implementation) for finding similar items and users
body: <p>I have a database of about 700k users along with items they have watched/listened to/read/bought/etc.
  I would like to build a recommendation engine that recommends new items based on what users with similar taste in things have enjoyed, as well as actually finding people the user might want to be friends with on a social network I'm building (similar to last.fm).</p>
  
  <p>My requirements are as follows:</p>
  
  <ul>
  <li>Majority of the "users" in my database aren't actually users of my website. They have been data mined from third-party sources. However, when recommending users, I would like to limit the search to people who are members of my website (while still taking advantage of the bigger data set).</li>
  <li>I need to take multiple items into consideration. Not "people who like this one item you enjoyed...", but "people who like most of the items you enjoyed...".</li>
  <li>I need to compute similarities between users and show them when viewing their profiles (taste-o-meter).</li>
  <li>Some items are rated, others are not. Ratings are from 1-10, not boolean values. In most cases it would be possible to deduct a rating value from other stats if it's not present (e.g. if the user has favourited an item, but hasn't rated it, I could just assume a rating of 9).</li>
  <li>It has to interact with Python code in one way or another. Preferably, it should use a seperate (possibly NoSQL) database and expose an API to use in my web back-end. The project I'm making uses Pyramid and SQLAlchemy.</li>
  <li>I would like to take item genres into account.</li>
  <li>I would like to display similar items on item pages based on both its genre (possibly tags) and what users who enjoyed the item liked (like Amazon's "people who bought this item" and Last.fm artist pages). Items from different genres should still be shown, but have a lower similarity value.</li>
  <li>I would prefer a well-documented implementation of an algorithm with some examples.</li>
  </ul>
  
  <p>Please don't give an answer like "use pysuggest or mahout", since those implement a plethora of algorithms and I'm looking for one that's most suitable for my data/use. I've been interested in Neo4j and how it all could be expressed as a graph of connections between users and items.</p>