- It’s a web app that can predict the disease based on user symptoms.
- The data we’re using is taken from the Kaggle.
- Python & its libraries such as Pandas, Numpy, Matplotlib & Sklearn is used for model creation.
- React is used as Frontend and Sass is used for Styling.
- Google Firebase & Firestore is used as Backend.
- Google OAuth is used for authentication purposes
Live Link: BayMax
- Node v10+
- Configured firebase.config.js file
- Google Account
ML Model API
Model is deployed on Hugging spaces using Gradio.
Input Payload
{
"data": [
string, // represents symptoms
]
}
Response Object
{
"data": [
string, // represents predictions
],
"duration": (float) // number of seconds to run function call
}
-
Create
firebase.config.js
file inclient/src/
Create a Firebase App using google account and then you will get below drive code & some API keys.
Ensure the API keys are configured in.env
in this directory. It should include the following keys:
import { getFirestore } from 'firebase/firestore';
import { initializeApp } from "firebase/app";
const firebaseConfig = {
apiKey: "XXXXXXXXXXXXXXX",
authDomain: "XXXXXXXXXXXXXXX",
projectId: "XXXXXXXXXXXXXXX",
storageBucket: "XXXXXXXXXXXXXXX",
messagingSenderId: "XXXXXXXXXXXXXXX",
appId: "XXXXXXXXXXXXXXX",
measurementId: "XXXXXXXXXXXXXXX"
};
// Initialize Firebase
const app = initializeApp(firebaseConfig);
export const db = getFirestore();
-
Create
.env
file inclient/
If you want to use another disease prediction API, replace the below key with that one.
REACT_APP_BACKEND_API = 'https://dikshant09-disease-prediction-api.hf.space/run/predict'
- Install dependencies and start the localhost server.
npm install
npm run start