This project demonstrates key Natural Language Processing (NLP) techniques in Python using NLTK and simple data storage using SQLite.
It includes downloading and processing a real text corpus, tokenization, stopword filtering, stemming, lemmatization, and part-of-speech tagging.
This demo performs the following operations:
- Downloads a Project Gutenberg text (Mary Shelley’s Frankenstein)
- Stores text in a SQLite database for simple corpus management
- Tokenizes text into words
- Removes stopwords (common words such as “the”, “and”, “is”)
- Applies stemming using Porter and Snowball stemmers
- Applies lemmatization, both basic and POS-tag–aware
- Performs POS tagging with NLTK’s universal tagset
- Counts tokens with specific suffixes (e.g. words ending in “-ing”)
git clone https://github.com/ekmuji/simple-nlp.git
cd simple-nlp- nltk
- urllib
- sqlite3
python simple-nlp.py