We’ve all been there. You sneeze twice, Google your signs, and instantly you’re spiraling right into a WebMD rabbit gap that ends with uncommon jungle illnesses. That’s precisely why I constructed SymptoCare — your pleasant AI-powered well being detective.
SymptoCare is a web-based app that mixes machine studying with conversational AI to assist customers:
- Perceive their signs and doable situations
- Get psychological wellness assist from an empathetic chatbot
- Discover preliminary actions earlier than seeing a physician
Whether or not you’re feeling off bodily or mentally, SymptoCare offers you a place to begin with kindness and readability.
SymptoCare runs on a versatile and trendy stack:
- Frontend: React.js with Context API and Styled Parts
- Backend: Flask (Python), exposing prediction and chat endpoints
- Machine Studying: Customized-trained fashions utilizing scikit-learn for illness and final result prediction (pickled as
outcome_model.pkl
anddisease_model.pkl
) - LLM Agent: OpenAI’s ChatGPT or Google Gemini with a selectable interface
SymptoCare’s ML fashions analyze structured well being knowledge corresponding to:
- Fever, cough, fatigue
- Respiratory problem
- Blood stress and ldl cholesterol
- Age and gender
When you enter your signs, the ML pipeline first checks in case your situation is probably going severe, after which predicts a doable illness. All that is powered by scikit-learn classifiers and served by way of a Flask API returning real-time JSON responses to the frontend.
To assemble the ML pipeline, I developed the whole workflow in a Jupyter Pocket book. Right here’s the precise breakdown of the method from the prototype file:
- Knowledge Assortment: I used a customized CSV dataset (
combined_datasets.csv
) that merges affected person demographic information (age, gender) with scientific options (fever, cough, blood stress, and so on.) and related illness/final result labels. - Preprocessing & Cleansing:
Renamed columns for readability and consistency
Verified lacking/null values and cleaned inconsistent label formatting
Encoded categorical fields (e.g., gender) utilizing
LabelEncoder
Checked correlation heatmaps to get rid of irrelevant or extremely collinear options
Maintained 8–10 clinically related predictors for prototyping simplicity
Used Logistic Regression from
scikit-learn
to construct two classifiers:— — — — — — Final result Mannequin (predict if the person is prone to have a severe final result)
— — — — — — Illness Mannequin (predict the most probably illness if the result is optimistic)
Cut up the information utilizing an 80:20 train-test technique
Achieved round 91% accuracy on validation because of clear options and restricted class imbalance
Serialized educated fashions utilizing
pickle
Built-in them with Flask API endpoints (
/predict
) for real-time use by the frontend
This clear, testable, and modular method permits for straightforward future growth and tuning.
Psychological well being is simply as necessary. SymptoCare features a Thoughts-Bot chat interface the place customers can speak freely and get supportive, conversational replies. Whether or not you’re feeling unhappy, anxious, or simply want somebody to speak to, the bot responds with empathy and might information you towards actual assist sources.
🔄 Switching Between ChatGPT and Gemini
Customers can select between:
- ✨ ChatGPT (OpenAI): Identified for conversational finesse
- 💡 Gemini (Google): Quick, structured, and highly effective
That is dealt with by a easy dropdown UI and handed to the /chat
endpoint within the backend.
The Seek the advice of Physician module enables you to discover profiles of specialist medical doctors and e book time slots based mostly on availability. Knowledge is managed utilizing Firebase Firestore. It’s an awesome step towards integrating actual supplier networks sooner or later — however even with mock knowledge, the expertise is clean and significant.
Think about this:
- You’re feeling fatigued and have a gentle fever.
- You enter signs into SymptoCare.
- The mannequin suggests doable outcomes (e.g., viral flu).
- The chatbot provides care recommendation and even psychological assist.
- You verify close by medical doctors, decide a time slot, and e book.
It’s like having a digital pal who’s good with knowledge and sort with phrases.
- Firebase integration for real-world physician databases
- Speech-to-text for symptom entry
- Consumer login & historical past monitoring
- Extra customized suggestions utilizing person profiles
- Deploying on cellular by way of React Native
This mission means quite a bit to me. It’s a small step towards utilizing AI not only for automation, however for empathy. Whether or not you’re feeling bodily unwell or simply want a digital nudge of assist, SymptoCare is right here to assist.
Attempt it, break it, and inform me what you suppose. Suggestions welcome, humor inspired, and contributions much more so!