Serve the model that you trained in Machine Learning to real users. Package it with its contract, choose batch, online or asynchronous serving, build and measure the prediction service, and release a new version with a tested way back.
Read every lesson as a guest, or sign in to enroll and track your progress.
Enroll to save the lessons that you complete. It is free.
To get your certificate, mark every knowledge check as matching. These lessons have checks to finish:
What you'll learn
By the end of this course, you will be able to:
Package training artifacts with inference contracts.
Choose batch or online serving.
Measure prediction latency and capacity.
Release and roll back model versions safely.
About this course
A trained model is a file. It helps nobody until another program can send it a ticket, a loan application or a patient record and get an answer back: fast enough, every time, and the same answer that the model gave in training. That last step is called serving, and it is where many good models fail.
In this course, you serve the ticket escalation model that you trained in Machine Learning: From Problem to Reliable Model. First you write down exactly what the model accepts and returns, and you package it so that nothing can change it on the way. Then you choose how predictions should reach the help desk: a nightly file, an answer to each new ticket, or a job that runs in the background.
You build the prediction service with FastAPI, the same way as the API in Build and Deploy Your First API, and you prove that it gives the same scores as training. You put it in a container with CPU and memory limits, and you measure how fast it answers and how many requests it can take. Then you release a new model version. First it runs in shadow, where it scores real tickets but nobody sees its answers, and you decide with evidence whether it may go live. When a faulty version gets through, you roll back and check that everything works again.
Every number in the lessons was measured on a real run, and every lesson shows a common mistake: what you see, why it happens and how to recover. Diagrams and interactive charts carry the main ideas, so the text stays short.
Before you start
You completed Machine Learning, Build and Deploy Your First API, and Docker and Cloud Essentials for AI Developers, or you can already train a scikit-learn pipeline and save it, build a FastAPI service with tests, and build and run a container image with Docker Compose. You do not need a GPU or a cloud account; every exercise runs on your computer.
People who trained a model, as in Machine Learning, and built and containerized an API, as in Build and Deploy Your First API and Docker and Cloud Essentials. A model helps nobody until a program can ask it for a prediction, safely and fast enough. This course closes that gap.
How we made this course
Experienced AI practitioners designed this course. AI helped us draft the content; people chose the teaching approach and the examples, and reviewed every lesson. The outputs that you see are the actual results of running the code. How we make our courses
Inside the course
Module 1Define the inference contract
3 lessons
Write the inference contract that says exactly what the model accepts and returns. Then bundle the model with its preprocessing, metadata and tested versions, and load it only after a hash check proves that it is the file you expect.
Choose how predictions reach the people who use them. Score a whole file on a schedule, answer one request at a time within a time budget, or accept a large job now and return the result later, and plan what to do when each one fails.
Build the prediction service. Load the model once at start-up, answer validated requests with the model version in every answer, and prove with parity tests that the service gives the same scores as training.
Choose where the model runs, then measure it. You compare CPU, GPU and managed endpoints, set CPU, memory and worker limits for the container, and benchmark cold and warm latency, p50 and p95 and throughput.
Release a new model version safely. Run it in shadow next to the live model and decide with evidence, watch the model's health signals, and when a faulty version gets through, roll back to the known-good one and check the contract again.
Three end-to-end case studies on real data, as projects that you download and run in VS Code. Score credit default in batch and online, release a new house-price model, and score hospital readmissions with queued jobs. Complete at least one for the certificate; each one is a portfolio piece.
Complete at least one case study for the certificate. The others are optional. What each one covers
Realistic projects from start to finish, on real data, with every output explained. Each one makes a portfolio piece. Complete at least one for the certificate; the others are optional.
Release a retrained house-price model behind the house-price API from the API course: shadow it, compare it on real traffic, promote it, and roll it back.