Design a distributed demand-response control system for a power grid. A grid operator provides an event containing a target cohort, a requested load reduction such as 20%, a start time, and a duration. The system is responsible for translating that target into commands for millions of smart devices such as air conditioners, water heaters, EV chargers, and thermostats. Forecasting grid demand and deciding when curtailment should happen are out of scope.
A typical event targets approximately 5M devices out…