title: Collaborative filtering in MySQL?
body: <p>I'm <em>trying</em> to develop a site that recommends items(fx. books) to users based on their preferences. So far, I've read O'Reilly's "Collective Intelligence" and numerous other online articles. They all, however, seem to deal with single instances of recommendation, for example if you like book A then you might like book B. </p>
  
  <p>What I'm trying to do is to create a set of 'preference-nodes' for each user on my site. Let's say a user likes book A,B and C. Then, when they add book D, I don't want the system to recommend other books based solely other users experience with book D. I wan't the system to look up similar 'preference-nodes' and recommend books based on that.</p>
  
  <p>Here's an example of 4 nodes:</p>
  
  <pre><code>User1: 'book A'-&gt;'book B'-&gt;'book C'
  User2: 'book A'-&gt;'book B'-&gt;'book C'-&gt;'book D'
  user3: 'book X'-&gt;'book Y'-&gt;'book C'-&gt;'book Z'
  user4: 'book W'-&gt;'book Q'-&gt;'book C'-&gt;'book Z'
  </code></pre>
  
  <p>So a recommendation system, as described in the material I've read, would recommend book Z to User 1, because there are two people who recommends Z in conjuction with liking C (ie. Z weighs more than D), even though a user with a similar 'preference-node', User2, would be more qualified to recommend book D because he has a more similar interest-pattern.</p>
  
  <p>So do any of you have any experience with this sort of thing? Is there some things I should try to read or does there exist any open source systems for this?</p>
  
  <p>Thanks for your time! </p>
  
  <p><em>Small edit:</em> I think last.fm's algorithm is doing exactly what I my system to do. Using the preference-trees of people to recommmend music more personally to people. Instead of just saying "you might like B because you liked A"</p>