IoT and AI
AIoT, the combination of the Internet of Things and artificial intelligence, is the practice of running machine-learned models on, or close to, networked sensors and devices so that raw physical measurements are turned into decisions, alerts or compressed summaries where they are produced, rather than every sample being streamed to a data center. A thermostat that learns occupancy, a camera that counts people without uploading video, a vibration sensor that flags a failing bearing and a wake-word detector in a speaker all fit the pattern. The IoT supplies the sensing, connectivity and actuation, and the AI supplies the interpretation, and the pairing matters because physical data is high-volume, noisy, continuous and often private, while the devices producing it are small, battery-limited and cheap.
Edge inference is the core idea: execute a trained model on the device or a nearby gateway so that latency, bandwidth, privacy and offline operation are handled locally. Training usually still happens in the cloud on pooled data, and the result is shrunk for deployment using quantization (storing weights as 8-bit integers rather than 32-bit floats), pruning, knowledge distillation and architectures designed for efficiency such as MobileNet-style convolutions. A response time of milliseconds is possible because no network round trip is needed, an inspection line or a collision-avoidance system cannot wait for a cloud reply, and a device that never uploads raw audio or video exposes less sensitive data. A related approach, federated learning, introduced by McMahan and colleagues at Google in 2017 and used for keyboard prediction, trains a shared model from updates computed on devices without collecting the underlying data, although it reduces rather than eliminates privacy risk.
TinyML pushes the same idea down to microcontrollers with kilobytes of memory and milliwatts of power, which changes what kind of model is even possible. The term was popularized around 2019 by the book of Pete Warden and Daniel Situnayake and by the community that formed around the TinyML meetups, and the toolchain includes TensorFlow Lite for Microcontrollers, Edge Impulse and vendor libraries. Typical tasks are keyword spotting, simple anomaly detection on accelerometer or current data, gesture recognition and visual wake words (detecting whether a person is in view), using models whose size is measured in tens of kilobytes. The MLPerf Tiny benchmark, released in 2021 by the MLCommons community, measures accuracy, latency and energy on exactly these tasks. The constraint shapes design: there is no operating system to spare, no floating-point unit on many parts, and every kilobyte of RAM for activations is a budget line.
Sensor data pipelines are where most AIoT projects succeed or fail, because the model is the small part. Real signals drift as sensors age, differ between units, arrive with gaps and clock skew, and change with season and installation, so a pipeline must handle calibration, timestamping, buffering during outages, windowing, feature extraction and the return path for labeled edge cases. Monitoring for data drift is essential, since a model that was accurate on a lab bench can degrade silently in a factory. Over-the-air update capability is what makes the edge fleet maintainable, and it is also what makes it risky if updates are not authenticated. A frequent misconception is that edge AI means the cloud disappears; in practice the cloud still handles training, fleet management, aggregation and retraining, and the device handles the real-time decision.
Security is the sharpest pitfall, and the Mirai botnet of 2016 is the canonical lesson. Mirai scanned the internet for devices such as IP cameras and home routers that still used factory-default credentials, logged in using a short list of common username and password pairs, and enrolled them into a botnet used for distributed denial-of-service attacks. It was used in September 2016 against the security journalist Brian Krebs's site and the French host OVH, and on 21 October 2016 against the DNS provider Dyn, which disrupted access to many well-known websites. The source code was published online soon afterwards, spawning many variants, and the academic analysis "Understanding the Mirai Botnet" by Antonakakis and colleagues, presented at USENIX Security in 2017, documented its growth and behavior. The attack required no cleverness, only devices that were exposed, unpatched and unmonitored, and embedding AI in more such devices enlarges the surface unless secure boot, unique credentials, signed updates and network isolation are standard.
Adversarial and privacy risks are specific to the AI layer. A model on a device can be extracted by someone with physical access, fooled by adversarial inputs such as patterned stickers or inaudible audio perturbations, or poisoned through its retraining data, and a camera that processes video locally may still leak sensitive inferences through the metadata it uploads. Devices also have long lifetimes, which means a model and its firmware may need support for years after the vendor loses interest. Responsible practice treats the device as a small networked computer with a threat model, and keeps the model, data flow and update channel inside that model.
Read IoT and AI as moving judgment to where the measurement happens: edge inference and TinyML make sensors smarter and more private by shrinking models to fit the device, but a pipeline that cannot calibrate, update and defend itself, as Mirai showed, is a liability whatever its accuracy.