10 - production ML and the model lifecycle

DATA
  ↓
validation
  ↓
TRAIN
  ↓
evaluate
  ↓
good enough?
  ↓
MODEL
  ↓
register
  ↓
deploy
  ↓
inference
  ↓
monitor
  ↓
performance degraded?
  ↓
retrain
  │
  └───────────────↺
registry

  • a centralised store for managing versioned assets like models or datasets

DetectorFailureModel

├── Version 1
│ ├── F1 = 0.89
│ ├── training run 143
│ └── created June 3

├── Version 2
│ ├── F1 = 0.92
│ ├── training run 217
│ └── created July 14

└── Version 3
├── F1 = 0.94
├── training run 391
└── created August 20
```

lineage

  • the tracked history showing the exact data, code, and parameters used to create them

Production model v17
	│
	├── training run 8342
	│
	├── Git commit a8f21...
	│
	├── dataset v42
	│
	├── environment v8
	│
	├── hyperparameters
	│
	└── evaluation metrics
deployment

making a validated model available in an environment where it can actually perform its intended job

Registered model v17
	↓
deployment
	↓
production environment
	↓
real data
	↓
predictions
inference

  • the execution phase where the trained, frozen model applies training knowledge to generate real-time predictions on new data

training: Dtrainθinference: xnewf(x,θ)y^
data drift

  • the change in the statistical properties or distribution (P(X)) of the input data over time after deployment

concept drift

  • the change in the statistical relationship ((P(X|Y)) between the input features and the darget variable over time

ground-truth feedback

  • the process of comparing machine learning or AI model predictions against verified, real-world data labels to measure accuracy and guide model improvements

retraining