This project is a Flask-based web application for predicting customer churn using a machine learning model. It allows users to input customer data and receive predictions on whether a customer is likely to churn.
- Web interface for customer data input
- Machine learning model for churn prediction
- Configurable model and preprocessor paths
- Easy deployment and local development
.
├── app.py
├── artifacts/
│ ├── model.pkl
│ ├── preprocessor.pkl
│ └── top_features.json
├── requirements.txt
├── .env
├── .gitignore
└── README.md
- Python 3.7+
- pip
-
Clone the repository:
git clone https://github.com/004Gaurav/Customer_Churn.git cd Customer_Churn
-
Create a virtual environment and activate it:
python -m venv venv venv\Scripts\activate
-
Install dependencies:
pip install -r requirements.txt
-
Configure environment variables:
- Edit the
.env
file as needed.
- Edit the
-
Add model artifacts:
- Place your
model.pkl
,preprocessor.pkl
, andtop_features.json
in theartifacts/
directory.
- Place your
flask run
The app will be available at http://localhost:5000.
- All configuration is managed via the
.env
file. - Model and preprocessor paths can be changed as needed.
This project is licensed under the MIT License.