Zeynel
Zeynel

Reputation: 13525

Using NLTK with Google App Engine

Is anyone using NLTK with GAE? From this thread it appears that GAE does not support NLTK (Special installation tricks needed.) Do you know any other lightweight similar Python module? Thanks.

Upvotes: 2

Views: 1302

Answers (1)

mjhm
mjhm

Reputation: 16705

GAE supports pretty much any "pure" Python modules which don't try to access files or sockets or other system level utilities. The poster from your link was mostly just trying to minimize the number of modules they included. They expressed a trial and error approach to figuring out which NLTK modules would be needed for their application. A slightly faster approach would be to download the whole NLTK package and move in all the ".py" files rather than just one at a time. There's no big downside to including modules you won't be using.

However this process is something of a fact of life with GAE. Any modules that aren't directly included in the GAE libraries need to be installed manually, and they need to be checked for any deviations from the GAE sandbox restrictions. See this.

A quick glance at the NLTK source code suggests that modules that depend on "mallet" in particular might be problematic, since this is compiled java code.

Upvotes: 3

Related Questions