Skip to content

ShwetaPardhi0/Sentiment-Analysis-nlp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

7 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🧠 Sentiment Analysis on Product Reviews

This project applies Natural Language Processing (NLP) techniques to classify customer reviews from Amazon and a product's official site into Positive, Negative, or Neutral sentiments. It uses both traditional NLP methods and transformer-based deep learning models for comparison.


πŸ“Œ Project Goals

  • Clean and preprocess customer reviews using NLP techniques.
  • Analyze and classify review sentiments using:
    • VADER (Lexicon-Based)
    • TextBlob
    • RoBERTa (Transformer-Based)
    • BERT
  • Evaluate model performance using source ratings for validation.

🧰 Technologies Used

  • Languages: Python
  • Libraries:
    • NLP: nltk, textblob, vaderSentiment, transformers
    • ML: scikit-learn
    • Data Handling: pandas, numpy
    • Visualization: matplotlib, seaborn

🧠 Models Overview

Model Type Highlights
VADER Lexicon-based Best for social media-like text
TextBlob Rule-based Quick and lightweight sentiment analyzer
BERT Transformer-based Pre-trained language model from Google
RoBERTa Transformer-based Improved variant of BERT by Facebook

πŸ§ͺ Preprocessing Steps

  • Lowercasing and text cleaning
  • Tokenization and lemmatization
  • Stopwords removal
  • Vectorization (TF-IDF and transformer tokenization)

πŸ“Š Evaluation

Sentiment predictions were cross-validated using actual star ratings to measure accuracy.
πŸ“Œ RoBERTa achieved the highest performance among all models.


πŸ—‚οΈ How to Run

  1. Clone the repository:
    git clone https://github.com/ShwetaPardhi0/Sentiment-Analysis-nlp.git
    cd Sentiment-Analysis-nlp

About

Analyze customer review sentiments using NLP and transformer models like RoBERTa and BERT.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published