The rule engine sends an admin's plain-English input to the OpenAI API, which generates executable JavaScript handlers from the description. Those handlers run inside a vm2 sandbox on Node.js, so AI-generated code executes without touching the rest of the app. It works like a locked box: code runs inside, nothing escapes. Rules chain in order and trigger status changes, alerts, and display actions. Getting output consistent enough to run in production without malformed handlers took real iteration, the careful side of AI integration.