Playground · recipes
Streaming intelligence recipes
Short, focused guides for common streaming intelligence patterns. Each recipe solves one problem with an interactive demo running real winkComposer nodes in your browser.
Change detection
Which approach fits depends on the signal. Gradual drift needs evidence accumulation — patience. Sudden shifts need immediate detection — speed. Subtle shifts need pattern recognition — sensitivity. Some real systems need all three.
Gradual Drift
Spot a signal that drifts slowly off its setpoint — invisible to threshold alarms, buried in noise. A fast/slow crossover surfaces the trend while Page-Hinkley accumulates evidence.
Open the recipeDirectional Trend
A signal slips by a tenth of a dB per sample — too small for magnitude alarms, too steady to read as noise. A Savitzky-Golay slope kernel turns the signal into its rate of change so the trend surfaces samples before the magnitude does.
Open the recipeSudden Shifts
Catch a signal that jumps to a new level. The Kalman filter fires when reality disagrees with its prediction — toggle between tracking the jump and rejecting it as an outlier.
Open the recipeSubtle Process Shifts
Find a process that creeps off-target — no single reading trips an alarm, but the pattern is non-random. Four Western Electric rules fire in sequence as the deviation grows.
Open the recipePID Loop Hunting
Catch a control loop oscillating around its setpoint before the actuator fails. winnow counts trajectory turning points, swStats turns events into a rate, and categorize grades the severity by frequency, not amplitude.
Open the recipeModel-vs-reality diagnostics
When a sensor reports what it sees but cannot see everything, the model-vs-reality gap becomes the diagnostic signal.
Signal quality
Sometimes the problem is not that the signal changed — it is that it stopped changing. A frozen sensor reports stale data that looks perfectly valid to every other check.
Subsampling & compression
The opposite of detection: deciding which samples are not worth keeping. A high-rate sensor stream is mostly redundant — the trick is identifying the informative samples and dropping the rest without losing what matters. Read the deadband recipe first for the adaptive-gate pattern; the trajectory-aware recipe then adds a Kalman predictor and boundary anchoring for when reconstruction quality matters.
Subsampling Noisy Signals with a Deadband
Build an adaptive gate that concentrates samples on events and drops the quiet-region redundancy. A running stats node sets a breathing threshold; passIf keeps the samples that depart from the noise floor.
Open the recipeTrajectory-Aware Adaptive Compression
When reconstruction quality matters, add a model. A Kalman predictor and trajectory-aware winnow gate anchor each kept sample to its boundary, cutting max error by 3–4× over the deadband.
Open the recipe