Sentiment analysis (also known as opinion mining or emotion AI) refers to the use of natural language processing, text analysis, computational linguistics, and biometrics to systematically identify, extract, quantify, and study affective states and subjective information. Sentiment analysis is widely applied to voice of the customer materials such as reviews and survey responses, online and social media, and healthcare materials for applications that range from marketing to customer service to clinical medicine.
Used here is TextBlob, a Python library for processing textual data. It provides a simple API for diving into common natural language processing (NLP) tasks such as part-of-speech tagging, noun phrase extraction, sentiment analysis, classification, translation, and more. It's documentation here.
The Twitter API tweepy was used to collect tweets related to COVID-19. You may view the script collect_tweets.py
UPDATE:
- Added script (collect_tweets.sh) to collect more data. Here we use Twint as it is more efficient and flexible than tweepy. It also gathers a lot of data in minimal time.
UPDATE 2: (16-02-2022)
- Added external dataset (see notebook 2) This minimizes data labeling errors by diversifying data sources.
A web-app handling sentiment analysis where a user inputs their text and the system outputs the sentiment associated with it was deployed using the Flask API and is live here.