How senbenz/test_inference-images works
iris-docker is a small Iris classification service. Its workflow trains a Random Forest model, saves it as a joblib artifact, and serves single-sample and batch predictions through FastAPI; the single-prediction route also increments a Redis counter, which a separate route reads. The README documents local and Docker-based operation, but the Docker configuration was not sampled, so deployment details and wiring are omitted.
Main entry points: train.py Model trainer · serve.py FastAPI service
Components 11
Model training
- Model trainer
train.py - Joblib model
Inference API
- FastAPI service
serve.py - Single prediction
serve.py - Batch prediction
serve.py - Health check
serve.py
Request state
- Counter route
serve.py - Redis counter
Other components
- Operator
- Iris dataset
- API client
Connections 10
- Operator → Model trainer: runs training
README.md - Model trainer → Iris dataset: loads dataset
train.py - Model trainer → Joblib model: saves model
train.py - Operator → FastAPI service: starts service
README.md - FastAPI service → Joblib model: loads model
serve.py - API client → Single prediction: requests prediction
serve.py - API client → Batch prediction: requests predictions
serve.py - API client → Health check: checks health
serve.py - Single prediction → Redis counter: increments counter
serve.py - Counter route → Redis counter: reads counter
serve.py