Machine learning with football · Chapter 11

Production ML systems

A model is the small box in the middle. Everything around it, from data feeds to monitoring, is where most of the work goes.

Estimated time: 5 minutes · page 1 of 8

The small box in the middle

Everything in this course so far happened inside the model. In a real system the model is often 5% of the code or less. Around it sit data collection, checks on the data, feature extraction, configuration, scheduling, serving, monitoring and the machines everything runs on.

This site is a small example, and the board draws it. An updater runs around the clock. It fetches live scores and tables every minute, betting prices every 10 minutes and news every 30, and rebuilds the fixture lists at night. Each job stops after 15 minutes if it hangs, and a failing job sends an alert, at most every six hours. The tables, team stats and player stats on every page are built from that, and the course's own boards read the same data through the site's public API. The models are a few hundred lines in all of that.

This chapter is about the rest: when to retrain, when to predict, where to transform data, how to test before going live, what to watch afterwards, and which questions to ask about any model before you trust it.

Check yourself

In a production machine learning system, how big is the model code compared with everything else?

Leagues