Skip to content

DevanshChhabra/Sentiment_Analysis

Repository files navigation

Amazon Reviews Sentiment Analysis

This is a Streamlit app for sentiment analysis of Amazon reviews using a pre-trained model.

Setup Instructions

  1. Clone the repository:

    git clone https://github.com/DevanshChhabra/Sentiment_Analysis.git
    cd Sentiment_Analysis
  2. Create a virtual environment and activate it:

    python -m venv venv
    source venv/bin/activate  # On Windows, use `venv\Scripts\activate`
  3. Install the dependencies:

    pip install -r requirements.txt
  4. Download NLTK data (if not included in the project):

    import nltk
    nltk.download('punkt')
    nltk.download('stopwords')
  5. Run the Streamlit app:

    streamlit run sentiment_analysis.py

Files

  • sentiment_analysis.py: Main Streamlit app script.
  • Sentiment_Analysis.h5: Trained model file.
  • tokenizer_(1).json: Tokenizer file.
  • requirements.txt: Python dependencies.

Usage

Enter a review into the text box and click "Predict" to get the sentiment analysis result.

Releases

No releases published

Packages

No packages published