This project is a submission for the MODE-LX hackathon. The goal is to build a binary classification model that predicts a person's risk of dementia using only non-medical variables.
This solution is built as a reproducible pipeline that automates data preprocessing, model training, and evaluation, and includes a script to run live predictions from user input.
- Best Model:
LightGBM - Test Set PR AUC (Primary Metric):
0.560 - Test Set ROC AUC:
0.734 - Top Predictors:
NACCAGE(Age),EDUC(Years of Education), andSMOKYRS(Total Years Smoked) were identified as the most important predictive features.
- Data Analysis & Manipulation:
pandas,numpy - Data Visualization:
matplotlib,seaborn - Preprocessing & Modeling:
scikit-learn,lightgbm - Notebooks:
jupyter - Model Serialization:
pickle
DimensiaRiskAi/
│
├── data/
│ ├── raw/
│ │ ├── dataset.csv (Not in repo - Must be added manually)
│ ├── processed/ (Ignored by git)
│ │ ├── X_train_processed.npy
│ │ ├── y_train.csv
│ │ └── ...
│
├── models/
│ ├── LightGBM.pkl
│ ├── RandomForest.pkl
│ └── ...
│
├── notebooks/ (Original development notebooks)
│ ├── 01_eda.ipynb
│ ├── 02_preprocessing.ipynb
│ ├── 03_modeling.ipynb
│ └── 04_evaluation.ipynb
│
├── report/
│ ├── figures/
│ │ ├── model_comparison.png
│ │ ├── feature_importance.png
│ │ └── ...
│
├── src/ (Source code for the pipeline)
│ ├── preprocessing.py
│ ├── train.py
│ ├── evaluation.py
│ ├── predict.py (Run this for a new prediction)
│ ├── main.py (Run this to train everything)
│ └── utils.py
│
├── .gitignore
├── README.md (This file)
└── requirements.txt (Generated by 'pip freeze')- Clone the repository:
git clone https://github.com/vidun-upek/DementiaInsight.git cd DementiaInsight # Locate it in the vs code
- Create a virtual environment:
python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate
- Install the required packages:
(You will need to create a
requirements.txtfile withpandas,numpy,scikit-learn,lightgbm,matplotlib,seaborn)pip install -r requirements.txt
This will run all steps: data preprocessing, model training, and evaluation. Figures will be saved to report/figures/.
python src/main.py
After running the main pipeline, you can use the predict.py script to get a new prediction from the command line.
python src/predict.py
The script will prompt you for the 8 non-medical features.
- Pr_curve_Comaprison
2. Model_comparison
3. Feature_importance
4. Roc_curve_comparison

