MedSense is an intelligent and interactive medical chatbot web application that helps users identify possible diseases based on their symptoms and provides tailored suggestions including precautions, medications, diets, and workouts.
It is built using Flask, Streamlit, LangChain, and Hugging Face, with integrated patient-type handling, chat interface, and disease prediction powered by machine learning. 💡
✅ Disease prediction based on symptoms
✅ Chatbot UI with natural interaction flow
✅ Personalized suggestions (based on patient type: Normal / Diabetic / BP)
✅ Precautions, Medications, Diet & Workout recommendations
✅ User Sign Up & Login Authentication
✅ Stylish and responsive UI with Bootstrap & Streamlit
✅ Trained ML model and symptom-based prediction flow
✅ Ready-to-use vector database with LangChain + HuggingFace
- 👤 User selects patient type: (Normal / Diabetic / BP)
- 🧾 User enters symptoms via dropdowns (dynamic based on count)
- 🤖 ML model predicts possible disease
- 🧠 Model provides:
- Precautions
- Medications
- Diet
- Workouts
- 💬 User can continue interacting via chat
- 🔐 Sign In / Sign Up page added for user access control
- Frontend: HTML, CSS, Bootstrap, Streamlit
- Backend: Flask
- ML & NLP: scikit-learn, Pandas, LangChain, Hugging Face
- Database: FAISS Vector Store
- Authentication: Flask-Login
- UI Components: Jinja2 templates, Streamlit custom components
Follow these steps to run the project on your local machine:
git clone https://github.com/WaseemKhan09/medisense.git
cd medisense# On Linux/Mac:
python3 -m venv venv
source venv/bin/activate
# On Windows:
python -m venv venv
venv\Scripts\activatepip install -r requirements.txtCreate a .env file in the root directory with the following:
HF_TOKEN=your_huggingface_api_key_hereflask runIn a new terminal:
streamlit run medibot.pyThe Flask app will run your core project, and the Streamlit app will launch the chatbot interface in a browser.
- Medical students or enthusiasts learning about AI in healthcare
- Developers exploring LangChain + Hugging Face integrations
- Institutions needing a basic AI-powered symptom-checker prototype
- Anyone interested in ML/NLP-based chatbot systems
Thanks to:
For queries, feedback, or collaboration:
📩 waseem7861khan@gmail.com
⭐ If you found this helpful, please consider giving it a star!