Reputation: 5407
I want to build a recommender system that needs to work online.
I have a very large database of music, with about 40 features per song. These need to be clustered and then a few songs need to be suggested based on the current song.
I can cluster the data with Weka with simpleClustering. Do I just take items out of the same cluster for recommendation. Any idea how to do this with weka?
How could I make this an online continuously updating system? Or do there exist services or APIs that offer this?
Upvotes: 2
Views: 2470
Reputation: 4603
I would suggest that yes, you should just recommend other songs items drawn from the same cluster as the current song.
From the way you've phrased your question, it appears you weren't aware of this, but actually, Weka exposes its own API, containing all of the same classes available internally within the GUI. For classes related to clustering, I'd suggest you take a look at EM, XMeans, and Cobweb, although there are also other clustering algorithms that you could use as well. The clustering classes all have a pretty consistent design, there is usually a buildClusterer()
method that you can use to build the cluster, and a clusterInstance()
method that you can use to retrieve the cluster ID for a given song in the database. I actually built a small Java-based clustering demo project a few months ago in an attempt to try to improve my skills in both Java and Weka at the same time. Feel free to take a look at the source code if you feel it will help.
Upvotes: 2