βοΈ Disclaimer: Echo is an educational AI tool. It does not replace professional medical advice, diagnosis, or treatment. Always consult a qualified healthcare provider.
Echo is a desktop AI health assistant built with Python and Tkinter that helps users identify possible health conditions based on their symptoms using fuzzy logic matching. It provides personalised medication guides, diet plans, and tracks your session history β all from a clean, dark-themed GUI powered by CSV datasets.
User enters symptoms β FuzzyWuzzy AI matches β Top diseases ranked by confidence
β β
Session logged β Diet Plan loaded β Medications displayed
|
|
|
|
π¦ echo_health_assistant/
β
βββ π main.py β Entry point β run this
βββ π₯οΈ app.py β Main Tkinter GUI (4 tabs)
βββ π§ symptom_engine.py β FuzzyWuzzy matching logic
βββ πΎ health_tracker.py β Medication & diet + history
βββ π¨ ui_components.py β Custom dark-theme widgets
βββ π requirements.txt
β
βββ π data/
βββ ποΈ symptoms.csv β 20 diseases Γ 6 symptoms each
βββ π medications.csv β 3 meds + dosages per disease
βββ π₯ diet_plans.csv β Full diet + supplement plans
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β π Echo β Personal AI Health Assistant [FuzzyWuzzy AI] β
ββββββββββββββββββββ¬βββββββββββββββββ¬ββββββββββββ¬ββββββββββββββββββ€
β π Symptom β π Medications β π₯ Diet β π History β
β Checker β Guide β Plans β β
ββββββββββββββββββββ΄βββββββββββββββββ΄ββββββββββββ΄ββββββββββββββββββ€
β β
β βββββββββββββββββββββββ ββββββββββββββββββββββββββββββββββββ β
β β Describe Symptoms β β Analysis Results β β
β β βββββββββββββββββββ β β #1 ββββββββββββββββ 87.4% β β
β β β headache, fever,β β β #2 ββββββββββββββββ 61.2% β β
β β β nausea... β β β #3 ββββββββββββββββ 43.8% β β
β β βββββββββββββββββββ β β β β
β β Sensitivity: [60%] β β π Most Likely: Influenza β β
β β [π Analyze] [β] β β Confidence: 87.4% β β
β βββββββββββββββββββββββ ββββββββββββββββββββββββββββββββββββ β
β β
β βοΈ Not a substitute for professional medical advice β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
βββββββββββββββββββββββββββββββ
β User Input (raw text) β
β "headache, fevr, nausea" β
ββββββββββββββββ¬βββββββββββββββ
β
ββββββββββββββββΌβββββββββββββββ
β Tokenize & Normalize β
β Split by comma / newline β
ββββββββββββββββ¬βββββββββββββββ
β
ββββββββββββββββΌβββββββββββββββ
β FuzzyWuzzy Matching β
β token_sort_ratio per sym β
β "fevr" β "fever" (94%) β
β "headach"β"headache"(91%) β
ββββββββββββββββ¬βββββββββββββββ
β
ββββββββββββββββΌβββββββββββββββ
β Disease Scoring Formula β
β β
β Score = (FuzzyQ Γ 0.6) β
β + (Coverage Γ 0.4) β
ββββββββββββββββ¬βββββββββββββββ
β
ββββββββββββββββΌβββββββββββββββ
β Top 5 Ranked Results β
β + Visual Confidence Bars β
βββββββββββββββββββββββββββββββ
- Python 3.8 or higher
- pip package manager
- Windows / macOS / Linux
# 1οΈβ£ Navigate to project folder
cd echo_health_assistant
# 2οΈβ£ Create a virtual environment
python -m venv venv
# 3οΈβ£ Activate venv
venv\Scripts\activate # Windows
source venv/bin/activate # Mac / Linux
# 4οΈβ£ Install dependencies
pip install fuzzywuzzy python-Levenshtein pandas Pillow
# 5οΈβ£ Launch Echo
python main.py| Package | Version | Purpose |
|---|---|---|
fuzzywuzzy |
0.18.0 | Fuzzy string matching for symptoms |
python-Levenshtein |
0.21.1 | Speeds up FuzzyWuzzy by 4β10Γ |
pandas |
2.1.4 | CSV dataset loading & querying |
Pillow |
10.2.0 | Image support for Tkinter |
tkinter |
built-in | GUI framework (no install needed) |
| π€§ Common Cold | π€ Influenza | π¦ COVID-19 | π€ Migraine |
| β€οΈ Hypertension | π¬ Diabetes Type 2 | π¨ Asthma | π©Έ Anemia |
| π« Gastritis | π° Anxiety Disorder | π Depression | π¦ UTI |
| 𦴠Arthritis | π¦ Thyroid Disorder | π¦ Dengue Fever | π« Pneumonia |
| π« IBS | π§΄ Eczema | π Sinusitis | πͺ¨ Kidney Stones |
- Fuzzy Matching: Uses
fuzz.token_sort_ratioβ handles typos, word-order variations, and partial matches perfectly for medical symptom text - Confidence Formula: Weighted blend: 60% fuzzy quality + 40% symptom coverage ratio β avoids false positives from single-symptom hits
- Threading: Symptom analysis runs on a background thread so the GUI stays fully responsive during processing
- CSV Architecture: All disease data in plain CSV β extend the dataset by simply adding rows, zero code changes required
- Rich Text Tags: Tkinter
Textwidget uses named tags (heading,success,warning) for coloured output β requiresforeground=notfg=intag_configure - Auto-fill Tabs: After analysis, Medications and Diet tabs automatically pre-load data for the top-matched disease
- Session Logging: Every symptom check is timestamped and stored in-memory, visible in the History tab
_tkinter.TclError: bitmap "#00D9C0" not defined
Root Cause: Tkinter's Text.tag_configure() does not accept fg= β it requires foreground=
# β WRONG β causes TclError on all platforms
self.text.tag_configure("heading", fg="#00D9C0", font=...)
# β
CORRECT β use foreground= for Text widget tags
self.text.tag_configure("heading", foreground="#00D9C0", font=...)This fix is already applied in the latest ui_components.py.
βββββββββββββββ ββββββββββββββββββββ ββββββββββββββββββββββ
β main.py ββββββΆβ EchoApp() ββββββΆβ 4 Notebook Tabs β
β Entry Pointβ β app.py β β Symptom / Med / β
βββββββββββββββ ββββββββββ¬ββββββββββ β Diet / History β
β ββββββββββββββββββββββ
ββββββββββββββββΌβββββββββββββββ
βΌ βΌ βΌ
ββββββββββββββββ ββββββββββββββββ ββββββββββββββββββββββββ
β symptom_ β β health_ β β ui_components.py β
β engine.py β β tracker.py β β CardFrame β
β β β β β EchoButton β
β FuzzyWuzzy β β Medications β β ScrollText β
β Scoring β β Diet Plans β β ConfidenceBar β
β Ranking β β History Log β β TagEntry / Badge β
ββββββββ¬ββββββββ ββββββββ¬ββββββββ ββββββββββββββββββββββββ
β β
ββββββββββ¬βββββββββ
βΌ
βββββββββββββββββββββββ
β data/ β
β symptoms.csv β
β medications.csv β
β diet_plans.csv β
βββββββββββββββββββββββ
- Fork the repository
- Branch:
git checkout -b feature/add-more-diseases - Extend CSV files with new diseases
- Commit:
git commit -m "Add 10 more diseases to dataset" - Open a Pull Request
- More diseases & symptoms in CSV
- BMI / vitals calculator tab
- PDF report export
- Voice symptom input
- Real medical API integration (e.g. OpenFDA)
This project is licensed under the MIT License β free to use, modify, and distribute.