Downloads · 30 days
0
VinayRevanuru/Medical_Chat_App
Medical_Chat_App is a machine learning model from VinayRevanuru. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
Downloads · 30 days
0
Access
Public
Updated Sep 28, 2024
Repo size
13.2 MB
Likes
0
Public
Click a slice to open those files.
.map23.9 MB · 38%
From the Hugging Face model README
Medical Chatbot App
This Medical Chatbot is designed for personal use and is built with Django on the backend and Vite.js on the frontend. It supports two AI modes: GeminiAI mode and OpenAI mode, allowing users to switch seamlessly between these two chatbot functionalities.
The project utilizes the Django Rest Framework (DRF) for API endpoints and Django Channels for handling WebSocket connections, providing a real-time chat experience.
This Medical Chatbot Assistant aims to provide users with quick, accurate, and reliable medical information through an interactive chat interface. Whether you need answers to common medical queries or want to understand symptoms better, this assistant leverages advanced AI technology to assist you in making informed decisions about your health.
To get started with this project, follow the steps below.
You can download or clone this repository using the following command:
git lfs install #installs lfs if not initialize earlier
git lfs clone https://huggingface.co/Vinay2701/Medical_Chat_App
Once Conda is installed, you can easily create the environment using the provided environment.yml file. Run the following command in your terminal:
conda env create -f environment.yml
After the environment is created, activate it using the command:
conda activate DTX_chat
For this project, we are utilizing the managed PostgreSQL database provided by Tembo.io. It's designed to help developers build, scale, and maintain Postgres databases effortlessly.
Before running the application, ensure that you have the necessary credentials for connecting to your Tembo.io PostgreSQL database. These credentials can be added to your environment variables or configuration files.
To obtain a Google API key, visit the Google Cloud Platform and create a project. Enable the necessary APIs and generate an API key for your application. Refer to the official Google Cloud documentation for more details.
To get an OpenAI API key, sign up at the OpenAI website and navigate to the API section of your account. There, you can create and manage your API keys. Visit the OpenAI documentation for further information. """
Create a .env file in the root directory of the project and add the following environment variables:
GOOGLE_API_KEY=
TEMBO_HOST= ## your host name
TEMBO_PASSWORD= #Tembo Password
OPENAI_API_KEY=
Make sure to replace these placeholder values with your actual API keys and credentials.
Once the environment is set up and the necessary variables are added, you can start the project by running:
python connection_setup.py
if you run connection_Setup again, it will reset your database and start from fresh. Since this is not a production-level project, I like to keep it simple like this.
Once everything is setup, stay in the project home directory and run the project:
python run_server.py
This command will launch both the backend server and the frontend server.
To access the frontend, open your browser and navigate to:
http://localhost:5173
You should see the chat interface where you can start interacting with the bot.
You can easily switch between GeminiAI and OpenAI modes by using the switch button located at the top-right corner of the chat interface.
I am planning to implement Docker for containerization and deployment on Hugging Face, making the app easily deployable across different environments.
Feel free to contribute or provide feedback to improve this project!