You are viewing...

Recommenders and Web Services API Idea

Updated on April 14, 2012 at the 09th hour
Posted under:

DISCLAIMER: Expressed views on this blog are my own.

I've been reading Mahout in Action and its very good to say the least. The one thing I was annoyed at was the lack of an up to date chapter on creating a Web Service to feed Mahout data. I mean this is Java right? We have access to many different libraries, so my idea now is to create a basic recommender and use an http library to listen to requests or even create a web service layer in Python and create the recommender in Java and find a way to link them up.

One way to get python to work with Mahout may be to have the Web Service add records to a MySQL database and then have Mahout read from the SQL database using the MySQLJDBC classes, so I can decouple them essentially. The dependencies between the two is the MySQL layer and any web service that has access will be able to work that way. [Keep in mind I'm only thinking about a way to add records not interact with Mahout]

Another way might be to just code up a web service and a recommender in Java, just for fun anyway, and have everything work from that point.

Maybe look towards Scala to do the web service stuff? and create a recommender using JPython or Java? Maybe have it add data straight to the memory... (just for funsies). Best way to use and learn languages.

The key thing about the web service is that GET gets recommendations, POST adds new data, PUT edits data that was entered and DELETE marks the data as not significant or just deletes it (which ever is convenient).

I'm not sure what to do yet, but I'll see how this works. I'll eventually end up creating a web service and a recommender that communicates with MySQL unless I really need Hadoop, which probably won't happen in the short term.
You just read "Recommenders and Web Services API Idea". Please share if you liked it!
You can read more recent posts here.