How Prime Video distills time series anomalies into actionable alarms

Kurt Cutajar, Hanting Xie18 Nov 2022

Problem

Prime Video must stream reliably on many device types, with code and integrations that differ by region and device family. Writing alarms by hand for every combination of customer activity, device type and region is infeasible, so the team runs automated time-series anomaly detection on all of them. The detector also flags traffic drops when viewers are simply watching something else, such as a major football match. Each false alarm alerts an on-call engineer and distracts them from real customer problems.

Example from the article: a series shows two deviations from expected traffic. The first is lower viewership during an external event. The second is a software malfunction that engineers can fix. Without context the two look alike.

Solution in brief

Split the non-fault deviations ("special events") into three types and give each its own remedy. Scheduled events become model covariates. Unscheduled mild events are filtered by an ensemble of complementary detectors. Sudden large events are checked against unrelated metrics in the same region.

Questions this case answers
  • How to separate benign deviations caused by external events from real faults when monitoring a very large number of time series with an automated anomaly detector
  • How to stop false alarms when traffic metrics dip or spike because of external events and not software faults?
  • How to monitor thousands of metric series split by activity, device and region without writing alarms by hand?
  • How to tell a real outage from a drop caused by a news broadcast or a natural disaster?

Tools and methods

  • Forecasting-based anomaly detection — compares observed traffic with a forecast and scores the gap
  • Covariates (exogenous variables) — a binary event schedule fed to the forecaster
  • Derivative- and correlation-based detectors — extra scorers that react to change in trend and not only to the size of the gap
  • Cross-metric correlation check — verifies a drop against metrics from other technology stacks in the same region
Continue reading — it's free

Google or a one-time email code. No password.