Skip to content

Sreehitha03/Sentiment-Analysis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

Sentiment Analysis

This is a sentiment analysis web application that utilizes a fine-tuned model to classify statements into three categories: Political, Regional, and Sports. The application is built using React for the frontend and Python/Node.js/Express.js for the backend. This application also detects postive and negative statements used to detect social media sentiment detection.


Features

  • Classifies statements into Political, Regional, or Sports categories.
  • Utilizes a fine-tuned model for accurate sentiment analysis.
  • Supports database integration with tables for results and users.

Getting Started

Step 1: Clone the Repository

Step 2: Install Dependencies

npm install
pip install -r requirements.txt

Step 3: Train the Model

Run the training script with the provided dataset:

python train_model.py

Step 4: Set Up the Database

  1. Create a database in MySQL.
  2. Execute the SQL commands below to create the required tables:
CREATE TABLE users (
    id INT AUTO_INCREMENT PRIMARY KEY,
    username VARCHAR(100),
    email VARCHAR(100),
    password_hash VARCHAR(255)
);

CREATE TABLE results (
    id INT AUTO_INCREMENT PRIMARY KEY,
    user_id INT,
    input_text TEXT,
    category VARCHAR(50),
    FOREIGN KEY (user_id) REFERENCES users(id)
);

Step 5: Run the frontend and backend commands

  1. Frontend
npm start
  1. Start the Python backend:
python app.py
  1. Start the Node.js server:
node --experimental-modules server.mjs

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors