CloudSketch AI Logo
FeaturesTemplatesPricingEnterpriseAboutContactLog in
πŸŒ™β˜€οΈ
Log inStart free
Home/Templates/AI & Machine Learning

🧠 AI & Machine Learning · State Machine

ML Model Lifecycle

The states a machine learning model moves through, from experiment to production to retirement, including rollback when live performance drops.

More AI & Machine Learning templates

Opening a template is free and never counts toward your daily diagrams. Asking the AI to change it counts as one.

Drawing diagram…

What this diagram shows

  • Nothing reaches production without validation and approval
  • Shadow mode tests a model on live traffic without affecting users
  • Drift in live data sends the model back for retraining

Prompt used

State machine for an ML model: Experiment, Trained, Validated (passes metric thresholds), Approved, Shadow (runs on live traffic without serving answers), Production, Degraded when drift is detected, then Retraining, and Retired when replaced. A failed validation goes back to Experiment and a bad shadow result is rejected.

Mermaid code
stateDiagram-v2
  [*] --> Experiment
  Experiment --> Trained: Training run finished
  Trained --> Validated: Metrics above threshold
  Trained --> Experiment: Metrics too low
  Validated --> Approved: Reviewer sign-off
  Approved --> Shadow: Deploy without serving
  Shadow --> Production: Live results match
  Shadow --> Rejected: Live results worse
  Production --> Degraded: Data drift detected
  Degraded --> Retraining
  Retraining --> Trained
  Production --> Retired: Replaced by new version
  Rejected --> [*]
  Retired --> [*]

Inside this diagram

A state diagram with 10 states and 11 transitions.

States

  • Experiment
  • Trained
  • Validated
  • Approved
  • Shadow
  • Production
  • Rejected
  • Degraded
  • Retraining
  • Retired

Starts in

  • Experiment

Ends in

  • Rejected
  • Retired

Transitions

  • Experiment β†’ Trained when Training run finished
  • Trained β†’ Validated when Metrics above threshold
  • Trained β†’ Experiment when Metrics too low
  • Validated β†’ Approved when Reviewer sign-off
  • Approved β†’ Shadow when Deploy without serving
  • Shadow β†’ Production when Live results match
  • Shadow β†’ Rejected when Live results worse
  • Production β†’ Degraded when Data drift detected
  • Degraded β†’ Retraining
  • Retraining β†’ Trained
  • Production β†’ Retired when Replaced by new version

Make your own diagram like this

Describe your own system in plain English and CloudSketch AI draws it in seconds. See all AI diagram generators.

Related templates

C4 ArchitectureProAI & Machine Learning

RAG Chatbot over Company Documents

A chatbot that answers staff questions from company documents: documents are split and indexed in a vector database, and each question pulls the most relevant passages before the language model writes an answer.

SequenceAI & Machine Learning

RAG Question Answering Sequence

What happens when a user asks the document chatbot a question: permission check, embedding, vector search, prompt building and a cited answer.

Data FlowAI & Machine Learning

Document Ingestion for Vector Search

How documents become searchable passages for an AI assistant: extraction, cleaning, chunking, embedding and indexing, with changed files re-processed automatically.

FlowchartAI & Machine Learning

AI Agent Tool-Use Workflow

How an AI agent completes a task by planning, calling tools, checking results and asking a person to approve risky actions before it finishes.

DeploymentProAI & Machine Learning

MLOps Model Training Pipeline

Where each part of an MLOps setup runs: feature store, training jobs on GPU nodes, experiment tracking, model registry and automated deployment to serving.

C4 ArchitectureProAI & Machine Learning

LLM Gateway with Cost and Safety Controls

One gateway that every app in a company uses to reach language models: it applies budgets, rate limits, content filters and caching, and records usage per team.