A machine learning service as part of the MAIO course that helps predict diabetes progression to determind it the patients need follow-up care.
python src/train.pyfastapi dev .\src\main.pyPOST /predict
curl --location --request POST 'http://127.0.0.1:8000/predict' \
--header 'Content-Type: application/json' \
--data-raw '{"age": 0.02, "sex": -0.044, "bmi": 0.06, "bp": -0.03, "s1": -0.02, "s2": 0.03, "s3": -0.02, "s4": 0.02, "s5": 0.02, "s6": -0.001}'Returns:
{ "prediction": "123" }GET /health
curl --location --request GET 'http://127.0.0.1:8000/health' \
--header 'Content-Type: application/json'Returns:
{ "status": "ok", "model_version": "v0.1" }Build:
docker build -t diabetes-triage-ml:v0.1 .Run:
docker run -p 8000:8000 diabetes-triage-ml:v0.1