Best way to visualize real-time sensor data in Bokeh?

Hi everyone, I’m trying to build a Bokeh dashboard that updates in near-real-time from IoT sensor data (e.g., readings from temperature or motion detectors), and I’m curious what the best integration pattern is for those frequent updates without overwhelming the server or client. For context, I’ve been looking at this ESP32 motion-detection project https://www.theengineeringprojects.com/2022/03/iot-based-motion-detection-with-email-alert-using-esp32.html which shows how an ESP32 sends sensor data via HTTP, and it made me think about ingesting and streaming that into Bokeh.

I’ve also seen Arduino forum threads and Raspberry Pi community projects where people push sensor values via REST or MQTT into dashboards or databases. For those who’ve done something similar, should I be using websockets, periodic callbacks with server pushed patches, or another pattern for smooth real-time updates in Bokeh? Any examples or pitfalls to watch out for would be greatly appreciated!