This project implements a Sentiment Analysis application with a React frontend, FastAPI backend, and a dedicated analysis section for exploring different machine learning models. The application allows users to input text, analyze its sentiment, and display the results.
/frontend: React + TypeScript frontend./backend: FastAPI backend powered by Unicorn for running sentiment analysis./analysis: Model analysis and experimentation folder, dedicated to working with various sentiment analysis models.
Sentiment analysis is the process of determining the sentiment expressed in a piece of text. It typically classifies text as positive, negative, or neutral. This project utilizes machine learning models to analyze text and classify its sentiment.
- Text Input: Enter text into the frontend interface.
- Sentiment Analysis: Sentiment is processed and analyzed by a FastAPI-based backend.
- Results Display: The sentiment score and classification are displayed on the frontend.
- Model Analysis: Different models for sentiment analysis can be explored and compared in the
/analysisdirectory.
Make sure you have the following installed:
-
Navigate to the
/backenddirectory:cd backend -
Install the required dependencies:
pip install -r requirements.txt
-
Run the FastAPI server with Unicorn:
uvicorn main:app --reload
-
The backend will be accessible at http://localhost:8000.
-
Navigate to the
/frontenddirectory:cd frontend -
Install the required dependencies:
yarn install
-
Start the React development server:
yarn start
-
The frontend will be accessible at http://localhost:3000.
The /analysis folder contains various models and experiments for sentiment analysis. This folder is intended for researchers and data scientists looking to evaluate and compare different models.
-
Navigate to the
/analysisdirectory:cd analysis -
You can use Jupyter notebooks, scripts, or other tools to analyze and test different sentiment analysis models.
