TWEET CLASSIFICATION USING NLP
Name: Name:
Student ID Student ID
Name:
Student ID
• Tweet sentiment analysis
analyzes the sentiment or
emotion of tweets. It uses
natural language processing
algorithms to classify tweets
INTRODUCTION automatically as positive or
negative based on their content.
It can be done for individual
tweets or a larger dataset
related to a particular topic or
event.
WHY IS TWEET SENTIMENT ANALYSIS IMPORTANT?
Sentimental Analysis models are used in
various industries for different purposes.
Some examples are:
• Understanding Customer Feedback:
• Reputation Management:
• Political Analysis:
• Crisis Management:
• Marketing Research
1. First we will gather the required
Tweets
2. We will prepare the data using
different pre-processing techniques.
STEPS FOR 3. After pre-processing the data, we
IMPLEMENTING will create the sentimental analysis
SENTIMENT model using different NLP models.
ANALYSIS OF 4. We will analyze our Tweet data
TWEET IN using our sentiment analysis model
PYTHON: on the basis of sentiment score, i.e.,
a positive, negative
5. Eventually, we will visualize the
output from our model.
To start, we aim to analyze Tweet sentiment analysis using NLP
algorithms, the sentiment of tweets provided from the
Sentiment140 dataset by developing a pipeline involving the use of
two classifiers (LSTM, Bernoulli Naive Bayes)along with using
Term Frequency- Inverse Document Frequency (TF-IDF). The
performance of these classifiers is then evaluated using accuracy,
confusion matrix and ROC curve.
TWEET SENTIMENT ANALYSIS: DATA SET
target: the polarity
of the tweet ids: Unique id of date: the date of
(positive or the tweet the tweet
negative)
flag: It refers to the
user: It refers to text: It refers to
query. If no such
the name of the the text of the
query exists, then it
user that tweeted tweet
is NO QUERY.
EDA
1.6 million tweets
which contains 0.8
No null values were
million positive and Balanced Dataset
present
0.8 million negative
tweets
2 columns text and
0.4 million tweets
label were used to
were used for training
train the models
DATASET
PREPROCESSING
Lower Case Remove Remove
Stopwords Punctuations
Repeating Remove Remove
Characters Email’s URL’s
Cleaning Stemming Lemmatizatio
Numbers n
MODEL ➢ LSTM
SELECTION ➢ Bernoulli
LSTM MODEL
LSTM MODEL
BERNOULLI MODEL
BERNOULLI MODEL
• NGROK Secure Tunnels allow user to
instantly open access to remote
systems without touching any of your
network settings or opening any ports
on your router. Ngrok provides a unique
NGROK URL for the tunnel APIs, and other
services that require an external
connection. Ngrok supports multiple
protocols, including HTTP, HTTPS, TCP,
and SSH. It has both a free and a paid
version with additional features.
POSITIVE & NEGATIVE
0.5 > positive 0.5 < negative
AN HTML/CSS PROJECT TYPICALLY INVOLVES
DESIGNING AND DEVELOPING A WEBSITE OR
WEB APPLICATION USING HTML AND CSS.
1. Determine the purpose and scope of our project: This
involves deciding on the type of website we want to create,
what it will contain, and what it will look like. we should
also consider the target audience and any specific
requirements or constraints for the project.
2. Plan our website structure: Decide on the main pages or
sections of our website, and how they will be linked
together. Create a site map or wireframe to help visualize
our website structure.
3. Style your website with CSS: Use CSS to define the visual
style and layout of our web pages. This includes defining
fonts, colors, backgrounds, and positioning of elements on
the page.
POSITIVE TWEETS
NEGATIVE TWEETS
When any issue occurred during the
development or analysis phase, our
team collaborated and tried to
resolve the issue
TROUBLESHOOT
The selected dataset has 1.6 million
tweets, which was causing the system
to crash, and we have decided to use
only 0.4 million tweets
Right now, the accuracy of the model
is 76 % using LSTM model and our
team members are trying to improve
accuracy given more time.
CONCLUSION
Selected dataset has 1.6 million LSTM and Bernoulli models are
Sentiment or emotion of the
tweets. 0.4 million tweets were used and achieved 76 and 77%
tweet is analysed using NLP
used to train the model. accuracy respectively
Tweet classification is very
useful in customer feedback,
Reputation management and
Developed GUI using Flask and
market research and hence
ngrok platform
many researchers are working
on the sentiment analysis or
tweet classification