Model Registry, MLflow, and prompt versioning

Lesson 3 of 4 in MLOps Pipelines: CI/CD for Models.

A pipeline can only roll back to things that have versions, and C02 extends the versioning question across the whole GenAI stack: models, containers, and prompts. The spine is the SageMaker Model Registry: a model package group per problem, a numbered model package per candidate (artifact + inference image + metrics + lineage), and an approval status — PendingManualApproval → Approved or Rejected — whose flip is the classic deploy trigger.

Everything that changes needs a versioned home
ArtifactVersioned whereRollback means

Training/app code

Git, via CodeConnections (or legacy CodeCommit)

Revert the commit; the pipeline rebuilds

Container images

Amazon ECR — immutable tags / digests

Point the model back at the previous digest

Models

SageMaker Model Registry (or MLflow, mirrored into it)

Deploy the previous Approved package

Prompts

Bedrock Prompt Management — numbered versions behind an ARN

Reference the previous prompt version

Fine-tuned FMs

Bedrock custom/imported models as named resources; SageMaker fine-tunes as registry packages

Invoke the previous model resource

Model Registry mechanics worth memorizing

Register from a pipeline step or SDK; each package carries the inference spec (image + artifact), evaluation metrics, and lineage. Approval-status changes emit EventBridge events — wiring "Approved → deploy pipeline runs" is the canonical MLOps pattern.

MLflow on SageMaker AI

SageMaker AI runs managed MLflow tracking servers — experiments, runs, and the MLflow Model Registry with its open-source API. The integration detail exams like: models registered in MLflow can auto-register into the SageMaker Model Registry, so OSS-tooling teams still land in the same deploy flow.

Prompt Management, and testing prompts like code

Bedrock Prompt Management stores prompts with variants (compare wordings/models side by side) and versions — immutable snapshots applications reference by ARN + version. Pipeline-grade prompt work means evaluating a candidate prompt version against a test set before repointing production, exactly like a model quality gate.

Interactive checkpoint quiz (2 questions) — open this page in a browser to take it.