I would like to set up a webpage that takes a number of Facebook status updates via the Javascript API and sorts them into an array. Then I'd like to send this array to a Python script, which can specifically do language analysis with NLTK. After I get a suitable result in Python, I'd like to return the result from that script to Javascript for displaying to the user, etc. Does this sound possible?
|
Yes, totally. Check out Google App Engine to build this sort of functionality. In particular check out these links: NLTK on App Engine: Using the Python NLTK (2.0b5) on the Google App Engine and http://code.google.com/p/nltk-gae/ Facebook API on App Engine: https://developers.google.com/appengine/articles/shelftalkers I assume that you want to make it interactive because you mentioned the word "user". |
|||||
|
Calling a service from Javascript is a very common problem. One way of solving it is to write a specific type of website known as a Webservice which would make the process flow something like...
The easiest way to send a request is using jQuery. The easiest way to format the data to be passed back and forth is JSON (JavaScript Object Notation). An example call would look something like this...
It's up to you how you'd implement the Webservice. If you want to use Python, Django is one of many good frameworks to get you started |
|||
|