May 9, 2018

Using NLTK library with AWS Lambda

This is a walk through of the process of creating a simple serverless app for finding part-of-speech tag of an input text. 1 Create virtual environment In order to separate system-wide dependencies from this app, create a separate virtual environment with: ~ mkvirtualenv nltk_env 2 Install nltk In the virtual environment use pip to install nltk package: (nltk_env) ~ pip install nltk 3 Download nltk data Pip doesn’t install additional files that are needed to the app, but nltk has a helper functions to download them: Read more

© Alexey Smirnov 2021