Skip to content

An intelligent chatbot that can engage in conversations and learn from user interactions.

License

Notifications You must be signed in to change notification settings

aashish-thapa/Sentiment-Chatbot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sentiment Analysis Chatbot

This project features a sentiment analysis chatbot that processes user messages and returns the sentiment of the message along with a simulated chatbot response. The application uses FastAPI for the backend and React.js for the frontend. Below are the picture of the demo(The product is not ready yet):

image

image

Table of Contents

Overview

This project includes:

  • Backend (FastAPI): Provides endpoints to analyze the sentiment of user input and simulate chatbot responses.
  • Frontend (React.js): Displays a chat interface where users can type a message and receive a sentiment analysis from the bot.

The application allows users to interact with a chatbot where the sentiment of their message is analyzed and the response is displayed on the chat interface.

Backend Setup

Requirements

  • Python 3.7+
  • FastAPI
  • Uvicorn
  • psycopg2-binary

Installation

  1. Clone the repository:

    git clone https://github.com/aashish-thapa/Sentiment-Chatbot.git
    cd Sentiment-Chatbot
  2. Install the required dependencies:

    pip install -r requirements.txt
  3. Start the FastAPI server:

    uvicorn app.main:app --reload

    This will start the server on http://127.0.0.1:8000.

  4. Ensure your database is set up correctly and the necessary tables (like messages) exist. If using PostgreSQL or MySQL, ensure the user has proper permissions.

Frontend Setup

Requirements

  • Node.js
  • npm (or yarn)

Installation

  1. Navigate to the frontend directory:

    cd frontend
  2. Install the dependencies:

    npm install
  3. Start the React development server:

    npm start

    This will start the frontend on http://localhost:3000.

Running the Application

  1. Ensure both the backend and frontend servers are running.
  2. Navigate to http://localhost:3000 in your browser.
  3. Start chatting with the bot. Type a message and the sentiment will be analyzed and displayed in the chat.

Technologies Used

  • Backend: FastAPI, SQLAlchemy (or your preferred database)
  • Frontend: React.js, Axios for API requests, React hooks for state management
  • Sentiment Analysis: Custom sentiment analysis model (integrated with the backend)
  • Styling: Basic CSS/Inline styles for chat interface

License

This project is licensed under the MIT License - see the LICENSE file for details.


Feel free to update this with specific details related to your project, like database setup instructions or any extra tools or libraries used.

About

An intelligent chatbot that can engage in conversations and learn from user interactions.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published